Agentic-first time and date utility service. Get current time, parse dates, format dates, convert timezones, calculate durations, add/subtract time, Unix timestamp conversion. Plain text API, MCP-enabled, single Go binary, zero dependencies, no database.
make build
./timekitServer starts on :7700 by default.
| Endpoint | Description |
|---|---|
GET /now |
Get current time (optional: ?tz=, ?format=) |
GET /parse |
Parse a time string (?t=) |
GET /format |
Format a time (?t= &format=) |
GET /convert |
Convert timezone (?t= &tz=) |
GET /duration |
Duration between times (?t1= &t2=) |
GET /add |
Add duration to time (?t= &dur=) |
GET /sub |
Subtract duration from time (?t= &dur=) |
GET /unix |
Time to Unix timestamp (?t=) |
GET /fromunix |
Unix timestamp to time (?ts=) |
GET /dayofweek |
Day of week (?t=) |
GET /week |
ISO week number (?t=) |
GET /weekend |
Is weekend? (?t=) |
GET /startofday |
Start of day (?t=) |
GET /endofday |
End of day (?t=) |
GET /startofweek |
Start of week (?t=) |
GET /endofweek |
End of week (?t=) |
GET /startofmonth |
Start of month (?t=) |
GET /endofmonth |
End of month (?t=) |
GET /startofyear |
Start of year (?t=) |
GET /endofyear |
End of year (?t=) |
GET /timezones |
List common IANA timezone names |
GET /help |
Full usage manual |
POST /mcp |
MCP JSON-RPC 2.0 endpoint |
- Plain text by default (one labeled line per result)
- JSON on demand:
Accept: application/jsonor?format=json
Supports Go durations (1h, 30m, 1h30m) and custom units:
1d— days1w— weeks1mo— months1y— years
rfc3339, iso8601, unix, unixmilli, date, datetime, time, kitchen, ansic, stamp, stampmilli, stampmicro, stampnano, cookie, w3c, or any Go reference layout.
| Source | Variables |
|---|---|
| Env | TIMEKIT_PORT, TIMEKIT_HOST |
| Flags | -port, -host |
Priority: defaults < env < flags.
MIT