# MCP Quickstart


The Social Neuron MCP server gives AI agents access to 91 tools for content creation, scheduling, analytics, and optimization. This guide gets you connected in under 2 minutes.

## Prerequisites

- A Social Neuron account on a Pro plan or above, or an active 14-day trial (trials include full MCP access)
- Node.js 20+ installed
- An MCP-compatible client (Claude Code, Claude Desktop, VS Code, or Cursor)

## Step 1: Authenticate

```bash
npx -y @socialneuron/mcp-server login --device
```

This opens your browser to authorize access. After you approve, the CLI receives your API key automatically and stores it in your OS keychain.

## Step 2: Add to Your Client

### Claude Code

```bash
claude mcp add socialneuron -- npx -y @socialneuron/mcp-server
```

### Claude Desktop

Add to your `claude_desktop_config.json`:

- **macOS**: `~/Library/Application Support/Claude/claude_desktop_config.json`
- **Windows**: `%APPDATA%\Claude\claude_desktop_config.json`
- **Linux**: `~/.config/Claude/claude_desktop_config.json`

```json
{
  "mcpServers": {
    "socialneuron": {
      "command": "npx",
      "args": ["-y", "@socialneuron/mcp-server"]
    }
  }
}
```

### VS Code

Add to `.vscode/mcp.json` in your workspace:

```json
{
  "servers": {
    "socialneuron": {
      "command": "npx",
      "args": ["-y", "@socialneuron/mcp-server"]
    }
  }
}
```

### Cursor

Add to `.cursor/mcp.json` in your workspace:

```json
{
  "mcpServers": {
    "socialneuron": {
      "command": "npx",
      "args": ["-y", "@socialneuron/mcp-server"]
    }
  }
}
```

## Step 3: Start Using

Ask Claude things like:

- "What content should I post this week?"
- "Generate 5 content ideas about sustainable fashion for Gen Z"
- "Schedule my latest video to YouTube and TikTok"
- "Show me my best-performing content this month"
- "Check my analytics and suggest improvements"

## CLI Reference

After global install (`npm i -g @socialneuron/mcp-server`), you can use the `socialneuron-mcp` command directly. Otherwise, prefix with `npx @socialneuron/mcp-server`.

```bash
# Authentication
socialneuron-mcp login --device     # Device code flow (recommended)
socialneuron-mcp login              # Browser OAuth flow
socialneuron-mcp login --paste      # Paste API key manually
socialneuron-mcp logout             # Clear stored credentials

# Quick commands (no LLM needed)
socialneuron-mcp sn credits         # Check credit balance
socialneuron-mcp sn posts --days 7  # Recent posts
socialneuron-mcp sn usage           # API usage breakdown
socialneuron-mcp sn info            # Version, auth, credits, tool count
socialneuron-mcp sn tools           # List all available tools

# Interactive mode
socialneuron-mcp repl               # Start interactive REPL
```

Add `--json` to any command for machine-readable output.

## Troubleshooting

### Authentication fails

Make sure you have a Pro plan or above, or an active trial. Free and Starter plans do not include API access.

### "Command not found" after install

Use `npx @socialneuron/mcp-server` instead of `socialneuron-mcp`, or install globally with `npm i -g @socialneuron/mcp-server`.

### Windows credential storage

The file fallback (`~/.config/social-neuron/credentials.json`) does not have strong permission enforcement on NTFS. For production use on Windows, set the `SOCIALNEURON_API_KEY` environment variable instead.

## Next Steps

- [Authentication Guide](/docs/guides/authentication) -- OAuth2, scopes, and security details
- [Credit System](/docs/guides/credit-system) -- How credits work and cost per operation
- [Workflow Recipes](/docs/guides/workflows) -- Common multi-step automation patterns
- [MCP Tools API](/tools-api) -- Full tool reference with parameters and schemas
