Skip to main content
Glama

Connect an agent connector

connect_agent_connector
Destructive

Connect an external service connector to a deployed agent so it gains that service's tools, using saved API keys or a user-approved sign-in link.

Instructions

Connect a Connector (an outside service from list_agent_connectors) to a deployed agent, which then gets its tools. action connect: a connector that takes a key saves the values in values and connects at once; the result never shows them again. A sign-in connector returns a link that the user must open in their own browser and approve within 10 minutes; never open it for them. A sign-in with the service's own OAuth uses the user's own app there: its keys (such as a client id and secret) go in values with the same call. A connector that offers both takes mode sign_in or key. The wiro connector runs with a Wiro project and gives the agent only Wiro's model, task and file upload tools, plus read-only docs search and playbooks: connecting it takes project_id from list_projects (or the project of this connection) and makes that project the agent's own Wiro project, as bind_agent_project does, so its calls count as the agent's own (its spend limits and Model Access rules apply, and account, agent and billing calls are refused). It first shows the project, what it replaces, which wallet pays and the scheduled tasks and custom skills the project turns on. A call with required values missing sends nothing and lists what to ask for, with where each value comes from. action status: whether the sign-in finished (wait_seconds waits for the user). Connecting a connector that is connected now replaces that connection, and a connector that runs with a Wiro project always shows its project first: both take confirm: true after the user agreed. A running agent gets most changes without a restart; a few restart it, which takes a minute or two. Where a connector has account choices, such as the advertisers a TikTok Ads sign-in reaches, set_agent_connector_accounts lists and saves the accounts it may act on once it is connected; accounts saves ids the user already knows with this call. disconnect_agent_connector removes a connection. The person who deployed the agent or a team admin of its team can connect. Keys go only in values, never in a message to an agent.

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": {
      "agent_guid": "<agent_guid>",
      "connector": "<connector>"
    },
    "name": "connect_agent_connector"
  }
}

Input Schema

NameRequiredDescriptionDefault
modeNoconnect, for a connector that connects either way: sign_in (the default) or key.
actionNoconnect (default) connects or starts the sign-in, status checks a sign-in.connect
valuesNoconnect: the Connect card's values by field name, as list_agent_connectors shows them, for example {"apikey": "..."}. A json field takes the JSON value or its text. Values saved before are kept unless sent again; null or "" clears an optional one. Never echoed back.
confirmNoconnect: true to replace a working connection, or to connect a connector that runs with a Wiro project (it binds the project to the agent), after the user agreed.
accountsNoconnect: the accounts the connection may act on, {account key: [ids]}, saved with it as given; a sign-in saves them once it finishes. Use it for ids the user already knows, such as TikTok Ads advertiser ids under "advertisers", or where the connector's setup steps name an account key. Otherwise choose them once connected with set_agent_connector_accounts, which lists the accounts the connection reaches and takes only those. A connector with account choices takes only their keys. Leave it out to keep the accounts saved before.
connectorYesThe connector's slug, from list_agent_connectors, such as "serper" or "google-ads".
agent_guidYesThe deployed agent's guid, from list_my_agents.
project_idNoconnect, for a connector that runs with a Wiro project (wiro): the project's id from list_projects, which becomes the agent's own Wiro project. Leave it out for the project of this connection.
redirect_urlNoconnect, for a sign-in: where the browser goes after approving, an https address or a local one on the user's own machine (http://localhost or http://127.0.0.1). Leave it out for Wiro's own page, which says how it went.
wait_secondsNostatus: how long to wait for the sign-in to finish, 0 to 3600 seconds (default 0, a single check).
since_connected_atNostatus: the since_connected_at value from connect's nextAction, so the connection from before is not taken for the new one.

Output Schema

NameRequiredDescriptionDefault
modeNo
stateYes
titleYes
actionYes
fieldsNosetup_needed: the values to ask the user for, with where each one comes from.
appliedNo1 when the saved connection changed, 0 when it already held this.
messageYes
missingNosetup_needed: the names of the required values that are missing.
projectNoA connector that runs with a Wiro project (the wiro connector): the project connecting it binds to the agent as its own Wiro project, which the agent's video and voice skills use too.
restartNolive: the running agent got the connector with no restart. scheduled: a running agent restarts to load the connector. none: nothing to load, or the agent is not running. failed: it is saved, but a running agent needs control_agent restart.
agentGuidYes
connectorYes
connectionNo
nextActionNo
authorizeUrlNoThe sign-in link for the user to open in their own browser. Never open it for them.
replacesProjectNoThe agent's Wiro project now, which the connect replaces. Left out when it has none, or when it is the same project.
expiresInSecondsNo

Schema Changelog

Changes observed during successful MCP inspections.

  1. Addedv2.0.0

TDQS

A4.2/5.0
Behavior4/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

Annotations already declare destructiveHint=true, readOnlyHint=false, openWorldHint=true and idempotentHint=false, and the description adds substantial context beyond them: replacement overwrites an existing connection, key values are stored but never shown again, sign-in links expire in 10 minutes and must be opened by the user, and the Wiro binding changes spend limits and refuses account/billing calls. Restart behavior (most changes are live, a few take a minute or two) and the permission requirement (deployer or team admin) further enrich it. It never misstates the annotations, and only the exact consequences of a replacement (whether prior tool access is revoked) are left implicit.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness3/5

Is the description appropriately sized, front-loaded, and free of redundancy?

The content is front-loaded with the core action and mode rules, but the single dense paragraph mixes connect behavior, Wiro specifics, account choices, permissions and secret-handling into one block. Sentences like the Wiro project clause and the accounts clause are long and would be clearer as separate lines, and some detail (the scheduled tasks and skills preview) is marginal for tool selection.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness4/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

For an 11-parameter mutation tool with nested objects and an output schema, the description covers prerequisites, confirmation gating, secret handling, mode branching, and side effects such as agent restarts. The main gap is what a replacement does to the prior connection's saved values and permissions, which the reader must infer.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters4/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema coverage is already 100%, so the baseline is 3, but the description still adds cross-parameter meaning: which fields belong to which action (values/confirm/project_id/accounts for connect, wait_seconds/since_connected_at for status), where each required value comes from, and the special case of null or empty string clearing optional values. It explains the interplay between mode and connector capability rather than restating field docs.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description states a specific verb and resource (connect a Connector from list_agent_connectors to a deployed agent) and immediately distinguishes both action modes, connect vs status. It also names the siblings that handle adjacent jobs (set_agent_connector_accounts, disconnect_agent_connector, bind_agent_project, list_projects), so an agent can route correctly.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines4/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

It gives explicit conditions for mode sign_in versus key, when confirm: true is required (replacing a working connection, or binding a Wiro project), and when to use accounts versus set_agent_connector_accounts. It also names disconnect_agent_connector for removal. It stops short of stating outright when not to use the tool (for example, when the connector is already connected and unchanged), but the replacement rule covers most of it.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.