← Back to Skills Marketplace
unknown-shu

Codex Account Switcher

by Unknown-shu · GitHub ↗ · v0.2.0 · MIT-0
cross-platform ✓ Security Clean
63
Downloads
0
Stars
0
Active Installs
2
Versions
Install in OpenClaw
/install unknownshu-codex-account-switcher
Description
Query OpenAI Codex OAuth account quotas in OpenClaw, switch the preferred account by email/profile id, and optionally auto-switch when 5h quota drops below a...
Usage Guidance
This skill appears to do what it says: it reads your OpenClaw auth profiles, uses each profile's OAuth access token to query the ChatGPT WHAM usage endpoint, and can reorder auth-state.json to make another profile primary. Before installing/running: 1) Inspect the scripts locally (they are bundled) and confirm the WHAM_URL (chatgpt.com) is acceptable for your environment. 2) Understand codex-cli-sync will import tokens from ~/.codex/auth.json into OpenClaw profiles (tokens end up on disk in auth-profiles.json) — ensure you trust the machine and repository. 3) Run with --dry-run first to confirm behavior and check backups created (profiles/state backups are made). 4) Confirm OpenClaw and the scripts run under an account with appropriate permissions; consider limiting runtime to a dedicated user or container if you are nervous. 5) If you use notifications, verify NapCat/sendUrl configuration so messages do not leak account details to unintended recipients. If you want higher assurance, run the scripts manually from a secure shell and audit network traffic during a dry-run.
Capability Analysis
Type: OpenClaw Skill Name: unknownshu-codex-account-switcher Version: 0.2.0 The skill bundle is a legitimate utility designed to manage multiple OpenAI Codex OAuth accounts within the OpenClaw environment. It includes scripts for querying quotas, switching active accounts, and automatically failing over when rate limits are reached. While the scripts handle sensitive OAuth tokens and perform network requests to OpenAI and local notification endpoints (NapCat), the code logic is transparent, includes safety features like atomic file writes and backups, and explicitly avoids logging or printing secrets. No evidence of data exfiltration, malicious execution, or prompt injection was found; the capabilities are strictly aligned with the stated purpose of account management.
Capability Tags
requires-oauth-tokenrequires-sensitive-credentials
Capability Assessment
Purpose & Capability
Name/description claim: manage openai-codex OAuth profiles and switch preferred account based on quota. The scripts read OpenClaw auth/profile files, query quota endpoints, and reorder auth-state.json. The declared required binary ('openclaw') and provided scripts match the stated purpose.
Instruction Scope
Runtime instructions and bundled scripts read local OpenClaw agent files (auth-profiles.json, auth-state.json, agent dir), optionally read ~/.codex/auth.json, call an external quota endpoint (https://chatgpt.com/backend-api/wham/usage) using each profile's access token, and may rewrite auth-state.json (to switch accounts). The SKILL.md promises tokens won't be printed; the code appears careful not to print token values. This is in-scope but is sensitive: the scripts do transmit local access tokens to the chatgpt.com usage endpoint (necessary for quota checks).
Install Mechanism
No install spec; the skill is instruction- and script-based and runs local Python scripts. Nothing is downloaded from external URLs or written to non-standard system locations beyond the OpenClaw agent directory and logs, so install risk is low.
Credentials
Registry metadata declares no required env vars; SKILL.md lists optional env vars the scripts use (OPENCLAW_HOME, OPENCLAW_AGENT_ID, etc.). The scripts access local auth/profile files (and may import ~/.codex/auth.json). They copy access/refresh tokens into OpenClaw profiles (codex-cli-sync) and use tokens to call the WHAM endpoint — this is proportional to the task but is sensitive access to local credentials and results in tokens being present in OpenClaw profile files.
Persistence & Privilege
Skill does not request always:true and does not attempt to modify other skills or system-wide settings beyond the OpenClaw auth state and profiles it legitimately manages. It writes backups before changing files. It can be run manually or as cron; autonomy is the platform default but not elevated here.
How to Use
  1. Make sure OpenClaw is installed (local or Docker)
  2. Run the install command in chat: /install unknownshu-codex-account-switcher
  3. After installation, invoke the skill by name or use /unknownshu-codex-account-switcher
  4. Provide required inputs per the skill's parameter spec and get structured output
Version History
v0.2.0
Add explicit Codex CLI sync: import current ~/.codex/auth.json login into OpenClaw auth profiles with dry-run and backups.
v0.1.0
Initial release: query OpenAI Codex OAuth quotas, switch preferred account, and auto-switch on low 5h quota.
Metadata
Slug unknownshu-codex-account-switcher
Version 0.2.0
License MIT-0
All-time Installs 0
Active Installs 0
Total Versions 2
Frequently Asked Questions

What is Codex Account Switcher?

Query OpenAI Codex OAuth account quotas in OpenClaw, switch the preferred account by email/profile id, and optionally auto-switch when 5h quota drops below a... It is an AI Agent Skill for Claude Code / OpenClaw, with 63 downloads so far.

How do I install Codex Account Switcher?

Run "/install unknownshu-codex-account-switcher" in the OpenClaw or Claude Code chat to install it in one step — no extra setup required.

Is Codex Account Switcher free?

Yes, Codex Account Switcher is completely free, licensed under MIT-0. You can download, install and use it at no cost.

Which platforms does Codex Account Switcher support?

Codex Account Switcher is cross-platform and runs anywhere OpenClaw / Claude Code is available (cross-platform).

Who created Codex Account Switcher?

It is built and maintained by Unknown-shu (@unknown-shu); the current version is v0.2.0.

💬 Comments