> ## Documentation Index
> Fetch the complete documentation index at: https://docs.postsyncer.com/llms.txt
> Use this file to discover all available pages before exploring further.

# Integrating MCP clients

> Connect Claude (connector/OAuth), Claude Desktop, Claude Code, Cursor, and other MCP clients to PostSyncer over Streamable HTTP.

# Client setup

Configure your AI client to connect to the PostSyncer MCP server. There are two ways to authenticate:

* **Connector (OAuth)** — for clients that support it (e.g. Claude custom connectors). No token to create; you authorize in PostSyncer. See [Connect as a connector (OAuth)](#connect-as-a-connector-oauth) below.
* **Bearer token** — for config-file clients (Claude Desktop, Claude Code, Cursor) and scripts. See [Connect with a Bearer token](#connect-with-a-bearer-token) below.

## Connect as a connector (OAuth)

If your client supports MCP connectors (Claude on the web and desktop do), this is the simplest path — there is **no token to create or paste**.

1. In Claude, open **Settings → Connectors → Add custom connector** (the option may be **Add custom connector** / **Connect apps**; it requires custom connectors to be enabled for your plan).
2. Set the **URL** to `https://postsyncer.com/mcp` and add it.
3. Claude sends you to PostSyncer to **authorize**. Sign in if needed, then click **Allow** on the consent screen.
4. Claude is connected. The PostSyncer tools (e.g. `list-workspaces`, `create-post`) are now available, scoped to the workspaces you belong to.

To disconnect later, remove the connector in Claude and/or revoke access from your PostSyncer account.

### One-click connect links

Some clients accept a deep link that pre-fills the PostSyncer server, so you only confirm and authorize. The same buttons are available in-app under **Settings → API Keys → Connect to AI assistants**.

| Client     | One-click link                                                                                                                                                                                                                |
| ---------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| **Claude** | [Add PostSyncer to Claude](https://claude.ai/customize/connectors?modal=add-custom-connector\&connectorName=PostSyncer\&connectorUrl=https%3A%2F%2Fpostsyncer.com%2Fmcp) — opens the *Add custom connector* dialog, prefilled |

**ChatGPT** and other clients have no prefill link — add `https://postsyncer.com/mcp` manually in their connector settings.

<Note>
  Behind the scenes this uses standard OAuth 2.0 (discovery + Dynamic Client Registration + PKCE). Any MCP client that implements the connector/OAuth flow can use it against `https://postsyncer.com/mcp` — it will discover the endpoints automatically.
</Note>

## Connect with a Bearer token

<Note>
  **Create a token first:** open [app.postsyncer.com → Settings → API Integrations](https://app.postsyncer.com/dashboard?action=settings\&section=api-integrations), click **Create**, and copy the key, see [Authentication](/essentials/authentication).
</Note>

### Connection details

| Setting           | Value                                                         |
| ----------------- | ------------------------------------------------------------- |
| **URL**           | `https://postsyncer.com/mcp`                                  |
| **Transport**     | Streamable HTTP                                               |
| **Authorization** | `Bearer YOUR_TOKEN` (send as the `Authorization` HTTP header) |

Replace `YOUR_TOKEN` with the token from API Integrations (include the `Bearer ` prefix in the header value).

## Claude Desktop

Claude Desktop only loads MCP servers as **local processes** (`command` + `args`). It does **not** use the `url` / `headers` shape from HTTP-native clients. Use the [`mcp-remote`](https://www.npmjs.com/package/mcp-remote) proxy so stdio speaks to PostSyncer’s HTTPS endpoint.

Add PostSyncer under `mcpServers` in your Claude Desktop config:

<Tabs>
  <Tab title="macOS">
    Edit `~/Library/Application Support/Claude/claude_desktop_config.json`:

    ```json theme={null}
    {
      "mcpServers": {
        "postsyncer": {
          "command": "npx",
          "args": [
            "mcp-remote",
            "https://postsyncer.com/mcp",
            "--header",
            "Authorization: Bearer YOUR_TOKEN_HERE"
          ]
        }
      }
    }
    ```
  </Tab>

  <Tab title="Windows">
    Edit `%APPDATA%\Claude\claude_desktop_config.json`:

    ```json theme={null}
    {
      "mcpServers": {
        "postsyncer": {
          "command": "npx",
          "args": [
            "mcp-remote",
            "https://postsyncer.com/mcp",
            "--header",
            "Authorization: Bearer YOUR_TOKEN_HERE"
          ]
        }
      }
    }
    ```
  </Tab>
</Tabs>

On Linux, the file is usually `~/.config/Claude/claude_desktop_config.json`.

**Tips:** If `npx` prompts to install packages, add `-y` as the first entry in `args` (for example `["-y", "mcp-remote", ...]`). Node 18+ must be on your PATH-Claude Desktop uses your system Node. Restart Claude Desktop after saving.

On **Windows** (and some Cursor builds), spaces inside a single `args` string can be mangled; if the header fails, use the [env workaround](https://www.npmjs.com/package/mcp-remote#custom-headers): put `Authorization:Bearer ${POSTSYNCER_TOKEN}` in `args` (no space after the colon) and set `POSTSYNCER_TOKEN` to `Bearer YOUR_TOKEN_HERE` in `env`.

## Claude Code

Claude Code supports **HTTP** MCP servers natively (recommended for PostSyncer). Use the CLI or a `.mcp.json` / `~/.claude.json` entry as in the [Claude Code MCP docs](https://code.claude.com/docs/en/mcp).

**CLI (Bearer token):**

```bash theme={null}
claude mcp add --transport http postsyncer https://postsyncer.com/mcp \
  --header "Authorization: Bearer YOUR_TOKEN_HERE"
```

**JSON** (for example project `.mcp.json` or user config)-HTTP servers use `type`, `url`, and `headers`:

```json theme={null}
{
  "mcpServers": {
    "postsyncer": {
      "type": "http",
      "url": "https://postsyncer.com/mcp",
      "headers": {
        "Authorization": "Bearer YOUR_TOKEN_HERE",
        "Accept": "application/json"
      }
    }
  }
}
```

Alternatively, you can use the same **`mcp-remote` + `npx`** block as [Claude Desktop](#claude-desktop) if you prefer one config shape everywhere.

## Cursor

1. Open **Cursor Settings → MCP** and add a new server, **or** edit **`~/.cursor/mcp.json`** (global) or **`.cursor/mcp.json`** (project)-see [Cursor’s MCP docs](https://cursor.com/docs/context/mcp).
2. For a remote server, use **`url`** and **`headers`** (Cursor’s supported remote shape). Prefer an env var for the token via [config interpolation](https://cursor.com/docs/context/mcp):

```json theme={null}
{
  "mcpServers": {
    "postsyncer": {
      "url": "https://postsyncer.com/mcp",
      "headers": {
        "Authorization": "Bearer ${env:POSTSYNCER_TOKEN}",
        "Accept": "application/json"
      }
    }
  }
}
```

Set `POSTSYNCER_TOKEN` to your personal access token only (the same secret string as in API Integrations-not the word `Bearer`; the JSON adds `Bearer ` for you). For a one-off test you can use `"Authorization": "Bearer YOUR_TOKEN_HERE"` instead of `${env:...}`.

If your Cursor version does not connect with `url` + `headers`, use the same **`mcp-remote` + `npx`** block as [Claude Desktop](#claude-desktop) ([`mcp-remote` notes](https://www.npmjs.com/package/mcp-remote) that some clients still need this for OAuth or compatibility).

Restart Cursor so the tool list refreshes.

## Other MCP clients

Any MCP-compatible client that supports **Streamable HTTP** (or remote HTTP) and **custom headers** can use PostSyncer:

* **URL:** `https://postsyncer.com/mcp`
* **Transport:** Streamable HTTP
* **Header:** `Authorization: Bearer YOUR_TOKEN_HERE`
* **Recommended:** `Accept: application/json`

Follow that product’s own docs for where to enter the URL and headers.

## Verify the connection

After connecting, ask your assistant to run a read-only tool, for example:

> List my workspaces

If setup is correct, it should call `list-workspaces` and return data. Then try **list my connected accounts** to exercise `list-accounts`.

## Troubleshooting

| Symptom                    | What to check                                                                                                                                                                                                                                           |
| -------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| 401 / Unauthorized (token) | Token missing, revoked, or `Authorization` not formatted as `Bearer ` plus your token (no typos or extra spaces). Create a new token from [API Integrations](https://app.postsyncer.com/dashboard?action=settings\&section=api-integrations) if unsure. |
| Connector won't authorize  | Make sure you're signed in to PostSyncer in the same browser, then click **Allow** on the consent screen. If the connector was removed, re-add `https://postsyncer.com/mcp` and authorize again.                                                        |
| Missing tools (token)      | Token abilities: you need `posts` for post, comment, and analytics tools; `workspaces` and `accounts` to discover IDs. Connector authorizations get full access, scoped to your workspaces.                                                             |
| Empty or partial tools     | Update the client; some older builds mishandle `tools/list` pagination.                                                                                                                                                                                 |

## See also

* [MCP overview](/mcp/overview)
* [Tools reference](/mcp/tools-reference)
* [Authentication](/essentials/authentication)
