- Hosted (remote) server — OAuth. You sign in through your browser; there is no key to copy or store.
- Local (npm) server — an API key in the
ALPHACAST_API_KEYenvironment variable.
OAuth (hosted server)
The hosted server athttps://mcp.alphacast.io/mcp is an OAuth 2.0 protected resource. The first time your client connects, it runs a standard authorization-code flow with PKCE:
- Your client opens a browser to the Alphacast authorization server at
https://auth.alphacast.io/. - You sign in with your Alphacast account (or approve the request if already signed in) and consent to the requested scopes.
- The client receives a token and uses it as a
Bearertoken on every request. Most clients refresh it automatically, so you only sign in once.
No API key is involved in this path — nothing to paste into a config file and nothing to rotate. To revoke access, sign out / remove the connector in your client, or revoke the session from your Alphacast account.
Most clients that support remote MCP servers (Claude Code, Claude Desktop, Cursor, VS Code) handle this OAuth flow for you. Clients that only support local stdio servers can reach the hosted server through the
mcp-remote bridge, which performs the same browser login — see Other clients.API key (local server)
The local npm package reuses the same API key as the REST API. There is no OAuth flow on this path.Environment variable
The server reads your API key from theALPHACAST_API_KEY environment variable at startup. You set this once in your client’s MCP configuration:
The key is the same raw API key you use for the REST API (where it goes as the HTTP Basic Auth username). Both authenticate as the same Alphacast account.
Permissions
The MCP server inherits whatever permissions the API key has on the underlying account:
If a tool call returns
403 Forbidden, the API key does not have the required permission on the target repository. Generate a new key under an account with the right access, or have the repository owner grant you write access.
Where to manage your key
- View, create, and revoke keys: alphacast.io/settings.
- Reference for the same key in the REST API: Authentication.
- Rotate immediately if a key was exposed; rotation invalidates the previous value.