curl --request DELETE \
--url https://api.tryfuse.ai/api/v1/business/agents/{agentId} \
--header 'Authorization: Basic <encoded-value>'import requests
url = "https://api.tryfuse.ai/api/v1/business/agents/{agentId}"
headers = {"Authorization": "Basic <encoded-value>"}
response = requests.delete(url, headers=headers)
print(response.text)const options = {method: 'DELETE', headers: {Authorization: 'Basic <encoded-value>'}};
fetch('https://api.tryfuse.ai/api/v1/business/agents/{agentId}', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));{
"error": {
"code": "<string>",
"message": "<string>",
"param": "<string>",
"doc_url": "<string>",
"request_id": "<string>"
}
}{
"error": {
"code": "<string>",
"message": "<string>",
"param": "<string>",
"doc_url": "<string>",
"request_id": "<string>"
}
}{
"error": {
"code": "<string>",
"message": "<string>",
"param": "<string>",
"doc_url": "<string>",
"request_id": "<string>"
}
}{
"error": {
"code": "<string>",
"message": "<string>",
"param": "<string>",
"doc_url": "<string>",
"request_id": "<string>"
}
}{
"error": {
"code": "<string>",
"message": "<string>",
"param": "<string>",
"doc_url": "<string>",
"request_id": "<string>"
}
}{
"error": {
"code": "<string>",
"message": "<string>",
"param": "<string>",
"doc_url": "<string>",
"request_id": "<string>"
}
}{
"error": {
"code": "<string>",
"message": "<string>",
"param": "<string>",
"doc_url": "<string>",
"request_id": "<string>"
}
}{
"error": {
"code": "<string>",
"message": "<string>",
"param": "<string>",
"doc_url": "<string>",
"request_id": "<string>"
}
}{
"error": {
"code": "<string>",
"message": "<string>",
"param": "<string>",
"doc_url": "<string>",
"request_id": "<string>"
}
}Delete an agent (409 while a run is processing)
Deletes the agent and tears down the provider subscriptions behind it. The results list it built and the rows already delivered are KEPT — delete the list separately if you want them gone. Drafts delete immediately. An agent whose run is in progress (status: processing) answers 409 AGENT_PROCESSING; wait until it reads active or paused and retry. Nothing is refunded, and a deleted agent is not recoverable — duplicate it first if you may want it back. Answers 204 with no body.
Errors:
404AGENT_NOT_FOUND— No agent with this id belongs to the token owner. A deleted agent and another user’s agent answer identically.409AGENT_PROCESSING— A run is in progress (statusprocessing); the agent cannot be changed until it settles. Retry once it isactiveorpaused.422VALIDATION_FAILED— The request failed this endpoint’s own validation —paramnames the offending field andmessagesays why.429RATE_LIMITED— The agents bucket is exhausted: 30 requests per minute or 2,000 per day per token owner, shared by every /business/agents operation (a 429 raised by the agents service is relayed with this code too). Retry after theRetry-Afterheader.500UNEXPECTED_ERROR— The agents service failed (5xx, refused service credential, or a timeout after 60s) or the rate limiter was unavailable. Retry later; quoterequest_idto support.
Requires one of the following token scopes: agents.
curl --request DELETE \
--url https://api.tryfuse.ai/api/v1/business/agents/{agentId} \
--header 'Authorization: Basic <encoded-value>'import requests
url = "https://api.tryfuse.ai/api/v1/business/agents/{agentId}"
headers = {"Authorization": "Basic <encoded-value>"}
response = requests.delete(url, headers=headers)
print(response.text)const options = {method: 'DELETE', headers: {Authorization: 'Basic <encoded-value>'}};
fetch('https://api.tryfuse.ai/api/v1/business/agents/{agentId}', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));{
"error": {
"code": "<string>",
"message": "<string>",
"param": "<string>",
"doc_url": "<string>",
"request_id": "<string>"
}
}{
"error": {
"code": "<string>",
"message": "<string>",
"param": "<string>",
"doc_url": "<string>",
"request_id": "<string>"
}
}{
"error": {
"code": "<string>",
"message": "<string>",
"param": "<string>",
"doc_url": "<string>",
"request_id": "<string>"
}
}{
"error": {
"code": "<string>",
"message": "<string>",
"param": "<string>",
"doc_url": "<string>",
"request_id": "<string>"
}
}{
"error": {
"code": "<string>",
"message": "<string>",
"param": "<string>",
"doc_url": "<string>",
"request_id": "<string>"
}
}{
"error": {
"code": "<string>",
"message": "<string>",
"param": "<string>",
"doc_url": "<string>",
"request_id": "<string>"
}
}{
"error": {
"code": "<string>",
"message": "<string>",
"param": "<string>",
"doc_url": "<string>",
"request_id": "<string>"
}
}{
"error": {
"code": "<string>",
"message": "<string>",
"param": "<string>",
"doc_url": "<string>",
"request_id": "<string>"
}
}{
"error": {
"code": "<string>",
"message": "<string>",
"param": "<string>",
"doc_url": "<string>",
"request_id": "<string>"
}
}Authorizations
Your API token (af_…) as the Basic-auth username, with an empty password.
Path Parameters
The agent's id: a 24-character hex string — the id of an item from GET /business/agents, or the agent.id a create or duplicate returned.
Response
Deleted