no-api-key
time
timezones

Timezone converter: instant to local time in an IANA time zone and back, with UTC offset and DST state

Timezone converter: convert an instant to wall-clock time in a named IANA time zone, or a wall-clock time in a zone back to an instant. Returns the local date and time, the UTC offset in ±HH:MM and seconds, the zone abbreviation, whether DST is in effect, the ISO week date, and the day of year. Handles the ambiguous and skipped local times at DST boundaries explicitly rather than guessing.

Output (data): zone, instant (RFC 3339 UTC), epoch_ms, local (YYYY-MM-DDTHH:MM:SS), offset (+HH:MM), offset_seconds, abbreviation, dst, weekday, iso_week {year, week, weekday}, day_of_year, ambiguity (null|repeated|skipped), resolution (null|the ambiguous mode applied), gap (true when a skipped local time was moved forward by the gap length). abbreviation is the runtime (Intl en-US) short name, e.g. GMT+2 or EDT.

Deterministic only when the query fixes the instant; otherwise the answer depends on the current time and is served no-store. meta.deterministic says which.

Price: $0.05 USDC per call (x402, Base). Route contract version 1.0.0. Docs: https://api.duoleads.com/docs#time-zone

get/v1/time/zone

Request

  • Base URL: https://api.duoleads.com
  • URL: https://api.duoleads.com/v1/time/zone
  • Auth: none declared

Query parameters

zonestring required

IANA time zone id, e.g. Europe/Amsterdam. Accepted: an IANA time zone id, e.g. Europe/Amsterdam.

instantstring

RFC 3339 timestamp or integer Unix seconds/milliseconds. Defaults to now. Mutually exclusive with local. Accepted: RFC 3339 timestamp or integer epoch.

localstring

Wall-clock time YYYY-MM-DDTHH:MM[:SS] in zone, converted back to an instant. Mutually exclusive with instant. Accepted: YYYY-MM-DDTHH:MM[:SS].

ambiguous'earlier' | 'later' | 'reject'

Only with local: which instant a repeated local time maps to. Default earlier. Accepted: earlier, later, reject.

Response

Paid and settled. data is route-specific; a route that judges its input returns 200 with data.valid: false for a bad value.

okunknown required
route'/v1/time/zone' required
version'1.0.0' required

Changes

No recorded changes to this operation across all 1 revision of this API.