# MediaMarkt Product Search API Documentation

`GET /api/mediamarkt/search` returns products of MediaMarkt Deutschland or Saturn Deutschland as structured JSON. A page holds up to 12 products.

## What you get

Each item has `id`, `title`, `brand`, `price`, `original_price`, `discount_percent`, `currency`, `rating`, `review_count`, `online_available`, `delivery_status`, `delivery_window`, `in_store_pickup`, `image`, `badges` and `marketplace`. Use `id` unchanged with the product and reviews endpoints.

## Prices and parameters

Prices are numbers in EUR. `original_price` is the struck price, `discount_percent` the saving. The verified page recipe supports `query`, `category` and `page` only. `brand`, `price`, `min_price`, `max_price` and any `sort` other than `relevance` need a whole result set. The storefront recipe cannot apply them to one page without mislabelling page two or returning a short page, so they return a structured 422 before any lookup and cost nothing. Use `query` or `category`, not both. No made-up `total` is returned; a page reports only its own items and a `next_page` link.

## Sites and pages

`site` is `mediamarkt-de` (default) or `saturn-de`. Other country sites are not published until they pass the production soak. `sort` is `relevance`, the only applied ordering; `price_asc`, `price_desc` and `rating` return 422. `page` is 1-30. An empty page stays empty; page one is never relabelled.

Single-word queries with umlauts, such as `kopfhörer`, are supported. A query with no products answers HTTP 200 with `items: []`, `meta.billable: false` and `meta.credits_charged: 0`. `meta.unavailable_reason` names what the page lacks: `no_results`, `original_price` or `discount_percent`.

## Credits

A successful request costs **11 credits**. Errors, challenges and `404` answers cost nothing. The response shows the charge in `meta.credits_charged`.

- **Documentation:** [https://scrappa.co/docs/mediamarkt-api/mediamarkt_search](https://scrappa.co/docs/mediamarkt-api/mediamarkt_search)
- **API group:** MediaMarkt API
- **Endpoint:** `GET https://scrappa.co/api/mediamarkt/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 |
| --- | --- | --- | --- |
| `site` | string | No | mediamarkt-de (default) or saturn-de. |
| `query` | string | No | Search words. Use this or category. |
| `category` | string | No | Category path such as fernseher-203. Use this or query. |
| `sort` | string | No | Not available yet: returns 422 `unsupported_filter`. Only `relevance` is applied; `price_asc`, `price_desc` and `rating` are rejected. |
| `price` | number | No | Not available yet: returns 422 `unsupported_filter`. Highest price in euros. Alias for max_price. |
| `min_price` | number | No | Not available yet: returns 422 `unsupported_filter`. Lowest price in euros. |
| `max_price` | number | No | Not available yet: returns 422 `unsupported_filter`. Highest price in euros. Must not be lower than min_price. |
| `brand` | string | No | Not available yet: returns 422 `unsupported_filter`. Exact brand as the storefront shows it. |
| `page` | integer | No | Result page of 12 products, 1-30. |

## Example request

```bash
#!/bin/bash

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

## Example response

```json
{
    "success": true,
    "site": "mediamarkt-de",
    "query": "fernseher",
    "category": null,
    "items": [
        {
            "position": 1,
            "id": "12345678",
            "title": "Example Fernseher 55 Zoll",
            "brand": "ExampleBrand",
            "price": 499,
            "original_price": 699,
            "discount_percent": 29,
            "currency": "EUR",
            "rating": 4.5,
            "review_count": 120,
            "online_available": true,
            "delivery_status": "Lieferbar",
            "delivery_window": "2026-11-18",
            "in_store_pickup": true,
            "image": "https://assets.mmsrg.com/image.jpg",
            "badges": [],
            "marketplace": false
        }
    ],
    "page": 1,
    "page_size": 12,
    "next_page": 2,
    "has_more": true,
    "sort": "relevance",
    "applied_filters": {
        "query": "fernseher"
    },
    "facets": [],
    "meta": {
        "endpoint_family": "mediamarkt-search",
        "billable": true,
        "attempts": 1,
        "credits_charged": 11,
        "unavailable_reason": []
    }
}
```

## Errors

| Status | Error | Description |
| --- | --- | --- |
| 422 | Parameter Needs a Whole Result Set | `brand`, `price`, `min_price`, `max_price` and a `sort` other than `relevance` have no verified page recipe (`unsupported_filter`). They are rejected before any lookup, so a page is never mislabelled. 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 storefront 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)
