export type DeleteApiApiGraphchainChainSdoIdAttributeBlobsBlobHashArgs = {chain: string, sdoId: string, attribute: string, blobHash: string};
export type DeleteApiApiGraphchainChainSdoIdAttributeBlobsBlobHashOptions = {baseUrl?: string | undefined, fetch?: typeof fetch | undefined};
/**
* Allowed user roles:
deletes a blob(s) from an SDO by attribute name and blob hash
*
* DELETE /api/graphchain/{chain}/{sdoId}/{attribute}/blobs/{blobHash}
*/
export const deleteApiApiGraphchainChainSdoIdAttributeBlobsBlobHash = async (args: DeleteApiApiGraphchainChainSdoIdAttributeBlobsBlobHashArgs, options?: DeleteApiApiGraphchainChainSdoIdAttributeBlobsBlobHashOptions) => {
const {baseUrl = "https://api.burstiq.com", fetch: fetchFn = fetch} = options ?? {}
const query = new URLSearchParams()
const headers = new Headers()
const url = `${baseUrl.replace(/\/+$/, '')}/api/graphchain/${encodeURIComponent(String(args.chain))}/${encodeURIComponent(String(args.sdoId))}/${encodeURIComponent(String(args.attribute))}/blobs/${encodeURIComponent(String(args.blobHash))}${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
};