Dates and time zones
Time tracking is mostly about time, so the rules here are strict and the same everywhere.
Instants: ISO 8601, answered in UTC
A moment in time — a start, an end, when something was created — is an ISO 8601 date-time.
- We answer in UTC, with milliseconds:
2026-09-30T03:30:00.000Z. - You may send any offset:
2026-09-30T09:00:00+05:30and2026-09-30T03:30:00Zare the same instant, and both are accepted. An offset is required: a time withoutZor±hh:mmis refused, because it could mean any moment.
Store instants as UTC and convert for display. Every language has a well-tested way to do that; don't do the arithmetic by hand.
Days: YYYY-MM-DD in a named time zone
A day — a report range, a filter, the day an entry is booked to — is a plain date such as 2026-09-30. A date only means something in a time zone, so Punchly always says which one:
- Time entries belong to the day they start, in the time zone of the person whose key it is (their Punchly profile setting). That is
localStartDate. An entry from 22:00 to 02:00 counts towards the day it began;endDayOffset: 1says it ended the next day. - The time-entry list's
fromandtoare such local start dates, both inclusive. - Reports take a
tz(an IANA name such asAsia/KolkataorAmerica/New_York) and draw every day's boundaries in it. Leave it out and the key owner's profile zone is used. Send it explicitly when your system runs somewhere else, so a night shift lands on the day your payroll expects. - Weeks start on the person's week-start setting.
weekTotalsin the time-entry list follow it.
Always use IANA names (Europe/London), never abbreviations (BST) or fixed offsets: names know about daylight saving, offsets don't.
Durations: whole seconds
Durations are integers in seconds, and their names end in S or Seconds: durationS, workS, breakS, overtimeS, totalSeconds.
- A running entry has
endAt: nullanddurationS: null. Work its duration out fromstartAtand your own clock if you need it. - To show hours, divide by 3600 at the last moment; round only what you display.
Money: minor units and a currency
Amounts and rates are integers in the currency's minor unit — cents, pence, paise — with names ending in Minor, and a currencyCode (ISO 4217) beside them:
{ "billableRateMinor": 7500, "billableAmountMinor": 33750, "currencyCode": "USD" }That is a rate of 75.00 an hour and an amount of 337.50. Integers mean no floating-point surprises when you add up a month.
A rate or amount is null when the key's owner may not see money in that workspace — the same rule as in the app. Use an owner's or admin's key if your integration needs them.
Ids
Every id is a UUID (for example 01928f3e-7a1c-7d2e-9b1a-3c4d5e6f7a8b). Treat it as an opaque string: compare it, store it, send it back; don't parse it.