Agents and MCP
Claude Code
Add a Tracehold MCP server to Claude Code with one command.
Add the server#
How you add it depends on the server's Who can connect setting (Agent identity). The app shows the right command, filled in, on the last step of the server wizard and on the server's page.
A server people sign in to#
In your project directory:
claude mcp add --transport http tracehold-dev-agents https://api.tracehold.ai/mcp/<server-id>/
Then type /mcp in Claude Code, pick the server and choose
Authenticate. Claude Code opens Tracehold in your browser; sign in and
choose Allow. Its calls are then recorded as yours. Claude Code keeps
the sign-in and refreshes it by itself.
A server that takes a token#
claude mcp add --transport http tracehold-prod-ops https://api.tracehold.ai/mcp/<server-id>/ \
--header "Authorization: Bearer <token>"
The token is shown once at creation; if you lost it, rotate it on the server's page (the old token stops working at once).
Check it connected#
claude mcp list
You should see the server with ✔ Connected. The server's page in Tracehold
also shows the first connection.
Share it with your team#
claude mcp add --scope project ... writes .mcp.json at the project root,
which you can commit. For a server people sign in to, the file holds only
the address, and each person signs in with their own account. For a token
server, keep the token out of version control by using an environment
variable in the header:
{
"mcpServers": {
"tracehold-prod-ops": {
"type": "http",
"url": "https://api.tracehold.ai/mcp/<server-id>/",
"headers": { "Authorization": "Bearer ${TRACEHOLD_TOKEN}" }
}
}
}
What the agent experiences#
- Allowed actions return the cloud's response.
- Blocked actions return an error with the reason and, where there is one, a safer alternative.
- Actions that need approval return an error with an action ID. Claude Code
then waits with
tracehold_wait_for_approvalby itself, and gets the result once a reviewer approves (checked with Claude Code 2.1.296). See Approvals. - Tools added or removed on the server reach a running session without a reconnect.
To run Claude Code in a CI job or pipeline, see Agents in pipelines.