CountdownMCP
A local, read-only MCP server that gives Codex a plan-aware view of its remaining usage and helps choose work that fits the current usage window.
README
CountdownMCP
CountdownMCP is a local, read-only MCP server that gives Codex a plan-aware view of its remaining usage and helps it choose work that fits the current usage window.
It reports a percentage in the context of the actual plan (plus, pro, and other Codex plan types). It does not invent a token allowance or pretend that the same percentage means the same capacity across plans.
CountdownMCP complements TodoMCP, but both servers remain fully independent and useful on their own.
Codex should skip CountdownMCP for small, self-contained, low-risk tasks that can reasonably finish in one short turn. It should check usage once before work expected to take more than 10 minutes, require at least three meaningful execution steps, involve repeated implementation-and-test cycles, or be explicitly described as continuing across multiple substantial prompts.
What it does
- Reads live ChatGPT/Codex rate-limit data through the local Codex app-server.
- Reports plan, used and remaining percentages, all returned windows, reset time, credits, and limit state.
- Falls back to the latest local rate-limit metadata when app-server access is unavailable. Fallback results are explicitly marked with their source and staleness.
- Advises which ready tasks to run in normal, guarded, critical, and exhausted usage states.
- Keeps an active, continuation-safe task eligible even at 0% remaining, because an already-running Codex turn can often continue without a new user message.
- Uses STDIO only: no port, HTTP server, account token, or direct modification of another MCP server.
Requirements
- Node.js 18 or newer
- Codex CLI available as
codexand signed in to ChatGPT
Install
Clone the repository and run the installer:
git clone https://github.com/AlonTsur1601/CountdownMCP.git
Set-Location CountdownMCP
node install.mjs
The installer builds and tests the project first. It then installs a stable runtime under CODEX_HOME/mcp/countdown-mcp (normally ~/.codex/mcp/countdown-mcp) and updates only the countdown_mcp entry through the Codex CLI. Restart Codex after installation.
The installer preserves every other MCP entry. If replacing the CountdownMCP entry fails, it restores the prior Codex configuration and prior installed CountdownMCP runtime.
An installed copy is a local snapshot. New Git commits and GitHub Releases do not update it automatically. To update an existing clone, pull the newer source and rerun the installer:
Set-Location CountdownMCP
git pull --ff-only
node install.mjs
Restart Codex after installing or updating.
Tools
countdown_get_usage
No input. Returns structured data similar to:
{
"planType": "plus",
"usedPercent": 31,
"remainingPercent": 69,
"effectiveLimitId": "codex",
"source": "app_server",
"stale": false
}
Credits are reported separately from the plan percentage.
countdown_advise_work
Accepts the TodoMCP WorkCandidate v1 contract. Unknown fields are ignored for forward compatibility:
{
"currentTaskId": "task-1",
"tasks": [
{
"id": "task-1",
"title": "Run integration tests",
"priority": 5,
"estimatedMinutes": 20,
"dependenciesReady": true,
"needsUserInput": false,
"canContinueWithoutNewMessage": true,
"checkpointable": true
}
]
}
The output itself is compatible with TodoMCP's advice input:
{
"recommendedNow": ["task-1"],
"deferUntilReset": [],
"executionOrder": ["task-1"],
"checkpoint": "Create a small verified checkpoint after the first recommended task.",
"source": "countdown-mcp"
}
CountdownMCP does not store a queue, read TodoMCP files, import TodoMCP code, or bypass TodoMCP dependency and completion gates.
Either server continues to work normally when the other is absent.
Development
npm ci
npm run check
npm run smoke
npm run smoke uses the signed-in local Codex account and prints only the plan type and remaining percentage.
Data and security
- The live path asks Codex app-server only for
account/rateLimits/read. - The fallback parser returns only the
rate_limitsobject and its timestamp. It never returns conversation text, authentication data, or token-usage details. - Both tools are advertised as read-only, non-destructive, closed-world, and idempotent.
- Runtime diagnostics go to stderr; stdout is reserved for MCP protocol messages.
Releases
Pushing a tag that exactly matches the version in package.json (for example, v0.1.0) runs the release workflow. It repeats the full check and publishes a GitHub Release containing a source ZIP and SHA-256 checksum. Users extract the ZIP and run node install.mjs; no global npm publication is required.
License
推荐服务器
Baidu Map
百度地图核心API现已全面兼容MCP协议,是国内首家兼容MCP协议的地图服务商。
Playwright MCP Server
一个模型上下文协议服务器,它使大型语言模型能够通过结构化的可访问性快照与网页进行交互,而无需视觉模型或屏幕截图。
Magic Component Platform (MCP)
一个由人工智能驱动的工具,可以从自然语言描述生成现代化的用户界面组件,并与流行的集成开发环境(IDE)集成,从而简化用户界面开发流程。
Audiense Insights MCP Server
通过模型上下文协议启用与 Audiense Insights 账户的交互,从而促进营销洞察和受众数据的提取和分析,包括人口统计信息、行为和影响者互动。
VeyraX
一个单一的 MCP 工具,连接你所有喜爱的工具:Gmail、日历以及其他 40 多个工具。
graphlit-mcp-server
模型上下文协议 (MCP) 服务器实现了 MCP 客户端与 Graphlit 服务之间的集成。 除了网络爬取之外,还可以将任何内容(从 Slack 到 Gmail 再到播客订阅源)导入到 Graphlit 项目中,然后从 MCP 客户端检索相关内容。
Kagi MCP Server
一个 MCP 服务器,集成了 Kagi 搜索功能和 Claude AI,使 Claude 能够在回答需要最新信息的问题时执行实时网络搜索。
e2b-mcp-server
使用 MCP 通过 e2b 运行代码。
Neon MCP Server
用于与 Neon 管理 API 和数据库交互的 MCP 服务器
Exa MCP Server
模型上下文协议(MCP)服务器允许像 Claude 这样的 AI 助手使用 Exa AI 搜索 API 进行网络搜索。这种设置允许 AI 模型以安全和受控的方式获取实时的网络信息。