import { Config } from '..'; export type APIRouteConfig = { /** @default process.env.KEYSTATIC_GITHUB_CLIENT_ID */ clientId?: string; /** @default process.env.KEYSTATIC_GITHUB_CLIENT_SECRET */ clientSecret?: string; /** @default process.env.KEYSTATIC_URL ?? process.env.NODE_ENV === 'development' ? 'http://localhost:3000' : error */ url?: string; /** @default process.env.KEYSTATIC_SECRET */ secret?: string; config: Config; }; type KeystaticRequest = { method: string; jsonBody: () => Promise; headers: Record; cookies: Record; query: Record; params: string[]; }; type KeystaticResponse = { kind: 'redirect'; headers?: Record; to: string; } | { kind: 'response'; status: number; headers?: Record; body: Uint8Array | string; }; export declare function createGenericApiRouteHandler(_config: APIRouteConfig): (req: KeystaticRequest) => Promise; export {};