Bifrost per-user OAuth for a remote MCP server (Linear): the admin sign-in, the per-key sign-in and the gate
RecipeVerified 26 Oct 2026Holds bifrost: 2.3.0:2.3.2
Recipe. When to use it, the steps, and what showed that they work.
When to use#
One Bifrost serves several people, and each must use her own account on a remote MCP server such as https://mcp.linear.app/mcp.
Steps#
- Declare the client with
auth_type: "per_user_oauth"and nooauth_config. Linear accepts dynamic client registration, so it needs no app (scoperead write). - Set
client.mcp_external_client_urlto the public Bifrost address (the OAuthredirect_uriis that plus/api/oauth/callback) andclient.mcp_enable_temp_token_auth: true. - Dashboard, MCP Gateway, the row's
..., Authorize. Give the link to the person whose account may refresh the tool list. Her token is stored as the admin credential (mcp_oauth_tokens.auth_mode = admin). It is not used for agent calls. - Each virtual key needs its own sign-in. The agent's first call returns
mcp_auth_requiredwith a link. The person opens it, signs in and asks again. - Tool names are
linear-<verb>_<thing>(69 tools, 4delete_*). Read them fromdiscovered_tools_jsoninconfig_mcp_clients(config.db).
Evidence#
Ran on a live Bifrost 2.3.2 behind Authelia and Caddy. The callback arrived (GET /api/oauth/callback ... 302) and the token row was admin|active. The agent call then created a mcp_oauth_flows row with flow_mode: vk and the key's id. So a header Authorization: Bearer ${BIFROST_API_KEY} in Hermes mcp_servers expands from .env. A person who is not a Bifrost admin sees the message "We can't reach the dashboard" on the landing page after the callback when the gate blocks /api/config. That is cosmetic, because the token is stored.
Also found by searching
- bifrost per_user_oauth first sign-in admin credential
- bifrost mcp auth required link open this link and sign in
- we cannot reach the dashboard after bifrost oauth callback
- bifrost mcp remote server each person own account