MCP Catalogs
首页

time

官方

by modelcontextprotocol·85,748·综合分 77

功能全面的 MCP 服务器,提供时间和时区转换功能,可自动检测系统时区。

productivitydeveloper-toolscommunication
10,713
Forks
459
活跃 Issue
本月
最近提交
2 天前
收录于

概述

Time MCP Server 是一个维护良好、可投入生产使用的实现,它允许 LLM 访问当前时间信息并使用 IANA 时区名称执行时区转换。它提供两个主要工具:'get_current_time' 用于获取指定时区的当前时间,以及 'convert_time' 用于在不同时区之间转换时间。该服务器具有自动系统时区检测功能,但也允许显式时区配置。

试试问 AI

装完之后,这里有 5 个你可以让 AI 做的事:

:协助安排跨时区的国际会议
:为基于位置的查询提供实时时间信息
:为旅行计划和行程安排提供时间转换
:如何使用特定时区而不是系统时区?
:时区参数应使用什么格式?

什么时候选它

当您的 LLM 应用需要处理时间相关查询和时区转换,特别是为不同地理区域的用户提供服务时,选择此服务器。

什么时候不要选它

如果您需要比基本当前时间检索和时区转换更复杂的时间操作,或需要与日历系统集成,请避免使用。

此 server 暴露的工具

从 README 抽取出 2 个工具
  • get_current_timeget_current_time(timezone: string)

    Get current time in a specific timezone or system timezone.

  • convert_timeconvert_time(source_timezone: string, time: string, target_timezone: string)

    Convert time between timezones.

可对比工具

datetime-mcptimezone-mcpshell-mcp

安装

安装选项

**使用 uv(推荐):**

uvx mcp-server-time

**使用 PIP:**

pip install mcp-server-time
python -m mcp_server_time

**为 Claude Desktop 配置:**

{
  "mcpServers": {
    "time": {
      "command": "uvx",
      "args": ["mcp-server-time"]
    }
  }
}

FAQ

如何使用特定时区而不是系统时区?
您可以通过在配置的 args 中添加 '--local-timezone=Your/Timezone' 来覆盖系统时区,例如 '--local-timezone=America/New_York'。
时区参数应使用什么格式?
服务器使用 IANA 时区名称(例如 'America/New_York'、'Europe/London'、'Asia/Tokyo')。对于 convert_time 函数中的时间参数,请使用 24 小时格式(HH:MM)。

Hacker News 讨论

开发者社区最近的相关讨论。

time 对比

GitHub →

最后更新于 · 由 README + GitHub 公开数据自动生成。