MCP Integrations

Claude Code

Set up SocialCRM as an MCP server in the Claude Code CLI.

Connect SocialCRM to Claude Code as an MCP server. Query brand data, check AI platform visibility, and run optimization workflows directly from your terminal or editor.

Using the Claude desktop app (Cowork) instead? This guide is for the Claude Code CLI. For the desktop app's Connectors UI, see Claude Cowork.

Prerequisites

  • Claude Code installed
  • Node.js 18+
  • SocialCRM account with API key (get one from Settings > API Keys)

Quick Start

1. Authenticate

npx socialcrm auth sk_live_YOUR_KEY

Paste your API key when prompted, or pass it as an argument.

2. Configure Claude Code

npx socialcrm init --claude

This creates .mcp.json in your project directory with the SocialCRM MCP server config.

3. Restart Claude Code

Close and reopen Claude Code to connect. Wait 3–5 seconds for the MCP server to initialize. Claude will automatically discover all 21 tools.

Manual Configuration

If you prefer to configure manually, add this to .mcp.json in your project root:

{
  "mcpServers": {
    "socialcrm": {
      "type": "http",
      "url": "https://socialcrm.com/mcp",
      "headers": {
        "Authorization": "Bearer sk_live_YOUR_KEY_HERE"
      }
    }
  }
}

Replace sk_live_YOUR_KEY_HERE with your actual API key from Settings > API Keys.

Tip: Store your API key in an environment variable and reference it in the config to avoid committing secrets.

What You Can Ask

Once connected, ask questions in natural language. Claude translates these into SocialCRM API calls:

  • "List my brand profiles"
  • "What is my brand visibility score on ChatGPT, Claude, and Gemini?"
  • "Show me recent mentions of my brand across the core benchmarked engines"
  • "List available workflows and check my credit balance"
  • "Run the AI Citation Builder workflow for my main brand"

Example Session

You: What does AI say about Ace Auto Repair?

Claude: I'll check your AI visibility across platforms.
[Calls get_platform_metrics with brandId: "Ace Auto Repair"]
[Calls get_brand_mentions with brandId: "Ace Auto Repair"]

Your brand "Ace Auto Repair" has visibility scores of:
- ChatGPT: 68/100 (42 mentions, mostly positive)
- Claude: 55/100 (28 mentions)
- Gemini: 40/100 (15 mentions)

I found some issues — ChatGPT lists incorrect hours. Want me to run an
AI Shop Checkup workflow for a full audit?

You: Yes, run it.

Claude: Let me check your credits first.
[Calls get_credits]
You have 425 credits available. The AI Shop Checkup costs 25 credits.

[Calls run_workflow with workflowId: "ai_shop_checkup"]
Workflow started! Run ID: run_f47ac10b...
I'll poll for status.

[Calls get_run_status — polls every 10 seconds]
...
Workflow completed in 4 minutes. Here's your AI Health Report:
- Overall accuracy: 72%
- 3 hallucinations detected
- Top fix: Route corrected hours for the tested engines

Tips

  • You can use brand names directly (e.g., "Ace Auto Repair") instead of looking up UUIDs — the server resolves names automatically.
  • Ask Claude to run workflows, poll for results, and interpret findings all in a single conversation.
  • For a user-wide setup across every project, put the same JSON in ~/.claude/mcp.json instead of the per-project .mcp.json.

Troubleshooting

Tools not appearing — Restart Claude Code completely (close the window and reopen). Wait 3–5 seconds for the MCP server to initialize. If tools still don't appear, check the .mcp.json file exists and is valid JSON, and that type is "http" (not "url").

Authentication failed — Run npx socialcrm auth again with a fresh key. You can regenerate API keys in Settings > API Keys.

Check connection — Run npx socialcrm status to verify the CLI can reach the MCP server and your key is valid.