# Nehnutelnosti Autocomplete API Documentation

<p><strong>Nehnutelnosti Autocomplete API</strong> turns text into Slovak regions, districts, cities and streets on Nehnutelnosti.sk. Each result has an <code>id</code>, a <code>name</code>, a <code>slug</code>, a <code>type</code> and the parent places. Send the <code>slug</code> as the <code>location</code> of the search route. An empty list is a valid answer and is billed.</p>

- **Documentation:** [https://scrappa.co/docs/nehnutelnosti-api/nehnutelnosti_autocomplete](https://scrappa.co/docs/nehnutelnosti-api/nehnutelnosti_autocomplete)
- **API group:** Nehnutelnosti API
- **Endpoint:** `GET https://scrappa.co/api/nehnutelnosti/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 100 characters. Diacritics work, for example žilina. |
| `limit` | integer | No | Number of suggestions, 1 to 20. Default 10. |

## Example response

```json
{
    "data": {
        "query": "\u017eilina",
        "results": [
            {
                "id": "100011403",
                "name": "\u017dilina",
                "slug": "zilina",
                "type": "CITY",
                "parents": [
                    "okres \u017dilina",
                    "\u017dilinsk\u00fd kraj",
                    "Slovensko"
                ]
            },
            {
                "id": "100001042",
                "name": "okres \u017dilina",
                "slug": "zilina",
                "type": "DISTRICT",
                "parents": [
                    "\u017dilinsk\u00fd kraj",
                    "Slovensko"
                ]
            }
        ]
    },
    "meta": {
        "billable": true,
        "endpoint_family": "autocomplete"
    },
    "success": true
}
```

## Errors

| Status | Error | Description |
| --- | --- | --- |
| 422 | Validation Error | A required parameter or a value is invalid. This response is not billable. |
| 503 | Upstream Unavailable | Nehnutelnosti.sk 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)
