Authentication
Bedrock supports two authentication schemes. Most programmatic callers use an API key; the Bedrock portal and a handful of user-scoped endpoints use token auth.API Key (Bearer)
API keys are scoped to your organization and grant access to every resource your organization owns — templates, agents, adapters, tracing, and default adapter state.Getting an API Key
- Sign in to the Bedrock portal
- Navigate to API Keys
- Click Create API Key, give it a name (e.g., “Production”), and copy the value immediately
Using Your API Key
Include your API key in theAuthorization header with the Bearer prefix:
API Key Scope
An API key’s access follows the organization it belongs to:Creating API Keys via API
You can also create API keys programmatically against/api/organizations/api-keys/:
Managing API Keys
List keys:Token Auth (portal / user-scoped)
The portal and the/api/organizations/auth/* endpoints use DRF’s TokenAuthentication:
POST /api/organizations/auth/signup/— creates org + user + membership + tokenPOST /api/organizations/auth/login/— returns a token for an existing userPOST /api/organizations/invites/{id}/accept/— returns a token for the invitee
TokenAuthentication and APIKeyAuthentication are installed): /api/organizations/organizations/, /api/organizations/api-keys/, /api/templates/.
Security Best Practices
Environment Variables
Store API keys in environment variables, never hardcode in source.
Server-Side Only
Never expose API keys in client-side code or public repositories.
Rotate Regularly
Create new keys and delete old ones periodically.
Descriptive Names
Name keys by environment/purpose for easy auditing.