Skip to content

Feature Request: Add Charm Hyper (hyper.charm.land) as a provider #2318

Description

@JavaGT

Feature Request: Add Charm Hyper (hyper.charm.land) as a provider

Summary

Would love to see CodexBar support Charm Hyper — Charm's coding-optimized inference provider (official provider for the Crush agent). It uses a Hypercredit-based billing model (1 Hypercredit = 5¢) with free monthly grants, daily-refreshing subscriptions, and prepaid bundles that never expire.

The web dashboard shows a reset panel ("Plan / Shred / Next Hypercredit refresh in 13 hours"), which lines up with CodexBar's per-provider reset-countdown feature.

Investigation findings

Sharing what I turned up while looking into feasibility. Not prescribing any particular implementation — just recording the evidence so a maintainer can pick scope.

Endpoints probed (authenticated with HYPER_API_KEY):

Path Status Notes
GET /v1/models 200 (public) OpenAI-shaped list with per-model pricing.input/pricing.output/cache_create/cache_hit
GET /v1/credits 200 Returns {"balance": <int>} only — 21 bytes, no reset_at, no plan, no limit
GET /v1/me, /v1/usage, /v1/account, /v1/subscription, /v1/plan, /v1/key 404 No account/usage/plan endpoints on the API-key side
GET /api/* 404 No separate dashboard API surface

Chat completion response (POST /v1/chat/completions) carries metadata in two places:

  • Body: usage.remaining.hypercredits (float) and usage.cost.usd / usage.cost.hypercredits per response
  • Headers: x-ratelimit-limit-day, x-ratelimit-limit-hour, x-ratelimit-remaining-day, x-ratelimit-remaining-hour (request windows, not Hypercredit refresh)

Dashboard "Plan / Shred / Next Hypercredit refresh in 13h" panel is server-rendered HTML behind cookie auth, not exposed via any API-key endpoint I could find.

Auth conventions:

  • HYPER_API_KEY env var — matches Crush and @charmland/pi-hyper-provider conventions
  • OAuth subscription flow also exists (used by Crush), but API key is the simpler path

Operator: Charmbracelet, Inc., Brooklyn NY — first-party operator, not a reseller (relevant to CodexBar's hosted-relay eligibility clause in docs/provider.md).

Reference implementations in the wild:

  • charmbracelet/crush/internal/agent/hyper/provider.go — Go; calls /v1/credits for balance, also extracts remaining.hypercredits from chat response metadata
  • @charmland/pi-hyper-provider (TypeScript) — Pi extension; same /credits endpoint, plus OAuth + team-name display

Existing CodexBar providers with similar shape

Recorded in case useful as templates — not a recommendation:

  • DeepSeek — API-key balance-only, no reset window (docs/deepseek.md)
  • Mistral — API-key + browser-cookie hybrid; cookie path scrapes a server-rendered dashboard for plan + reset (docs/mistral.md)
  • Codex / Claude cost scan — local JSONL log scanner for per-response cost history

Open questions for the maintainer

  • Is balance-only (no reset timer) acceptable for a v1, or is the reset countdown a must-have from day one?
  • If reset is needed: is a browser-cookie strategy (Mistral-style) in scope, or should it wait for Charm to expose reset info via API key?
  • Any interest in a local Crush-log cost-scan path (reusing the existing Codex/Claude cost-scan architecture), or out of scope?

References

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    P3Low-risk cleanup, docs, polish, ergonomics, or speculative feature.clawsweeper:needs-maintainer-reviewClawSweeper marked this issue as needing maintainer review before automation.clawsweeper:needs-product-decisionClawSweeper marked this issue as needing a product or behavior decision.clawsweeper:no-new-fix-prClawSweeper does not recommend queueing a new automated fix PR for this issue.impact:auth-providerThis issue is about auth, provider routing, model choice, or SecretRef resolution.issue-rating: 🌊 off-meta tidepoolIssue quality rating does not apply to this item.

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions