← 返回
未分类 中文

cpbox-news-search

USE FOR news search. Returns news articles with title, URL, description, age, thumbnail. Supports freshness and date range filtering, SafeSearch filter and G...
用于新闻搜索。返回标题、URL、描述、发布时间和缩略图的新闻。支持新鲜度和日期范围筛选、安全搜索过滤以及 G...
sprintmint sprintmint 来源
未分类 clawhub v1.0.0 1 版本 100000 Key: 无需
★ 0
Stars
📥 468
下载
💾 2
安装
1
版本
#latest

概述

News Search

Paid News Search proxy via x402 pay-per-use (HTTP 402).

> Prerequisites: This skill requires x402-payment. Complete the setup steps before first use.

>

> Security: Documentation only — no executable code or credentials. Wallet/keys stay on your machine; never stored here.

Service URLs

RoleDomain
--------------
API Providerhttps://www.cpbox.io
Facilitatorhttps://www.cppay.finance

Endpoint (Agent Interface)

GET  /api/x402/news-search
POST /api/x402/news-search/post

Payment Flow (x402 Protocol)

  1. First request (no PAYMENT-SIGNATURE) -> 402 Payment Required with requirements JSON
  2. Client signs (EIP-712) -> PAYMENT-SIGNATURE
  3. Retry with PAYMENT-SIGNATURE -> Server settles and returns JSON

With @springmint/x402-payment or x402-sdk-go, payment is automatic.

Quick Start (cURL)

Basic Search

curl -s "https://www.cpbox.io/api/x402/news-search?q=space+exploration" \
  -H "Accept: application/json"

Recent News (Past 24 Hours)

curl -s "https://www.cpbox.io/api/x402/news-search" \
  -H "Accept: application/json" \
  -G \
  --data-urlencode "q=cybersecurity" \
  --data-urlencode "country=US" \
  --data-urlencode "freshness=pd" \
  --data-urlencode "count=20"

Date Range Filter

curl -s "https://www.cpbox.io/api/x402/news-search" \
  -H "Accept: application/json" \
  -G \
  --data-urlencode "q=climate summit" \
  --data-urlencode "freshness=2026-01-01to2026-01-31"

Using with x402-payment

npx @springmint/x402-payment \
  --url https://www.cpbox.io/api/x402/news-search \
  --method GET

Parameters

ParameterTypeRequiredDefaultDescription
----------
qstringYes-Search query (1-400 chars, max 50 words)
countrystringNoUSSearch country (2-letter country code or ALL)
search_langstringNoenLanguage preference (2+ char language code)
ui_langstringNoen-USUI language (e.g., "en-US")
countintNo20Number of results (1-50)
offsetintNo0Page offset (0-9)
safesearchstringNostrictAdult content filter (off/moderate/strict)
freshnessstringNo-Time filter (pd/pw/pm/py or date range)
spellcheckboolNotrueAuto-correct query
extra_snippetsboolNo-Up to 5 additional excerpts per result
gogglesstring or arrayNo-Custom ranking filter (URL or inline; repeat param for multiple)
operatorsboolNotrueApply search operators
include_fetch_metadataboolNofalseInclude fetch timestamps in results

Freshness Values

ValueDescription
----
pdPast day (24 hours) - ideal for breaking news
pwPast week (7 days)
pmPast month (31 days)
pyPast year (365 days)
YYYY-MM-DDtoYYYY-MM-DDCustom date range

Response Format

{
  "type": "news",
  "query": {
    "original": "space exploration"
  },
  "results": [
    {
      "type": "news_result",
      "title": "New Developments in Space Exploration",
      "url": "https://news.example.com/space-exploration",
      "description": "Recent missions have advanced our understanding of...",
      "age": "2 hours ago",
      "page_age": "2026-01-15T14:30:00",
      "page_fetched": "2026-01-15T15:00:00Z",
      "meta_url": {
        "scheme": "https",
        "netloc": "news.example.com",
        "hostname": "news.example.com",
        "favicon": "https://imgs.search.provider/favicon/news.example.com",
        "path": "/space-exploration"
      },
      "thumbnail": {
        "src": "https://imgs.search.provider/..."
      }
    }
  ]
}

Response Fields

FieldTypeDescription
------
typestringAlways "news"
query.originalstringThe original search query
query.alteredstring?Spellcheck-corrected query (if changed)
query.cleanedstring?Cleaned/normalized query from spellchecker
query.spellcheck_offbool?Whether spellcheck was disabled
query.show_strict_warningbool?True if strict safesearch blocked results
query.search_operatorsobject?Applied search operators
query.search_operators.appliedboolWhether operators were applied
query.search_operators.cleaned_querystring?Query after operator processing
query.search_operators.siteslist[str]?Domains from site: operators
results[].typestringAlways "news_result"
results[].titlestringArticle title
results[].urlstringSource URL of the article
results[].descriptionstring?Article description/summary
results[].agestring?Human-readable age (e.g. "2 hours ago")
results[].page_agestring?Publication date from source (ISO datetime)
results[].page_fetchedstring?When page was last fetched (ISO datetime)
results[].fetched_content_timestampint?Fetch timestamp (only with include_fetch_metadata=true)
results[].meta_url.schemestring?URL protocol scheme
results[].meta_url.netlocstring?Network location
results[].meta_url.hostnamestring?Lowercased domain name
results[].meta_url.faviconstring?Favicon URL
results[].meta_url.pathstring?URL path
results[].thumbnail.srcstringServed thumbnail URL
results[].thumbnail.originalstring?Original thumbnail URL
results[].extra_snippetslist[str]?Up to 5 additional excerpts per result

Goggles (Custom Ranking)

Goggles let you re-rank news results — boost trusted outlets or suppress unwanted sources.

MethodExample
----
Hosted--data-urlencode "goggles=https://"
Inline--data-urlencode 'goggles=$discard\n$site=example.com'

> Hosted goggles should be hosted on a public URL and include ! name:, ! description:, ! author: headers. Inline rules need no registration.

Syntax: $boost=N / $downrank=N (1–10), $discard, $site=example.com. Combine with commas: $site=example.com,boost=3. Separate rules with \n (%0A).

Allow list: $discard\n$site=docs.python.org\n$site=developer.mozilla.orgBlock list: $discard,site=pinterest.com\n$discard,site=quora.com

Resources: See your upstream provider's Goggles documentation.

Search Operators

Use search operators to refine results:

  • site:local-paper.com - Limit to specific news site
  • "exact phrase" - Match exact phrase
  • -exclude - Exclude term

Set operators=false to disable operator parsing.

Use Cases

  • Breaking news monitoring: Use freshness=pd for the most recent articles on a topic.
  • Custom news feeds with Goggles: Boost trusted sources and discard other sources.
  • Historical news research: Use freshness=YYYY-MM-DDtoYYYY-MM-DD to find articles from specific time periods.
  • Multilingual news: Combine country, search_lang, and ui_lang for cross-locale results.
  • Data pipelines: Set include_fetch_metadata=true for fetched_content_timestamp on each result.

Notes

  • SafeSearch: Defaults to strict
  • Pagination: Use offset (0-9) with count
  • Extra snippets: Up to 5 additional excerpts when extra_snippets=true

版本历史

共 1 个版本

  • v1.0.0 当前
    2026-03-31 03:38 安全 安全

安全检测

腾讯云安全 (Keen)

安全,无风险
查看报告

腾讯云安全 (Sanbu)

安全,无风险
查看报告

🔗 相关推荐

knowledge-management

Obsidian

steipete
操作 Obsidian 仓库(纯 Markdown 笔记)并通过 obsidian-cli 自动化。
★ 451 📥 106,005
dev-programming

cpbox-batch-balance

sprintmint
当用户询问批量余额查询或多调用(multicall)余额等问题时,指导其使用批量EVM地址余额查询API(/api/x402/batch-balance)。
★ 2 📥 691
knowledge-management

Summarize

paudyyin
智能摘要工具,自动为长文本、文档、网页生成摘要,提取要点与关键词,支持自定义摘要长度。
★ 968 📥 523,319