Skip to content

fix(workbuddy): keep regional catalog prices honest - #180

Merged
caigee-cmd merged 2 commits into
mainfrom
fix/workbuddy-catalog-no-hardcode
Sep 16, 2026
Merged

caigee-cmd merged 2 commits into
mainfrom
fix/workbuddy-catalog-no-hardcode

Conversation

@caigee-cmd

Copy link
Copy Markdown
Owner

Summary

  • Source WorkBuddy catalog credits/free from the official product-config response instead of hardcoding prices.
  • Keep /v1/models and default /api/models merged for OpenAI/Access/Overview stability.
  • Add /api/models?view=regional for the Providers page so each provider+region row shows that region's real credits/free/capabilities; omit conflicting prices from merged rows.

Test plan

  • go test ./internal/api/ -run 'TestFetchProviderModels|TestNamedAPIKeyRegionScopedModelsList|TestModelsAPICachesCatalog'
  • cd frontend && npm run sync
  • Providers page filter shows Qoder/WorkBuddy/Trae region options and empty regions render empty state
  • Same WorkBuddy model shows distinct CN vs Global credits on ?view=regional
  • Access/Overview still use the merged catalog (no duplicate model IDs)

Source WorkBuddy credits/free from the official catalog, keep /v1 models
merged, and expose /api/models?view=regional so the Providers page can show
per-region prices without breaking Access/Overview.
@caigee-cmd
caigee-cmd merged commit 7f35718 into main Sep 16, 2026
6 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant