# Ceneo Product Search API Documentation

`GET /api/ceneo/ceneo.search` `GET /api/ceneo/search` returns public Ceneo products as structured JSON. Use `query` or `category`. One row is returned per real product id: duplicate cards are merged, energy-label rows and tracking links are dropped, and HTML entities are decoded. `facets` are grouped under the sidebar heading with counts in a separate numeric field; internal keys and groups without counts are removed. Rows with no name or price are dropped. A row without a published image gets a full-size image URL built from its id. In a verified category such as `Smartfony`, rows of another product type are dropped. `price_band` reads only the whole-result band, never item one; when the page publishes none its fields are null and named in `unavailable_fields`. `brand`, `min_price` and `max_price` filter the returned rows: a row that breaks a requested filter is removed. Only page 1 is public; `page` above 1 returns 422 instead of relabelling page one. Positions are contiguous from 1 after filtering. A source page with no product rows is retried once on a fresh session and then returns a clean, non-billable error, never a successful empty result. A query whose rows are all removed by a requested filter stays a non-billable empty result with a `reason`.

## Credits

A successful request costs **10 credits**. Errors, challenges and empty results cost nothing. The response shows the charge in `meta.credits_charged`. Clients are never rate limited.

- **Documentation:** [https://scrappa.co/docs/ceneo-api/ceneo_search](https://scrappa.co/docs/ceneo-api/ceneo_search)
- **API group:** Ceneo API
- **Endpoint:** `GET https://scrappa.co/api/ceneo/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 | telefon |
| `category` | string | Yes | Smartfony |
| `brand` | string | No | ExampleBrand |
| `min_price` | number | No | Lowest price in PLN. |
| `max_price` | number | No | Highest price in PLN. |
| `page` | integer | No | Only page 1 is public. |

## Example request

```bash
#!/bin/bash

curl -X GET \
    -H "x-api-key: YOUR_API_KEY_HERE" \
    "https://scrappa.co/api/ceneo/search?query=telefon"
```

## Example response

```json
{
    "success": true,
    "currency": "PLN",
    "items": [
        {
            "id": 199941331,
            "name": "Example",
            "price": 1234.5,
            "currency": "PLN"
        }
    ],
    "unavailable_fields": [],
    "meta": {
        "endpoint_family": "ceneo-search",
        "billable": true,
        "attempts": 1,
        "credits_charged": 10
    }
}
```

## Errors

| Status | Error | Description |
| --- | --- | --- |
| 404 | Not Found | The public page has no product with that id (`not_found`). Non-billable. |
| 422 | Parameter Not Available Yet | Ceneo page numbers above one return 422 (`unsupported_page`) instead of relabelling page one. Non-billable. |
| 422 | Validation Error | A query parameter is missing, unknown, conflicting or unusable. Unknown parameters are rejected, never ignored. Non-billable. |
| 503 | Upstream Unavailable | The source could not be reached, answered with a challenge, or changed its page shape (`upstream_blocked`, `upstream_unavailable`, `parser_drift`). Retryable and never billed. Clients are never rate limited. |

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