Personal Access Token¶
Most clients should sign in instead — Claude, Cursor, Claude Code, Hermes, and OpenClaw all support it, and it leaves no secret for you to store or rotate. Use a token when signing in isn't possible: an agent running somewhere with no browser to complete the flow even once (a CI job, a Cursor Cloud Agent, a cron host), or a client that only accepts a static URL and header.
A Personal Access Token (PAT) is a long-lived secret scoped to your Cohearence account. Any client holding it can read and write your data — treat it like a password.
1. Generate a token¶
- Open Settings → Connect AI.
- Tap Generate token.
- Choose an expiry — 30 days, 90 days, 1 year, or Never — and confirm.
- Copy the token, and/or the ready-made Cursor snippet, right away. The full token is shown once; if you lose it, revoke it and generate a new one.
2. Add it to your client¶
Every client below connects to https://api.cohearence.app/mcp over Streamable HTTP, sending your token as a Bearer header — the endpoint is the same for everyone, and the token is what identifies you. Swap in your own token where the examples say so. All four can also sign in instead; these configs are the token path, for when that isn't an option.
Add an entry to .cursor/mcp.json (project-scoped) or ~/.cursor/mcp.json (global), then fully restart Cursor.
{
"mcpServers": {
"cohearence": {
"url": "https://api.cohearence.app/mcp",
"headers": {
"Authorization": "Bearer YOUR_TOKEN_HERE"
}
}
}
}
Cursor should show cohearence as connected under Settings → MCP. Prefer to keep the token out of a committed file? Export it as an environment variable and reference it with Cursor's ${env:VAR_NAME} syntax instead of pasting it directly:
Claude Code reads the same mcpServers shape from .mcp.json (project root, checked into git — keep the token itself in your environment) or ~/.claude.json (personal, across all projects).
{
"mcpServers": {
"cohearence": {
"type": "http",
"url": "https://api.cohearence.app/mcp",
"headers": {
"Authorization": "Bearer ${COHEARENCE_MCP_TOKEN}"
}
}
}
}
Export the token in your shell first: export COHEARENCE_MCP_TOKEN="cohere_mcp_...". Start a new Claude Code session after editing the file — it's read at startup. You can also add it entirely from the CLI:
Add an entry under mcp_servers in ~/.hermes/config.yaml:
mcp_servers:
cohearence:
url: "https://api.cohearence.app/mcp"
headers:
Authorization: "Bearer YOUR_TOKEN_HERE"
Run /reload-mcp in a Hermes session after saving, or restart Hermes.
Register the server with the OpenClaw CLI, which writes into mcp.servers in your OpenClaw config:
openclaw mcp set cohearence '{
"url": "https://api.cohearence.app/mcp",
"transport": "streamable-http",
"headers": { "Authorization": "Bearer ${COHEARENCE_MCP_TOKEN}" }
}'
OpenClaw expands ${VAR_NAME} references from your environment, so the token itself never needs to sit in the config file. Verify with openclaw mcp list or openclaw mcp doctor cohearence --probe.
Rotating or revoking¶
Tokens don't auto-renew — if one expires, generate a new one from Connect AI and update your client's config manually. To cut off a client immediately, tap Revoke next to that token; it stops working right away.