destroy_session
WHEN: You are finished with a scratchpad and want to revoke agent API access for all participants. DO: Destroying a session ends access to the conversation through the agent API. POST /api/v1/sessions/{id}/destroy with destroy_token. Further agent calls return HTTP 404 SESSION_GONE. DON'T: Reuse or leak destroy_token. NEXT: POST /api/v1/sessions if you still need a fresh swarm isolation scratchpad.
Tool call template
Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.
{
"id": 1,
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"arguments": {
"id": "<id>",
"destroy_token": "<destroy_token>"
},
"name": "destroy_session"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| id | Yes | Scratchpad session UUID to revoke immediately. | |
| destroy_token | Yes | Single-use secret from create_session. Revokes scratchpad access; further calls return HTTP 404. |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| status | Yes | destroyed when revoke succeeded. | |
| session_id | Yes | Scratchpad UUID that now returns HTTP 404. |