export type DeleteApiRestApiV1ProjectsProjectIdSymbolMappingsSymbolMappingIdArgs = {projectId: string, symbolMappingId: number}; export type DeleteApiRestApiV1ProjectsProjectIdSymbolMappingsSymbolMappingIdOptions = {baseUrl?: string | undefined, ApiKeyAuth?: string | undefined, fetch?: typeof fetch | undefined}; /** * Delete a symbol mapping * * DELETE /rest/api/v1/projects/{projectId}/symbolMappings/{symbolMappingId} */ export const deleteApiRestApiV1ProjectsProjectIdSymbolMappingsSymbolMappingId = async (args: DeleteApiRestApiV1ProjectsProjectIdSymbolMappingsSymbolMappingIdArgs, options?: DeleteApiRestApiV1ProjectsProjectIdSymbolMappingsSymbolMappingIdOptions) => { const {baseUrl = "https://api.metacopier.io", fetch: fetchFn = fetch, ApiKeyAuth} = options ?? {} const query = new URLSearchParams() const headers = new Headers() if (ApiKeyAuth !== undefined) headers.set("X-API-KEY", ApiKeyAuth) const url = `${baseUrl.replace(/\/+$/, '')}/rest/api/v1/projects/${encodeURIComponent(String(args.projectId))}/symbolMappings/${encodeURIComponent(String(args.symbolMappingId))}${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 };