Pause or resume a tool
SDK platic.agents.tools.setState()
Choose whether an agent can use a tool: send state: "paused" to pause it or state: "active" to activate it. Pausing keeps the connection. The change applies immediately, without publishing, does not create a version and only affects this agent.
Example
curl -X PATCH https://api.platic.ai/v1/agents/$AGENT_ID/tools/$TOOL_ID \
-H "Authorization: Bearer $PLATIC_API_KEY" \
-H "Content-Type: application/json" \
-d '{ "state": "paused" }' await platic.agents.tools.setState("agent_123", "tool_123", "paused"); Path parameters
| Parameter | Type | Description | Required |
|---|---|---|---|
agentId | string | Agent id | ✓ |
toolId | string | Tool id | ✓ |
Request body
| Field | Type | Description | Required |
|---|---|---|---|
state | string | paused pauses it; active resumes it. | ✓ |
{ "state": "paused" } Response
200 OK with the connection:
{
"status": "success",
"data": {
"toolId": "8fK2mQpLxT4vNbRc",
"name": "mcp_create_issue_a1b2c3",
"description": "Create a new issue in Linear",
"kind": "mcp",
"state": "paused",
"toolExists": true,
"attachedAt": "2026-07-14T18:05:22.881Z"
}
} data is the connection, with the fields from List agent tools.
Errors
| Status | details.code | When |
|---|---|---|
400 | INVALID_REQUEST | state is missing or isn't active or paused. |
404 | AGENT_NOT_FOUND | The agent doesn't exist or belongs to another workspace. |
404 | TOOL_NOT_FOUND | The tool doesn't exist in this workspace. details.toolId names it. |
404 | TOOL_NOT_CONNECTED | Pausing a tool that isn't connected to this agent. details.toolId names it. |
The format and codes for the rest of the API are in Errors.
Notes
- Resuming a tool that wasn't connected connects it:
{ "state": "active" }always leaves the connection active. - Pausing doesn't change the tool, its API or its MCP server.
- To remove the connection, use Disconnect a tool.
- From an AI agent, the tool is
set_agent_tool_state.