Creating & deleting
Standing an agent up from code, and taking one down without losing it.
Creating one
POST /v1/agents with a name (2–80 characters) and, optionally, a description (up to 500).
curl -X POST https://api.tigerbase.cloud/v1/agents \
-H "Authorization: Bearer $TIGERBASE_KEY" \
-H "Content-Type: application/json" \
-d '{"name":"Returns Desk","description":"Answers questions about returns and refunds."}'{
"publicId": "a1b2c3d4…",
"name": "Returns Desk",
"isActive": true,
"createdAt": "2026-10-31T10:02:17.000Z",
"apiSecret": "…"
}The agent exists immediately and is empty: no documents, no capabilities, default appearance. Fill it in afterwards from the dashboard, or with updateAgent.
CarefulapiSecret is returned once
What comes back
| publicId | The stable public id. Every other method takes it. |
|---|---|
| name | As you passed it. |
| apiSecret | The widget secret. Once. See above. |
| isActive | True. A new agent answers straight away — it just has nothing to answer from yet. |
| createdAt | An ISO timestamp. |
When the plan is full
Creating spends plan quota. An App already at its agent limit gets a 403 whose message says how many agents the plan allows. The SDK reports it as unknown with status: 403 — it is not a scope problem, so editing the key will not help. Deleted agents do not count towards the limit.
Deleting one
DELETE /v1/agents/:publicId, with the agent's current name in the body.
curl -X DELETE https://api.tigerbase.cloud/v1/agents/a1b2c3d4… \
-H "Authorization: Bearer $TIGERBASE_KEY" \
-H "Content-Type: application/json" \
-d '{"name":"Returns Desk"}'{
"deleted": true,
"restorableUntilDays": 30,
"hidden": {
"agent": "Returns Desk",
"conversations": 412,
"documents": 9,
"capabilities": 3,
"openHandoffs": 1
}
}WarningThe name is a required argument
{
"statusCode": 400,
"error": "Bad Request",
"message": "To delete this agent, send its name in the body as {\"name\": \"...\"}. This would hide 412 conversation(s), 9 document(s) and 3 capability/capabilities for 30 days.",
"impact": { "agent": "Returns Desk", "conversations": 412, "documents": 9, "capabilities": 3, "openHandoffs": 1 }
}Delete is reversible for thirty days
Nothing is destroyed. The agent disappears from agents() and from the dashboard, stops answering, and stops counting against your plan's agent limit. Its conversations, documents and capabilities stay exactly where they were, hidden with it.
| hidden.agent | The name of the agent that was hidden. |
|---|---|
| hidden.conversations | Hidden, not deleted. They come back with the agent. |
| hidden.documents | Same — the knowledge base is kept. |
| hidden.capabilities | Same. |
| hidden.openHandoffs | Conversations that were waiting for a person. Worth reading before you confirm: these are live customers. |
NoteRestoring is a dashboard action
The widget key is retired immediately
Any page still embedding the deleted agent stops working the moment the call returns, rather than quietly carrying on against a hidden agent. Its integration key is cleared at the same time. Restoring issues a fresh key and secret, so an agent that comes back needs its embed updated — the old pair is not reinstated, because the thirty days it spent deleted are thirty days anyone could have been holding it.
Scope
Both need write. Without it they throw forbidden_scope.
NoteAn agent in another App is not found
404, exactly like one that never existed.