> For the complete documentation index, see [llms.txt](https://docs.ox.security/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.ox.security/api-documentation/api-reference/model-context-protocol/mcp-integration-using-oauth.md).

# MCP Integration Using OAuth

This guide explains how to connect your IDE or AI coding tool to OX Security by using the OX MCP server and your OX Security account.

The first time your tool connects, sign in to your OX Security account in your browser instead of creating an MCP Integration Key.

You can use this guide to configure:

* [Cursor with OX MCP](#integrating-cursor-with-ox-mcp)
* [Claude Desktop with OX MCP](#integrating-claude-desktop-with-ox-mcp)
* [Claude Code with OX MCP](#integrating-claude-code-with-ox-mcp)
* [Visual Studio Code with OX MCP](#integrating-visual-studio-code-with-ox-mcp)

The OX MCP server URL is: <https://mcp.app.ox.security/>

> **Note:** Browser sign-in is available only with the SaaS OX MCP server. If you use an on-premises deployment, authenticate by using an MCP Integration Key instead. For instructions, see [**MCP Integration Guide using an MCP Integration Key**](/api-documentation/api-reference/model-context-protocol/mcp-integration-guide.md).

## Log into OX Security

The following login process is applicable to any tool used with this integration method.

1. Log in to OX if you are not already signed in.

> **Note:** If your organization requires SSO, sign in using your enterprise email address.

2. Select the OX organization to authorize MCP access for.

> **Note:** If you belong to a single OX organization only, it is selected automatically, and this step is skipped.

<figure><img src="/files/0iOX7Ku2rgsrjgsMdzy6" alt="" width="563"><figcaption></figcaption></figure>

The **Authorization Complete** message appears, and you are redirected back to your IDE or AI coding tool; OX Security now appears as a connected MCP server.

<figure><img src="/files/iGBOdvHaOu2hec0XgvaE" alt="" width="563"><figcaption></figcaption></figure>

## Integrating Cursor with OX MCP

By integrating with OX's MCP, Cursor becomes a security-aware development assistant, able to query live security data, suggest actions, and triage issues directly from your IDE.

**To integrate Cursor with OX MCP:**

1. Click [here](cursor://anysphere.cursor-deeplink/mcp/install?name=ox-security\&config=eyJ1cmwiOiJodHRwczovL21jcC5hcHAub3guc2VjdXJpdHkvIn0%3D) to open Cursor in the relevant location where you can start working.
2. Select **Install**. No token or header configuration is required.

<figure><img src="/files/YOh085ygkDTU0lxk2nch" alt="" width="563"><figcaption></figcaption></figure>

In the Cursor MCP settings, the **ox-security** server appears with a **Needs authentication** indication.

3. Select **Connect**.

<figure><img src="/files/EFazhsxYCsmsqI9JeR38" alt="" width="563"><figcaption></figcaption></figure>

The browser opens the OX Security authorization page.

4. Complete the login as described in [Logging in to OX Security](#logging-in-to-ox-security).

After logging in, the OX Security logo appears in the Cursor tools menu with the list of available tools. For more info, refer to [Cursor Documentation](https://docs.cursor.com/en/tools/developers).

<figure><img src="/files/zpJstXaH9z2x2KpGZgIj" alt="" width="563"><figcaption></figcaption></figure>

## Integrating Claude Desktop with OX MCP

Claude Desktop connects to the OX MCP server as a custom connector, providing teams with robust security capabilities directly from their desktop environment. No local configuration file is required.

**To integrate Claude Desktop with OX MCP:**

1. In Claude Desktop, go to **Settings** > **Connectors**.
2. Select **Add custom connector**.
3. Set a name (for example, **OX Security**) and the URL:

```
https://mcp.app.ox.security/
```

4. Select **Add**.

<figure><img src="/files/IkJs2dTHJXLudRGa0Jxn" alt="" width="563"><figcaption></figcaption></figure>

5. Open the new OX Security connector and select **Connect**.

The browser opens the OX Security authorization page.

6. Complete the login as described in [Log into OX Security](#log-into-ox-security).

<figure><img src="/files/NC7Lc2jbwARvq85D6get" alt="" width="563"><figcaption></figcaption></figure>

After authorization, OX Security tools are available in Claude Desktop conversations through the tools menu.

<figure><img src="/files/xa3fLDzFQsc4Ib4kpG42" alt="" width="563"><figcaption></figcaption></figure>

7. Review and adjust what Claude is allowed to do with each OX Security tool under **Settings** > **Connectors** > **OX Security** > **Tool permissions**.

<figure><img src="/files/PVT6FDIGySkjyFxXa8TN" alt="" width="563"><figcaption></figcaption></figure>

### Integrating Claude Code with OX MCP

Claude Code, Anthropic's agentic coding tool for the terminal, connects to the OX MCP server directly from the command line, allowing developers to query live security data, triage issues, and get remediation guidance without leaving their coding session.

> **Note:** Ensure Claude Code is installed and up to date. To check your version, run `claude --version`; to update, run `claude update`.

**To integrate Claude Code with OX MCP:**

1. Open a terminal and run the following command:

```bash
claude mcp add --transport http ox-security https://mcp.app.ox.security/
```

2. Start Claude Code:

```bash
claude
```

3. Run the `/mcp` command, select **ox-security** (shown with a **needs authentication** status), and choose **Authenticate**.

<figure><img src="/files/i0K9oAHotHAo5LqlRBhN" alt="" width="563"><figcaption></figcaption></figure>

The browser opens the OX Security authorization page.

4. Complete the login as described in [Log into OX Security](#log-into-ox-security).

<figure><img src="/files/BLrRCEuEQzkvEO6M714X" alt="" width="563"><figcaption></figcaption></figure>

5. Return to the terminal. The `/mcp` menu now shows **ox-security** with a **connected** status, along with the OX Security tools available to Claude Code.

<figure><img src="/files/eKls3J5ULOPwvWagD1Rn" alt="" width="563"><figcaption></figcaption></figure>

By default, the server is added only for the current project directory. To make it available in all of your projects, add `--scope user` to the command in step 1.

## Integrating Visual Studio Code with OX MCP

Visual Studio Code provides versatile options to connect with OX Security's MCP, enabling developers to streamline their security workflows within the VS Code ecosystem.

**To integrate VS Code with OX MCP:**

1. Open **VS Code Settings**.
2. Open **MCP User Configuration**, see [VS Code MCP Docs](https://code.visualstudio.com/docs/copilot/chat/mcp-servers) for details.

<figure><img src="/files/vaFE7X7yWcQDDMmQzjXF" alt="" width="449"><figcaption></figcaption></figure>

3. Add the JSON MCP server configuration for OX Security in `mcp.json`:

```json
{
  "servers": {
    "ox-security": {
      "type": "http",
      "url": "https://mcp.app.ox.security/"
    }
  }
}
```

4. Save the configuration and start the server. When VS Code prompts that the MCP server requires authentication, select **Allow**.

The browser opens the OX Security authorization page. complete the login as described in [Log into OX Security](#log-into-ox-security).

<figure><img src="/files/kZCBMPfMXArSVq1tF4EB" alt="" width="519"><figcaption></figcaption></figure>

5. In the **VS Code chat**, click **Add Context**.

<figure><img src="/files/4QfWq91oNLDG9cECH3ZV" alt="" width="444"><figcaption></figcaption></figure>

6. Select the desired tools.

<figure><img src="/files/IagZB4D42PIBfGCZraiu" alt="" width="440"><figcaption></figcaption></figure>

OX Security appears as an available MCP server.

<figure><img src="/files/TjsQ2IFABxEHcCkONsqa" alt="" width="382"><figcaption></figcaption></figure>


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter, and the optional `goal` query parameter:

```
GET https://docs.ox.security/api-documentation/api-reference/model-context-protocol/mcp-integration-using-oauth.md?ask=<question>&goal=<endgoal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is optional and describes the broader end goal you are ultimately trying to accomplish on behalf of the user. GitBook uses it to tailor the answer towards what is most useful for that goal.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
