export type DeleteApiApiV3TesterGroupsTesterGroupIdContactsContactIdArgs = {tester_group_id: string, contact_id: string}; export type DeleteApiApiV3TesterGroupsTesterGroupIdContactsContactIdOptions = {baseUrl?: string | undefined, apiKey?: string | undefined, fetch?: typeof fetch | undefined}; /** * Delete contact from the tester group * * DELETE /api/v3/tester-groups/{tester_group_id}/contacts/{contact_id} */ export const deleteApiApiV3TesterGroupsTesterGroupIdContactsContactId = async (args: DeleteApiApiV3TesterGroupsTesterGroupIdContactsContactIdArgs, options?: DeleteApiApiV3TesterGroupsTesterGroupIdContactsContactIdOptions) => { const {baseUrl = "https://codemagic.io", fetch: fetchFn = fetch, apiKey} = options ?? {} const query = new URLSearchParams() const headers = new Headers() if (apiKey !== undefined) headers.set("x-auth-token", apiKey) const url = `${baseUrl.replace(/\/+$/, '')}/api/v3/tester-groups/${encodeURIComponent(String(args.tester_group_id))}/contacts/${encodeURIComponent(String(args.contact_id))}${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 };