export type DeleteApiApiClubSpecDeletionClubCodeClubSpecIdDeletedArgs = {clubCode: string, clubSpecId: number, deleted: boolean}; export type DeleteApiApiClubSpecDeletionClubCodeClubSpecIdDeletedOptions = {baseUrl: string, fetch?: typeof fetch | undefined}; /** * changeDeletion * * DELETE /api/club-spec/deletion/{clubCode}/{clubSpecId}/{deleted} */ export const deleteApiApiClubSpecDeletionClubCodeClubSpecIdDeleted = async (args: DeleteApiApiClubSpecDeletionClubCodeClubSpecIdDeletedArgs, options: DeleteApiApiClubSpecDeletionClubCodeClubSpecIdDeletedOptions) => { const {baseUrl, fetch: fetchFn = fetch} = options ?? {} const query = new URLSearchParams() const headers = new Headers() headers.set('accept', "*/*") const url = `${baseUrl.replace(/\/+$/, '')}/api/club-spec/deletion/${encodeURIComponent(String(args.clubCode))}/${encodeURIComponent(String(args.clubSpecId))}/${encodeURIComponent(String(args.deleted))}${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 res.blob() };