Hi, I’m using OpenCode with the built-in OpenAI/ChatGPT Plus OAuth login, not an API key. onWatch looks like it can already monitor ChatGPT/Codex quota via the ChatGPT usage endpoints, but it seems to only auto-detect Codex-style credentials from ~/.codex/auth.json or CODEX_HOME/auth.json.
OpenCode stores its OAuth credentials at:
~/.local/share/opencode/auth.json
with a different shape, roughly:
{
"openai": {
"type": "...",
"refresh": "...",
"access": "...",
"expires": 1234567890,
"accountId": "..."
}
}
onWatch appears to expect Codex-style fields like:
{
"tokens": {
"access_token": "...",
"refresh_token": "...",
"account_id": "..."
}
}
Could onWatch support OpenCode’s ChatGPT OAuth credential file directly, either by auto-detecting ~/.local/share/opencode/auth.json or by allowing a provider/profile config that maps this format?
This would let OpenCode users monitor their ChatGPT Plus/Pro quota/reset without setting up separate Codex auth or copying tokens into another file.
Hi, I’m using OpenCode with the built-in OpenAI/ChatGPT Plus OAuth login, not an API key. onWatch looks like it can already monitor ChatGPT/Codex quota via the ChatGPT usage endpoints, but it seems to only auto-detect Codex-style credentials from ~/.codex/auth.json or CODEX_HOME/auth.json.
OpenCode stores its OAuth credentials at:
~/.local/share/opencode/auth.jsonwith a different shape, roughly:
onWatch appears to expect Codex-style fields like:
Could onWatch support OpenCode’s ChatGPT OAuth credential file directly, either by auto-detecting ~/.local/share/opencode/auth.json or by allowing a provider/profile config that maps this format?
This would let OpenCode users monitor their ChatGPT Plus/Pro quota/reset without setting up separate Codex auth or copying tokens into another file.