Secure OAuth authentication for GitScrum CLI.
| Command | Description |
|---|---|
gitscrum auth login |
Initiate OAuth login |
gitscrum auth logout |
Clear stored credentials |
gitscrum auth status |
Check authentication status |
gitscrum auth whoami |
Show authenticated user |
$ gitscrum auth login
! GitScrum CLI wants to authenticate with your account.
Press Enter to open the browser...
✓ Logged in successfully!
Tip: Run 'gitscrum config set workspace <slug>' to set your default workspaceThe CLI uses OAuth 2.0 Device Authorization Grant:
- CLI generates a device code
- You authorize in your browser
- CLI securely stores the access token locally
Credentials are stored in ~/.gitscrum/token.json with restricted permissions.
$ gitscrum auth status
✓ Authenticated
Workspace: acme-corp
Project: backend-api
Token: Valid (expires in 29 days)$ gitscrum auth whoami
Logged in as Alice Smith (alice@example.com)$ gitscrum auth logout
✓ Logged out successfullyInteractive login isn't possible in CI/CD. Use environment variables:
# Export your access token
export GITSCRUM_ACCESS_TOKEN="your-oauth-access-token"
# Now all commands authenticate automatically
gitscrum tasks listTo get your access token:
- Run
gitscrum auth loginlocally - Copy
access_tokenfrom~/.gitscrum/token.json - Add as secret in your CI/CD platform
# Extract token
cat ~/.gitscrum/token.json | jq -r '.access_token'| Aspect | Protection |
|---|---|
| Authentication | OAuth 2.0 Device Grant — no password transmission |
| Token Storage | Local filesystem with 0600 permissions |
| Token Scope | Minimum required permissions |
| CI/CD | Environment variable injection |
| Platform | Path |
|---|---|
| Linux/macOS | ~/.gitscrum/token.json |
| Windows | %USERPROFILE%\.gitscrum\token.json |
Add to .gitignore:
.gitscrum/
~/.gitscrum/$ gitscrum tasks
Error: token expired. Run 'gitscrum auth login' to re-authenticate
$ gitscrum auth login
✓ Logged in successfully!Check that GITSCRUM_ACCESS_TOKEN is correctly set:
# Verify token is available
echo $GITSCRUM_ACCESS_TOKEN | head -c 20
# Should show: eyJhbGciOiJSUzI1...- Stay logged in: Tokens are long-lived; you rarely need to re-authenticate
- Multiple accounts: The CLI supports one account at a time
- Security first: Never share your access token or commit it to repositories