Connect
MCP server and API
Every automation is a typed tool on your workspace's MCP server, and an HTTP endpoint for scripts.
Any AI that speaks the Model Context Protocol, and any script that can make an HTTP request, can run your automations. Both use the same API key, created under Workspace settings → Messaging & API.
API keys
Press New key, name it, choose an Expiration (30 days, 90 days, a year, or none; 90 days is the default) and press Create key. Copy it once; only the prefix, last use and expiry are shown afterwards. The key acts as you, scoped to this workspace: runs it starts run under your account. Delete a key to revoke it.
The MCP server
The MCP URL is shown on the same page, with Copy MCP config for a ready-made configuration. Per-client guides cover:
- Claude (claude.ai and Claude Desktop): the key is appended to the URL path, because Claude's connector dialog has no header field and drops query strings.
- Claude Code: one command,
claude mcp add cmdk --transport http <url>, with the key as a bearer header. - Cursor and any MCP client: a snippet for
.cursor/mcp.json. - ChatGPT: Settings → Connectors → Advanced → Developer mode.
A shareable version of these guides is at /connect.
Tools the server exposes
| Tool | What it does |
|---|---|
| One tool per automation | Runs it with typed inputs. Waits up to about two minutes for the result. |
check_run | Polls a run that took longer. |
list_automations | Lists what the workspace can do. |
get_automation_detail | The brief, plan and inputs of one automation. |
update_automation | Changes an automation's instructions, plan or overview configuration. |
list_tools, get_tool_file, update_tool_files | Read and write the files of script tools. |
This means an engineer in Cursor or Claude Code can read a plan, fix a script and run the automation again without opening the app.
The HTTP invoke API
Start a run:
curl -X POST https://<your cmdk host>/api/automations/<automationId>/invoke \
-H "Authorization: Bearer <your API key>" \
-H "Content-Type: application/json" \
-d '{"inputs": {"inquiry": "...", "port": "Rotterdam"}}'The response carries a runId, a chatId and the status pending. Add "wait": true to the body to hold the request open until the run finishes instead. Otherwise, poll it:
curl https://<your cmdk host>/api/automations/<automationId>/invoke?runId=<runId> \
-H "Authorization: Bearer <your API key>"The result includes the run status, its fields, its summary and links to its files. A run that parks with Needs input stays in that state until someone answers in the app or through an escalation door. The key can also be sent as an x-api-key header or a key query parameter.
Per-automation doors
Each automation's Settings tab has an AI agents switch that decides whether the automation is exposed on the MCP server at all, and Copy MCP setup for your AI for the same server configuration.