()
| 1627 | } |
| 1628 | |
| 1629 | export function isCodexSubscriber(): boolean { |
| 1630 | // Only treat as Codex subscriber when explicitly using OpenAI provider |
| 1631 | if (getAPIProvider() !== 'openai') { |
| 1632 | return false |
| 1633 | } |
| 1634 | |
| 1635 | // Verify we actually have valid Codex tokens |
| 1636 | const tokens = getCodexOAuthTokens() |
| 1637 | return !!tokens?.accessToken |
| 1638 | } |
| 1639 | |
| 1640 | /** |
| 1641 | * Check if the current OAuth token has the user:profile scope. |
no test coverage detected