import type { ClerkAPIError } from '@clerk/types';
export type ClerkBackendApiRequestOptions = {
    method: 'GET' | 'POST' | 'PATCH' | 'DELETE' | 'PUT';
    queryParams?: Record<string, unknown>;
    headerParams?: Record<string, string>;
    bodyParams?: object;
    formData?: FormData;
} & ({
    url: string;
    path?: string;
} | {
    url?: string;
    path: string;
});
export type ClerkBackendApiResponse<T> = {
    data: T;
    errors: null;
    totalCount?: number;
} | {
    data: null;
    errors: ClerkAPIError[];
    totalCount?: never;
    clerkTraceId?: string;
    status?: number;
    statusText?: string;
};
export type RequestFunction = ReturnType<typeof buildRequest>;
type BuildRequestOptions = {
    secretKey?: string;
    apiUrl?: string;
    apiVersion?: string;
    userAgent?: string;
};
export declare function buildRequest(options: BuildRequestOptions): LegacyRequestFunction;
type LegacyRequestFunction = <T>(requestOptions: ClerkBackendApiRequestOptions) => Promise<T>;
export {};
//# sourceMappingURL=request.d.ts.map