# Gelbe Seiten Business Search API Documentation

Search public Gelbe Seiten businesses by term and place (city or postal code), 10 per page: id, name, category, rating, review count, address, phone, website, open status, distance and coordinates. Sort by relevance or distance and set a radius in meters. Costs 1 credit. Failed requests are free.

- **Documentation:** [https://scrappa.co/docs/gelbeseiten-api/gelbeseiten_search](https://scrappa.co/docs/gelbeseiten-api/gelbeseiten_search)
- **API group:** Gelbe Seiten API
- **Endpoint:** `GET https://scrappa.co/api/gelbeseiten/search`

## 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 | What to look for, 2 to 100 characters. Example: Friseur. |
| `location` | string | Yes | City or postal code, 2 to 100 characters. Example: Berlin or 10115. |
| `page` | integer | No | Page number, starting at 1. Each page holds up to 10 businesses. A page past the end returns an empty list and the real total. |
| `radius` | integer | No | Only businesses within this many meters of the location, 500 to 100000. Omit for the whole place. |
| `sort` | string | No | relevance or distance. Defaults to relevance. |

## Example request

```bash
#!/bin/bash

curl -X GET \
    -H "x-api-key: YOUR_API_KEY_HERE" \
    "https://scrappa.co/api/gelbeseiten/search?query=Friseur&location=Berlin"
```

## Example response

```json
{
    "success": true,
    "data": {
        "query": "Friseur",
        "location": "Berlin",
        "sort": "relevance",
        "radius_m": null,
        "page": 1,
        "per_page": 10,
        "total": 185,
        "has_more": true,
        "next_page": 2,
        "results": [
            {
                "id": "9ae83a87-cd19-433c-b348-cb26fc3b9887",
                "name": "Domino's Pizza Berlin Mitte",
                "url": "https://www.gelbeseiten.de/gsbiz/9ae83a87-cd19-433c-b348-cb26fc3b9887",
                "category": "Gastst\u00e4tten: Pizzerias",
                "rating": 3,
                "review_count": 1,
                "address": {
                    "street": "Schumannstra\u00dfe 19",
                    "postal_code": "10117",
                    "city": "Berlin",
                    "formatted": "Schumannstra\u00dfe 19, 10117 Berlin"
                },
                "distance_m": 839,
                "phone": "030 27 57 24 10",
                "website": "https://www.dominos.de",
                "open_status": "Ge\u00f6ffnet \u2013 Schlie\u00dft um 23:00",
                "coordinates": {
                    "lat": 52.523823,
                    "lon": 13.379811
                }
            }
        ]
    },
    "meta": {
        "endpoint_family": "business_search",
        "billable": true
    }
}
```

## Errors

| Status | Error | Description |
| --- | --- | --- |
| 422 | Validation Error | A required parameter is missing or invalid. This response is not billable. |
| 502 | Upstream Unavailable | Gelbe Seiten did not answer with usable data. This response is not billable. Retry later. |

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