# momo Search API Documentation

<p><strong>momo Search API</strong> searches products on momo in Taiwan. Each item has the sale price, original price and discount as TWD numbers, the brand, seller, stock, availability and a full-size image url.</p><p>Filter by category code, sort, price range and brand. Category, brand and price are applied to the returned page, so pagination counts and has_next describe the unfiltered set; pagination.filtered_out reports how many items were dropped. Every returned item follows the filters you send. There are 20 results per page and page N returns the real page N. The sort price_asc orders the returned page by price. Rows without a price or title are omitted. Rows with a third-party id are omitted too, because those ids have no public product page. Every id in search works unchanged in the product endpoint.</p><p>Search carries no rating or review count. Read the aggregate rating of one product from the reviews route. The goodsCode feeds the product and reviews routes unchanged. Costs 1 credit per successful request. Empty results and failed requests are free.</p>

- **Documentation:** [https://scrappa.co/docs/momo-api/momo_search](https://scrappa.co/docs/momo-api/momo_search)
- **API group:** momo API
- **Endpoint:** `GET https://scrappa.co/api/momo/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 | Search text, 1 to 120 characters, for example iphone. |
| `page` | integer | No | One-based page number, 20 results per page (default 1). |
| `category` | string | No | Category code from the facets in a search answer. Applied to the returned items. |
| `sort` | string | No | One of relevance or price_asc. price_asc sorts the returned page by price. |
| `min_price` | number | No | Lowest price in TWD. |
| `max_price` | number | No | Highest price in TWD. |
| `brand` | string | No | Brand text to match. A missing brand is filled from the facet label and title when they match. |

## Example response

```json
{
    "data": {
        "query": "iphone",
        "facets": {
            "brands": [],
            "filters": [],
            "categories": []
        },
        "results": [
            {
                "url": "https://www.momoshop.com.tw/goods/GoodsDetail.jsp?i_code=15684486",
                "brand": "Apple",
                "image": "https://img.momoshop.com.tw/abc.jpg",
                "price": 32900,
                "stock": 12,
                "title": "iPhone",
                "seller": "momo",
                "currency": "TWD",
                "product_id": "15684486",
                "availability": "in_stock",
                "original_price": 35900,
                "discount_percent": 8.36
            }
        ],
        "currency": "TWD",
        "pagination": {
            "page": 1,
            "has_next": true,
            "per_page": 20,
            "filtered_out": 0,
            "total_results": 843
        }
    },
    "meta": {
        "credits": 1,
        "billable": true,
        "endpoint_family": "search"
    },
    "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 | The source could not be reached. This response is not billable. Retry shortly. |

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