Uwierzytelnianie
Wyślij klucz API jako token bearer. Klucz musi posiadać uprawnienie mcp.manage; klucz bez niego jest odrzucany z kodem 403, a nie 404.
Miejsce na identyfikator organizacji
Ten punkt końcowy przyjmuje org_id jako pole w treści JSON.
Identyfikator Twojej organizacji znajduje się na ekranie kluczy API w Twoim panelu, obok samego klucza. Jest to ten sam identyfikator w każdym wywołaniu, które wykonujesz.
Wypróbuj
Zastąp wszystko w nawiasach ostrych własnymi wartościami, a zastępczy znacznik klucza kluczem ze swojego pulpitu nawigacyjnego.
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[]> }'Zalogowany? Konsola API w Twoim panelu uzupełnia rzeczywiste identyfikator organizacji oraz Twój własny klucz i wykonuje żądanie względem aktywnego API, dzięki czemu możesz zobaczyć rzeczywistą odpowiedź. Otwórz ten punkt końcowy w konsoli API
Szczegóły
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`.
Treść żądania
| Nazwa | Typ | Wymagane | Co to jest |
|---|---|---|---|
name | string | Tak | — |
client | McpClient | Nie | The AI client a connection is for (informational). |
scopes | string[] | Tak | 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 | Nie | — |
org_id | Uuid | null | Nie | The org the connection belongs to. Defaults to the caller's sole managed org. |
spend_cap_minor | integer | null | Nie | Optional per-window paid-action budget (integer minor units). Null = no cap. |
spend_currency | CurrencyCode | Nie | ISO 4217 currency code (money is minor units + this code — CLAUDE.md §2.8). |
spend_window_seconds | integer | Nie | — |
Odpowiedź
| Nazwa | Typ | Wymagane | Co to jest |
|---|---|---|---|
id | Uuid | Tak | UUIDv7 identifier — sortable by creation time (docs/02 §8). |
name | string | Tak | — |
client | McpClient | Tak | The AI client a connection is for (informational). |
prefix | string | Tak | The token's public lookup prefix (not a secret). |
scopes | string[] | Tak | The RBAC permission keys this connection's token may exercise. |
sandbox | boolean | Tak | — |
spend_cap_minor | integer | null | Nie | Optional per-window budget (integer minor units, CLAUDE.md §2.8) for AI-triggered paid actions. Null = no cap. |
spend_currency | CurrencyCode | Nie | ISO 4217 currency code (money is minor units + this code — CLAUDE.md §2.8). |
spend_window_seconds | integer | Tak | The rolling window the spend cap applies over. |
last_used_at | string | null | Nie | — |
revoked_at | string | null | Nie | — |
created_at | string | Tak | — |
token | string | Tak | The full `zmcp_…` token, shown exactly once. |
endpoint | string | Tak | The MCP protocol endpoint URL to configure in the AI client. |
config | object | Tak | A paste-ready MCP client config snippet embedding the endpoint + token. |
Błędy, które ten punkt końcowy może zwrócić
401 · 403 · 422 · 429