[PR #9972] feat: OAuth Enhancements - Multi-Account, YOLO Mode, Auto-Relogin #13287

Closed
opened 2026-02-16 18:18:09 -05:00 by yindo · 0 comments
Owner

Original Pull Request: https://github.com/anomalyco/opencode/pull/9972

State: closed
Merged: No


Summary

Combined PR for three OAuth/authentication enhancements for power users:

  • Multi-Account OAuth Rotation - Use multiple Claude Max accounts with auto-rotation on rate limits
  • YOLO Mode - Skip all permission prompts for trusted workflows
  • Auto-Relogin Browser Sessions - Automatic token refresh via Puppeteer

Closes #9971

Features

1. Multi-Account OAuth Rotation

  • Providers tab in Settings with full account management UI
  • Display Anthropic rate limits (5-hour, 7-day, Sonnet) with real-time updates
  • Click to switch accounts, auto-rotate on rate limits
  • CLI: opencode auth usage

2. YOLO Mode

  • Skip ALL permission prompts (respects explicit deny rules)
  • Session-only or persistent mode
  • Settings > General > YOLO Mode section
  • CLI: opencode --yolo or OPENCODE_YOLO=true

3. Auto-Relogin Browser Sessions

  • Puppeteer-based with stealth plugin (bypasses Cloudflare)
  • Isolated browser profiles per account
  • Automatic headless token refresh on 401 errors
  • CLI: opencode auth browser setup/status/refresh/remove

Changed Files

App (Frontend)

  • dialog-settings.tsx - Add Providers tab
  • settings-providers.tsx - New provider management UI
  • settings-general.tsx - Add YOLO Mode section
  • session-context-tab.tsx - Add rate limit display and account switching

OpenCode (Backend)

  • auth/index.ts - Multi-account support, usage API, token management
  • auth/browser.ts - Puppeteer browser session management
  • auth/context.ts - Auth context utilities
  • yolo/index.ts - YOLO mode state management
  • config/config.ts - Add yolo config field
  • flag/flag.ts - Add OPENCODE_YOLO flag
  • permission/next.ts - YOLO auto-approve integration
  • project/bootstrap.ts - Initialize YOLO on startup
  • server/routes/config.ts - YOLO API endpoints
  • server/routes/provider.ts - Browser session endpoints
  • server/server.ts - Auth usage and active account endpoints

SDK

  • Regenerated with new auth endpoints
**Original Pull Request:** https://github.com/anomalyco/opencode/pull/9972 **State:** closed **Merged:** No --- ## Summary Combined PR for three OAuth/authentication enhancements for power users: - **Multi-Account OAuth Rotation** - Use multiple Claude Max accounts with auto-rotation on rate limits - **YOLO Mode** - Skip all permission prompts for trusted workflows - **Auto-Relogin Browser Sessions** - Automatic token refresh via Puppeteer Closes #9971 ## Features ### 1. Multi-Account OAuth Rotation - Providers tab in Settings with full account management UI - Display Anthropic rate limits (5-hour, 7-day, Sonnet) with real-time updates - Click to switch accounts, auto-rotate on rate limits - CLI: `opencode auth usage` ### 2. YOLO Mode - Skip ALL permission prompts (respects explicit deny rules) - Session-only or persistent mode - Settings > General > YOLO Mode section - CLI: `opencode --yolo` or `OPENCODE_YOLO=true` ### 3. Auto-Relogin Browser Sessions - Puppeteer-based with stealth plugin (bypasses Cloudflare) - Isolated browser profiles per account - Automatic headless token refresh on 401 errors - CLI: `opencode auth browser setup/status/refresh/remove` ## Changed Files ### App (Frontend) - `dialog-settings.tsx` - Add Providers tab - `settings-providers.tsx` - New provider management UI - `settings-general.tsx` - Add YOLO Mode section - `session-context-tab.tsx` - Add rate limit display and account switching ### OpenCode (Backend) - `auth/index.ts` - Multi-account support, usage API, token management - `auth/browser.ts` - Puppeteer browser session management - `auth/context.ts` - Auth context utilities - `yolo/index.ts` - YOLO mode state management - `config/config.ts` - Add yolo config field - `flag/flag.ts` - Add OPENCODE_YOLO flag - `permission/next.ts` - YOLO auto-approve integration - `project/bootstrap.ts` - Initialize YOLO on startup - `server/routes/config.ts` - YOLO API endpoints - `server/routes/provider.ts` - Browser session endpoints - `server/server.ts` - Auth usage and active account endpoints ### SDK - Regenerated with new auth endpoints
yindo added the pull-request label 2026-02-16 18:18:09 -05:00
yindo closed this issue 2026-02-16 18:18:09 -05:00
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: anomalyco/opencode#13287