# Hemnet Toplists API

Get one Hemnet editorial toplist: a category, its title and its hits. Omit `categories` and Hemnet picks the toplist it currently features. Categories are Hemnet `ToplistCategory` enum values such as `NEWEST_APARTMENTS`, `NEWEST_VACATION_HOMES`, `LARGEST_HOUSES` and `MOST_EXPENSIVE_APARTMENTS_BY_SQM`; an unrecognised value is rejected by Hemnet as a whole, so send only values from that enum.

- **Documentation:** [https://scrappa.co/docs/hemnet-api/hemnet_toplist](https://scrappa.co/docs/hemnet-api/hemnet_toplist)
- **API group:** Hemnet API
- **Endpoint:** `GET https://scrappa.co/api/hemnet/toplist`

## 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 |
| --- | --- | --- | --- |
| `categories` | string | No | JSON array of `ToplistCategory` values, e.g. ["NEWEST_VACATION_HOMES"] |

## Example request

```bash
#!/bin/bash

curl -X GET \
    -H "x-api-key: YOUR_API_KEY_HERE" \
    "https://scrappa.co/api/hemnet/toplist?categories=%5B%22NEWEST_VACATION_HOMES%22%5D"
```

## Example response

```json
{
    "success": true,
    "data": {
        "toplist": {
            "category": "NEWEST_VACATION_HOMES",
            "title": "Senaste fritidshusen",
            "hits": [
                {
                    "title": "86 m\u00b2"
                }
            ]
        }
    }
}
```

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