Convert a unix timestamp
convert_unix_timestampConvert epoch seconds, milliseconds, microseconds, or nanoseconds to ISO-8601 and RFC 2822 in an IANA time zone, or convert a calendar time back to epoch.
Tool call template
This tool declares no required parameters. Add optional parameters from the input schema as needed.
{
"id": 1,
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"arguments": {},
"name": "convert_unix_timestamp"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| day | No | ||
| hour | No | ||
| unit | No | auto | |
| year | No | ||
| input | No | Unix timestamp, ISO-8601, RFC 2822, or now. Leave it empty when year, month, and day are set. | |
| month | No | ||
| minute | No | ||
| second | No | ||
| timeZone | No | IANA time zone, such as UTC or America/New_York. | UTC |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| unit | Yes | ||
| isoUtc | Yes | ||
| offset | Yes | ||
| rfc2822 | Yes | ||
| seconds | Yes | ||
| weekday | Yes | ||
| isoLocal | Yes | ||
| relative | Yes | ||
| timeZone | Yes | ||
| milliseconds | Yes | ||
| alternateIsoUtc | Yes |