New:Introducing Socket Scanning for VS Code Marketplace Extensions.Learn more →
Get Started

@strix-ai/currentdt

Package Overview
Dependencies
Maintainers
1
Versions
9
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install
Package was removed
Sorry, it seems this package was removed from the registry

@strix-ai/currentdt

A simple MCP tool that provides current date/time context to AI assistants in IDEs. strix-ai 🦉 - Wisdom in Every Line of Code

latest
Source
npmnpm
Version
1.3.1
Version published
Maintainers
1
Created
Source

CurrentDT - MCP DateTime Tool

strix-ai 🦉
Wisdom in Every Line of Code
Engineered by AI, Empowering AI

A minimal Model Context Protocol (MCP) tool that injects current date/time into AI prompts in supported IDEs.

What is CurrentDT?

CurrentDT is a small MCP server that provides the current date/time as a resource to AI assistants. It runs only when the IDE sends a prompt and returns a fresh timestamp each request.

  • Minimal surface: initialize, resources/list, resources/read, tools/list (placeholder for green status)
  • ISO 8601 by default; optional single custom format
  • Single timezone per request: local or utc
  • Config via env vars (optional tiny JSON)
  • No background processes, caching, hot-reload, or time-sync

Quick Start

# Install globally
npm install -g @strix-ai/currentdt

# Start the MCP server
currentdt start

Environment variables (optional):

# Format: 'iso' | 'custom'
export CURRENTDT_FORMAT=iso
# Custom format when format=custom (tokens: YYYY, MM, DD, HH, mm, ss)
export CURRENTDT_CUSTOM_FORMAT="YYYY-MM-DD HH:mm:ss"
# Timezone: 'local' | 'utc'
export CURRENTDT_TIMEZONE=local
# Provider: 'local' | 'remote' (remote requires consent; currently falls back to local)
export CURRENTDT_PROVIDER=local
# Remote URL (future use)
export CURRENTDT_REMOTE_URL=https://worldtimeapi.org/api/timezone/Etc/UTC
# Consent for any remote request (future use)
export CONSENT_REMOTE_TIME=true

IDE Integration

  • Cursor: auto-discovery; tools/list placeholder keeps status green
  • Other MCP-compatible IDEs: configure command currentdt with args start

JSON Configuration (optional)

Create a minimal JSON file (e.g., currentdt.config.json) and point the CLI to it:

{
  "format": "iso",          
  "timezone": "utc",        
  "provider": "local",      
  "customFormat": "YYYY-MM-DD HH:mm:ss",
  "remoteUrl": "https://worldtimeapi.org/api/timezone/Etc/UTC"
}

Run with:

currentdt start --config ./currentdt.config.json

Resource

  • URI: datetime://current
  • mimeType: text/plain
  • Content: one line ISO or custom formatted datetime in the selected timezone

Examples:

  • ISO + utc: 2025-01-15T12:34:56.789Z
  • ISO + local: 2025-01-15T07:34:56.789-05:00
  • Custom (YYYY-MM-DD HH:mm:ss) + utc: 2025-01-15 12:34:56

Development

npm install
npm run build
npm test
npm run local   # local runner with debug logging

Project structure:

src/
├── core/       # MCP server
├── resources/  # datetime resource provider
├── cli/        # CLI entry
├── utils/      # logger, result, validation
├── types/      # TS types
└── version.ts  # centralized version

License

MIT

Keywords

mcp

FAQs

Package last updated on 22 Aug 2025

Related posts