# Baidu News Search

Returns the articles Baidu News shows for a query: title, article URL, snippet, publisher, publisher icon, thumbnail and Baidu's display time. Page with page (1 to 10, 10 articles per page). Narrow by age with period: hour, day, week, month or year. date is Baidu's own text, for example 3天前 or 9月1日, and is never turned into a guessed timestamp. A request that returns no articles or fails is not billed.

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

## 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 query in any language. Chinese queries return the most results. |
| `page` | integer | No | Page number from 1 to 10, 10 articles per page. Default: 1. |
| `period` | string | No | Only articles up to this age: hour, day, week, month or year. |

## Example response

```json
{
    "pagination": {
        "page": 1,
        "next_page": 2,
        "results_on_page": 10
    },
    "news_results": [
        {
            "url": "https://baijiahao.baidu.com/s?id=1880139673342805861&wfr=spider&for=pc",
            "date": "3\u5929\u524d",
            "title": "\u4e3a\u4eba\u5de5\u667a\u80fd\u6cbb\u7406\u951a\u5b9a\u65f6\u4ee3\u822a\u5411",
            "source": "\u5149\u660e\u7f51",
            "snippet": "\u57282026\u4e16\u754c\u4eba\u5de5\u667a\u80fd\u5927\u4f1a\u4e0a\uff0c\u4e60\u8fd1\u5e73\u603b\u4e66\u8bb0\u90d1\u91cd\u5ba3\u5e03\u2026\u2026",
            "position": 1,
            "thumbnail": null,
            "source_icon": "https://pic.rmb.bdstatic.com/388317709b6c55c898306a6925fc8279.jpeg"
        }
    ],
    "response_time_ms": 4200,
    "search_parameters": {
        "page": 1,
        "query": "\u4eba\u5de5\u667a\u80fd",
        "engine": "baidu_news",
        "period": "week"
    }
}
```

## Errors

| Status | Error | Description |
| --- | --- | --- |
| 422 | Invalid parameter | query is missing, page is outside 1 to 10 or period is not one of the listed values. Not billed. |
| 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)
