Timezones
Base URL https://api.leadx.in/api/key/protected. Every request needs an apikey header — see Authentication.
8 endpoints.
GET /timezone
Get all timezones.
Auth apikey
:::note Used by the web app
utils/timezoneService.js
:::
Query parameters
| Field | Default |
|---|---|
page | 1 |
limit | 50 |
search | "" |
offset | — |
isdst | — |
sort | offset,option |
global | true |
Response — data is one Timezone object. (Resource deduced from the collections this handler reads, not read off an explicit return.)
POST /timezone
Create timezone.
Auth apikey · Success 201
:::note Used by the web app
utils/timezoneService.js
:::
Request body
| Field | Default |
|---|---|
value | — |
abbr | — |
offset | — |
isdst | — |
option | — |
utc | — |
isActive | true |
Response — data is one Timezone object. updatedBy, createdBy are populated, so they arrive as nested objects rather than ids.
Errors DuplicateTimezone_409 · ValidationError_400
GET /timezone/:id
Get timezone by id.
Auth apikey
Path parameters
| Name | |
|---|---|
id | Required |
Response — data is one Timezone object. updatedBy, createdBy are populated, so they arrive as nested objects rather than ids.
Errors TimezoneNotFound_404
PUT /timezone/:id
Update timezone.
Auth apikey
Path parameters
| Name | |
|---|---|
id | Required |
Response — data is one Timezone object. updatedBy, createdBy are populated, so they arrive as nested objects rather than ids.
Errors DuplicateTimezone_409 · TimezoneNotFound_404
DELETE /timezone/:id
Delete timezone.
Auth apikey
Path parameters
| Name | |
|---|---|
id | Required |
Response — data is one ResponseMessage object. (Resource deduced from the collections this handler reads, not read off an explicit return.)
Errors TimezoneNotFound_404
POST /timezone/initialize
Initialize timezones.
Auth apikey · Success 201
Query parameters
| Field | Default |
|---|---|
force | false |
Response — data is one Timezone object.
Errors FileNotFound_404 · InvalidDataFormat_400
GET /timezone/search
Search timezones.
Auth apikey
Query parameters
| Field | Default |
|---|---|
q | "" |
limit | 20 |
Response — data is one ResponseMessage object. (Resource deduced from the collections this handler reads, not read off an explicit return.)
GET /timezone/stats
Get timezone stats.
Auth apikey
Response — data is one Timezone object.