For the complete documentation index, see llms.txt. This page is also available as Markdown.

How do I use Model Context Protocol (MCP) with Web API?

Learn how to connect an MCP client to Web API.

MCP is optional. Your existing requests to Web API keep working, and you can connect the MCP server whenever you want an AI agent to call Web API directly.

Connect to the Oxylabs MCP server

The remote MCP server is hosted and maintained by Oxylabs, so there is nothing to install.

1

In the dashboard, create a Web API instance and copy its API key.

2

Add your API key to the environment:

3

Add the server to your MCP client.

claude mcp add --transport http --scope user oxylabs-web-api \
  https://mcp.oxylabs.io/web-api-mcp \
  --header "Authorization: Bearer ${OXYLABS_WEB_API_KEY}"
codex mcp add oxylabs-web-api \
  --url https://mcp.oxylabs.io/web-api-mcp \
  --bearer-token-env-var OXYLABS_WEB_API_KEY

For any client that supports remote MCP servers with custom headers, add the server URL and an Authorization header to the client's MCP configuration. For Cursor mcp.json:

{
  "mcpServers": {
    "oxylabs-web-api": {
      "url": "https://mcp.oxylabs.io/web-api-mcp",
      "headers": {
        "Authorization": "Bearer ${env:OXYLABS_WEB_API_KEY}"
      }
    }
  }
}

Field names can differ between clients – check your client's documentation for how to add a remote MCP server with headers.

Note: Remote MCP works with clients that support remote MCP servers with custom headers. Clients that only support OAuth sign-in, such as custom connectors in the claude.ai web interface, can't connect to it. If your client falls into that group, or you prefer to run the server yourself, use the self-hosting option.

🧠 For configuration, self-hosting, and the full tool list, see MCP server documentation and GitHub.

Last updated

Was this helpful?