Authentication
API keys for the REST API and CLI, and OAuth for the hosted MCP server.
BrainyShorts has two ways to authenticate, one per surface.
| Surface | Credential | How to send it |
|---|---|---|
| REST API, CLI, runners | API key (ba_sk_...) |
Authorization: Bearer <key> |
| Hosted MCP server | OAuth access token | Your MCP client handles it |
API keys
Sign in
Create a free account at brainyshorts.com and connect at least one social account.
Create a key
Open Dashboard → API keys and create a key. The full key is shown once and never again, so store it in your secret manager right away.
Send it as a Bearer token
curl https://www.brainyshorts.com/api/cli/accounts \
-H "Authorization: Bearer $BRAINY_API_KEY"Keys:
- start with
ba_sk_, and only a hash is stored - expire 365 days after creation
- carry the scopes
cli:access,media:write, andautomation:runs:claim - can be revoked from the same dashboard page
OAuth for MCP
The hosted MCP server at https://www.brainyshorts.com/api/mcp uses OAuth 2.1 with PKCE and dynamic client registration. You don’t create anything by hand: add the server URL to your client, and it discovers the flow from:
https://www.brainyshorts.com/.well-known/oauth-protected-resource/api/mcphttps://www.brainyshorts.com/.well-known/oauth-authorization-server
The client opens a browser window, you sign in and approve, and the client stores the token. Scopes are brainy:read and brainy:write. See MCP server for per-client setup.
