export type DeleteApiOrganizationMemberArgs = {created_at?: unknown | undefined, user_id?: string | undefined, organization_id?: string | undefined, email?: unknown | undefined, organization_role?: unknown | undefined, Prefer?: ('return=representation' | 'return=minimal' | 'return=none') | undefined}; export type DeleteApiOrganizationMemberOptions = {baseUrl?: string | undefined, fetch?: typeof fetch | undefined}; /** * DELETE /organization_member */ export const deleteApiOrganizationMember = async (args: DeleteApiOrganizationMemberArgs, options?: DeleteApiOrganizationMemberOptions) => { const {baseUrl = "https://vnaabuozknwgxuvnfwjo.supabase.co:443", fetch: fetchFn = fetch} = options ?? {} const query = new URLSearchParams() const headers = new Headers() if (args.created_at != null) query.append("created_at", String(args.created_at)) if (args.user_id != null) query.append("user_id", String(args.user_id)) if (args.organization_id != null) query.append("organization_id", String(args.organization_id)) if (args.email != null) query.append("email", String(args.email)) if (args.organization_role != null) query.append("organization_role", String(args.organization_role)) if (args.Prefer != null) headers.set("Prefer", String(args.Prefer)) const url = `${baseUrl.replace(/\/+$/, '')}/organization_member${query.size > 0 ? `?${query}` : ''}` const res = await fetchFn(url, {method: "DELETE", headers}) if (!res.ok) throw new Error(`Request failed with status ${res.status}`, {cause: {status: res.status, body: await res.text()}}) return undefined };