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

# Connect MCP

> Add the hosted Straddle Docs MCP and API MCP servers to your coding agent.

Connect Docs MCP for documentation search and API MCP for Straddle requests. If you want integration skills too, [install the Straddle plugin](/developer-tools/agent-plugin/install), which includes both connections.

## Before you start

Use a client that supports remote HTTP MCP servers. For API requests, get a sandbox API key from the [Straddle dashboard](https://dashboard.straddle.com) and supply it as `STRADDLE_API_KEY` in the environment that starts your client.

Restart the client after setting the variable. A desktop app must inherit the variable in its own process, including when you open it outside a terminal. Docs MCP needs no credential, so you can connect it independently.

## Add the servers

Choose your client. For documentation search alone, add only the `straddle-docs` entry or command.

<Tabs>
  <Tab title="Claude Code">
    From your project directory, register both servers in local scope:

    ```bash theme={null}
    claude mcp add --transport http --scope local \
      straddle-docs \
      https://straddle-build-straddle-openapi.apidocumentation.com/mcp

    claude mcp add --transport http --scope local \
      straddle-api \
      https://mcp.scalar.com/mcp/d5d1b1c2-ae5b-432d-b795-4fcb31cfdedd \
      --header 'Authorization: Bearer ${STRADDLE_API_KEY}'
    ```

    Keep the single quotes around the header so Claude Code receives the variable reference. Start Claude Code from that environment, enter `/mcp`, and confirm both connections.
  </Tab>

  <Tab title="Codex">
    Register the hosted servers:

    ```bash theme={null}
    codex mcp add straddle-docs \
      --url https://straddle-build-straddle-openapi.apidocumentation.com/mcp

    codex mcp add straddle-api \
      --url https://mcp.scalar.com/mcp/d5d1b1c2-ae5b-432d-b795-4fcb31cfdedd \
      --bearer-token-env-var STRADDLE_API_KEY
    ```

    Check the configuration before starting a new session:

    ```bash theme={null}
    codex mcp list --json
    ```

    Confirm both server URLs and `bearer_token_env_var: "STRADDLE_API_KEY"` for `straddle-api`.
  </Tab>

  <Tab title="Cursor">
    Open `~/.cursor/mcp.json` for a personal connection, or `.cursor/mcp.json` for a project connection. Merge these entries into the existing `mcpServers` object:

    ```json theme={null}
    {
      "mcpServers": {
        "straddle-docs": {
          "url": "https://straddle-build-straddle-openapi.apidocumentation.com/mcp"
        },
        "straddle-api": {
          "url": "https://mcp.scalar.com/mcp/d5d1b1c2-ae5b-432d-b795-4fcb31cfdedd",
          "headers": {
            "Authorization": "Bearer ${env:STRADDLE_API_KEY}"
          }
        }
      }
    }
    ```

    In **Customize**, confirm both servers are enabled and their tools appear. For additional options, see [Cursor's MCP guide](https://cursor.com/docs/mcp).
  </Tab>

  <Tab title="VS Code">
    In the Command Palette, select **MCP: Open User Configuration**. For a project connection, open `.vscode/mcp.json`. Merge these entries into the existing `servers` object:

    ```json theme={null}
    {
      "servers": {
        "straddle-docs": {
          "type": "http",
          "url": "https://straddle-build-straddle-openapi.apidocumentation.com/mcp"
        },
        "straddle-api": {
          "type": "http",
          "url": "https://mcp.scalar.com/mcp/d5d1b1c2-ae5b-432d-b795-4fcb31cfdedd",
          "headers": {
            "Authorization": "Bearer ${env:STRADDLE_API_KEY}"
          }
        }
      }
    }
    ```

    Select **MCP: List Servers**, choose each server, and select **Start**. Review the server trust prompt. In chat, open **Configure Tools** and confirm the tools appear.
  </Tab>
</Tabs>

## Verify each connection

<Steps>
  <Step title="Search documentation">
    Ask your agent to query Docs MCP:

    <Prompt description="Check Straddle documentation search." actions={["copy"]}>
      Use straddle-docs to search for webhook signature verification. Summarize the relevant instructions and link to the source.
    </Prompt>

    Expect a relevant documentation result with a source link.
  </Step>

  <Step title="Discover the API">
    Ask for a specification summary:

    <Prompt description="Check API MCP discovery." actions={["copy"]}>
      Use straddle-api's summarize-openapi-specs tool to summarize the available Straddle API specification.
    </Prompt>

    Expect a specification summary. This checks discovery; [read a sandbox account](/developer-tools/mcp/api-requests) to verify an authenticated request.
  </Step>
</Steps>

For connection or authentication errors, follow [MCP troubleshooting](/developer-tools/mcp/troubleshooting).


## Related topics

- [Troubleshoot MCP](/developer-tools/mcp/troubleshooting.md)
- [Connect your agent to Straddle](/developer-tools/mcp/overview.md)
- [Install the Straddle plugin](/developer-tools/agent-plugin/install.md)
- [Authentication and permissions](/developer-tools/mcp/safety.md)
- [Search Straddle documentation](/developer-tools/mcp/docs-search.md)


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.