Skip to content

API keys and service accounts ​

Use your signed-in account to create a personal key for scripts, or ask a workspace administrator for a service account. A key acts with its account’s current permissions. The generated machine UUID identifies a host; it is not an authentication credential.

Put credentials at the operation boundary ​

Agent permissions, isolation and account authorization control different things. A sandbox cannot reduce the server rights of a credential deliberately provided to a run.

For operations exposed through conductor tools, keep the required credential with the integration. Forge tools can deliver work using the conductor's forge token; the agent needs permission to call the tool, not the token value. The tool still checks scope and authorization. A credential passed directly to an agent remains usable within its accessible environment.

Give the worker only the project access it needs. Separate model-provider credentials from server/forge credentials, and inspect what a tool returns: secrets in results can enter model requests or transcripts. Tools that run worktree code also expose their execution authority to that code.

Personal API keys ​

Every signed-in user creates, lists and revokes their own keys under Account → API keys. No administrator is involved.

FactValue
Acts asYou, with your current ranks and permissions; a rank change applies on the next request
Sign-in typeClient credentials with the bb:session scope; tokens live 300 seconds; the client obtains another using the key
Lifetime90 days by default, at most 365
SecretShown once, at creation; store it in an environment variable, never in a repository
RevocationImmediate; every token issued for the key stops working in the same request

After creation the dialog offers two ready snippets that reference the secret's environment variable: a prompt for your agent, and the CLI connection setup.

Per CLI
sh
export BAKERS_CONSUMER_SECRET=<the secret>
bakers config init --scope connection --auth-type client_credentials --client-id <client id> --secret-env BAKERS_CONSUMER_SECRET

Use a personal key for CI jobs and scripts that should act as you. Revoke keys you no longer need and remove their copies from CI secrets. Leaving a team changes access on the next request but does not delete the key.

Use a key as bearer on /mcp ​

A client that can only send a fixed header and cannot refresh a token, such as a bot reading its settings from an env file, may send the key itself to the MCP endpoint:

http
POST /mcp
Authorization: Bearer <client id>:<secret>

The client id and secret are the two values the key dialog shows, joined by one :. A service account's key works the same way.

FactValue
Acts asThe key's owner with their current permissions, exactly like a token from the key
LifetimeThe key's own: until it is revoked or disabled, its expiry date passes, or its owner is blocked. There is no 300-second token limit
RefusedEvery such case, a wrong secret and an unknown key get 401 with error="invalid_token"; nothing falls back to anonymous access
Where/mcp only. JSON:API and every other path still need an exchanged token
Token exchangeUnchanged; clients that refresh tokens keep doing so

Every request checks the key again, so revoking it cuts the client off on its next call. Keep the header value as secret as the secret itself.

Machine identities ​

For automation managed by a workspace, an authorized workspace administrator can open Service accounts in workspace settings, create an account bound to that workspace and one team, and issue its key. The supported workspace ranks are Guest or Contributor, and team roles Member or Reporter. These accounts cannot sign in through the human login flow. Manage or disable them through the browser; a bearer key administers identities only as a workspace administrator's key, or as a provisioner key for its own bots. Disabling the account invalidates its access. A Reporter can create tickets in its team's projects without broader ticket-edit rights. A Contributor account can create teams, which it owns and joins; it never owns a workspace.

Verify: use the issued credentials for a read in the intended project and confirm an unrelated project is denied. Never test with an administrator's credentials in their place.

A conductor on a server can use a client-credentials connection issued by the instance operator. Keep this identity separate from the host's generated machine_id. Its permissions depend on the account and token configuration; a secret does not grant unrestricted access.

Personal keyService account
Created byThe user, self-serviceAn authorized workspace administrator
Acts asThat userAn account bound to one workspace and team
Typical useCI, scripts, a second agentUnattended conductor on a worker server
Where configuredYour CI secrets, ~/.bakers/connections/<id>.jsThe worker's connection file

Setting up a worker with such a connection: Set up a worker server and Connections.

Provisioner service accounts ​

A provisioning script can set up an organization with its own key instead of an administrator's. When creating a service account, the administrator ticks May provision service accounts. The box cannot be changed later: recreate the account to grant or remove the right.

With its key, such a provisioner calls these tools:

ToolWhat it does
bakers_team_create, bakers_group_create, bakers_project_createCreate a team, a group and projects. Every Contributor may do this
bakers_service_account_createCreate a bot in a team the provisioner owns, with its first key
bakers_team_member_addAdd one of its bots to another team it owns, or change the bot's rank there
bakers_service_account_key_issue, bakers_service_account_key_revokeRenew a bot's key: issue a new one, then revoke the old one
bakers_service_account_listList its bots with their ranks, teams and keys, so a rerun reuses them
bakers_team_membersRead a team's members, including its own owner membership
LimitValue
BotsBound to the provisioner's workspace; Guest or Contributor there; Member or Reporter in a team
TeamsOnly teams the provisioner created and owns
AccountsOnly bots it created; never humans, other service accounts or itself
Not allowedDisabling bots, changing workspace ranks, owning or administering the workspace
Further provisioningBots never carry the flag, so a bot cannot create bots

Secrets appear only in the results of bakers_service_account_create and bakers_service_account_key_issue.

Verify: with the provisioner's credentials, bakers_service_account_create on a team it did not create is refused.

Scopes and permissions ​

Both kinds sign in with the single bb:session scope. What a request may do is decided by the account's workspace rank and team membership on every call (Who sees what), never by the key itself.