Connect with Bily Connect
Bily Connect is the recommended choice for clients that support MCP OAuth. It keeps a long-lived key out of client configuration.- The client discovers Bily’s public authorization metadata.
- The client can register dynamically as a public client.
- The user signs in to Bily and grants the
mcp_accessscope. - The client uses Authorization Code with PKCE and can refresh the connection.
- Bily resolves the signed-in identity and checks that user’s current organization and store memberships.
Access key fallback
Use a fallback key only when the client cannot complete Bily Connect.- Select the intended store in Bily.
- Open Settings > MCP.
- Under Access key fallback, choose a name and expiration.
- Create the key and copy the full value immediately.
- Send it in the
x-api-keyheader.
Know what each connection can access
Both paths follow these rules:
storeUrlmust identify a store available to the authenticated identity.organizationIdmust identify an accessible organization.- A scoped key cannot override its recorded store or organization in
searchorexecute. - Bily checks scope on the server, not only in the client prompt.
Resolve authentication failures
401 Unauthorizedmeans the connection is missing, expired, revoked, or invalid. Reconnect or replace the key.403 Forbiddenmeans the identity is authenticated, but the requested store, organization, permission, or action is outside its allowed scope. Confirm the requested scope.
403 requires a store-scoped API key, select the intended store and create a replacement fallback key.
Do not broaden a key to solve a 403 until you understand why the request needs more access.