Read all timezones
GET {{baseUrl}}/api/model/timezones
This API gets a list of all available timezones. An information field describes the common object information such as the object ID, creation time, version ID, etc. The baseTimezone field is a reference to system timezone
object, and it only exists for custom timezones. The currentOffset field shows the number of seconds current timezone is ahead of or behind UTC. Since timezones are configuration objects, the project ID is not required to return a timezone's definition in metadata.
The changeset ID is required to return a timezone's definition within a specific changeset. A changeset ID can be obtained using the changeset creation API. An authorization token is required to execute the request and can be obtained using Authentication endpoints.
Body
PARAM
Key | Datatype | Required | Description |
subType
|
null | Specify which type of timezone shoud be returned. If not provided, all system and custom timezones will re returned. |
HEADERS
Key | Datatype | Required | Description |
X-MSTR-AuthToken
|
string | (Required) Authorization Token | |
X-MSTR-ProjectID
|
string | Project ID | |
X-MSTR-MS-Changeset
|
null | Changeset ID |
RESPONSES
status OK
{
"timezones": [
{
"information": {
"dateCreated": "2021-10-30T18:24:39.325Z",
"dateModified": "2021-10-30T18:24:39.325Z",
"versionId": "B92F4A710C43CA40E836FFA023B0C79D",
"primaryLocale": "en-US",
"objectId": "0B4AC9E54E016BF00EAA99929C2B4E5C",
"subType": "timezone_system",
"name": "Asia Shanghai time",
"ownerId": "54F3D26011D2896560009A8E67019608",
"description": "The time Curl curl -X GET 'baseUrl/api/model/timezones?subType=' -H 'X-MSTR-AuthToken: authToken' -H 'X-MSTR-ProjectID: projectId' -H 'X-MSTR-MS-Changeset: ' ENDPOINTS |