Connections

Connect a system

connect_add · Changes data · Markdown

Connects one of the company's systems: its address, its credential (kept encrypted) and the calls it may make.

Free

This tool costs nothing to call.

An example

Connect our Zendesk so you can read tickets and close the ones we moved.

Your agent callsconnect_addFree

The example business is Hansen & Voss, a restaurant-equipment wholesaler in Hamburg with 60 staff. The reply is the one the tool really gives.

With these arguments
{
  "name": "zendesk",
  "base_url": "https://hansenvoss.zendesk.com/api/v2",
  "auth": "bearer",
  "allow": [
    "GET /tickets*",
    "PUT /tickets/*"
  ],
  "description": "The old help desk, until the move is done"
}
What comes back
{
  "link": "https://conecto.chat/api/bots/connect/des6IIpQfad0cq8CC9h7kD17kjCCqtwR4R7EslbveSQ",
  "expires_in_minutes": 60,
  "tell_the_owner": "Open this link within the hour, sign in to Conecto and type zendesk's API token there. It goes to Conecto only; I never see it.",
  "from_a_terminal": "npx @conecto-chat/cli@latest run connect_add -i '{\"name\": \"zendesk\", \"base_url\": \"https://hansenvoss.zendesk.com/api/v2\", \"auth\": \"bearer\", \"allow\": [\"GET /tickets*\", \"PUT /tickets/*\"], \"description\": \"The old help desk, until the move is done\"}' -s secret",
  "from_a_terminal_with_curl": "printf %s 'API token: '; read -rs v1; echo; curl -sS -H \"Authorization: Bearer $CONECTO_KEY\" --data-urlencode secret@<(printf %s \"$v1\") https://conecto.chat/api/bots/connect/des6IIpQfad0cq8CC9h7kD17kjCCqtwR4R7EslbveSQ; unset v1",
  "next": "When the owner types it on the link, account.credential_added (account_events) says so, with what connect_add answered."
}

Use it when

The agent needs to read or change something in a system that has a REST API.

What it does

Connect one of the company's own systems (an ERP, a ticketing tool, any REST API): its https base address, its credential and the calls the agent may make. Called without secret, it answers with a link for the owner, who sees the address and the calls and types the credential on a Conecto page, so it never passes through the chat (from_a_terminal does the same from a terminal); account.credential_added says when it is connected. The credential is kept encrypted and never shown again. A system behind the company's firewall goes through one of its bridges instead: give `bridge` and `system` (connect_list shows the bridges and the systems each serves) in place of base_url and a credential, which the bridge adds inside the network. On accounts with an owner, writes (POST, PUT, PATCH, DELETE) and changing the allowed calls wait for the owner's approval by default, which shows the exact request. Free.

What comes back

Without secret: link, a page where the owner or an admin, signed in, types the credential, with expires_in_minutes, tell_the_owner, from_a_terminal (the CLI), from_a_terminal_with_curl and next. With secret: connection, its name, base address, kind of auth, allowed calls and description; writes_need_approval, true when POST, PUT, PATCH and DELETE wait for the owner. Every reply also carries cost_usd and balance_usd.

Inputs

NameTypeWhat it is
nameRequiredstringLowercase letters, digits and dashes, like "netsuite" or "zendesk". 2 to 40 characters.
base_urlstringUp to 500 characters.
authstringbearer (Authorization: Bearer <secret>), header (the secret in `header`), basic (secret is "user:password") or none. One of: bearer,header,basic,none. Default: bearer.
headerstringFor auth header, like X-API-Key. Up to 60 characters.
secretstringThe credential: a token, the header's key, or "user:password" for basic. Leave it out to get the link instead. Up to 4,000 characters.
allowRequiredarray of stringsThe calls it may make: a method and a path pattern each, like "GET /v1/customers*" or "POST /v1/tickets". * matches anything. 1 to 50 items.
descriptionstringUp to 300 characters.
bridgestringFor a system behind the firewall: the bridge it goes through. Up to 40 characters.
systemstringWith bridge: the system's name in the bridge's config, like "sap". Up to 40 characters.

The call

Over MCP, call connect_add on https://api.conecto.chat/mcp/connect. Over REST:

Terminal
curl -X POST https://api.conecto.chat/v1/tools/connect_add \
  -H "Authorization: Bearer $CONECTO_KEY" \
  -H "Content-Type: application/json" \
  -d '{"name":"zendesk","base_url":"https://hansenvoss.zendesk.com/api/v2","auth":"bearer","allow":["GET /tickets*","PUT /tickets/*"],"description":"The old help desk, until the move is done"}'

When it refuses

A refused call costs nothing and says what to do next.

CodeWhenWhat to do
invalid_input400The name, address, auth or an allowed call is not valid.Fix what the message names.
conflict409A connection with that name exists.Pick another name, or remove the old one.
limit_reached409The account has 50 connections.Remove one first.
not_found404The bridge, or the system on it, does not exist.connect_list shows the account's bridges and the systems each serves.

Give this to your agent.

Set up Conecto from https://conecto.chat/SKILL.md