Geographic
Get Cities by State
This endpoint returns a list of states or provinces for a specified country.
URL
PROD https://api.skypostal.com/
TEST https://api-test.skypostal.com/
Endpoint
POST /wcf-services/service-geographic.svc/geographic/get-states-by-country
Request Parameters
Parameters | |
---|---|
| Object - Required User Info Definition. |
| Integer - Required This is the code from the country that you want to get the states from. |
User Info Definition
Parameters | |
---|---|
| Integer - Required This is the user code provided by Skypostal. |
| String - Required This is the app key provided by Skypostal. |
| String - Required This is the app key provided by Skypostal. |
Remember
user_code
and app_key
are generic credentials, make sure to request your own for TEST
and PROD
environemnts.
The command should be run as in the following example:
{
"user_info": {
"user_code": 123123,
"user_key": "**",
"app_key": "***"
},
"country_code": 001
}
The command will return the following format:
[
{
"_verify": true,
"additional_info": {
"internal": [],
"server": {
"server_id": null,
"server_time": 0
}
},
"country_code": 230,
"country_iso_code": "UY",
"error": {
"error_code": "",
"error_description": "",
"error_location": "",
"system_error": false
},
"state_code": 4441,
"state_name": "Artigas"
}
]