Skip to main content
Cortex XCOR provides two MCP servers:
  • XCOR MCP server: Connects to your tenant and requires authentication.
  • Documentation MCP server: Serves public XCOR documentation and doesn’t require authentication.
Before you can use the XCOR MCP server, authenticate with the MCP client you use to access a large language model (LLM). Use one of the following options to configure authentication:
  • Generate an XCOR API token, either through a personal access token or a service account.
  • Use OAuth. To use the XCOR MCP server with OAuth, your MCP client must support OAuth.
    OAuth authentication with the XCOR MCP server has been tested with the following MCP clients only.
The following steps explain how to authenticate with popular AI-powered code editors. After authenticating, you can use the LLM features in your code editor to interact with the Cortex XCOR MCP server tools.

Prerequisites

If you’re authenticating your MCP client with an XCOR API token, use one of the following options to generate one:
  • Personal access: Create a personal access token to authenticate your user account with XCOR. When you authenticate with a personal access token, XCOR associates the actions you take with your identity and respects the permissions granted to your user account’s team.
  • Programmatic access: Create an unrestricted service account to create a persistent identity for a service or agent that you want to authenticate with your MCP client. You must have administrative access to create a service account.

Authenticating using Claude Code

To authenticate with the XCOR MCP server from Claude Code, add the MCP server as a remote HTTP server.
  1. From within Claude Code, run the following commands to add the XCOR MCP server and the public documentation MCP server:
    Replace the following for the XCOR MCP server:
    • Replace TENANT with the name of your Cortex XCOR tenant.
    • Replace API_TOKEN with the API token generated from your service account. Cortex XCOR recommends storing your API token in a separate file or Kubernetes Secret and calling it using an environment variable, such as $API_TOKEN.
    To authenticate using OAuth instead of an XCOR API token, omit the --header flag. You can also use the /mcp command to authenticate with OAuth authentication.
  2. Test your connection with the XCOR MCP server:
The command returns the details for the XCOR MCP server.

Authenticating using Codex command line interface

To authenticate with the XCOR MCP server from the Codex command line interface, add the MCP server as a streamable HTTP server.
  1. Store your XCOR API token in the CHRONOSPHERE_API_TOKEN environment variable. The Codex command line interface reads the token from this variable when it connects to the XCOR MCP server:
    Replace the following:
    • Replace API_TOKEN with the API token generated from your service account. Cortex XCOR recommends storing your API token in a separate file or Kubernetes Secret and calling it using an environment variable, such as $API_TOKEN.
  2. Run the following commands to add the XCOR MCP server and the public documentation MCP server:
    Replace the following for the XCOR MCP server:
    • Replace TENANT with the name of your Cortex XCOR tenant.
    To authenticate using OAuth instead of an XCOR API token, skip the previous step and omit the --bearer-token-env-var flag. When the Codex command line interface detects OAuth support, it starts the OAuth flow after adding the server. Otherwise, run codex mcp login chronosphere to authenticate with OAuth.
  3. Test your connection with the XCOR MCP server:
The command returns the details for the XCOR MCP server.

Authenticating using Cursor

To authenticate with the XCOR MCP server from Cursor, modify the mcp.json file to include the XCOR MCP server remote endpoint.
  1. From within Cursor, access the mcp.json file.
  2. Add the following configuration to the mcp.json file to add the XCOR MCP server and the public documentation MCP server:
    Replace the following for the XCOR MCP server:
    • Replace TENANT with the name of your Cortex XCOR tenant.
    • Replace API_TOKEN with the API token generated from your service account. Cortex XCOR recommends storing your API token in a separate file or Kubernetes Secret and calling it using an environment variable, such as $API_TOKEN.
    To authenticate using OAuth instead of an XCOR API token, omit the headers section from the configuration.
  3. Save and close the mcp.json file.
  4. Refresh the MCP server settings in Cursor.
The XCOR MCP server and documentation MCP server display in the list of configured MCP servers.

Authenticating using Gemini command line interface

To authenticate with the XCOR MCP server from the Gemini command line interface, add the MCP server as an HTTP server.
  1. Run the following commands to add the XCOR MCP server and the public documentation MCP server:
    Replace the following for the XCOR MCP server:
    • Replace TENANT with the name of your Cortex XCOR tenant.
    • Replace API_TOKEN with the API token generated from your service account. Cortex XCOR recommends storing your API token in a separate file or Kubernetes Secret and calling it using an environment variable, such as $API_TOKEN.
    The --scope user flag saves the configuration in your user settings instead of the current project, so your API token isn’t stored in project files.
    To authenticate using OAuth instead of an XCOR API token, omit the --header flag. The Gemini command line interface detects that the server requires OAuth and starts the OAuth flow. You can also use the /mcp auth chronosphere command to authenticate with OAuth.
  2. Test your connection with the XCOR MCP server:
The command returns the configured MCP servers and their connection status.

Authenticating using Visual Studio Code

To authenticate with the XCOR MCP server from Visual Studio Code, add the MCP server to the GitHub Copilot MCP configuration file.
  1. Store your XCOR API token in the CHRONOSPHERE_API_TOKEN environment variable on the host where Visual Studio Code runs. Visual Studio Code reads the token from this variable when it connects to the XCOR MCP server:
    Replace the following:
    • Replace API_TOKEN with the API token generated from your service account. Cortex XCOR recommends storing your API token in a separate file or Kubernetes Secret and calling it using an environment variable, such as $API_TOKEN.
  2. Open the ~/.copilot/mcp-config.json file. If the file doesn’t exist, create it.
  3. Add the following configuration to the mcp-config.json file to add the XCOR MCP server and the public documentation MCP server:
    Replace the following for the XCOR MCP server:
    • Replace TENANT with the name of your Cortex XCOR tenant.
    To authenticate using OAuth instead of an XCOR API token, skip the first step and omit the headers section from the configuration. When Visual Studio Code prompts you, complete the OAuth flow.
  4. Save and close the mcp-config.json file.
  5. In Visual Studio Code, run Chat: Open Customizations and select MCP Servers.
The XCOR MCP server and documentation MCP server display in the list of configured MCP servers.