# Point2 Homes Autocomplete API Documentation

<p><strong>Point2 Homes Autocomplete API</strong> turns the start of a city name into the <code>country</code>, <code>state</code> and <code>city</code> values the rental search needs. Each result has an <code>id</code>, the city <code>name</code>, a <code>label</code> such as "Vancouver, BC", and a ready <code>search</code> object you can pass to the search endpoint.</p><p>Type at least 3 characters. Results only include cities in the requested country.</p>

- **Documentation:** [https://scrappa.co/docs/point2homes-api/point2homes_autocomplete](https://scrappa.co/docs/point2homes-api/point2homes_autocomplete)
- **API group:** Point2 Homes API
- **Endpoint:** `GET https://scrappa.co/api/point2homes/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 | Start of a city name, 3 to 100 characters. Example: vancou. |
| `country` | string | Yes | CA for Canada or US for the United States. |
| `limit` | integer | No | Number of results, 1 to 25, default 10. |

## Example response

```json
{
    "data": {
        "results": [
            {
                "id": "960103",
                "city": "Vancouver",
                "name": "Vancouver",
                "label": "Vancouver, BC",
                "state": "BC",
                "search": {
                    "city": "Vancouver",
                    "state": "BC",
                    "country": "CA"
                },
                "country": "CA",
                "search_path": "/api/point2homes/search?country=CA&state=BC&city=Vancouver"
            },
            {
                "id": "960134",
                "city": "North Vancouver",
                "name": "North Vancouver",
                "label": "North Vancouver, BC",
                "state": "BC",
                "search": {
                    "city": "North Vancouver",
                    "state": "BC",
                    "country": "CA"
                },
                "country": "CA",
                "search_path": "/api/point2homes/search?country=CA&state=BC&city=North+Vancouver"
            },
            {
                "id": "960104",
                "city": "West Vancouver",
                "name": "West Vancouver",
                "label": "West Vancouver, BC",
                "state": "BC",
                "search": {
                    "city": "West Vancouver",
                    "state": "BC",
                    "country": "CA"
                },
                "country": "CA",
                "search_path": "/api/point2homes/search?country=CA&state=BC&city=West+Vancouver"
            }
        ]
    },
    "meta": {
        "billable": true,
        "endpoint_family": "autocomplete"
    },
    "success": true
}
```

## Errors

| Status | Error | Description |
| --- | --- | --- |
| 422 | Validation Error | A parameter is missing or outside its allowed values. This response is not billable. |
| 503 | Upstream Unavailable | Point2 Homes could not be reached, or returned a page that does not match the expected shape. Retry shortly. 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)
