Loading
Loading
https://api.apifreaks.com/v1.0/geo/admin-units
1. Open the Authorizations dropdown and Verify your API key.
2. Click Run to see the live response here.
$ pip install requestsimport requests
url = "https://api.apifreaks.com/v1.0/geo/admin-units"
payload = {}
headers = {
'X-apiKey': ''
}
response = requests.request("GET", url, headers=headers, data=payload)
print(response.text)
| Field | Type | Requirement | Description |
|---|---|---|---|
| admin_units | Array | Mandatory | An array of administrative unit objects for the specified country, optionally filtered by admin level. |
| admin_units[].name | String | Mandatory | The full name of the administrative unit (e.g., "Punjab", "Azad Kashmir"). |
| admin_units[].admin_code | String | Mandatory | The short code identifying the administrative unit (e.g., "PB", "JK"). |
| admin_units[].admin_level | String | Mandatory | The type/level of the administrative unit (e.g., "province", "administered area", "federal capital territory"). |