Skip to content

Instantly share code, notes, and snippets.

@eonist
Created January 30, 2026 04:04
Show Gist options
  • Select an option

  • Save eonist/951e9888e0f799f6d2d288fc3eadfd0b to your computer and use it in GitHub Desktop.

Select an option

Save eonist/951e9888e0f799f6d2d288fc3eadfd0b to your computer and use it in GitHub Desktop.
signing with chatgpt

OpenAI recently introduced OAuth authentication for ChatGPT subscriptions, allowing tools like Cline to use your existing subscription instead of managing API keys. Here are the key restrictions: cline

Usage Limits

The main restriction is rate limiting tied to your ChatGPT subscription tier: reddit

  • Plus users: Around 300–1,500 local messages every 5 hours, or 50–400 cloud tasks depending on complexity
  • Pro users: Higher limits but still capped with 5-hour and weekly limits
  • Usage counts against your overall ChatGPT subscription quota, not separate API credits github

Many users report hitting limits quickly, especially with intensive agentic coding workflows. community.openai

Model Access

The models available depend on your subscription tier :

  • gpt-5.2-codex: Optimized for agentic coding
  • gpt-5.2: General-purpose with strong reasoning
  • gpt-5-mini: Fast and cost-effective
  • o3 / o4-mini: Advanced and everyday reasoning tasks

How It Differs from API Keys

Aspect OAuth (ChatGPT Subscription) API Keys
Pricing Flat-rate (subscription) cline Pay-per-token reddit
Limits Time-based (5h/weekly caps) github Token/request limits platform.openai
Setup One-click sign-in Manual key management
Credential exposure Tokens handled automatically cline Risk of accidental commits

Key Considerations

  • Shared quota: Usage in Cline draws from the same pool as your ChatGPT web/app usage github
  • No separate budget: You cannot add API credits to bypass OAuth limits—they're tied strictly to your subscription tier github
  • Security: Your OpenAI credentials never leave OpenAI's servers; Cline only receives access tokens cline

For heavy coding use, some users find the 5-hour and weekly caps frustrating and prefer third-party providers or direct API access for more flexibility. community.openai

@eonist
Copy link
Author

eonist commented Jan 30, 2026

You've identified the key architectural difference. OpenAI built server-side infrastructure to handle third-party OAuth access, while Anthropic's cost optimizations only exist in the Claude Code client itself.

OpenAI's Approach: Server-Side Control

OpenAI explicitly designed their OAuth system to work with third-party tools:[developers.openai]

  • Sign in with ChatGPT is an official authentication method they actively support

  • Third-party tools like Cline connect through OpenAI's "LLM proxy server"[developers.openai]

  • Rate limiting, model routing, and cost management happen on OpenAI's backend regardless of which client sends the request

  • OpenAI can apply the same optimizations whether you use their CLI, VS Code extension, or Cline[cline]

Anthropic's Approach: Client-Side Only

Anthropic never built equivalent server-side infrastructure:[news.ycombinator]

  • Claude Code's OAuth endpoints are not a public API—they're internal authentication for the official client only

  • All the smart routing (Haiku for file reads, etc.) happens inside the Claude Code CLI

  • Third-party tools like OpenCode and Roo Code had to "reverse-engineer Claude Code's OAuth endpoints and API"[news.ycombinator]

  • When you bypass the official client, you bypass all cost optimizations

Why This Matters

Aspect | OpenAI Codex | Anthropic Claude Code -- | -- | -- OAuth designed for | Third-party tools ✅ [developers.openai]​ | Internal client only [news.ycombinator]​ Cost routing location | Server-side (backend) | Client-side (CLI) Third-party tools | Officially supported [cline]​ | Treated as "spoofing" [reddit]​ Subscription economics | Sustainable with any client | Only works with official client [reddit]​

As one commenter explained: "OpenCode reverse-engineers Claude Code's OAuth endpoints and API... This is harmful from Anthropic's perspective because Claude Code is subsidized relative to the API".[news.ycombinator]

The Buffet Analogy

A popular Reddit comment captured it well: "Utilizing third-party wrappers is akin to showing up at Anthropic's all-you-can-eat buffet with an elephant. Since Anthropic manages Claude Code, they can fine-tune it to reduce context consumption... Third-party developers lack the motivation to reduce context usage".[reddit]

So yes—OpenAI can afford to let any client use their OAuth because their backend enforces the rules. Anthropic's model only works when you use their client, which is why they had to block everything else.

You've identified the key architectural difference. OpenAI built server-side infrastructure to handle third-party OAuth access, while Anthropic's cost optimizations only exist in the Claude Code client itself.

OpenAI's Approach: Server-Side Control

OpenAI explicitly designed their OAuth system to work with third-party tools: [developers.openai](https://developers.openai.com/codex/auth/)

Anthropic's Approach: Client-Side Only

Anthropic never built equivalent server-side infrastructure: [news.ycombinator](https://news.ycombinator.com/item?id=46625918)

  • Claude Code's OAuth endpoints are not a public API—they're internal authentication for the official client only
  • All the smart routing (Haiku for file reads, etc.) happens inside the Claude Code CLI
  • Third-party tools like OpenCode and Roo Code had to "reverse-engineer Claude Code's OAuth endpoints and API" [news.ycombinator](https://news.ycombinator.com/item?id=46625918)
  • When you bypass the official client, you bypass all cost optimizations

Why This Matters

Aspect OpenAI Codex Anthropic Claude Code
OAuth designed for Third-party tools ✅ [developers.openai](https://developers.openai.com/codex/auth/) Internal client only [news.ycombinator](https://news.ycombinator.com/item?id=46625918)
Cost routing location Server-side (backend) Client-side (CLI)
Third-party tools Officially supported [cline](https://cline.bot/blog/introducing-openai-codex-oauth) Treated as "spoofing" [reddit](https://www.reddit.com/r/ClaudeAI/comments/1qa50sq/anthropic_banning_thirdparty_harnesses_while/)
Subscription economics Sustainable with any client Only works with official client [reddit](https://www.reddit.com/r/ClaudeAI/comments/1qa50sq/anthropic_banning_thirdparty_harnesses_while/)

As one commenter explained: "OpenCode reverse-engineers Claude Code's OAuth endpoints and API... This is harmful from Anthropic's perspective because Claude Code is subsidized relative to the API". [news.ycombinator](https://news.ycombinator.com/item?id=46625918)

The Buffet Analogy

A popular Reddit comment captured it well: "Utilizing third-party wrappers is akin to showing up at Anthropic's all-you-can-eat buffet with an elephant. Since Anthropic manages Claude Code, they can fine-tune it to reduce context consumption... Third-party developers lack the motivation to reduce context usage". [reddit](https://www.reddit.com/r/ClaudeAI/comments/1qa50sq/anthropic_banning_thirdparty_harnesses_while/)

So yes—OpenAI can afford to let any client use their OAuth because their backend enforces the rules. Anthropic's model only works when you use their client, which is why they had to block everything else.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment