export type HeadApiApiOnboardingPublicV1IntentsArgs = {'x-provider': string}; export type HeadApiApiOnboardingPublicV1IntentsOptions = {baseUrl?: string | undefined, fetch?: typeof fetch | undefined}; /** * HEAD /api/onboarding/public/v1/intents */ export const headApiApiOnboardingPublicV1Intents = async (args: HeadApiApiOnboardingPublicV1IntentsArgs, options?: HeadApiApiOnboardingPublicV1IntentsOptions) => { const {baseUrl = "https://api.complif.com", fetch: fetchFn = fetch} = options ?? {} const query = new URLSearchParams() const headers = new Headers() if (args['x-provider'] != null) headers.set("x-provider", String(args['x-provider'])) const url = `${baseUrl.replace(/\/+$/, '')}/api/onboarding/public/v1/intents${query.size > 0 ? `?${query}` : ''}` const res = await fetchFn(url, {method: "HEAD", headers}) if (!res.ok) throw new Error(`Request failed with status ${res.status}`, {cause: {status: res.status, body: await res.text()}}) return undefined };