# Centaline Autocomplete API

<p>Find districts, estates, buildings, MTR stations, schools, universities, developers, shopping malls and car parks by name in English or Chinese. Each result has a `location` that the search endpoint takes as its `location` parameter, the listing count, the centre position and the Chinese and English names. Pass `listing_type=rent` to get the rental listing counts. A keyword without a match returns empty groups.</p>

- **Documentation:** [https://scrappa.co/docs/centaline-api/centaline_autocomplete](https://scrappa.co/docs/centaline-api/centaline_autocomplete)
- **API group:** Centaline Property API
- **Endpoint:** `GET https://scrappa.co/api/centaline/autocomplete`

## Authentication

Send your Scrappa API key in the `X-API-KEY` request header. Paid endpoints also support accountless x402 payments when called without an API key.

## Parameters

| Parameter | Type | Required | Description |
| --- | --- | --- | --- |
| `keyword` | string | Yes | Place, estate, building, MTR station, school or developer name in English or Chinese. |
| `listing_type` | string | No | `sale` (default) or `rent`. Changes the listing counts. |
| `size` | integer | No | Results per group, 1 to 20. Default 5. |
| `lang` | string | No | `en` (default) for English names, `hk` for Traditional Chinese. |

## Example response

```json
{
    "data": {
        "keyword": "taikoo",
        "results": {
            "districts": [
                {
                    "code": "19-HMA034",
                    "name": "Taikoo Shing",
                    "center": {
                        "lat": 22.287405,
                        "lng": 114.217804
                    },
                    "name_en": "Taikoo Shing",
                    "name_zh": "\u592a\u53e4\u57ce",
                    "location": "eyJ0eXBlQ29kZXMiOlsiMTktSE1BMDM0Il19",
                    "listing_count": 371
                }
            ],
            "mtr_stations": [
                {
                    "code": "58",
                    "name": "Tai Koo",
                    "name_en": "Tai Koo",
                    "name_zh": "\u592a\u53e4",
                    "location": "eyJtdHJzIjpbIjU4Il0sIm10clN0YXRpb25zIjpbeyJyb3V0ZU5vIjoiMSIsInN0YXRpb25ObyI6IjU4In1dfQ",
                    "listing_count": 597
                }
            ]
        },
        "listing_type": "sale"
    },
    "meta": {
        "billable": true,
        "endpoint_family": "autocomplete"
    },
    "success": true
}
```

## Errors

| Status | Error | Description |
| --- | --- | --- |
|  | The property or agent does not exist or is no longer online. This response is not billable. |  |
|  | A parameter is missing or invalid, or the page reaches past the first 10000 results. This response is not billable. |  |
|  | Centaline is temporarily unavailable, or its answer did not match the request. Retry the request. This response is not billable. |  |

## More Scrappa resources

- [API documentation](https://scrappa.co/docs)
- [Full LLM-readable API reference](https://scrappa.co/llms-full.txt)
- [OpenAPI specification](https://scrappa.co/docs/api.json)
- [Pricing](https://scrappa.co/pricing)
