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

# Hosted MCP server

> Connect to the hosted MCP server over Streamable HTTP with interactive OAuth or a private scoped bearer key.

Your MCP client must support a remote server at `https://api.bead.run/mcp`. The hosted MCP server provides tool discovery and skill resources so your agent can load guidance as it works.

## Interactive OAuth

Add the endpoint in your MCP client's remote-server configuration:

```json theme={"theme":{"light":"github-light","dark":"github-dark-default"}}
{
  "mcpServers": {
    "bead": {
      "url": "https://api.bead.run/mcp"
    }
  }
}
```

Configuration fields vary by client. Choose Streamable HTTP and use the client's OAuth connection flow. The server's 401 challenge points to protected-resource metadata.

Consent uses GitHub sign-in at [app.bead.run](https://app.bead.run), followed by explicit approval of requested client permissions. The authorization server supports dynamic registration and authorization code with S256 PKCE. Access tokens last one hour and target the MCP audience. API device-flow tokens target a different audience.

## Headless bearer access

Configure a private scoped bead key through your client's secret or environment support. Send it as `Authorization: Bearer` on every request. A session ID is not authorization.

For an HTTP transport check:

```bash theme={"theme":{"light":"github-light","dark":"github-dark-default"}}
curl -sS https://api.bead.run/mcp   -H "Authorization: Bearer $BEAD_API_KEY"   -H 'Content-Type: application/json'   -H 'Accept: application/json, text/event-stream'   --data '{"jsonrpc":"2.0","id":1,"method":"tools/list","params":{}}'
```

Use a private execution environment and keep request headers out of logs. Your MCP client handles protocol negotiation for normal use.

## Discover capabilities

Read every `tools/list` page using its `nextCursor`. Discovery returns 12 tools per page. Tool schemas and access depend on the server and your credentials.

Discovery, skill reads, pricing and enrollment are available without an account key. Purchase tools also support access through privately retained purchase IDs and possession secrets. Other operations require authenticated access and enforce their applicable scope, organization, revocation and funding checks. See [tools](https://docs.bead.run/mcp/tools.md), [skills and retained results](https://docs.bead.run/mcp/resources-results.md), and [agent signup](https://docs.bead.run/agent-signup.md).


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