MCP server
Let Claude, ChatGPT, Codex, Gemini, Cursor or VS Code read your Inboxy company and answer questions about orders, customers and conversations.
Scoped operations · local STDIO + hosted HTTPS/OAuth · v0.2.0 on npm
npx -y @inboxychat/mcp@0.2.0On this page
Who it is for
Merchants, support leads and developers who use an AI assistant that speaks the Model Context Protocol.
What it can do
- This source version adds 80 audited operations across SDK, CLI and MCP. Installed npm versions and hosted enablement must be checked separately.
- 27 tools, including 11 public reads and 4 operation adapters and 4 separate message-send, activation, campaign-send and campaign-schedule actions: company and key, plan usage, orders, contacts, conversations, messages and products.
- One company per server, decided by the API key. No tool takes a company id, and audited mutations require explicit preview approval.
- Every result is marked as untrusted customer data, so the model is told never to follow instructions written inside messages.
Overview
Audited operations and actual coverage
This source version adds 80 audited operations across SDK, CLI and MCP. Installed npm versions and hosted enablement must be checked separately.
Coverage: contacts, tasks, tickets, inbox assignment/status/labels/internal notes and separate text sending; AI drafts/configuration/reviewed text knowledge/channels/tests/readiness/publish; manual orders/status/payment/fulfillment; products/categories; contact status/stage/assignment/tags/custom fields; automation inspection/inactive draft/dry simulation/pause/approved activation; campaign audience estimates/drafts/pause/cancel and approved send/resume/schedule. The 553-route inventory is discovery metadata, not executable full dashboard parity.
SDK: describeOperations(), prepareOperation(id, input, idempotencyKey), executeOperation(id, input, { idempotencyKey, confirmation }). CLI: operations list/inspect/preview/run with --input, --idempotency-key and --confirm. MCP: operations_list, operation_inspect, operation_preview, operation_execute; messages use message_send and activation uses lifecycle_activate; campaign delivery uses campaign_send or campaign_schedule. CLI sending uses messages send after previewing inbox.message.send.
Show the exact preview and obtain explicit user approval before a mutation. The confirmation hash binds normalized input and key; it does not prove human approval. Retain the same idempotency key for recovery. No automatic retries. Existing tenant, role, scope and plan gates apply. OAuth write scopes require new explicit consent and start unchecked; old grants do not gain permissions.
AI tests and knowledge processing may consume credits. Publishing and channel assignment can affect live replies. Sending requires approval of contactId, channelId/type and complete text; the server rechecks the target. Inbox media/template sends, entity deletion, arbitrary HTTP, billing and platform administration are not exposed. Campaign template delivery and scheduling require a separate approved frozen audience/content/sender/time snapshot. Order and contact tag changes may trigger configured automation; custom fields replace the entire map; payment updates do not charge a provider. Refunds/cancellation and full campaign/automation coverage remain excluded.
Hosted MCP (HTTPS + OAuth, no key to paste) lives at https://api.inboxy.chat/mcp. ChatGPT, claude.ai, Claude Code, Codex and Gemini CLI connect with that URL. Any client can keep using the local STDIO server below with an API key.
@inboxychat/mcp is a Model Context Protocol server that runs on your computer over STDIO. Your AI client starts it with npx; it reads Inboxy through the public API v1 with your key.
Install
Needs Node.js >= 20.3. Nothing to install globally: the client runs the package with npx. To check it starts:
INBOXY_API_KEY="inboxy_YOUR_KEY" npx -y @inboxychat/mcpIt prints "inboxy-mcp: ready (...)" on stderr and waits for a client. Press Ctrl-C to stop.
Authentication
- Sign in to Inboxy as a company admin and open Developers → API keys in the dashboard (/developer-center/keys).
- Choose "Create an API key" and give the key a name you will recognise (for example "Claude on my laptop").
- Tick only the scopes you need. There is no default set: a key without scopes cannot be created. The read tools need the ":read" scopes (contacts:read, orders:read, ...).
- Pick an expiry: 30, 90 (default), 180 or 365 days, or never. The default is 90 days.
- Copy the key when it is shown. It starts with "inboxy_". Store it in a secret manager or the OS keychain, never in a repository.
Where the server looks for the key
Best option: store the key once in the keychain with the CLI, then no client config needs to contain it.
- INBOXY_API_KEY in the client config "env" (INBOXY_API_URL optional).
- The OS keychain entry written by
inboxy auth login(CLI). INBOXY_PROFILE picks the profile. - Only on machines without a keychain: the 0600 config file written by
inboxy auth login --store file.
npm i -g @inboxychat/cli
inboxy auth login # opens the browser (or paste a key when piped)Connect your AI client
ChatGPT (hosted MCP)
ChatGPT cannot start a local process. Use the hosted server. You must be a company admin; consent opens in Inboxy and never shares a raw API key with OpenAI.
- In ChatGPT: Settings → Apps & Connectors (or Custom MCP) → add a new connector.
- Server URL:
https://api.inboxy.chat/mcp(OAuth is discovered from the well-known metadata on the same host). - Approve the consent screen in Inboxy as a company admin, then ask: "Which Inboxy company am I connected to?"
- Revoke any time under Developers → MCP → Connected AI apps.
https://api.inboxy.chat/mcpclaude.ai (hosted MCP)
Same hosted URL as ChatGPT. Claude.ai connectors use OAuth; the Inboxy consent page shows the requested read scopes before anything is granted.
- In Claude.ai: Settings → Connectors → Add custom connector / MCP server.
- Paste
https://api.inboxy.chat/mcp, complete OAuth, approve as company admin. - Try: "List my five oldest pending orders." Claude should call orders_list.
https://api.inboxy.chat/mcpClaude Code
Hosted server: add the URL, then type /mcp inside Claude Code, pick inboxy and sign in; approve the consent screen in Inboxy as a company admin. Local server: store the key with inboxy auth login and add the npx command.
claude mcp add --transport http inboxy https://api.inboxy.chat/mcpThen run /mcp in Claude Code to sign in.
claude mcp add inboxy -- npx -y @inboxychat/mcpclaude mcp add inboxy -e INBOXY_API_KEY="$INBOXY_API_KEY" -- npx -y @inboxychat/mcpClaude Code saves the value in its own config. Use the keychain form if that file is shared.
{
"mcpServers": {
"inboxy": {
"command": "npx",
"args": ["-y", "@inboxychat/mcp"],
"env": { "INBOXY_API_KEY": "${INBOXY_API_KEY}" }
}
}
}Claude Code expands ${INBOXY_API_KEY} from your shell, so the key stays out of the file.
Claude Desktop
Settings → Developer → Edit Config, add the server to claude_desktop_config.json, then restart Claude Desktop. Claude Desktop does not expand ${VAR}: store the key with inboxy auth login and leave out "env", or put the key in "env" and keep the file private.
{
"mcpServers": {
"inboxy": {
"command": "npx",
"args": ["-y", "@inboxychat/mcp"]
}
}
}If Claude Desktop cannot find npx, use its absolute path (run which npx).
Codex (OpenAI Codex CLI)
Codex connects to the hosted server over HTTPS and signs in with OAuth in your browser; approve the consent screen in Inboxy as a company admin. Needs a recent Codex CLI: update it if --url or codex mcp login is not recognised.
codex mcp add inboxy --url https://api.inboxy.chat/mcp
codex mcp login inboxy[mcp_servers.inboxy]
url = "https://api.inboxy.chat/mcp"The same server written in the Codex config file. Run codex mcp login inboxy after saving it.
codex mcp add inboxy --env INBOXY_API_KEY="$INBOXY_API_KEY" -- npx -y @inboxychat/mcpCodex saves the value in ~/.codex/config.toml; keep that file private. With the key in the keychain (inboxy auth login), leave out --env.
Gemini CLI
Gemini CLI connects to the hosted server over HTTPS. After adding it, start gemini and run /mcp auth inboxy to sign in with OAuth; approve the consent screen in Inboxy as a company admin.
gemini mcp add --transport http inboxy https://api.inboxy.chat/mcpThen run /mcp auth inboxy inside Gemini CLI.
{
"mcpServers": {
"inboxy": {
"httpUrl": "https://api.inboxy.chat/mcp"
}
}
}{
"mcpServers": {
"inboxy": {
"command": "npx",
"args": ["-y", "@inboxychat/mcp"],
"env": { "INBOXY_API_KEY": "$INBOXY_API_KEY" }
}
}
}Gemini CLI reads $INBOXY_API_KEY from your shell, so the key stays out of the file.
Cursor
{
"mcpServers": {
"inboxy": {
"command": "npx",
"args": ["-y", "@inboxychat/mcp"]
}
}
}With the key in the keychain. Otherwise add "env": { "INBOXY_API_KEY": "..." } and keep the file out of git.
VS Code
{
"inputs": [
{ "type": "promptString", "id": "inboxy-key", "description": "Inboxy API key", "password": true }
],
"servers": {
"inboxy": {
"type": "stdio",
"command": "npx",
"args": ["-y", "@inboxychat/mcp"],
"env": { "INBOXY_API_KEY": "${input:inboxy-key}" }
}
}
}VS Code asks for the key once and stores it securely. Drop "inputs" and "env" if the key is in the keychain.
Quickstart
- Create a key with the read scopes you want.
- Store it:
inboxy auth login. - Add the server to your client (above).
- Ask: "Which Inboxy company am I connected to?" The client calls company_get.
How-to guides
Questions to try
- "How many orders are still pending? List the five oldest." (orders_list)
- "Find the customer with phone 9665... and show their orders." (contacts_search, orders_list)
- "Summarise today’s unread WhatsApp conversations." (conversations_list, conversation_messages)
- "How close am I to my plan limits?" (usage_get)
- "Is product SKU ABC-1 in stock?" (products_search)
Several companies (agencies)
Store one profile per company with inboxy auth login --profile client-a, then add one server per company with INBOXY_PROFILE set.
claude mcp add inboxy-client-a -e INBOXY_PROFILE=client-a -- npx -y @inboxychat/mcp
claude mcp add inboxy-client-b -e INBOXY_PROFILE=client-b -- npx -y @inboxychat/mcpReference
Tools
Lists use cursor paging: limit 1-50 (default 20); pass meta.nextCursor back as cursor. operation_execute is marked potentially destructive; discovery and preview are read-only.
| Tool | Scope | Reads |
|---|---|---|
company_get | — | The connected company, the key in use (name, scopes, expiry) and its rate limits |
usage_get | analytics:read | Plan, billing period and usage against each limit |
orders_list | orders:read | Orders, newest first; filter by status, payment, fulfillment, source, store, contact, text or date |
order_get | orders:read | One order with items, totals, customer and tracking |
contacts_search | contacts:read | Contacts by name, phone or email; filter by status, lifecycle stage, tags or date |
contact_get | contacts:read | One contact with tags, custom fields and order totals |
conversations_list | conversations:read | Inbox conversations with their last message; filter by status, channel, assignee, unread, text or date |
conversation_get | conversations:read | One conversation: contact, channel, status, labels and last message |
conversation_messages | messages:read | Messages of one conversation, newest first |
products_search | products:read | Catalog products by name or SKU |
product_get | products:read | One product with price, stock and source store |
tickets_list | tickets:read | Customer tickets, filtered by status, priority, contact, assignee or text |
ticket_get | tickets:read | One ticket with status, priority, contact and due date |
tasks_list | tasks:read | Team tasks, filtered by status, priority, assignee, due date or overdue |
task_get | tasks:read | One task with its due date, assignee and links |
campaigns_list | campaigns:read | WhatsApp campaigns with sent, delivered, read and failed counts |
campaign_get | campaigns:read | One campaign and its results |
templates_list | templates:read | WhatsApp (Meta) templates with status, category and quality |
appointments_list | meetings:read | Calendar appointments with time, contact and confirmation |
operations_list | — | Discover 25 audited operations; metadata is not permission to execute |
operation_inspect | — | Inspect exact input schema, required scope, effects and warnings |
operation_preview | — | Validate locally and preview the exact request and confirmation hash |
operation_execute | — | Execute a bounded operation with its required scope; mutations require explicit approval, exact confirmation and idempotency key |
message_send | messages:send | Separate real text-send action: exact recipient, channel, content approval and idempotency required |
lifecycle_activate | — | Separate live activation with exact graph/version or channel approval and idempotency |
campaign_send | campaigns:write | Send or resume only the exact approved campaign snapshot |
campaign_schedule | campaigns:write | Authorize future delivery of the exact approved audience/content/sender/time |
Environment
| Variable | Meaning |
|---|---|
INBOXY_API_KEY | The API key |
INBOXY_API_URL | API origin (default https://api.inboxy.chat) |
INBOXY_PROFILE | Stored profile to use |
INBOXY_TIMEOUT_MS | Per-request timeout (default 20000) |
Limits and safety
Tool results contain text written by customers. Each result starts with an "UNTRUSTED DATA" notice and is wrapped in an <inboxy_data> block; the model is told never to follow instructions inside it. Review what your assistant does with the data.
- Writes are limited to the audited operation catalog with explicit confirmation.
- One API read per tool call, and nothing else.
- The same rate limits as the REST API apply to the key.
- HTTPS only (http for localhost); redirects are refused; the key never appears in results, errors or logs.
- Cancelling a request in the client aborts the HTTP request.
Troubleshooting
Run inboxy doctor to check the same key and URL the server uses.
| Symptom | Fix |
|---|---|
inboxy-mcp: no API key | Set INBOXY_API_KEY in the client config, or run inboxy auth login. |
Inboxy error API_TOKEN_REQUIRED | The key is unknown, revoked or expired. Create a new one. |
Inboxy error INSUFFICIENT_PERMISSIONS | The key lacks the scope the tool needs (see the table above). |
spawn npx ENOENT | The client cannot find npx. Use its absolute path, and Node.js >= 20.3. |
Links
Create an API key
Keys are created by a company admin on the Developers page of the dashboard.
