Problem
PORT is configurable, but the OAuth redirect URI is hard-coded to http://localhost:3979/oauth/callback. OAuth requires the redirect URI used for authorization and token exchange to match the registered URI. The initial flow also requires a placeholder LINEAR_ACCESS_TOKEN, even though OAuth replaces it.
Official docs: https://linear.app/developers/oauth-2-0-authentication.md
Proposed change
- Add
OAUTH_REDIRECT_URI configuration.
- Validate obvious port/URI inconsistencies.
- Explicitly load
.env in development.
- Permit startup without a bootstrap access token when authorization has not completed.
Acceptance criteria
- Authorization and token exchange use the same configured redirect URI.
- Non-default local ports work when configured correctly.
npm run dev explicitly loads .env.
- A fresh installation can boot and print its authorization URL without a fake token.
- Existing installations remain backward compatible or receive a clear migration error.
Linear execution plan
GitHub remains the public source of truth. Private prioritization, dependencies, and agent execution are tracked in the Linear Agent Bridge OSS project.
Parent: MPI-1428
- MPI-1429 — Make the OAuth redirect URI configurable and remove the placeholder token requirement
- MPI-1430 — Load .env explicitly in development and document configuration migration
Implementation tickets are labeled agent-ready in Linear and include scope, acceptance criteria, dependencies, repository constraints, and required verification evidence. Public decisions and completion status should be mirrored back to this issue.
Problem
PORTis configurable, but the OAuth redirect URI is hard-coded tohttp://localhost:3979/oauth/callback. OAuth requires the redirect URI used for authorization and token exchange to match the registered URI. The initial flow also requires a placeholderLINEAR_ACCESS_TOKEN, even though OAuth replaces it.Official docs: https://linear.app/developers/oauth-2-0-authentication.md
Proposed change
OAUTH_REDIRECT_URIconfiguration..envin development.Acceptance criteria
npm run devexplicitly loads.env.Linear execution plan
GitHub remains the public source of truth. Private prioritization, dependencies, and agent execution are tracked in the Linear Agent Bridge OSS project.
Parent: MPI-1428
Implementation tickets are labeled
agent-readyin Linear and include scope, acceptance criteria, dependencies, repository constraints, and required verification evidence. Public decisions and completion status should be mirrored back to this issue.