Get District by Keyword [Recommended use this]
GET
https://api-dev.kirimpaket.id/api/open/location/districts-search
Request
Authorization
Provide your bearer token in the
Authorization
header when making requests to protected resources.Example:
Authorization: Bearer ********************
Query Params
keyword
string
optional
Example:
cirebon
Header Params
Accept
string
optional
Example:
application/json
Request samples
Shell
JavaScript
Java
Swift
Go
PHP
Python
HTTP
C
C#
Objective-C
Ruby
OCaml
Dart
R
Request Request Example
Shell
JavaScript
Java
Swift
curl --location --request GET 'https://api-dev.kirimpaket.id/api/open/location/districts-search?keyword=cirebon' \
--header 'Accept: application/json'
Responses
🟢200Success
application/json
Body
current_page
integer
required
data
array [object {5}]
required
text
string
required
id
integer
required
name
string
required
city_id
integer
required
province_id
integer
required
first_page_url
string
required
from
integer
required
last_page
integer
required
last_page_url
string
required
links
array [object {3}]
required
url
string | null
required
label
string
required
active
boolean
required
next_page_url
string
required
path
string
required
per_page
integer
required
prev_page_url
null
required
to
integer
required
total
integer
required
Example
{
"current_page": 1,
"data": [
{
"text": "CAKUNG, KOTA ADM. JAKARTA TIMUR, DKI JAKARTA",
"id": 1966,
"name": "CAKUNG",
"city_id": 157,
"province_id": 11
},
{
"text": "CEMPAKA PUTIH, KOTA ADM. JAKARTA PUSAT, DKI JAKARTA",
"id": 1973,
"name": "CEMPAKA PUTIH",
"city_id": 158,
"province_id": 11
},
{
"text": "CENGKARENG, KOTA ADM. JAKARTA BARAT, DKI JAKARTA",
"id": 1983,
"name": "CENGKARENG",
"city_id": 159,
"province_id": 11
},
{
"text": "CILANDAK, KOTA ADM. JAKARTA SELATAN, DKI JAKARTA",
"id": 1951,
"name": "CILANDAK",
"city_id": 156,
"province_id": 11
},
{
"text": "CILINCING, KOTA ADM. JAKARTA UTARA, DKI JAKARTA",
"id": 1990,
"name": "CILINCING",
"city_id": 160,
"province_id": 11
},
{
"text": "CIPAYUNG, KOTA ADM. JAKARTA TIMUR, DKI JAKARTA",
"id": 1961,
"name": "CIPAYUNG",
"city_id": 157,
"province_id": 11
},
{
"text": "CIRACAS, KOTA ADM. JAKARTA TIMUR, DKI JAKARTA",
"id": 1960,
"name": "CIRACAS",
"city_id": 157,
"province_id": 11
},
{
"text": "DUREN SAWIT, KOTA ADM. JAKARTA TIMUR, DKI JAKARTA",
"id": 1965,
"name": "DUREN SAWIT",
"city_id": 157,
"province_id": 11
},
{
"text": "GAMBIR, KOTA ADM. JAKARTA PUSAT, DKI JAKARTA",
"id": 1976,
"name": "GAMBIR",
"city_id": 158,
"province_id": 11
},
{
"text": "GROGOL PETAMBURAN, KOTA ADM. JAKARTA BARAT, DKI JAKARTA",
"id": 1980,
"name": "GROGOL PETAMBURAN",
"city_id": 159,
"province_id": 11
},
{
"text": "JAGAKARSA, KOTA ADM. JAKARTA SELATAN, DKI JAKARTA",
"id": 1949,
"name": "JAGAKARSA",
"city_id": 156,
"province_id": 11
},
{
"text": "JATINEGARA, KOTA ADM. JAKARTA TIMUR, DKI JAKARTA",
"id": 1964,
"name": "JATINEGARA",
"city_id": 157,
"province_id": 11
},
{
"text": "JOHAR BARU, KOTA ADM. JAKARTA PUSAT, DKI JAKARTA",
"id": 1972,
"name": "JOHAR BARU",
"city_id": 158,
"province_id": 11
},
{
"text": "KALI DERES, KOTA ADM. JAKARTA BARAT, DKI JAKARTA",
"id": 1984,
"name": "KALI DERES",
"city_id": 159,
"province_id": 11
},
{
"text": "KEBAYORAN BARU, KOTA ADM. JAKARTA SELATAN, DKI JAKARTA",
"id": 1954,
"name": "KEBAYORAN BARU",
"city_id": 156,
"province_id": 11
}
],
"first_page_url": "https://api-dev.kirimpaket.id/api/open/location/districts-search?page=1",
"from": 1,
"last_page": 3,
"last_page_url": "https://api-dev.kirimpaket.id/api/open/location/districts-search?page=3",
"links": [
{
"url": null,
"label": "« Previous",
"active": false
},
{
"url": "https://api-dev.kirimpaket.id/api/open/location/districts-search?page=1",
"label": "1",
"active": true
},
{
"url": "https://api-dev.kirimpaket.id/api/open/location/districts-search?page=2",
"label": "2",
"active": false
},
{
"url": "https://api-dev.kirimpaket.id/api/open/location/districts-search?page=3",
"label": "3",
"active": false
},
{
"url": "https://api-dev.kirimpaket.id/api/open/location/districts-search?page=2",
"label": "Next »",
"active": false
}
],
"next_page_url": "https://api-dev.kirimpaket.id/api/open/location/districts-search?page=2",
"path": "https://api-dev.kirimpaket.id/api/open/location/districts-search",
"per_page": 15,
"prev_page_url": null,
"to": 15,
"total": 44
}