# LandWatch Agent Autocomplete API Documentation

<p><strong>LandWatch Agent Autocomplete API</strong> finds the cities and counties that the LandWatch agent search offers. Each suggestion has the <code>state</code> with the <code>county</code> or <code>city</code> to send to the agents route. An unknown query returns an empty list.</p>

- **Documentation:** [https://scrappa.co/docs/landwatch-api/landwatch_agent_autocomplete](https://scrappa.co/docs/landwatch-api/landwatch_agent_autocomplete)
- **API group:** LandWatch API
- **Endpoint:** `GET https://scrappa.co/api/landwatch/agent-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 |
| --- | --- | --- | --- |
| `q` | string | Yes | Place name, 2 to 100 characters. Example: aust. |

## Example response

```json
{
    "data": {
        "items": [
            {
                "id": 6247,
                "kind": "county",
                "label": "Austin County, TX",
                "state": "TX",
                "county": "Austin County"
            },
            {
                "id": 1235,
                "city": "Austin",
                "kind": "city",
                "label": "Austin, TX",
                "state": "TX"
            },
            {
                "id": 1240,
                "city": "Austin",
                "kind": "city",
                "label": "Austin, AR",
                "state": "AR"
            }
        ],
        "query": "aust"
    },
    "meta": {
        "billable": true,
        "endpoint_family": "agent-autocomplete"
    },
    "success": true
}
```

## Errors

| Status | Error | Description |
| --- | --- | --- |
| 422 | Validation Error | A parameter is missing or invalid. This response is not billable. |
| 503 | Upstream Unavailable | LandWatch could not be reached, or it answered with 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)
