Timezone list
This API returns a list of available time zones that can be used when configuring a user or an object.
How to get data
Request address
To get the data, use the address: https://<server_address>/api/api.php?
Request method
GET or POST
Request parameters
-
cmd=get_time_zones — API command to retrieve the list of time zones
-
node — node number where the command should be executed
Example GET request
https://<server_address>/api/api.php?cmd=get_time_zones&node=1
|
Example POST request
Request body (JSON):
{
"cmd": "get_time_zones"
}
|
Response
{
"code": 0,
"data": [
{ "text": "Africa/Abidjan" },
{ "text": "Africa/Accra" },
{ "text": "Africa/Addis Ababa" },
{ "text": "Africa/Algeria" },
{ "text": "Africa/Asmara" },
{ "text": "Africa/Bamako" },
{ "text": "Africa/Bangui" }
]
}
|
In response to the API request, the following is returned:
-
code — result code (0 = successful operation)
-
data — list of available time zones
-
text— time zone name in the format Region/City