Cover image
Einfacher Zeit-MCP-Server
Public

Einfacher Zeit-MCP-Server

Try Now
2025-03-27

UN DEFUR MCP Simple Qui Fournit UN Service de l'Heure Actuelle

3 years

Works with Finder

1

Github Watches

0

Github Forks

0

Github Stars

Serveur MCP Simple pour Service d'Heure

Ce dépôt contient un serveur MCP (Method Call Protocol) simple qui fournit un service pour obtenir l'heure actuelle. Le serveur implémente le protocole JSON-RPC 2.0 pour les appels de méthode.

Installation

# Cloner le dépôt
git clone https://github.com/Anragde/simple-time-mcp-server.git
cd simple-time-mcp-server

# Installer les dépendances
npm install

Démarrage du serveur

# Démarrer en mode développement (avec hot reload)
npm run dev

# Démarrer en mode production
npm start

Le serveur démarre par défaut sur le port 3000, mais vous pouvez le configurer en définissant la variable d'environnement PORT.

Méthodes disponibles

Le serveur expose les méthodes suivantes via l'endpoint /mcp :

1. getCurrentTime

Retourne l'heure actuelle dans le format spécifié.

Paramètres :

  • format (optionnel) : Format de l'heure (utilise le format de moment.js). Par défaut: 'YYYY-MM-DD HH:mm:ss'

Exemple de requête :

{
  "jsonrpc": "2.0",
  "method": "getCurrentTime",
  "params": {
    "format": "HH:mm:ss"
  },
  "id": 1
}

Exemple de réponse :

{
  "jsonrpc": "2.0",
  "result": {
    "time": "14:30:45",
    "timestamp": 1616929845123
  },
  "id": 1
}

2. getTimeInTimezone

Retourne l'heure actuelle dans le fuseau horaire spécifié.

Paramètres :

  • timezone (requis) : Le fuseau horaire (ex: 'Europe/Paris', 'America/New_York')
  • format (optionnel) : Format de l'heure. Par défaut: 'YYYY-MM-DD HH:mm:ss'

Exemple de requête :

{
  "jsonrpc": "2.0",
  "method": "getTimeInTimezone",
  "params": {
    "timezone": "Europe/Paris",
    "format": "ddd, DD MMM YYYY HH:mm:ss"
  },
  "id": 2
}

Exemple de réponse :

{
  "jsonrpc": "2.0",
  "result": {
    "time": "Mon, 28 Mar 2025 14:30:45",
    "timezone": "Europe/Paris",
    "timestamp": 1616929845123
  },
  "id": 2
}

Vérification de l'état du serveur

Un endpoint de vérification d'état est disponible à /health. Il peut être utilisé pour surveiller si le serveur fonctionne correctement.

Exemple de requête :

curl http://localhost:3000/health

Exemple de réponse :

{
  "status": "ok", 
  "timestamp": 1616929845123
}

Licence

MIT

相关推荐

  • NiKole Maxwell
  • I craft unique cereal names, stories, and ridiculously cute Cereal Baby images.

  • Bora Yalcin
  • Evaluator for marketplace product descriptions, checks for relevancy and keyword stuffing.

  • Joshua Armstrong
  • Confidential guide on numerology and astrology, based of GG33 Public information

  • https://suefel.com
  • Latest advice and best practices for custom GPT development.

  • Emmet Halm
  • Converts Figma frames into front-end code for various mobile frameworks.

  • Elijah Ng Shi Yi
  • Advanced software engineer GPT that excels through nailing the basics.

  • https://maiplestudio.com
  • Find Exhibitors, Speakers and more

  • lumpenspace
  • Take an adjectivised noun, and create images making it progressively more adjective!

  • Yasir Eryilmaz
  • AI scriptwriting assistant for short, engaging video content.

  • apappascs
  • Entdecken Sie die umfassendste und aktuellste Sammlung von MCP-Servern auf dem Markt. Dieses Repository dient als zentraler Hub und bietet einen umfangreichen Katalog von Open-Source- und Proprietary MCP-Servern mit Funktionen, Dokumentationslinks und Mitwirkenden.

  • huahuayu
  • Ein einheitliches API-Gateway zur Integration mehrerer Ethercan-ähnlicher Blockchain-Explorer-APIs mit Modellkontextprotokoll (MCP) für AI-Assistenten.

  • deemkeen
  • Steuern Sie Ihren MBOT2 mit einer Power Combo: MQTT+MCP+LLM

  • jae-jae
  • MCP -Server für den Fetch -Webseiteninhalt mit dem Headless -Browser von Dramatikern.

    Reviews

    2 (1)
    Avatar
    user_w1QJTsuH
    2025-04-16

    Mcp Server is an outstanding product by d747d that has significantly improved my server management experience. Its intuitive interface and reliable performance make it a must-have tool for any server administrator. The seamless integration and robust features ensure that my servers are always running smoothly and efficiently. Highly recommend! For more information, visit https://mcp.so/server/mcp-server/d747d.