GV

GeezerVison

The World Wide Web, restored to 800 pixels of glory.

Home|About|Gaming cabinet|Archives|How it works|Starter sites

On this site

  • Sign in
  • ActionsCI/CD and automation
  • CodespacesCloud development environments
  • All Features
  • Documentation
  • Training
  • Certifications
  • Build with Copilot
  • Customize Copilot
  • Integrations
  • Trending repos
  • GitHub Sponsors
  • Developer articles
  • Enterprises

This view

  • Original page
  • New address

GeezerVison is showing github.com — feat(console): add go usage endpoint by peculiarnewbie · Pull Request #16513 · anomalyco/opencode

Conversation

@peculiarnewbie

@peculiarnewbie peculiarnewbie commented Mar 7, 2026 •
edited
Loading

Uh oh!

There was an error while loading. Please reload this page.

Copy link
Copy Markdown
Contributor

Issue for this PR

Closes #16017

Type of change

  • Bug fix
  • New feature
  • Refactor / code improvement
  • Documentation

What does this PR do?

this PR adds an API endpoint at /zen/go/v1/usage that will provide the same opencode go usage data as in the zen workspace dashboard.

If you paste a large clearly AI generated description here your PR may be IGNORED or CLOSED!

How did you verify your code works?

unfortunately i don't think this is a change i can verify as an outside contributor. i did try running bun dev:remote but met with cloudflare api key error.
I did copy the pattern in /zen/v1/models and copied the logic from /workspace/[id]/billing/lite-section.tsx

Screenshots / recordings

not a ui change

Checklist

  • I have tested my changes locally
    i guess running dev server and building counts as testing? but yea i don't think i can test this feature locally
  • I have not included unrelated changes in this PR

If you do not follow this template your PR will be automatically rejected.

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

Th1nkK1D, 0serna, timm-u, Izzur, selogerkkk, waynehoover, capyBearista, emilianomongelo, Ksld154, LuisHerreraG, and 87 more reacted with thumbs up emoji rcambrj, zewelor, ssoteloserrano, molovo, yougotwill, Ksld154, btriapitsyn, mit4dev, Ruppy7, Wiktor102, and 11 more reacted with heart emoji discreteds, hendrixfreire, and PixmaNts reacted with eyes emoji
All reactions
  • 👍 97 reactions
  • ❤️ 21 reactions
  • 👀 3 reactions
@peculiarnewbie
feat(console): add go usage endpoint
2fea0c4
@github-actions github-actions Bot added the needs:compliance This means the issue will auto-close after 2 hours. label Mar 7, 2026
@peculiarnewbie peculiarnewbie mentioned this pull request Mar 7, 2026
[FEATURE]: Add Go plan usage/balance API endpoint (rolling/weekly/monthly windows) #16017
Closed
1 task done
@github-actions github-actions Bot removed the needs:compliance This means the issue will auto-close after 2 hours. label Mar 7, 2026
@github-actions

github-actions Bot commented Mar 7, 2026

Copy link
Copy Markdown
Contributor

Thanks for updating your PR! It now meets our contributing guidelines. 👍

All reactions

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

@github-actions github-actions Bot mentioned this pull request Mar 8, 2026
📊 AI CLI 工具社区动态日报 2026-03-08 duanyytop/agents-radar#95
Closed
@slkiser slkiser mentioned this pull request Apr 9, 2026
[feature]: Add Opencode GO Provider (edit: added via scraping, tracking for API) slkiser/opencode-quota#36
Closed
2 tasks done
@vmvarela vmvarela mentioned this pull request Apr 11, 2026
feat: add OpenCode Go quota provider slkiser/opencode-quota#41
Merged
@opencode-agent
opencode-agent Bot force-pushed the dev branch from 2f2ed11 to 9f201d6 Compare April 16, 2026 21:55
@gregor-tokarev gregor-tokarev mentioned this pull request Apr 17, 2026
[Agent Usage] Add opencode-go subscription raycast/extensions#27228
Open
@waynehoover waynehoover mentioned this pull request Apr 25, 2026
OpenUsage Limits Incorrect for OpenCode Go Plugin robinebers/openusage#361
Closed
@hendrixfreire

hendrixfreire commented May 3, 2026

Copy link
Copy Markdown

Hey, any news on merging this?

All reactions

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

@peculiarnewbie

peculiarnewbie commented May 3, 2026

Copy link
Copy Markdown
Contributor Author

no clue

All reactions

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

@n-osennij

n-osennij commented May 4, 2026

Copy link
Copy Markdown

+++

All reactions

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

@patrezp

patrezp commented May 4, 2026

Copy link
Copy Markdown

I would like to see this implemented

All reactions

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

@donrami

donrami commented May 9, 2026

Copy link
Copy Markdown

+1 for implementing this. In the meantime I'm using this hacky solution https://pi.dev/packages/pi-go-bars

All reactions

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

@OmSoft-tech

OmSoft-tech commented May 14, 2026

Copy link
Copy Markdown

I would like to see this implemented

All reactions

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

@slkiser

slkiser commented May 14, 2026

Copy link
Copy Markdown

Official support would be nice.

If you need usage and quota tracking in opencode, https://github.com/slkiser/opencode-quota

All reactions

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

@n-osennij

n-osennij commented May 15, 2026

Copy link
Copy Markdown

up

All reactions

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

@m-saghir

m-saghir commented May 15, 2026

Copy link
Copy Markdown

I'd employ this feature.

All reactions

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

@matiasict

matiasict commented May 18, 2026

Copy link
Copy Markdown

+1

All reactions

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

@Ksld154

Ksld154 commented May 19, 2026

Copy link
Copy Markdown

+1
really need this to check cross-device quota in OpenUsage

yougotwill reacted with thumbs up emoji
All reactions
  • 👍 1 reaction

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

@hendrixfreire

hendrixfreire commented May 19, 2026 •
edited
Loading

Uh oh!

There was an error while loading. Please reload this page.

Copy link
Copy Markdown

Did they truly forget about this?

All reactions

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

@robinebers

robinebers commented May 22, 2026

Copy link
Copy Markdown

Would really love this for OpenUsage. A lot of users keep asking, and the local SQL is unreliable.

edsonboldrini, Ksld154, admdly, yougotwill, peculiarnewbie, AshMcConnell, blackjlc, and P1N2O reacted with heart emoji
All reactions
  • ❤️ 8 reactions

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

@robinebers robinebers mentioned this pull request May 22, 2026
Monthly Opencode Go usage showing a wrong value robinebers/openusage#478
Closed
@edsonboldrini

edsonboldrini commented May 22, 2026

Copy link
Copy Markdown

+1

All reactions

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

@igcodinap

igcodinap commented May 23, 2026

Copy link
Copy Markdown

+1 pls merge this

All reactions

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

@github-actions github-actions Bot mentioned this pull request May 23, 2026
📊 AI CLI 工具社区动态日报 2026-05-23 ivanweng2077/big_model_radar#77
Open
@stevenup7

stevenup7 commented May 27, 2026

Copy link
Copy Markdown
  • 1 for this one, adding my name to the list of people wanting this, using @timm-u pi plugin but screen scraping feels pretty yuck
All reactions

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

@rcambrj

rcambrj commented May 27, 2026

Copy link
Copy Markdown

This pull request is now second most wanted, by measure of 👍 reactions

Screenshot 2026-05-27 at 08 50 58

Opencode continues to see improvements and bugfixes, which I'm eternally grateful for, but I do wonder what's holding this up. It seems like a quick QOL improvement for your paying subscribers. Is there something which needs to be fixed, opencode maintainers?

Ksld154, peculiarnewbie, Wiktor102, and MiningInMySleep reacted with thumbs up emoji
All reactions
  • 👍 4 reactions

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

@ddarkr ddarkr mentioned this pull request Aug 30, 2026
feat(quota): use official OpenCode Go usage API cheaper-inference/OmniRoute#12124
Merged
@cte13 cte13 mentioned this pull request Aug 30, 2026
fix: stop the usage-scan interval from driving remote limit requests cte13/PokeTokenBar-iOS#28
Merged
1056674754 added a commit to 1056674754/opencode that referenced this pull request Aug 31, 2026
@1056674754
chore: merge OpenCode v1.18.17-sscity
ab68129
Upstream v1.18.16 (a3647eb) -> v1.18.17 (02546df), 32 commits.

Functional changes:
- fix(compaction): clearer instructions for smaller models like dsv4 flash (anomalyco#42045)
- fix(provider): add Merge Gateway reasoning variants (anomalyco#41867)
- fix(opencode): cap session retries with jitter (anomalyco#41939) - retry policy
  gains RETRY_MAX_RETRIES=5 global cap and 25% jitter
- fix(opencode): detect Copilot PDF input support (anomalyco#41522)
- fix(provider): scope DeepSeek V4 Flash sampling defaults (anomalyco#41620)
- fix(session): route all Muse family models to the Meta system prompt (anomalyco#41581)
- fix(app): use current default model (anomalyco#38603)
- feat(console): add go usage endpoint (anomalyco#16513) and r2 data catalog stats
- fix(ui): correct OC-2 weak icon color (anomalyco#41504)
- fix(i18n): use widely recognized developer terminology (anomalyco#41532)

Conflicts resolved: 30 package.json version bumps (rebranded 1.18.17-sscity),
bun.lock (took upstream, rebranded workspace entries via bun install), and
session/retry.ts (kept fork per-reason maxAttempts cap alongside upstream
RETRY_MAX_RETRIES global cap and jitter).
@linletian linletian mentioned this pull request Sep 3, 2026
feat(opencode): switch usage query to official zen usage API linletian/api-usage-status#24
Merged
3 of 4 tasks
@Aser-Osama Aser-Osama mentioned this pull request Sep 10, 2026
feat(opencode): expose account usage limits raine/claude-code-proxy#146
Open
This was referenced Sep 11, 2026
AFK agent: notify on OpenCode Go usage via the usage API (follow-up to #176) corygyarmathy/dotfiles#221
Closed
Budget observation, deferral, and admission control corygyarmathy/afk-agent#5
Closed
@meisbokai meisbokai mentioned this pull request Sep 16, 2026
feat(opencode): use OpenCode Go usage API as primary source meisbokai/pi-usage-unified#5
Merged
This was referenced Sep 16, 2026
/usage shows no plan limits for opencode-go, unlike codex, anthropic and openrouter NousResearch/hermes-agent#113404
Closed
feat(usage): show opencode-go plan limits in /usage NousResearch/hermes-agent#113418
Closed
@coderabbitai coderabbitai Bot mentioned this pull request Sep 16, 2026
Show OpenCode Go usage in the status-bar footer hardbeat920/monocode#263
Merged
3 tasks done
androidand pushed a commit to androidand/opencode-skein that referenced this pull request Sep 18, 2026
@peculiarnewbie @vimtor
feat(console): add go usage endpoint (anomalyco#16513)
1e649b9
Co-authored-by: vimtor <[email protected]>
androidand pushed a commit to androidand/opencode-skein that referenced this pull request Sep 19, 2026
@peculiarnewbie @vimtor
feat(console): add go usage endpoint (anomalyco#16513)
9dd7eaa
Co-authored-by: vimtor <[email protected]>
androidand pushed a commit to androidand/opencode-skein that referenced this pull request Sep 19, 2026
@peculiarnewbie @vimtor
feat(console): add go usage endpoint (anomalyco#16513)
6669833
Co-authored-by: vimtor <[email protected]>
@IGabrielRC IGabrielRC mentioned this pull request Sep 19, 2026
feat(gentle-shell): add OpenCode Go subscription usage Gentleman-Programming/gentle-shell#872
Closed
2 tasks done
@coderabbitai coderabbitai Bot mentioned this pull request Sep 22, 2026
feat(providers): add Devin quota provider nghialuutrung/BirdNion#28
Merged
@grandamenium grandamenium mentioned this pull request Sep 23, 2026
feat(scripts): opencode-usage reader for OpenCode Go quota grandamenium/cortextos#1024
Merged
rldona pushed a commit to plazoleta-dev/FlupCode that referenced this pull request Sep 24, 2026
@peculiarnewbie @vimtor
feat(console): add go usage endpoint (anomalyco#16513)
d68897e
Co-authored-by: vimtor <[email protected]>
@baktiaditya baktiaditya mentioned this pull request Sep 30, 2026
Track OpenCode Go subscription quota baktiaditya/ai-usage-dashboard#21
Closed
@Fishforgithub Fishforgithub mentioned this pull request Oct 4, 2026
[FEATURE]: Return OpenCode Go usage with each response and keep it on the message #53044
Open
1 task done
arionrefat added a commit to arionrefat/open-usage that referenced this pull request Oct 6, 2026
@arionrefat
Read the merged opencode go usage API by its documented fields
584b38e
GET /zen/go/v1/usage merged in anomalyco/opencode#16513 and now answers
in production, so the parser no longer has to guess. The route returns
`{ usage: { rolling, weekly, monthly } }`, each window holding a status,
a floored percent and an ISO reset, and nothing else; the aliases and
dollar fallbacks written against the proposal are gone. A window marked
`rate-limited` reads as spent, since its floored percent can say 99.

A valid key on a workspace without Go answers 403 with an
EntitlementError, which now reads as no subscription instead of a
rejected key, and a 404 is drift rather than an outage. The cookie
still ranks above the key because only the console publishes dollars.
Ichinose-Kazuki pushed a commit to Ichinose-Kazuki/opencode that referenced this pull request Oct 7, 2026
@peculiarnewbie @vimtor
feat(console): add go usage endpoint (anomalyco#16513)
c51ff2e
Co-authored-by: vimtor <[email protected]>
@sidneijp sidneijp mentioned this pull request Oct 11, 2026
feat(opencode-go): read the OpenCode CLI's own api key from auth.json akitaonrails/ai-usagebar#408
Merged
5 tasks done
@Eloyye Eloyye mentioned this pull request Oct 17, 2026
M2: Subscription usage limits Eloyye/geleider#3
Closed
4 tasks
Frulko added a commit to Frulko/zinc that referenced this pull request Oct 20, 2026
@Frulko
feat(agents): read OpenCode Go usage with the Go key
866f1ce
opencode exposes no plan limits, but opencode.ai has an undocumented
usage route (GET /zen/go/v1/usage, anomalyco/opencode#16513) that
answers the 5-hour, week and month windows with a status, a percent
and a reset time. The Agents panel, the status bar and its hover now
show them like Claude's and Codex's, a rate-limited window in red, on
the same refresh interval.

The key comes only from `opencode auth export` run in the temporary
folder: the active opencode-go API key, every other entry ignored. It
lives for that one request, goes to opencode.ai over https in the
Authorization header and nowhere else: never written, logged, shown or
passed to a child; zinc.json asks for net:opencode.ai only. A Settings
toggle, on by default, turns it off. Off, no key, a revoked or expired
key, a 403 or an answer the app does not know show « unknown », the
reason and the console link.

agents_go.sh drives a fake export and made-up route answers (nothing
goes to the network) and checks the fake key appears in no file of the
run: data, settings, output, scenes, child arguments and environment.
One read-only check against the real route returned three windows ok.

New-task: owner ZN-770 OpenCode Go usage read with the Go key
@parkjangwon parkjangwon mentioned this pull request Oct 21, 2026
feat: add DeepSeek, Ollama Cloud and OpenCode Go providers parkjangwon/oot#38
Merged
@nalpri nalpri mentioned this pull request Oct 27, 2026
feat(quota): read OpenCode Go usage limits through the OpenCode CLI nalpri/ai-usage#77
Merged
@SimonBarnett SimonBarnett mentioned this pull request Nov 8, 2026
FR: pool monitor - bob-ear service owns usage acquisition + change-driven digest publish; tray read-only (gaps after PR #6244) SimonBarnett/bobiverse#6248
Closed
@MarioForte MarioForte mentioned this pull request Nov 12, 2026
feat(agents): show OpenCode Go plan limits vorssaint/vorssaint-utils#4080
Open
@kdenischenko kdenischenko mentioned this pull request Nov 21, 2026
Does the OpenCode Go plan expose its limits and window usage? kdenischenko/open-agent-router#18
Open
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Reviewers

No reviews

Uh oh!

There was an error while loading. Please reload this page.

Assignees

No one assigned

Labels

None yet

Projects

None yet

Milestone

No milestone

Development

Successfully merging this pull request may close these issues.

[FEATURE]: Add Go plan usage/balance API endpoint (rolling/weekly/monthly windows)

Uh oh!

There was an error while loading. Please reload this page.

20 participants

@peculiarnewbie @hendrixfreire @n-osennij @patrezp @donrami @OmSoft-tech @slkiser @m-saghir @matiasict @Ksld154 @robinebers @edsonboldrini @igcodinap @stevenup7 @rcambrj @vmvarela @taghouttarek @attilaszasz @meisbokai @mcchrome
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
You are visitor 01402775 — GeezerVison does not store the pages you look up.
Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800×600. No cookies required.