Thai Subdistricts
List of subdistricts (tambons) in Thailand, filterable by district code and/or keyword.
API Endpoint
URL |
{base url}/api/References/GetThaiSubDistrict |
Method |
GET |
Authorization |
Bearer Token |
Content-Type |
application/json |
Request Headers
Parameter |
Type |
Required |
Description |
APIKEY |
string |
true |
System key code |
Request Parameters
Parameter |
Type |
Required |
Description |
district_code |
string |
false |
District code to filter subdistricts
District data
|
filter |
string |
false |
Keyword to search by Id, Code, NameTH, NameEN, or PostalCode |
Request Example
{base url}/api/References/GetThaiSubDistrict?filter={}&district_code={}
Response Parameters
Parameter |
Type |
Description |
Id |
integer |
Error status (e.g. 0 = No error) |
Success |
boolean |
Request success status |
Message |
string |
Response message |
RequestId |
string |
Request reference ID |
Size |
integer |
Number of records returned |
Data |
array |
List of subdistrict data |
Data
Parameter |
Type |
Description |
Id |
string |
Subdistrict ID (GUID) |
Code |
string |
Subdistrict code |
NameTH |
string |
Subdistrict name in Thai |
NameEN |
string |
Subdistrict name in English |
DistrictCode |
string |
Associated district code |
PostalCode |
string |
Postal code |
Response JSON Example
{
"Id": 0,
"Success": true,
"Message": "SUCCESS",
"RequestId": "DC6970C7-3635-4791-BAC0-95C9A499919B",
"Size": 3,
"Data": [
{
"Id": "796CA9A4-139D-44CF-A43E-496F399EA6B9",
"Code": "130301",
"NameTH": "ประชาธิปัตย์",
"NameEN": "Prachathipat",
"DistrictCode": "1303",
"PostalCode": "12130"
},
{
"Id": "69C5939E-43F0-4800-8C83-D905E25691B8",
"Code": "130302",
"NameTH": "บึงยี่โถ",
"NameEN": "Bueng Yitho",
"DistrictCode": "1303",
"PostalCode": "12130"
},
{
"Id": "7849B292-7DA5-4550-84B9-F255B1399849",
"Code": "130601",
"NameTH": "คูคต",
"NameEN": "Khu Khot",
"DistrictCode": "1306",
"PostalCode": "12130"
}
]
}