intervals-mcp
intervals-mcp
一个独立的 MCP 服务器、CLI 和 Claude Code 插件,用于本地优先的 Intervals 时间跟踪。启动计时器或记录时间条目首先写入本地 SQLite 数据库;条目在后台或按需同步到 Intervals。报告和查询始终仅限本地,绝不调用 Intervals API。
安装(Claude Code 插件)
/plugin marketplace add sixfeetup/intervals-mcp
/plugin install intervals@intervals-mcp无需运行构建步骤:dist/ 捆绑包已提交到仓库。唯一的要求是 Node >= 22.5。
Related MCP server: Productivity Tracker MCP Server
安装(任意 MCP 主机)
克隆仓库并将你的 MCP 主机指向捆绑的服务器:
git clone https://github.com/sixfeetup/intervals-mcp.git{
"command": "node",
"args": ["/path/to/intervals-mcp/dist/server.mjs"]
}配置
凭据和设置按以下顺序解析:
环境变量
INTERVALS_HOME(或~/.intervals/)中的config.json
环境变量
Variable | Description |
| Intervals API 密钥,用于 HTTP Basic 认证 |
| Intervals API 基础 URL(默认: |
| 你的 Intervals 人员 ID(时间条目同步必需) |
| 覆盖默认本地存储路径( |
config.json 键
如果你更喜欢基于文件的配置,请在 INTERVALS_HOME(或 ~/.intervals/)中创建 config.json:
Key | Type | Description |
|
| Intervals API 密钥,用于 HTTP Basic 认证 |
|
| Intervals API 基础 URL(默认: |
|
| 你的 Intervals 人员 ID(时间条目同步必需) |
|
| 后台同步间隔(毫秒) |
运行 intervals setup(或 /intervals-setup 斜杠命令)会以 0600 权限写入此文件,并且绝不会将 API 密钥放入模型上下文中——密钥是在你自己的终端中通过交互式隐藏提示输入的。
CLI
该捆绑包附带一个零依赖的 CLI(dist/cli.mjs,作为包安装时通过 package.json#bin 暴露为 intervals):
Command | Description |
| 配置凭据并运行初始项目同步 |
| 显示数据库路径、凭据来源、计时器、待同步项 |
| 刷新本地项目目录 |
| 立即将待同步的时间条目推送到 Intervals |
| 显示、编辑或删除计时器 |
| 报告时间条目( |
| 设置项目默认值 |
运行 node dist/cli.mjs help(或 intervals help)查看完整用法文本。
代理工具
当作为 Claude Code 插件安装时,工具会以 mcp__plugin_intervals_intervals__ 前缀呈现:
Tool | Description |
| 在本地项目目录中搜索 ID 和分类(仅限本地) |
| 使用简单描述和可选的 |
| 停止计时器,解析分类,创建待处理的时间条目,并同步 |
| 更新运行中本地计时器的描述或项目/工作类型/模块提示 |
| 安全删除活动计时器或已停止且没有关联时间条目的计时器 |
| 直接添加已完成的时间条目(时长以分钟为单位) |
| 通过短 ID 或关联的计时器 ID 编辑现有的本地时间条目;使用 |
| 通过短 ID 或关联的计时器 ID 删除本地或已同步的时间条目 |
| 按日期范围和项目筛选器报告时间条目(仅限本地) |
| 列出活动或最近的本地计时器 |
| 将已停止的本地计时器 ID 映射到关联的本地时间条目 ID |
| 列出最近的本地时间条目及其同步状态 |
| 为项目配置默认工作类型/模块 |
| 立即重试将待处理的时间条目同步到 Intervals |
mcp__plugin_intervals_intervals__start_timer 接受可选的 start_at 值,用于追溯启动本地计时器。使用 HH:mm 或 H:mm 表示本地时间的今天,YYYY-MM-DD HH:mm 表示本地日期/时间,或使用带显式偏移/时区的 ISO 日期时间。未来的 start_at 值会被拒绝。
斜杠命令
Command | Description |
| 配置 Intervals 凭据并运行初始项目同步 |
| 显示 Intervals 数据库路径、凭据来源、活动计时器、待同步项、上次项目同步时间 |
| 刷新本地 Intervals 目录中的客户、项目、工作类型和模块 |
| 立即将待处理的本地时间条目推送到 Intervals |
| 显示活动或最近的 Intervals 计时器,或按 ID 编辑/删除计时器 |
| 按范围报告本地时间条目,或按 ID 编辑条目 |
| 为项目设置默认工作类型和可选模块 |
工作原理
计时器仅限本地。 启动计时器会写入一个轻量级本地行,仅包含描述。项目、工作类型和模块提示为可选。
运行中的计时器可以在本地重新分类。 在停止计时器之前编辑其项目、工作类型或模块提示;创建时间条目时会应用更新后的分类。
停止/应用会创建时间条目。 当你停止计时器时,你需要提供(或解析)项目和工作类型。服务器会创建一个待处理的时间条目,并立即尝试将其同步到 Intervals。
时间条目采用本地优先。
mcp__plugin_intervals_intervals__add_time、mcp__plugin_intervals_intervals__edit_time和mcp__plugin_intervals_intervals__stop_timer都会在任何网络调用之前持久化到 SQLite。如果同步失败,条目会以failed或pending状态保留在本地,并且可以重试。目录同步存储活动行。 项目同步会获取所有目录页面,保留活动项目和活动分类,并保留活动项目引用的客户。
报告仅限本地。
mcp__plugin_intervals_intervals__query_time和/intervals-time从 SQLite 读取,绝不调用 Intervals API。
开发者说明
如果你在 Claude Code 中打开此仓库本身,你可能会看到 intervals MCP 服务器被列为连接失败。这是预期的:仓库根目录下的 .mcp.json 是插件自身的配置,它引用了 ${CLAUDE_PLUGIN_ROOT},该变量仅在通过 /plugin install 安装插件时才会设置。编辑此仓库的源代码并不会安装插件,因此该变量未设置,服务器无法启动。在处理代码时,可以安全地拒绝或忽略任何相关提示。
This server cannot be installed
Maintenance
Resources
Unclaimed servers have limited discoverability.
Looking for Admin?
If you are the server author, to access and configure the admin panel.
Related MCP Servers
- FlicenseNot gradedqualityDmaintenanceEnables recording, querying, and summarizing daily work entries with tags using a local SQLite database. Supports work logging, search, timeline queries, tag management, and automated reminders for tracking daily tasks.
- FlicenseNot gradedqualityDmaintenanceEnables natural language task management including logging, updating, and summarizing productivity activities across multiple categories using a local SQLite database. It allows users to manage workflows and generate time-based summaries through standardized Model Context Protocol tools.1
- AlicenseAqualityAmaintenanceEnables tracking work time with start/stop timers, logging entries, and generating reports.48MIT
- AlicenseNot gradedqualityBmaintenanceEnables multi-project workspaces to share structured notes, API contracts, and handoff messages via a local SQLite database, with versioning and read tracking.GPL 3.0
Related MCP Connectors
Track time on usetimebook.com - start/stop timers, log entries, list projects/clients.
Business-day, SLA, cron and recurrence calculations — offline, holiday-aware, no network.
Private-by-default, local-first memory/context/task orchestrator for MCP apps and agents.
Latest Blog Posts
- Who's Calling? MCP Hosts Are an Identity Blind Spot (And the Spec Knows It)By Om-Shree-0709 on .mcpAgent IdentityOAuth 2.1
- Your AI Chatbot Just Exposed Your CEO's Salary to an InternBy Om-Shree-0709 on .Agent IdentityMCP SecurityOAuth Delegation
- Why MCP Servers Need Execution Sandboxing (And Why Your Current Stack Isn't Enough)By Om-Shree-0709 on .Agentic AiPrompt InjectionWebAssembly
MCP directory API
We provide all the information about MCP servers via our MCP API.
curl -X GET 'https://glama.ai/api/mcp/v1/servers/sixfeetup/intervals-mcp'
If you have feedback or need assistance with the MCP directory API, please join our Discord server