Geographic Data

Countries, cities, townships, districts (public)

List Countries

get

Get all available countries.

Query parameters
pageinteger · min: 1Optional

Page number (starts from 1)

Default: 1Example: 1
page_sizeinteger · min: 1Optional

Number of records per page

Default: 10Example: 10
Header parameters
Accept-Languagestring · enumOptional

Language preference (for multilingual content). Supported languages: tr, en, ar, ru, de, fr

Default: trExample: trPossible values:
Responses
200

List of countries

application/json
get
/address/country/
GET /address/country/ HTTP/1.1
Host: sandbox.akinon.com
Accept: */*
200

List of countries

{
  "count": 2,
  "next": null,
  "previous": null,
  "results": [
    {
      "pk": 1,
      "name": "Türkiye",
      "code": "TR",
      "is_active": true,
      "translations": {}
    },
    {
      "pk": 2,
      "name": "United States",
      "code": "US",
      "is_active": true,
      "translations": {}
    }
  ]
}

List Cities

get

Get cities, optionally filtered by country.

Query parameters
countryintegerOptional

Country ID

pageinteger · min: 1Optional

Page number (starts from 1)

Default: 1Example: 1
page_sizeinteger · min: 1Optional

Number of records per page

Default: 10Example: 10
Header parameters
Accept-Languagestring · enumOptional

Language preference (for multilingual content). Supported languages: tr, en, ar, ru, de, fr

Default: trExample: trPossible values:
Responses
200

List of cities

application/json
get
/address/city/
GET /address/city/ HTTP/1.1
Host: sandbox.akinon.com
Accept: */*
200

List of cities

{
  "count": 1,
  "next": "https://example.com",
  "previous": "https://example.com",
  "results": [
    {
      "pk": 1,
      "is_active": true,
      "name": "text",
      "country": 1,
      "translations": {},
      "priority": 1,
      "postcode": "text"
    }
  ]
}

Get City Details

get

View details of a specific city.

Path parameters
pkintegerRequired
Header parameters
Accept-Languagestring · enumOptional

Language preference (for multilingual content). Supported languages: tr, en, ar, ru, de, fr

Default: trExample: trPossible values:
Responses
200

City details

application/json
get
/address/city/{pk}/
GET /address/city/{pk}/ HTTP/1.1
Host: sandbox.akinon.com
Accept: */*
{
  "pk": 1,
  "is_active": true,
  "name": "text",
  "country": 1,
  "translations": {},
  "priority": 1,
  "postcode": "text"
}
get

Search cities by name (minimum 2 characters).

Note: Query parameter q is mapped internally to name.

Query parameters
qstring · min: 2Required

City name to search (minimum 2 characters)

countryintegerOptional

Filter by country ID

pageinteger · min: 1Optional

Page number (starts from 1)

Default: 1Example: 1
page_sizeinteger · min: 1Optional

Number of records per page

Default: 10Example: 10
Header parameters
Accept-Languagestring · enumOptional

Language preference (for multilingual content). Supported languages: tr, en, ar, ru, de, fr

Default: trExample: trPossible values:
Responses
200

Matching cities

application/json
get
/address/city/search/
GET /address/city/search/?q=text HTTP/1.1
Host: sandbox.akinon.com
Accept: */*
{
  "count": 1,
  "next": "https://example.com",
  "previous": "https://example.com",
  "results": [
    {
      "pk": 1,
      "is_active": true,
      "name": "text",
      "country": 1,
      "translations": {},
      "priority": 1,
      "postcode": "text"
    }
  ]
}

List Townships

get

Get townships (districts of cities), optionally filtered by city.

Query parameters
cityintegerOptional

City ID

pageinteger · min: 1Optional

Page number (starts from 1)

Default: 1Example: 1
page_sizeinteger · min: 1Optional

Number of records per page

Default: 10Example: 10
Header parameters
Accept-Languagestring · enumOptional

Language preference (for multilingual content). Supported languages: tr, en, ar, ru, de, fr

Default: trExample: trPossible values:
Responses
200

List of townships

application/json
get
/address/township/
GET /address/township/ HTTP/1.1
Host: sandbox.akinon.com
Accept: */*
200

List of townships

{
  "count": 1,
  "next": "https://example.com",
  "previous": "https://example.com",
  "results": [
    {
      "pk": 1,
      "is_active": true,
      "name": "text",
      "city": 1,
      "postcode": "text",
      "translations": {}
    }
  ]
}

List Districts

get

Get districts (neighborhoods), optionally filtered by township.

Query parameters
townshipintegerOptional

Township ID

pageinteger · min: 1Optional

Page number (starts from 1)

Default: 1Example: 1
page_sizeinteger · min: 1Optional

Number of records per page

Default: 10Example: 10
Header parameters
Accept-Languagestring · enumOptional

Language preference (for multilingual content). Supported languages: tr, en, ar, ru, de, fr

Default: trExample: trPossible values:
Responses
200

List of districts

application/json
get
/address/district/
GET /address/district/ HTTP/1.1
Host: sandbox.akinon.com
Accept: */*
200

List of districts

{
  "count": 1,
  "next": "https://example.com",
  "previous": "https://example.com",
  "results": [
    {
      "pk": 1,
      "is_active": true,
      "name": "text",
      "city": 1,
      "township": 1,
      "postcode": "text",
      "translations": {}
    }
  ]
}

Last updated

Was this helpful?