import type { SeamActionAttemptFailedError, SeamActionAttemptTimeoutError, SeamHttpApiError, SeamHttpEndpointQueryPaths, SeamHttpEndpoints, SeamHttpInvalidInputError } from '@seamapi/http/connect';
import type { ActionAttempt } from '@seamapi/types/connect';
import { type UseQueryOptions, type UseQueryResult } from '@tanstack/react-query';
export type UseSeamQueryParameters<T extends SeamHttpEndpointQueryPaths> = Parameters<SeamHttpEndpoints[T]>[0];
export type UseSeamQueryResult<T extends SeamHttpEndpointQueryPaths> = UseQueryResult<QueryData<T>, QueryError<T>>;
export declare function useSeamQuery<T extends SeamHttpEndpointQueryPaths>(endpointPath: T, parameters?: UseSeamQueryParameters<T>, options?: Parameters<SeamHttpEndpoints[T]>[1] & QueryOptions<QueryData<T>, SeamHttpApiError>): UseSeamQueryResult<T>;
type QueryData<T extends SeamHttpEndpointQueryPaths> = Awaited<ReturnType<SeamHttpEndpoints[T]>>;
type QueryError<T extends SeamHttpEndpointQueryPaths> = Error | SeamHttpApiError | SeamHttpInvalidInputError | (QueryData<T> extends ActionAttempt ? SeamActionAttemptFailedError<QueryData<T>> | SeamActionAttemptTimeoutError<QueryData<T>> : never);
type QueryOptions<X, Y> = Omit<UseQueryOptions<X, Y>, 'queryKey' | 'queryFn'>;
export {};
