Codex: expose provenance-aware plan and allowance metadata in Hooks
Maintainers usually reply within 1 day
Assessment
- Difficulty
- 5/5
- Estimated time
- Over a week
- Newbie friendliness
- 35/100
Research direction
Read Sources/CodexBarCore/Hooks/HookEvent.swift and Sources/CodexBarCore/Providers/Codex/CodexPlanFormatting.swift to understand current Hook fields and how display labels are mapped. Check existing usage metadata and tests before proposing a structured representation for provider-reported values, estimates, and unknowns. Done means Hooks can expose provenance-aware plan and allowance changes without treating display labels or observation time as verified facts.
Written by the indexing model from the issue text.
Description
I use CodexBar’s Hooks to keep a private history of my remaining Codex allowance. When a subscription tier or temporary allowance boost changes, the same percentage can represent a different amount of available usage. I would like to compare those periods without manually maintaining plan changes.
In v0.81.0, CodexPlanFormatting maps pro to Pro 20x and prolite variants to Pro 5x. A formatted label alone therefore cannot establish the currently effective multiplier. HookEvent does not include plan or allowance metadata, although other outputs already expose a plan display label.
Would you consider adding optional structured metadata to usage Hooks?
- The observed plan/tier and its source.
- A verified allowance multiplier, reference baseline and applicable quota window, only when the available source supports it. Otherwise leave it unavailable, rather than infer it from price or a display label.
- Observed plan/allowance changes through a dedicated event or timestamped usage metadata. Observation time should not imply exact effective time unless supplied upstream.
This would let external charts show percentage remaining or baseline-normalized allowance, with estimates and unknown values explicit. Display mappings should remain distinguishable from provider-reported values. No credentials or account-identifying information are needed.
If an existing field or issue covers this, please point me to it; I would prefer to reuse it.
Source: https://github.com/steipete/CodexBar/blob/v0.81.0/Sources/CodexBarCore/Providers/Codex/CodexPlanFormatting.swift
Hook fields: https://github.com/steipete/CodexBar/blob/v0.81.0/Sources/CodexBarCore/Hooks/HookEvent.swift
- Dominant language
- Swift
- Stars
- 22.8k
- Forks
- 2.2k
- Avg merge
- 21h 55m
- Merged PRs (30d)
- 403
Getting set up
This project ships no dev container, Dockerfile or contributing guide, so setting up is up to you: start from its README, and see our first-contribution guide for the general steps.
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
More from steipete/CodexBar
-
Improve readability of red pace text in stacked menu bar layoutPossibly taken A pull request linked to this issue is open or already merged. Openclawsweeper:fix-shape-clear clawsweeper:needs-live-repro clawsweeper:needs-maintainer-review clawsweeper:needs-product-decision clawsweeper:no-new-fix-pr impact:ux-friction issue-rating: 🐚 platinum hermit P2
Difficulty 2/5 1-3 hours Newbie friendliness 62/100
steipete/CodexBar#4714 · 3 comments · 1 reaction ·
Maintainers usually reply within 1 day
-
clawsweeper:fix-shape-clear clawsweeper:needs-maintainer-review clawsweeper:needs-product-decision clawsweeper:no-new-fix-pr clawsweeper:source-repro impact:ux-friction issue-rating: 🦞 diamond lobster P2
Difficulty 4/5 3-5 days Newbie friendliness 48/100
steipete/CodexBar#4796 · 2 comments · 1 reaction ·
Maintainers usually reply within 1 day
-
clawsweeper:fix-shape-clear clawsweeper:needs-maintainer-review clawsweeper:needs-product-decision clawsweeper:no-new-fix-pr impact:other issue-rating: 🦪 silver shellfish P2
Difficulty 5/5 Over a week Newbie friendliness 35/100
steipete/CodexBar#4794 · 1 comment · 1 reaction ·
Maintainers usually reply within 1 day
-
clawsweeper:needs-product-decision clawsweeper:needs-security-review clawsweeper:no-new-fix-pr clawsweeper:source-repro impact:auth-provider impact:ux-friction issue-rating: 🦞 diamond lobster P2
Difficulty 4/5 1-2 days Newbie friendliness 55/100
steipete/CodexBar#4792 · 1 comment · 1 reaction ·
Maintainers usually reply within 1 day
-
clawsweeper:needs-maintainer-review clawsweeper:needs-product-decision clawsweeper:no-new-fix-pr clawsweeper:source-repro impact:ux-friction issue-rating: 🦞 diamond lobster P3
Difficulty 5/5 Over a week Newbie friendliness 35/100
steipete/CodexBar#4789 · 2 comments · 1 reaction ·
Maintainers usually reply within 1 day
All issues in steipete/CodexBar
Similar issues
-
bug
Difficulty 2/5 1-3 hours Newbie friendliness 68/100
SwiftyLab/MetaCodable#169 ·
-
Difficulty 1/5 Under an hour Newbie friendliness 82/100
521xueweihan/HelloGitHub#4131 ·
-
[Bug] Error: thaw@beta: thaw@beta: This cask does not run on macOS versions older than Golden Gate.Openmacos-27 ops
Difficulty 2/5 1-3 hours Newbie friendliness 62/100
thaw-app/Thaw#1400 · 1 comment ·
Maintainers usually reply within 1 day
-
Difficulty 2/5 1-3 hours Newbie friendliness 68/100
ParetoSecurity/pareto-mac#324 ·
Maintainers usually reply within 1 day
-
enhancement
Difficulty 2/5 1-3 hours Newbie friendliness 74/100
duongductrong/Snapzy#691 ·
Maintainers usually reply within 1 day