🎁 Get the FREE AI Skills Starter Guide β€” Subscribe β†’
BytesAgainBytesAgain
πŸ¦€ ClawHub

Codex Profiler

by @deadlysilent

Manage OpenAI Codex profiles via Telegram commands for usage checks and OAuth token refresh with queued safe apply and progress updates.

Versionv1.0.27
Installs1
πŸ’‘ Examples

  • /codex_usage β†’ selector (default / all / discovered profiles)
  • /codex_usage
  • Auth

  • /codex_auth β†’ selector (profiles)
  • /codex_auth
  • /codex_auth finish (helper only; profile/order mutation must use gateway-native commands)
  • πŸ“‹ Tips & Best Practices

  • Uses auth profiles at ~/.openclaw/agents/main/agent/auth-profiles.json by default.
  • Current source of truth is auth-profiles.json; auth.json is legacy compatibility and should not be used as primary state.
  • If profile routing behaves unexpectedly, check for mixed state (missing/stale auth-profiles.json, leftover legacy files, or stale runtime cooldown) before assuming model fallback bugs.
  • Same accountId across two profile labels is not automatically a defect. In this environment, multiple labels can map to the same workspace/account identity while still operating correctly. Treat it as healthy when both profiles are auth-valid and usable in /codex_usage; investigate only when auth failures or routing failures appear.
  • Codex usage endpoint: https://chatgpt.com/backend-api/wham/usage.
  • Usage script now surfaces 401 as auth_not_accepted_by_usage_endpoint with a clear hint, while still returning local profile health.
  • Usage output now includes top-level summary, formatted_profiles, and suggested_user_message for cleaner slash-command formatting.
  • Preferred strict output format for /codex_usage (single line per profile):
  • - 🟒 \%profile%\ β€” 5h %5h_left% | week %week_left% | r5 %5h_reset% | rw %week_reset% - Use 🟠 when limited and πŸ”΄ when unusable/auth-invalid. - No preface, no table, no trailing summary unless explicitly requested.
  • OAuth flow: OpenAI auth endpoints + localhost callback on port 1455.
  • Preferred mutation path is gateway-native (openclaw models auth ... / openclaw models auth order ...) with mandatory preflight + verify.
  • codex_auth.py status --profile remains useful for per-profile helper status checks.
  • Keep temporary payload/token artifacts only until verification succeeds, then clean them up.
  • Codex CLI installation is not required for usage endpoint reads in this skill path.
  • View on ClawHub
    TERMINAL
    clawhub install codex-profiler

    πŸ§ͺ Use this skill with your agent

    Most visitors already have an agent. Pick your environment, install or copy the workflow, then run the smoke-test prompt above.

    πŸ” Can't find the right skill?

    Search 60,000+ AI agent skills β€” free, no login needed.

    Search Skills β†’