Cron Mcp

io.github.takeaseatventure由 GitHub 帳號 takeaseatventure 發布v0.1.2更新於 Oct 25, 2026

MCP cron validator for AI agents; flags impossible schedules and other silent cron bugs.

發布方自己的服務:Croncool Cron Jobs

已驗證STDIO僅桌面效率與工作流開發者工具

概覽

AI 產生的概覽

一個本機 MCP 伺服器,讓 AI 助理解析、驗證、解釋與預覽 cron 表達式,在部署前標出不可能或高風險的排程。

可以做什麼
將 cron 表達式解析成說明觸發時間的白話英文描述,支援 5 欄位標準 cron 以及 L、W、# 和月份/星期名稱寫法。深入驗證排程,檢查不可能日期、日與星期的 OR 語意、午夜尖峰、不均勻步長與閏年邊界,並估算觸發頻率。計算接下來 N 次觸發時間,以 ISO-8601 時間戳與相對位移呈現。查詢常見且經過驗證的預設排程庫,例如每 5 分鐘、每小時、工作日 9 點、每月與每季。
適用情境
適合在撰寫或審查排程工作、CI 流程或計畫任務的 cron 排程時使用,讓助理在任務部署前找出永不觸發、日與星期 OR 陷阱等隱性錯誤。也適合解釋既有表達式或產生下次觸發預覽。
執行需求
以本機 stdio 程序在使用者機器上執行,透過 npm 套件 cron-mcp-server 安裝(全域安裝或 npx),需要 Node.js。未宣告驗證、環境變數或標頭。需在 Claude Desktop、Cursor 或 VS Code Copilot 等桌面用戶端中設定啟動。
安裝前請注意
這些工具只對使用者提供的表達式做唯讀分析;README 未描述寫入、傳送或將資料傳給第三方。它只是內建 cron 引擎的薄封裝,結果取決於該引擎對 cron 語意的解讀。不要求任何憑證。

安裝

在 SourceWeft 中

  1. 開啟 儀表板中的 Cron Mcp,將其新增到工作區。
  2. 為需要使用其工具的對話啟用該服務。

Desktop only,透過 STDIO。 STDIO 服務會啟動本機處理程序,因此需要 SourceWeft 桌面主機。

其他 MCP 客戶端

參照 儲存庫 中的啟動說明。

README

cron-mcp

An MCP (Model Context Protocol) server that lets AI coding agents — Claude, Cursor, Copilot, Cline — parse, validate, explain, and preview cron expressions.

Built to catch silent cron bugs (impossible schedules, OR-semantics gotchas, midnight spikes) before a job is deployed — a class of mistake that's easy to make and hard to notice until a critical job silently fails to fire.

Why

Cron expressions are deceptively tricky. Common silent failures:

  • 0 0 30 2 * → never runs (February has no 30th). Syntactically valid, semantically dead.
  • 0 0 1,15 * 1 → fires on the 1st OR 15th OR Monday, not "the 1st and 15th if Monday" (the classic dom+dow OR-semantics trap).
  • */7 * * * * → uneven step; intervals drift (:00, :07, :14, …, :56, :00 — not "every 7 minutes" cleanly).
  • 0 0 * * * → midnight spike; every job in the system competes at 00:00.

cron-mcp surfaces these as warnings, observations, and suggestions that the AI agent can act on — before you ship the schedule.

Tools exposed

ToolDescription
parse_cronParse a cron expression → plain-English description of when it fires. Supports 5-field standard cron + L (last), W (nearest weekday), # (nth weekday), named months/days.
validate_cronDeep validation: impossible schedules, OR-semantics, midnight spikes, uneven steps, leap-year edges, frequency estimate (~runs/year).
next_runsCompute the next N fire times as ISO-8601 + relative offsets.
cron_presetsLibrary of common, proven schedules (every 5 min, hourly, weekdays 9am, monthly, quarterly, …).

Install

bash
npm install -g cron-mcp-server

Published links

Configure

Claude Desktop

Add to ~/Library/Application Support/Claude/claude_desktop_config.json (macOS) or the equivalent on your OS:

json
{  "mcpServers": {    "cron": {      "command": "cron-mcp-server",      "args": []    }  }}

Cursor

Add to .cursor/mcp.json (or ~/.cursor/mcp.json for global):

json
{  "mcpServers": {    "cron": {      "command": "cron-mcp-server"    }  }}

VS Code (Copilot)

json
{  "mcp.servers": {    "cron": {      "type": "stdio",      "command": "cron-mcp-server"    }  }}

Direct (no install)

bash
npx cron-mcp-server

Example usage

Once connected, just ask the agent in natural language:

  • "Validate this cron: 0 0 30 2 *"
  • "When does */5 * * * * next fire?"
  • "Give me a cron for every weekday at 9am"
  • "Is there anything risky about 0 0 1,15 * 1?"

The agent calls the tools and returns structured, actionable results.

Engine

The cron engine is battle-tested: 638 lines, zero dependencies, originally extracted from a browser-based cron generator and hardened with 69 unit tests. This MCP server is a thin tool wrapper around it.

License

MIT © takeaseatventure

來源:README.md,提交 902a68e

工具

0
SourceWeft 尚未在沙箱中啟動過該軟體包,因此其工具未知。

版本歷史

1
  1. v0.1.2最新Sep 16, 2026

評分

已滿足適用檢查項的 50%

該評分衡量此收錄條目的完整程度,依據註冊中心條目、端點與公開來源計算得出。它不是對伺服器本身的評價,也不表示伺服器安全或目前可用:可連通性是帶日期的檢查結果,評分也不包含安裝量或使用者評價。

  • 近 30 天內可連通25 分

    請保持端點能夠回應 MCP 握手;SourceWeft 每 30 天探測一次。

  • 已宣告認證方式10 分

    請在註冊中心條目中宣告憑證請求標頭,或保持端點能夠回應探測,以便判定其認證方式。

  • 已列出工具15 分

    請讓伺服器在無憑證時回應 tools/list,或發布可在沙箱中無憑證啟動的軟體包。

  • 描述必需15 分
  • 圖示10 分
  • 文件15 分
  • 授權條款10 分

其他 Cron 整合