export type CreateApiTrustExchangeTrustCenterUpdateDeleteArgs = {update_uuid: string}; export type CreateApiTrustExchangeTrustCenterUpdateDeleteOptions = {baseUrl?: string | undefined, APIKeyInHeader?: string | undefined, fetch?: typeof fetch | undefined}; /** * Delete Trust Center update * * POST /trust_exchange/trust_center/update/delete */ export const createApiTrustExchangeTrustCenterUpdateDelete = async (args: CreateApiTrustExchangeTrustCenterUpdateDeleteArgs, options?: CreateApiTrustExchangeTrustCenterUpdateDeleteOptions) => { const {baseUrl = "https://cyber-risk.upguard.com/api/public", fetch: fetchFn = fetch, APIKeyInHeader} = options ?? {} const query = new URLSearchParams() const headers = new Headers() if (args.update_uuid != null) query.append("update_uuid", String(args.update_uuid)) if (APIKeyInHeader !== undefined) headers.set("Authorization", APIKeyInHeader) const url = `${baseUrl.replace(/\/+$/, '')}/trust_exchange/trust_center/update/delete${query.size > 0 ? `?${query}` : ''}` const res = await fetchFn(url, {method: "POST", headers}) if (!res.ok) throw new Error(`Request failed with status ${res.status}`, {cause: {status: res.status, body: await res.text()}}) return undefined };