# NoBroker Location Autocomplete API Documentation

<p><strong>NoBroker Location Autocomplete API</strong> Find places in one city by a search text of 3 or more characters. Each result has a place_id, a name, a type (locality, building or place) and an area text. Send the place_id of a locality as the place_id parameter of the search endpoint. A building (needs_coordinates=true) has no area of its own: search around it with lat and lon instead. NoBroker gives no coordinates in autocomplete.</p>

- **Documentation:** [https://scrappa.co/docs/nobroker-api/nobroker_autocomplete](https://scrappa.co/docs/nobroker-api/nobroker_autocomplete)
- **API group:** NoBroker API
- **Endpoint:** `GET https://scrappa.co/api/nobroker/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, 3 to 100 characters, e.g. koramangala. |
| `city` | string | Yes | One of bangalore, mumbai, pune, chennai, gurgaon, hyderabad, delhi, noida, greater_noida, ghaziabad, faridabad. Bengaluru, Gurugram and New Delhi also work. |
| `service` | string | No | rent or buy (default rent). The same places are found for both. |
| `limit` | integer | No | Rows to return, 1 to 20 (default 10). |

## Example response

```json
{
    "data": {
        "city": "bangalore",
        "query": "koramangala",
        "results": [
            {
                "area": "Bangalore, Karnataka, IN",
                "name": "Koramangala",
                "type": "locality",
                "place_id": "ChIJLfyY2E4UrjsRVq4AjI7zgRY",
                "description": "Koramangala, Bengaluru, Karnataka, India",
                "needs_coordinates": false
            },
            {
                "area": "Koramangala, Bengaluru, Karnataka 560095",
                "name": "Koramangala Comforts",
                "type": "building",
                "place_id": "63aac691f372ac00019d9179_NBB",
                "description": "Koramangala Comforts Koramangala, Bengaluru, Karnataka 560095",
                "needs_coordinates": true
            },
            {
                "area": "20th Main Road, 6th Block, Koramangala, Bangalore, Karnataka, IN",
                "name": "Koramangala Police Station",
                "type": "place",
                "place_id": "ChIJ0WI9b0YUrjsRrGwyZxIzk_0",
                "description": "Koramangala Police Station, 20th Main Road, 6th Block, Koramangala, Bengaluru, Karnataka, India",
                "needs_coordinates": false
            }
        ]
    },
    "meta": {
        "billable": true,
        "endpoint_family": "autocomplete"
    },
    "success": true
}
```

## Errors

| Status | Error | Description |
| --- | --- | --- |
| 422 | Validation Error | A required parameter is missing or invalid. This response is not billable. |
| 503 | Temporarily Unavailable | NoBroker did not answer or refused the request after several attempts. This response is not billable. Retry after a short pause. |

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