Get City By ID API
Overview
Retrieves details of a specific City master record by its integer ID.
- Endpoint:
/api/cities/get-by-id - Method:
POSTorGET - Auth Required: Public / Optional
Request Schema (POST Body or GET Query)
| Field / Parameter | Type | Required | Description |
|---|---|---|---|
id | Number (Integer) | Yes | Integer ID of the target City |
Request Body Example (POST)
{
"id": 1
}
Response Example (200 OK)
{
"success": true,
"data": {
"id": 1,
"name": "Mumbai",
"stateId": 21,
"countryId": 101,
"active": true
},
"message": "City fetched successfully"
}