Skip to content

Municipalities

Municipality endpoints expose Turkey's municipality records and municipality-scoped child collections.

Base path:

http
/v2/municipalities

Endpoints

MethodPathDescription
GET/v2/municipalitiesList municipalities
GET/v2/municipalities/{municipalityId}Get one municipality by ID
GET/v2/municipalities/{municipalityId}/neighborhoodsList neighborhoods in a municipality

Municipality Object

FieldTypeDescription
idintegerMunicipality ID
namestringMunicipality name
slugstringURL-safe municipality name
typestringMunicipality type. Allowed values: province_center, district_center, town
provinceIdintegerParent province ID
districtIdintegerParent district ID
populationintegerMunicipality population
stats.neighborhoodCountintegerNumber of neighborhoods in the municipality

Example municipality:

json
{
  "id": 926,
  "name": "Yumurtalık",
  "slug": "yumurtalik",
  "type": "district_center",
  "provinceId": 1,
  "districtId": 1734,
  "population": 17806,
  "stats": {
    "neighborhoodCount": 24
  }
}

List Municipalities

http
GET /v2/municipalities

Returns a paginated list of municipalities.

Query Parameters

ParameterTypeDefaultDescription
searchstring-Filters by municipality name
fieldsstring-Comma-separated municipality fields to include
sortstringidSorts by a municipality field. Allowed values: id, -id, name, -name, population, -population
limitinteger100Number of records to return, from 1 to 1000
offsetinteger0Number of records to skip
minPopulationinteger-Minimum population
maxPopulationinteger-Maximum population
provinceIdinteger-Filters municipalities by parent province ID
districtIdinteger-Filters municipalities by parent district ID
typestring-Filters by municipality type. Allowed values: province_center, district_center, town

If both minPopulation and maxPopulation are provided, minPopulation must be less than or equal to maxPopulation. When combining provinceId and districtId, the district must belong to the selected province.

Allowed Fields

text
id,name,slug,type,provinceId,districtId,population,stats

Request

bash
curl "https://api.turkiyeapi.dev/v2/municipalities?provinceId=1&limit=2&fields=id,name,provinceId,population"

Response

json
{
  "data": [
    {
      "id": 926,
      "name": "Yumurtalık",
      "provinceId": 1,
      "population": 17806
    },
    {
      "id": 927,
      "name": "Tufanbeyli",
      "provinceId": 1,
      "population": 16027
    }
  ],
  "meta": {
    "count": 2,
    "total": 15,
    "limit": 2,
    "offset": 0,
    "datasetVersion": "2025",
    "lastUpdated": "2026-05-21"
  }
}

Get Municipality by ID

http
GET /v2/municipalities/{municipalityId}

Returns one municipality by numeric municipality ID.

Path Parameters

ParameterTypeDescription
municipalityIdintegerMunicipality ID

Query Parameters

ParameterTypeDescription
fieldsstringComma-separated municipality fields to include
includestringComma-separated related resources to include.

Includes

text
province,district,neighborhoods

Request

bash
curl "https://api.turkiyeapi.dev/v2/municipalities/926?include=province,district,neighborhoods"

Response

json
{
  "data": {
    "id": 926,
    "name": "Yumurtalık",
    "slug": "yumurtalik",
    "type": "district_center",
    "provinceId": 1,
    "districtId": 1734,
    "population": 17806,
    "stats": {
      "neighborhoodCount": 24
    },
    "province": {
      "id": 1,
      "name": "Adana",
      "slug": "adana",
      "population": 2283609,
      "area": {
        "value": 13844,
        "unit": "km2"
      },
      "altitude": {
        "value": 25,
        "unit": "m"
      },
      "phoneAreaCodes": [322],
      "isCoastal": true,
      "isMetropolitan": true,
      "region": {
        "tr": "Akdeniz",
        "en": "Mediterranean"
      },
      "coordinates": {
        "latitude": 36.9863599,
        "longitude": 35.3252861
      },
      "stats": {
        "districtCount": 15,
        "municipalityCount": 15,
        "neighborhoodCount": 831,
        "villageCount": 0
      }
    },
    "district": {
      "id": 1734,
      "name": "Yumurtalık",
      "slug": "yumurtalik",
      "provinceId": 1,
      "population": 17806,
      "area": {
        "value": 447,
        "unit": "km2"
      },
      "stats": {
        "municipalityCount": 1,
        "neighborhoodCount": 24,
        "villageCount": 0
      }
    },
    "neighborhoods": []
  },
  "meta": {
    "datasetVersion": "2025",
    "lastUpdated": "2026-05-21"
  }
}

Included resources use their own schemas. The example above shortens nested objects for readability.

List Neighborhoods in a Municipality

http
GET /v2/municipalities/{municipalityId}/neighborhoods

Returns neighborhoods whose municipalityId matches the path parameter.

Path Parameters

ParameterTypeDescription
municipalityIdintegerMunicipality ID

Query Parameters

ParameterTypeDefaultDescription
fieldsstring-Comma-separated neighborhood fields to include
postalCodestring-Filters by exact five-digit postal code
postalCodePrefixstring-Filters by one-to-five digit postal code prefix
postalCodeStatusstring-Comma-separated postal code status filter
limitinteger100Number of records to return, from 1 to 1000
offsetinteger0Number of records to skip

Allowed Fields

text
id,name,slug,provinceId,districtId,municipalityId,population,postalCode,postalCodeStatus

Request

bash
curl "https://api.turkiyeapi.dev/v2/municipalities/926/neighborhoods?postalCodeStatus=official"

Common Errors

StatusCodeWhen it happens
400BAD_REQUESTQuery or path parameter validation fails
400INVALID_RANGE_FILTERminPopulation is greater than maxPopulation
400INVALID_HIERARCHY_FILTERprovinceId and districtId do not describe the same hierarchy
400INVALID_FIELDSfields contains an unknown field for the requested resource
400INVALID_INCLUDEinclude contains an unsupported relation
404MUNICIPALITY_NOT_FOUNDThe requested municipality does not exist
429-Rate limit exceeded
500INTERNAL_SERVER_ERRORUnexpected server error

Error response:

json
{
  "error": {
    "code": "MUNICIPALITY_NOT_FOUND",
    "message": "Municipality not found.",
    "status": 404
  }
}