mcp
POST /v1/mcp/connections
Create an MCP connection (Connect AI tool).
Hitelesítés
Küldjön egy API-kulcsot bearer tokenként. A kulcsnak rendelkeznie kell a(z) mcp.manage jogosultsággal; az ezzel nem rendelkező kulcsok esetén a rendszer 403-as hibát ad vissza 404 helyett.
A szervezet azonosítójának helye
Ez a végpont a org_id mezőt várja a JSON törzsben.
A szervezeted azonosítója a vezérlőpult API-kulcsok képernyőjén található, közvetlenül a kulcs mellett. Ez ugyanaz az azonosító minden indított hívásban.
Próbálja ki
Cserélje ki a hegyes zárójelek közötti részt a saját értékeivel, a kulcshelyőrzőt pedig a vezérlőpultján található kulccsal.
curl -X POST https://api.zinndigital.com/v1/mcp/connections \
-H "Authorization: Bearer zdk_live_…" \
-H "Content-Type: application/json" \
-d '{ "name": <string>, "scopes": <string[]> }'Be van jelentkezve? A vezérlőpultban lévő API-konzol kitölti a valós szervezetazonosítóját és a saját kulcsát, és a kérést az éles API-n futtatja, hogy láthassa a tényleges választ. Nyissa meg ezt a végpontot az API konzolban
Részletek
Mints a per-tool MCP connection and returns the full zmcp_… token once (only its hash is stored) plus a paste-ready client config snippet. The requested scopes must be permissions the caller already holds in the target org — an unheld scope is a 403 (a connection can never out-scope its creator), an unknown one a 422. An optional spend cap bounds AI-triggered paid actions. Requires mcp.manage.
Kérés törzse
| Név | Típus | Kötelező | Mi ez |
|---|---|---|---|
name | string | Igen | — |
client | McpClient | Nem | The AI client a connection is for (informational). |
scopes | string[] | Igen | RBAC permission keys to grant the token. Each must be a permission the caller holds in the target org (a connection can never out-scope its creator); an unheld scope is a 403,… |
sandbox | boolean | Nem | — |
org_id | Uuid | null | Nem | The org the connection belongs to. Defaults to the caller's sole managed org. |
spend_cap_minor | integer | null | Nem | Optional per-window paid-action budget (integer minor units). Null = no cap. |
spend_currency | CurrencyCode | Nem | ISO 4217 currency code (money is minor units + this code — CLAUDE.md §2.8). |
spend_window_seconds | integer | Nem | — |
Válasz
| Név | Típus | Kötelező | Mi ez |
|---|---|---|---|
id | Uuid | Igen | UUIDv7 identifier — sortable by creation time (docs/02 §8). |
name | string | Igen | — |
client | McpClient | Igen | The AI client a connection is for (informational). |
prefix | string | Igen | The token's public lookup prefix (not a secret). |
scopes | string[] | Igen | The RBAC permission keys this connection's token may exercise. |
sandbox | boolean | Igen | — |
spend_cap_minor | integer | null | Nem | Optional per-window budget (integer minor units, CLAUDE.md §2.8) for AI-triggered paid actions. Null = no cap. |
spend_currency | CurrencyCode | Nem | ISO 4217 currency code (money is minor units + this code — CLAUDE.md §2.8). |
spend_window_seconds | integer | Igen | The rolling window the spend cap applies over. |
last_used_at | string | null | Nem | — |
revoked_at | string | null | Nem | — |
created_at | string | Igen | — |
token | string | Igen | The full zmcp_… token, shown exactly once. |
endpoint | string | Igen | The MCP protocol endpoint URL to configure in the AI client. |
config | object | Igen | A paste-ready config for the connection's client, embedding the endpoint and token. The shape differs per client: Claude Code gets an http-typed server, Cursor a url +… |
config_file | object | Igen | Where that client reads config — e.g. .mcp.json. null when it has no file. |
command | object | Igen | A one-line alternative for a client with a command line (Claude Code), else null. It embeds the token, so treat it like the token. |
note | object | Igen | Set when the client cannot use a bearer token at all. chatgpt_needs_oauth: ChatGPT connects by OAuth sign-in only, so this token cannot reach it. |
Hibák, amelyeket ez a végpont visszaadhattatlan
401 · 403 · 422 · 429