npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2026 – Pkg Stats / Ryan Hefner

@hckj00/mcp-servers

v1.0.1

Published

MCP Servers with date tool

Readme

MCP Servers

这是一个基于 Node.js 的 MCP Servers 实现,提供了符合 MCP(模型上下文协议)标准的工具接口。

功能特性

  • 符合 MCP 工具协议标准
  • 提供日期时间工具
  • 支持自定义日期格式
  • 支持时区设置
  • 返回时间戳和时区信息

安装

# 从 npm 安装
npm install @hckj00/mcp-servers

# 或者从源码安装
git clone <repository-url>
cd mcp-servers
npm install

运行服务器

# 开发模式运行(支持热重载)
npm run dev

# 生产模式运行
npm start

MCP 工具使用说明

1. 获取可用工具列表

GET /api/mcp/tools

响应示例:

[
  {
    "name": "get_current_date",
    "description": "获取当前日期时间,支持自定义格式和时区",
    "parameters": {
      "type": "object",
      "properties": {
        "format": {
          "type": "string",
          "description": "日期格式,例如:YYYY-MM-DD HH:mm:ss、YYYY年MM月DD日等"
        },
        "timezone": {
          "type": "string",
          "description": "时区,例如:Asia/Shanghai、America/New_York 等"
        }
      }
    }
  }
]

2. 调用工具

POST /api/mcp/invoke

请求体示例:

{
  "tool": "get_current_date",
  "parameters": {
    "format": "YYYY年MM月DD日 HH:mm:ss",
    "timezone": "Asia/Shanghai"
  }
}

响应示例:

{
  "date": "2024年03月20日 15:30:00",
  "timestamp": 1710932400000,
  "timezone": "Asia/Shanghai"
}

在模型中使用

在模型的工具配置中,可以这样定义:

{
  "name": "get_current_date",
  "description": "获取当前日期时间,支持自定义格式和时区。可用于获取系统时间、格式化日期等场景。",
  "parameters": {
    "type": "object",
    "properties": {
      "format": {
        "type": "string",
        "description": "日期格式,例如:YYYY-MM-DD HH:mm:ss、YYYY年MM月DD日等"
      },
      "timezone": {
        "type": "string",
        "description": "时区,例如:Asia/Shanghai、America/New_York 等"
      }
    }
  }
}

日期格式说明

支持的格式标记:

  • YYYY: 四位年份
  • MM: 两位月份
  • DD: 两位日期
  • HH: 24小时制小时
  • mm: 分钟
  • ss: 秒钟

更多格式请参考 Moment.js 文档

支持的时区

使用 IANA 时区数据库中的时区名称,例如:

  • Asia/Shanghai
  • America/New_York
  • Europe/London
  • UTC

完整的时区列表可以在 这里 查看。