GET /generic/city/{cityId} — İlçe Listesi
📋 Genel Bilgi
Belirli bir ilin tüm ilçelerini listeler. İl ID'si path parametre olarak gönderilir.
Base URL: {{url}}/generic/city/{{city_id}}
Method: GET
Content-Type: application/json
🔐 Headers
| Header | Value |
|---|---|
| Authorization | Bearer {{masked_jwt_9}} |
📥 URL Parametreleri
| Parametre | Tip | Açıklama | Örnek |
|---|---|---|---|
cityId | integer | İl ID'si (path param) | 34 (İstanbul) |
✅ Response — 200 OK
{
"RecordCount": 39,
"Result": [
{
"districtId": 416,
"name": "ADALAR",
"lat": 40.876377,
"lon": 29.095444,
"northeast_lat": 40.914627,
"northeast_lon": 29.148194,
"southwest_lat": 40.837376,
"southwest_lon": 29.039114
},
{
"districtId": 417,
"name": "ARNAVUTKÖY",
"lat": 41.2,
"lon": 28.733333,
"northeast_lat": 41.208395,
"northeast_lon": 28.74934,
"southwest_lat": 41.191604,
"southwest_lon": 28.717326
},
{
"districtId": 418,
"name": "ATAŞEHİR",
"lat": 40.983333,
"lon": 29.116667,
"northeast_lat": 41.009525,
"northeast_lon": 29.21224,
"southwest_lat": 40.959029,
"southwest_lon": 29.072244
},
{
"districtId": 419,
"name": "AVCILAR",
"lat": 41.015348,
"lon": 28.731462,
"northeast_lat": 41.106113,
"northeast_lon": 28.756692,
"southwest_lat": 40.9691,
"southwest_lon": 28.681979
},
{
"districtId": 420,
"name": "BAĞCILAR",
"lat": 41.045556,
"lon": 28.840556,
"northeast_lat": 41.072214,
"northeast_lon": 28.87269,
"southwest_lat": 41.017565,
"southwest_lon": 28.807967
},
{
"districtId": 421,
"name": "BAHÇELİEVLER",
"lat": 40.9975,
"lon": 28.850556,
"northeast_lat": 41.02785,
"northeast_lon": 28.884746,
"southwest_lat": 40.99166,
"southwest_lon": 28.681979
}
]
}
Response Alanları
| Alan | Tip | Açıklama |
|---|---|---|
RecordCount | integer | Toplam ilçe sayısı (İstanbul için: 39) |
Result[] | array | İlçe listesi |
Result[].districtId | integer | İlçe ID'si |
Result[].name | string | İlçe adı (TÜRKÇE, büyük harf) |
Result[].lat | float | Merkez koordinat — latitude |
Result[].lon | float | Merkez koordinat — longitude |
Result[].northeast_lat | float | Kuzeydoğu köşe latitude |
Result[].northeast_lon | float | Kuzeydoğu köşe longitude |
Result[].southwest_lat | float | Güneybatı köşe latitude |
Result[].southwest_lon | float | Güneybatı köşe longitude |
📝 Notlar
- Her il için farklı sayıda ilçe döner (ör: İstanbul → 39, Ankara → 25).
- Koordinat bilgileri ilçe sınırlarını belirlemek için kullanılır.
districtIdile mağaza oluştururken kullanılabilir.