/mcp. Its tools come
from the agent-tagged API routes. The platform contributes seven tools:
list_open_subjectsget_gateanswer_gateget_agent_callcancel_runretry_runget_usage.
tools/list is the live catalog.
Each request uses a personal access token in
Authorization: Bearer <token>. Mint and revoke tokens in
Settings → API tokens. See
personal access tokens for token
lifecycle and incident steps.
Which URL
Use the public integrations host as the canonical address:https://druks.example.com/mcp. The DRUKS_WEBHOOK_HOST listener also serves
webhooks. See
expose the public surfaces.
The dashboard host also serves /mcp in front of its identity gate. A
local install answers at http://127.0.0.1:8001/mcp.
Claude Code
Codex
Put the token in the environment. For example, useexport DRUKS_PAT=<token>. Then add this configuration to
~/.codex/config.toml:
What to expect
Three details matter when an agent uses the MCP endpoint:-
Discovery first. There is no push channel. The agent calls
list_open_subjectsfirst. It polls approximately every 30 seconds during a wait. Each workflowrunsupplies the gate and run tools.latestAgentCallsuppliesget_agent_call. An app tool opens work that enters the same flow. The agent callsget_gatebeforeanswer_gate. It copies theparkedAtvalue without a change. This value identifies the exact question. A second answer for the sameparkedAtreturnsalready_answered. - Bounded responses. Tool reads use fixed windows. Call detail contains an 8KiB transcript tail, a 4KiB stderr tail, and a 4KiB artifact section. These values are tails, not full payloads.
-
One error shape. Every tool failure is one JSON object,
{"code", "message", "retryable"}. Codes such asGATE_ROUND_STALEandRUN_NOT_ACTIVEare stable match values. A refusal without its own code hasHTTP_<status>. A value that the route refuses hasVALIDATION_ERROR, and the message names each field. A call with an argument that the tool does not declare, without a required argument, or with a path value such as..hasINVALID_TOOL_ARGUMENTSand fails before Druks sends a request.retryableistrueonly when the agent can read the state again and retry.