All services related to cities are listed in this page.
GET City List
This method returns a list of cities with less detailed information.
Path:/api/v1/oms/cities/
Query Parameters
The following query parameters can be used to get information about cities.
Parameter
Data Type
In
Description
token
string
header
The API key of the customer account
Example Request
To get a list of all cities, a GET request should be sent to the /api/v1/oms/cities/ endpoint. In the headers, set the Authorization header to include the token for authentication.
Here's an example of how to make the request in python:
In a successful response with a status code of 200 OK, the API returns all the cities in a JSON format. The response body contains a JSON object with the cities and their associated attributes, which may include ID, name, country, etc.
These attributes are described in the following table.
Parameter
Data Type
Description
pk
integer
The ID of the city
name
string
The name of the city
country
integer
The country ID of the city
is_active
boolean
The status of the city
latitude
decimal
The latitude value of the city
longitude
decimal
The longitude value of the city
This example response serves as a reference to understand the structure and data format returned from this API service.
This method retrieves a list of cities with detailed information.
Path:/api/v1/oms/cities/list-simple/
Query Parameters
The following query parameters can be used to get the information about cities.
Parameter
Data Type
In
Description
token
string
header
The API key of the customer account
Example Request
To get a detailed list of all cities, a GET request should be sent to the /api/v1/oms/cities/list-simple/ endpoint. In the headers, set the Authorization header to include the token for authentication.
Here's an example of how to make the request in python:
In a successful response with a status code of 200 OK, the API returns all the cities in a JSON format. The response body contains a JSON object with the cities and their associated attributes, which may include ID, name, country, created_date,
modified_date, etc.
These attributes are described in the following table.
Parameter
Data Type
Description
id
integer
The ID of the city
created_date
date
The creation date of the city
modified_date
date
The last modified date of the city
omnitron_id
integer
The Omnitron ID of the city
name
string
The name of the city
country
integer
The country ID of the city
is_active
boolean
The status of the city
latitude
decimal
The latitude value of the city
longitude
decimal
The longitude value of the city
mapping
json
The mapped values of the city
This example response serves as a reference to understand the structure and data format returned from this API service.