Authentication & API keys
Tested on 28 November 2026 against a local build of the current Simline API, with a simulated test phone that reports sent and delivered like a real one.
Every call to https://api.simline.dev is authenticated with a bearer token in the Authorization header.
| Token | Looks like | Used for | Where you get it |
|---|---|---|---|
| API key | sl_live_… |
The REST API (/v1/messages, /v1/conversations, /v1/webhooks) |
Dashboard → Developers → API keys |
| Agent key | sl_agent_… |
The MCP server (/mcp) for AI clients |
Dashboard → Agents (AI agents & MCP) |
| Webhook secret | whsec_… |
Checking that a webhook came from Simline (not sent by you) | When you create a webhook endpoint |
All three are shown once when created. Simline stores only a SHA-256 hash, so a lost key can’t be recovered: create a new one.
API keys
Section titled “API keys”curl https://api.simline.dev/v1/messages \ -H "Authorization: Bearer $SIMLINE_API_KEY"A missing, unknown or revoked key gets 401:
{"error": "unauthorized", "message": "Sign in or provide a valid token"}Scopes
Section titled “Scopes”| Scope | Lets the key |
|---|---|
send |
Send texts: POST /v1/messages |
read |
Read messages and conversations, mark conversations read |
send + read |
Everything above, plus manage webhooks (/v1/webhooks*, /v1/webhook-deliveries/*) |
New keys get both scopes unless you untick one. A key without the needed scope gets 403 forbidden. Give a key only what its app needs: a reporting job needs read, a backend that only sends notifications needs send.
Workspaces
Section titled “Workspaces”A key belongs to one workspace and only ever sees that workspace’s phones, messages and webhooks. If you run several businesses or environments, make a workspace for each and a key in each. Idempotency keys, conversations and limits are per workspace too.
Rotate and revoke
Section titled “Rotate and revoke”There’s no “rotate” for API keys; do it without downtime in three steps:
- Create a new key in Developers → API keys.
- Deploy it to your app.
- Revoke the old one. The list shows each key’s prefix and when it was last used (updated at most once a minute), so you can see when the old one has gone quiet.
Revoking takes effect immediately.
The dashboard session
Section titled “The dashboard session”The dashboard at app.simline.dev uses a session cookie (simline_session, HttpOnly, signed) against the same API. A few endpoints accept only the session, never an API key: creating, listing and revoking API keys (/v1/keys), agents and approvals, AI and Telegram settings, billing. That way a leaked API key can’t mint more keys.
With a session, the REST endpoints act in your first workspace unless you pass ?workspaceId=ws_…. With an API key, workspaceId is ignored: the key’s own workspace is used.
Agent keys
Section titled “Agent keys”AI clients (Claude Desktop, Claude Code, Cursor) connect to https://api.simline.dev/mcp with an agent key instead of an API key. Each agent has its own key and its own sending policy, so you can pause one client without touching the others. See AI agents & MCP.