ChatofyHelp Center
Enter
Developer DocsSign In
Help CenterAPI & DevelopersMCP Server for AI Assistants
Integration

MCP Server for AI Assistants

The Chatofy MCP server lets Claude, Cursor, ChatGPT, and other Model Context Protocol clients interact with your CRM in plain English — no code required. Connect Claude Desktop and AI clients directly via our hosted Streamable HTTP endpoint at https://app.chatofy.in/api/mcp with 1-click browser OAuth, or run the local stdio server on your machine.

Developer API vs Chatofy MCP Server

The Developer REST API is for developers writing scripts, webhooks, and backend services with code and schemas. The Chatofy MCP Server is for anyone — founders, operators, sales reps, and developers — to read CRM data and trigger actions in plain language using their favorite AI assistant.

What You Can Ask

  • "How many contacts do we have, and show the 10 newest?"
  • "Find the contact for +919876543210 and show their attributes."
  • "Show the chat history for +919876543210 and check if we are inside the 24-hour service window."
  • "Tag contact +919876543210 as high-intent and enterprise-prospect."
  • "List our sales pipelines and show deals in the Qualified stage."
  • "Create a deal for ₹5,00,000 for contact +919876543210 in the Enterprise Pipeline."
  • "Move deal deal-uuid-123 to Closed-Won."
  • "Draft a marketing template for our spring sale with {{1}} discount and submit it to Meta."
  • "Show all active chatbot flows and trigger the Onboarding Flow for +919876543210."
  • "Did our message to +919876543210 get delivered or read?"
  • "Which templates are still pending approval?"
  • "Send an appointment reminder with Yes and Reschedule reply buttons to +919876543210."
  • "Send our latest product catalogue PDF to +919876543210."
  • "Show the delivery logs for the spring-offer campaign."

WhatsApp 24-Hour Rule Still Applies

Meta restricts free-form text and media messages to active customer service windows (within 24 hours of the customer's last inbound message). If you ask the assistant to message a contact whose window has expired, it checks the window first and uses or suggests an approved Meta template instead.

Before You Start

  1. Confirm your plan includes API access. Otherwise requests return 403 FORBIDDEN.
  2. Create a key in Settings → API Keys.
  3. Install Node.js 18 or later.

Read and Write Access

The server is read-only by default. Set CHATOFY_ENABLE_WRITES=true (or pass ?writes=true on the hosted HTTP endpoint) to let the assistant create or update contacts, send plain text, media assets, interactive reply buttons, or approved templates. Write tools are not offered to the assistant while writes are off.

Hosted Streamable HTTP Endpoint (ChatGPT & Remote Agents)

For web-based AI clients like ChatGPT Custom GPTs, Claude Web custom connectors, or Cursor, Chatofy exposes a hosted Streamable HTTP MCP endpoint:

URL: https://app.chatofy.in/api/mcp
Header: Authorization: Bearer cfy_sk_live_...
Read-only mode: https://app.chatofy.in/api/mcp?writes=false

The hosted endpoint automatically validates tenant authentication, applies rate limits, and isolates data per organization. All API actions execute with the permissions and quota of your organization's API key.

1-Click Browser OAuth 2.0 PKCE Login

Chatofy supports standard OAuth 2.0 Authorization Code flow with PKCE (RFC 7636). Claude Code connects with the command below and no manual API key copying. Claude Desktop connects as a custom connector instead, described in the next section:

# 1. Add Chatofy Streamable HTTP MCP server
claude mcp add --transport http chatofy https://app.chatofy.in/api/mcp
# 2. Authenticate via browser consent window
claude mcp login chatofy

Connectors register themselves automatically (RFC 7591), so you only paste the server URL. You never need to create or enter an OAuth Client ID. For custom AI integrations, the OAuth endpoints are available at:

  • Dynamic Client Registration: https://app.chatofy.in/api/mcp/oauth/register
  • Authorization URL: https://app.chatofy.in/auth/mcp/authorize
  • Token URL (PKCE): https://app.chatofy.in/api/mcp/oauth/token
  • Userinfo URL: https://app.chatofy.in/api/mcp/oauth/userinfo
  • Protected Resource Metadata: https://app.chatofy.in/.well-known/oauth-protected-resource/api/mcp
  • Discovery Document: https://app.chatofy.in/.well-known/oauth-authorization-server
  • OIDC Discovery Document: https://app.chatofy.in/.well-known/openid-configuration
  • Static Client ID (optional manual fallback): claude-desktop

Connect Claude Desktop

Claude Desktop connects to Chatofy as a custom connector. You paste the server URL once and Claude registers itself. You never enter an OAuth Client ID or copy an API key.

  1. Open Claude Desktop and go to Customize → Connectors. On older builds, use Settings → Connectors.
  2. Click + Add, then choose Add custom connector.
  3. Enter the name Chatofy and the server URL https://app.chatofy.in/api/mcp. Click Continue.
  4. Under Authentication, choose Sign in now.
  5. Under OAuth client, choose Register automatically. Click Continue, then Add.
  6. In the browser consent page, sign in, choose the workspace, check the client name and redirect host, and click Approve.
  7. The connector shows as Connected. Enable it in a chat with + → Connectors.

Requirements: an organization plan with API Access, a Claude plan that supports custom connectors, and a public HTTPS server URL. Remote connectors are reached from Anthropic's cloud, so localhost and VPN-only addresses do not work. For read-only access, use ?writes=false on the URL.

If the connector shows 401 or 403, or cannot connect, the full troubleshooting table is in the Claude Desktop Setup guide.

Grounding Resources & Workflows

The server exposes MCP resources (resource://chatofy/rules, resource://chatofy/limits, resource://chatofy/templates, resource://chatofy/conversations, resource://chatofy/conversation/{phone}, resource://chatofy/pipelines, and resource://chatofy/flows) to ground the assistant on WhatsApp Cloud API policies, button limits, live templates, live customer chat threads, CRM sales pipelines, and visual chatbot flows without hallucination. Built-in prompts (re_engage_contact, analyze_campaign, send_interactive_survey, draft_contextual_reply, qualify_lead_and_create_deal, and draft_and_submit_template) guide multi-step workflows.

Full Setup & Dedicated Portal

The complete client configuration guides, 1-click browser OAuth, interactive tool catalog, schema explorer, and error reference are available in the dedicated MCP Developer Portal at /developer/mcp.

Was this article helpful?

Your feedback helps us refine and improve Chatofy technical documentation.

Related Articles

View all API & Developers guides

Getting Started with the Chatofy API

Overview of the REST API v1, authentication, and available endpoints.

API Key Management & Security

Generate, revoke, and manage API keys with granular permission scopes.

API Reference Overview

Complete reference for contacts, campaigns, templates, and messaging endpoints.

Webhooks Guide

Configure outbound webhooks to receive real-time events from Chatofy.

Chatofy Help Center
Help HomeDeveloper DocsPrivacyTerms

© 2026 Chatofy. All rights reserved.