getDateTime
Retrieve the current date and time in any IANA timezone, with optional custom formatting and NTP synchronization for higher accuracy. Falls back to server time on timeout.
Instructions
Get current date and time in specified timezone with optional NTP synchronization. Fast response using server time by default, optionally fetch from NTP servers for high accuracy.
Tool call template
Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.
{
"id": 1,
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"arguments": {
"timezone": "<timezone>"
},
"name": "getDateTime"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| format | No | Optional format string. Supported tokens: YYYY (year), MM (month), DD (day), HH (24-hour), hh (12-hour), mm (minutes), ss (seconds), SSS (milliseconds), A/a (AM/PM). Example: 'YYYY-MM-DD HH:mm:ss' | |
| locale | No | Optional locale for formatting (e.g., 'en-US', 'pl-PL'). Used when format string not provided. Default: 'en-US' | |
| useNTP | No | Use NTP servers for time synchronization. Default: false (uses fast server time) | |
| timezone | Yes | IANA timezone name (e.g., 'America/New_York', 'Europe/Warsaw', 'Asia/Tokyo') | |
| ntpTimeout | No | NTP timeout in milliseconds. Default: 1000ms. Falls back to server time on timeout |