[FEATURE] Using `CLAUDE_CODE_OAUTH_TOKEN` to start a remote session
Resolved 💬 4 comments Opened Apr 27, 2026 by moltar Closed May 29, 2026
Preflight Checklist
- [x] I have searched existing requests and this feature hasn't been requested yet
- [x] This is a single feature request (not multiple features)
Problem Statement
I would like to be able to use CLAUDE_CODE_OAUTH_TOKEN to start a remote session.
Right now, this fails with an arbitrary error.
Proposed Solution
Use CLAUDE_CODE_OAUTH_TOKEN environment variable. A long-lived OAuth token generated by claude setup-token. Use this for CI pipelines and scripts where browser login isn’t available.
This should work, but does not:
CLAUDE_CODE_OAUTH_TOKEN=sk-ant-oat01-xxx claude --remote "say ye"
Alternative Solutions
None.
Priority
Critical - Blocking my work
Feature Category
CLI commands and flags
Use Case Example
Ability to start a remote session programmatically.
Additional Context
None.
This issue has 4 comments on GitHub. Read the full discussion on GitHub ↗