date-time

Retrieve current date, time, and weekday for any IANA timezone.

2|Updated Feb 16, 2026
One-click install
npx skills add https://github.com/xkinput/keytao-bot --skill date-time-xkinput
Or copy as Structured Prompt for Agent▼
Please help me install this Agent Skill.
Skill: date-time
Source: https://github.com/xkinput/keytao-bot/tree/main/keytao_bot/skills/date-time
Command: npx skills add https://github.com/xkinput/keytao-bot --skill date-time-xkinput

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve? AI assistants cannot reliably answer questions about the current time or date from memory, leading to stale or fabricated answers. This Skill forces real-time lookups so users always get accurate, timezone-aware date and time information. ## Core Features & Use Cases - Real-Time Clock Lookup: Returns the current date, time, ISO timestamp, and Unix timestamp from the system clock. - Timezone Support: Accepts any IANA timezone name such as Asia/Shanghai, Asia/Tokyo, or UTC, with clear errors for invalid zones. - Localized Weekday Output: Provides the weekday in both English and Chinese for bilingual chatbot responses. - Use Case: A user in a QQ or Telegram group asks "东京现在几点?" and the bot calls the tool with timezone Asia/Tokyo to reply with the exact current time. ## Quick Start Ask the bot "现在几点?" or "What time is it in Tokyo right now?" and it will call the datetime tool to answer with the live result.

Frequently Asked Questions about date-time

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I get the current time in a specific timezone in Python?▼

Use datetime.now with zoneinfo.ZoneInfo passing an IANA timezone name like Asia/Shanghai or Asia/Tokyo. The tool returns the localized date, time, ISO string, and Unix timestamp for that zone.

What timezone format does the datetime tool accept?▼

The tool accepts IANA timezone names such as Asia/Shanghai, Asia/Tokyo, or UTC passed as the optional timezone parameter. If omitted, it defaults to the server's local timezone.

Why does the tool return an invalid timezone error?▼

The error occurs when the provided string is not a valid IANA timezone name recognized by zoneinfo, raising ZoneInfoNotFoundError. Check spelling and use the canonical Region/City format.

Does the datetime skill work without the zoneinfo module?▼

Without zoneinfo (Python before 3.9), timezone-specific queries return an error stating the environment does not support timezone lookup. Local time queries without a timezone parameter still work.

Can an AI chatbot answer time questions without calling this tool?▼

No, the skill explicitly requires calling the tool for real-time results because language models have no access to the live clock. Answering from memory would produce incorrect times.