Skip to content

API Reference

TurkiyeAPI v2 is a read-only REST API for Turkey's administrative data. This reference documents endpoint contracts, query parameters, response envelopes, resource schemas, and error formats.

Base URL:

http
https://api.turkiyeapi.dev

v2 API prefix:

http
/v2

Reference Sections

SectionDescription
SystemHealth, metadata, and OpenAPI endpoints
DatasetsStatic dataset downloads
ProvincesProvince resources and province-scoped collections
DistrictsDistrict resources and district-scoped collections
MunicipalitiesMunicipality resources and municipality-scoped collections
NeighborhoodsNeighborhood resources
VillagesVillage resources
ErrorsError envelope, status codes, and error codes
SchemasShared response envelopes and schema summaries

Endpoint Groups

System

MethodPathDescription
GET/healthCheck service health
GET/v2/metaGet API and dataset metadata
GET/v2/openapi.jsonGet OpenAPI document

Datasets

MethodPathDescription
GET/v2/datasets/{datasetFile}Download latest dataset file
GET/v2/datasets/{datasetVersion}/{datasetFile}Download versioned dataset file

Settlement Resources

MethodPathDescription
GET/v2/provincesList provinces
GET/v2/provinces/{provinceId}Get one province
GET/v2/districtsList districts
GET/v2/districts/{districtId}Get one district
GET/v2/municipalitiesList municipalities
GET/v2/municipalities/{municipalityId}Get one municipality
GET/v2/neighborhoodsList neighborhoods
GET/v2/neighborhoods/{neighborhoodId}Get one neighborhood
GET/v2/villagesList villages
GET/v2/villages/{villageId}Get one village

Common Query Parameters

Most list endpoints support:

ParameterDescription
searchFilters by resource name
fieldsComma-separated fields to include
sortSort value: id, -id, name, -name, population, -population
limitPage size, from 1 to 1000
offsetNumber of records to skip
minPopulationMinimum population
maxPopulationMaximum population

Resource-specific filters are documented on each resource page.

Response Format

List endpoints return:

json
{
  "data": [],
  "meta": {
    "count": 0,
    "total": 0,
    "limit": 100,
    "offset": 0,
    "datasetVersion": "2025",
    "lastUpdated": "2026-05-10"
  }
}

Single-resource endpoints return:

json
{
  "data": {},
  "meta": {
    "datasetVersion": "2025",
    "lastUpdated": "2026-05-10"
  }
}

Error responses return:

json
{
  "error": {
    "code": "ERROR_CODE",
    "message": "Error message.",
    "status": 400
  }
}