Search the web via Baidu AI Search API.
This skill requires a BAIDU_API_KEY to be configured in OpenClaw.
If you don't have an API key yet, please visit: https://console.bce.baidu.com/ai-search/qianfan/ais/console/apiKey
For detailed setup instructions, see: references/apikey-fetch.md
python3 skills/baidu-search/scripts/search.py '<JSON>'小葱技能站7w4.net发现了升级插件。
| Param | Type | Required | Default | Description |
|---|---|---|---|---|
| query | str | yes | - | Search query |
| count | int | no | 10 | Number of results to return, range 1-50 |
| freshness | str | no | Null | Time range, two formats: format one is ”YYYY-MM-DDtoYYYY-MM-DD“, and format two includes pd, pw, pm, and py, representing the past 24 hours, past 7 days, past 31 days, and past 365 days respectively |
# Basic search
python3 scripts/search.py '{"query":"人工智能"}'
# Freshness first format "YYYY-MM-DDtoYYYY-MM-DD" example
python3 scripts/search.py '{
"query":"最新新闻",
"freshness":"2025-09-01to2025-09-08"
}'
# Freshness second format pd、pw、pm、py example
python3 scripts/search.py '{
"query":"最新新闻",
"freshness":"pd"
}'
# set count, the number of results to return
python3 scripts/search.py '{
"query":"旅游景点",
"count": 20,
}'
Fully functional.
这个搜索工具质量不错,使用百度搜索接口,返回结果快速准确。文档说明详细,配置过程简单明了,新手也能快速上手。美中不足的是功能比较单一,目前只能搜索网页内容,不支持新闻、图片等其他类型的搜索。如果只需要基础的网页搜索功能,这是一个值得推荐的好工具。