# Dot Property Autocomplete API Documentation

<p><strong>Dot Property Autocomplete API</strong> returns matching provinces, districts, sub-districts, stations, neighbourhoods and projects as JSON. Each match carries a <code>location</code> slug to use as the Search location, or a <code>project_id</code> to use as the Search project filter. A text without matches returns empty lists and is a successful response.</p>

- **Documentation:** [https://scrappa.co/docs/dotproperty-api/dotproperty_autocomplete](https://scrappa.co/docs/dotproperty-api/dotproperty_autocomplete)
- **API group:** Dot Property API
- **Endpoint:** `GET https://scrappa.co/api/dotproperty/v1/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 |
| --- | --- | --- | --- |
| `query` | string | Yes | Search text, 2 to 60 characters. Example: sukhumvit. |
| `listing_category` | string | No | Category of the listing, for example condos-for-sale (default) or houses-for-rent. Example: condos-for-sale. |

## Example response

```json
{
    "data": {
        "query": "sukh",
        "projects": [],
        "locations": [
            {
                "name": "Sukhothai",
                "type": "Province",
                "address": null,
                "location": "sukhothai",
                "sub_name": null,
                "project_id": null,
                "project_slug": null
            },
            {
                "name": "Sukhirin, Narathiwat",
                "type": "District",
                "address": null,
                "location": "narathiwat/sukhirin",
                "sub_name": null,
                "project_id": null,
                "project_slug": null
            }
        ],
        "suggestions": [],
        "points_of_interest": [
            {
                "name": "MRT Sukhumvit",
                "type": "MRT Station",
                "address": null,
                "location": "mrt/sukhumvit",
                "sub_name": null,
                "project_id": null,
                "project_slug": null
            },
            {
                "name": "Sukhumvit",
                "type": "Neighborhood",
                "address": null,
                "location": "sukhumvit",
                "sub_name": null,
                "project_id": null,
                "project_slug": null
            }
        ]
    },
    "meta": {
        "billable": true,
        "endpoint_family": "autocomplete"
    },
    "success": true
}
```

## Errors

| Status | Error | Description |
| --- | --- | --- |
| 422 | Validation Error | The query is missing or too short. This response is not billable. |
| 503 | Upstream Unavailable | Dot Property could not be reached or returned data that does not match the request. This response is not billable and is retryable. |

## 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)
