# Baidu Trending

Returns Baidu ranking boards for real-time topics, novels, movies, television, or cars. The selected board is flattened into consistent trending_searches records while the complete nested board remains in trending and provider_response.

- **Documentation:** [https://scrappa.co/docs/baidu-api/baidu_trending](https://scrappa.co/docs/baidu-api/baidu_trending)
- **API group:** Baidu API
- **Endpoint:** `GET https://scrappa.co/api/baidu/trending`

## 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 |
| --- | --- | --- | --- |
| `tab` | string | No | One of realtime, novel, movie, teleplay, or car. Default: realtime. |

## Example request

```bash
#!/bin/bash

curl -X GET \
    -H "x-api-key: YOUR_API_KEY_HERE" \
    "https://scrappa.co/api/baidu/trending?tab=realtime"
```

## Example response

```json
{
    "search_parameters": {
        "engine": "baidu_trending",
        "tab": "realtime"
    },
    "trending_searches": [
        {
            "position": 1,
            "query": "Example topic",
            "title": "Example topic",
            "link": "https://www.baidu.com/s?wd=Example",
            "is_top": true,
            "hot_label": "\u70ed"
        }
    ],
    "available_tabs": [
        {
            "tab": "realtime",
            "title": "\u5b9e\u65f6"
        },
        {
            "tab": "movie",
            "title": "\u7535\u5f71"
        }
    ],
    "search_information": {
        "tab": "realtime",
        "board_title": "\u5b9e\u65f6\u70ed\u641c",
        "item_count": 1
    },
    "trending": {
        "cards": []
    },
    "provider_response": {
        "success": true,
        "data": []
    },
    "response_time_ms": 500
}
```

## Errors

| Status | Error | Description |
| --- | --- | --- |
| 503 | Upstream unavailable | Baidu could not be reached after safe retries. The request is not billed. |

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