Connecting Your Agent

This page shows how to connect an AI agent to the CloudShark MCP server. You need two things: an API token with MCP Access, and your agent configured with that token and the address of your CloudShark system.

The MCP server is off by default, so your CloudShark admin needs to turn it on before any agent can connect.

Create an API Token

If you don’t see API Tokens in your Preferences menu, user managed API tokens are turned off on your CloudShark system. This is the default. Ask your CloudShark admin to create a token for you or to turn on user managed tokens. See Who Can Create MCP Tokens.

No token can use the MCP server until you turn it on for that token. Open API Tokens, create a token or edit an existing one, and check MCP Access. Then check the token permissions for the tools you want your agent to use. The tool table lists the permission each tool needs.

MCP Access only admits the token to the MCP server. It does not grant any other permission, so a token with MCP Access and nothing else can connect but cannot read anything.

A token that requires a web login cannot be used with MCP, because MCP clients cannot log in through the web. Create a new token without that setting instead.

Once the token is saved, Show client setup in the token dialog gives you a ready-to-paste configuration for your agent with your server address and token already filled in. AI clients change often, so the configurations below are updated more frequently than the ones in CloudShark and may include clients that aren’t listed there yet.

Configure Your Agent

The MCP server is at /mcp on the address of your CloudShark system, for example https://cloudshark.example.com/mcp. Your agent sends the token in an Authorization header in the form Bearer <your API token>. Replace the example address and token below with your own.

Claude Code

Run this in a terminal:

claude mcp add --transport http cloudshark https://cloudshark.example.com/mcp \
  --header "Authorization: Bearer <your API token>"

Claude Desktop

Claude Desktop connects to CloudShark through mcp-remote, a small bridge that runs on your computer. Because the connection comes from your computer, this works when your CloudShark system is on a private network. You need Node.js 18 or later installed.

In Claude Desktop, open Settings, then Developer, and click Edit Config to open claude_desktop_config.json. Add this:

{
  "mcpServers": {
    "cloudshark": {
      "command": "npx",
      "args": [
        "-y",
        "mcp-remote",
        "https://cloudshark.example.com/mcp",
        "--header",
        "Authorization:${AUTH_HEADER}"
      ],
      "env": {
        "AUTH_HEADER": "Bearer <your API token>"
      }
    }
  }
}

Keep the header written as Authorization:${AUTH_HEADER} with no spaces. Claude Desktop on Windows does not handle spaces in args correctly, so the token goes in env instead.

If your CloudShark system uses http:// instead of https://, mcp-remote will not connect unless you add "--allow-http" to args after the server address. Only do this on a private network you trust, because your API token is sent unencrypted.

For other options, such as certificates on internal networks, see the mcp-remote documentation.

Save the file, then quit Claude Desktop completely and open it again.

Cursor and Other Clients

Add this to the client’s mcp.json, such as ~/.cursor/mcp.json:

{
  "mcpServers": {
    "cloudshark": {
      "type": "http",
      "url": "https://cloudshark.example.com/mcp",
      "headers": {
        "Authorization": "Bearer <your API token>"
      }
    }
  }
}

VS Code

Add this to .vscode/mcp.json in your workspace:

{
  "servers": {
    "cloudshark": {
      "type": "http",
      "url": "https://cloudshark.example.com/mcp",
      "headers": {
        "Authorization": "Bearer <your API token>"
      }
    }
  }
}

Codex

Add this to ~/.codex/config.toml:

[mcp_servers.cloudshark]
enabled = true
url = "https://cloudshark.example.com/mcp"

[mcp_servers.cloudshark.http_headers]
Authorization = "Bearer <your API token>"

Local Models

Agents that run a local model should work with the CloudShark MCP server as long as they support MCP over HTTP. The configuration varies from client to client, so check your client’s documentation for where to add the server address and Authorization header. If you run into problems with a specific agent, contact support and let us know.

Test the Connection

Once your agent is configured, try a simple prompt that only reads from CloudShark:

“List the five most recent captures in CloudShark and show me the details of the newest one.”

Your agent should call list_captures and capture_info and answer with filenames and capture details from your system. These tools need the Search for files and Get Info/Annotations permissions on the token.

Troubleshooting

If your agent cannot connect or its tools fail, check these first:

  • The token is refused. Make sure the token exists, is enabled, and has MCP Access checked. A token that requires a web login cannot be used.
  • A tool says the token lacks a permission. Check the matching permission on the token. See the tool table.
  • Nothing answers at /mcp. The MCP server may be turned off. Ask your CloudShark admin to turn it on.