# MCP server

> Connect Claude, Cursor, ChatGPT and other AI agents to Socialit through the remote MCP server at /mcp, with OAuth or an API key, and pick the toolsets they need.

Socialit runs a remote [Model Context Protocol](https://modelcontextprotocol.io) server. Every operation of the REST API is also an MCP tool, so an agent can draft and schedule posts, answer the inbox, read analytics, run broadcasts and manage accounts with the same validation, rate limits and permissions as the API. Tool calls run through the real `/v1` endpoints, so responses and errors are identical.

| | |
|---|---|
| URL | `https://api.socialit.com/mcp` |
| Transport | Streamable HTTP (stateless) |
| Auth | OAuth 2.1 with PKCE and dynamic client registration, or `Authorization: Bearer sk_live_…` |
| Plans | Every plan, using the plan's API request budget |

## Connect a client

  - [Claude](/docs/mcp/claude/)Claude, Claude Desktop and Claude Code.
  - [Cursor](/docs/mcp/cursor/)One entry in mcp.json.
  - [ChatGPT](/docs/mcp/chatgpt/)Custom connector in developer mode.

Any other client that supports remote MCP servers over Streamable HTTP works the same way: give it the URL and sign in, or send an API key header.

## OAuth or API key

- **OAuth** is best for people: the client opens a Socialit consent screen, you pick the workspaces and scopes (`read`, `write`, `admin`), and you can revoke the connection in **Account → Connected apps**. The agent acts with your role and profile access. OAuth connections can reach several workspaces: they get `list-workspaces` and `switch-workspace` tools and a `workspace` argument on every tool.
- **API keys** are best for servers and scripts. Use a `read` key for reporting agents, and restrict a key to some profiles to fence an agent in.

Everyone gets `get-current-workspace`. Tools the credential can't call are hidden from `tools/list`.

## Tool names

A tool is named after its operation ID in kebab-case: `createPost` is `create-post`, `listConversations` is `list-conversations`. Every endpoint in the [API reference](/docs/api-reference/) shows its tool name and toolset, and an **MCP** tab with a ready-made `tools/call` request. The input schema merges the path, query and body parameters; list tools also take `filters: [{ field, condition, value }]`. Tools are annotated as read-only, destructive, idempotent or open-world.

## Toolsets

Large tool lists cost tokens and attention. Narrow them with query parameters on the server URL (or the `X-MCP-Toolsets` and `X-MCP-Readonly` headers):

- `?toolsets=posts,inbox` exposes only those toolsets.
- `?read_only=true` exposes only tools that don't change anything.

```text
https://api.socialit.com/mcp?toolsets=posts,media,accounts,analytics&read_only=true
```

### Focus mode toolsets (opt in)

[Focus mode](/docs/focus-mode/) adds a typed toolset per network, nearly 2,000 tools in total. Select only the networks your agent works on, next to the generic `focus` toolset:

```text
https://api.socialit.com/mcp?toolsets=focus,focus_youtube,focus_reddit
```

## Good practice

- Ask the agent to create **drafts** for anything public and review them in the app before they go out.
- Use profile-restricted keys or a read-only connection for agents that only report.
- Give agents the toolsets they need instead of everything.
- Every tool call appears in the workspace request logs and activity with the client's name.

---

Source: https://socialit.com/docs/mcp/
