BrainDocs

GitHub

Connect GitHub with a static OAuth app, then per-user Connect.

Auth: Static OAuth app (client id + secret) → each user Connect.

MCP: https://api.githubcopilot.com/mcp/

Admin: Set up

  1. Create an OAuth / MCP app at the provider (see notes below)
  2. In Brain open /toolsGitHubSet up / App settings
  3. Enter client id and secret (scope: this workspace or entire instance, depending on your role)
  4. Save

Deploy-time env fallback (optional):

VariablePurpose
GITHUB_MCP_CLIENT_IDOAuth client id
GITHUB_MCP_CLIENT_SECRETOAuth client secret

Prefer UI Set up when possible; env remains a host-wide fallback.

Users: Connect

  1. Open /toolsGitHubConnect
  2. Approve access in the provider UI
  3. Enable the app for Agent-mode chats

Callback URL

{BRAIN_PUBLIC_URL}/api/connections/github/callback

GitHub OAuth App

Create an OAuth App at GitHub Developer settings:

  • Homepage URL: your Brain origin
  • Authorization callback URL: {BRAIN_PUBLIC_URL}/api/connections/github/callback

GitHub MCP is required for remote PR / issue operations. For sandbox coding against a private repo, connect GitHub so clone credentials work — see Attached repo.