> ## Documentation Index
> Fetch the complete documentation index at: https://docs.60db.ai/llms.txt
> Use this file to discover all available pages before exploring further.

# Assign Integration Agents

> Set which agents hold this connection's tools. Each listed agent gets exactly the tools you list

Set the agents that hold a connection's tools, in one request. Each agent you list gets exactly the tools you list for this connection. An agent's tools from other connections are kept.

* An agent you leave out, or list with an empty `tools`, loses this connection's tools.
* Every changed agent is updated as an agent edit is, and synced to the voice runtime.
* The change is all or nothing. Every agent is checked before the first write, so a refusal changes nothing.

Tool keys come from [List integration tools](https://docs.60db.ai/api-reference/agents/list-integration-tools.md). For the dashboard flow and the rules, see [Connect integrations to agents](https://docs.60db.ai/features/agents-integrations.md#connect-integrations-to-agents).

## Request

### Headers

**Authorization** `string` *required*

Bearer token with your API key (scope `agents`)

**Content-Type** `string` *required*

application/json

### Path

**id** `string` *required*

The connection `id` (UUID)

### Body

**agents** `object[]` *required*

Up to 200 entries. Each `agent_id` may appear once.

**agents\[].agent\_id** `string` *required*

The agent's public `id`, as the agents API returns it

**agents\[].tools** `string[]` (default: \[])

Tool keys of this connection, up to 16 per agent. Unique within the list

## Response

**200 OK**

```json theme={null}
{
  "success": true,
  "data": {
    "used_by": [
      { "agent_id": "9c2e1d7a-0b3f-4e6a-8f1d-5a7b9c0e2d44", "name": "Front desk", "tools": ["book_table", "check_availability"] }
    ]
  }
}
```

`used_by` is the connection's usage after the change: the agents that hold one of its tools, with their tool keys.

## Errors

| Status | Code | Meaning |
| - | - | - |
| 400 | `VALIDATION_ERROR` | The body is invalid, for example more than 200 agents, a repeated `agent_id`, or more than 16 tools for one agent. `field` names the entry |
| 403 | `POLICY_DENY` | Your role cannot use integrations, or cannot edit agents, or the API key lacks the `agents` scope |
| 404 | `AGENT_NOT_FOUND` | An `agent_id` is unknown or belongs to another workspace. `field` is `agents.<n>.agent_id` |
| 404 | `INTEGRATION_NOT_FOUND` | No connection with this ID in your workspace |
| 422 | `AGENT_TOOL_LIMIT` | The agent would have more than 16 tools in total, counting its own `tools`. The message names the agent |
| 422 | `INTEGRATION_TOOL_NOT_FOUND` | A tool key is not offered by this connection. `field` is `agents.<n>.tools` |
| 422 | `INTEGRATION_TOOL_INVALID` | A tool's parameter schema is larger than 4 KB, or two tools of the agent would have the same runtime name |
| 429 | `RATE_LIMITED` | More than 10 integration changes in the last minute |

## Example

```bash cURL theme={null}
curl -X PUT https://api.60db.ai/agents/integrations/INTEGRATION_ID/agents \
  -H "Authorization: Bearer your-api-key" \
  -H "Content-Type: application/json" \
  -d '{
    "agents": [
      { "agent_id": "AGENT_ID", "tools": ["book_table", "check_availability"] },
      { "agent_id": "OTHER_AGENT_ID", "tools": [] }
    ]
  }'
```


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.