# ScrapFly Top News API

> ScrapFly Top News API is a paid API for AI agents from scrapfly.vercel.app, paid per call via x402, $0.05/call, status unknown (last checked 2026-10-24).

Fetches the top news articles matching a given query, powered by ScrapFly's web scraping infrastructure

## Facts

- Endpoint: POST https://scrapfly.vercel.app/api/news/top?utm_source=zero.xyz
- Price: $0.05/call
- Payment: x402
- Status: unknown
- Last checked: 2026-10-24
- Activations on Zero: 0
- Tags: x402
- Canonical page: https://www.zero.xyz/c/scrapfly-top-news-api-154e2c92
- Structured record (JSON): https://api.zero.xyz/v1/capabilities/cap_1SBLoZv0hZahRQFQ8rEmF

Status and success rate cover calls made through Zero and Zero's own probes. Third-party monitors may report differently.

## How to call it through Zero

Zero handles the 402 payment challenge and records the run. With the Zero CLI installed (`npm i -g @zeroxyz/cli`):

```sh
zero fetch --capability scrapfly-top-news-api-154e2c92 -d '<json body>'
```

Example prompt: Pull the top news articles about 'AI regulation' using ScrapFly's news endpoint and show me what's trending right now.

## When to prefer this

Use this endpoint when you need real-time or near-real-time top news articles for a specific topic or keyword, especially in an agent context where you want to pay per request without a subscription. Prefer it over general web search endpoints when you specifically want news-formatted content. It is distinct from full-page scrapers because it is purpose-built to surface top news results for a query.

## Known failure modes

- Empty or vague query returns no results or low-quality matches
- Query string too long or malformed returns a validation error
- Scraping target temporarily blocked leads to empty or partial results
- Network timeout if upstream news sources are slow to respond
- Payment not processed (x402 flow fails) results in 402 error before scraping begins

## How this service works

69 endpoints for data, content generation, and web scraping. Pay per request via x402 on Base chain.

## Output

Returns a success flag and a data object containing top news articles matching the submitted query — likely including headlines, article metadata, and source information scraped from news sources via ScrapFly's infrastructure.

## Request schema (JSON Schema)

```json
{
 "type": "object",
 "required": [
  "query"
 ],
 "properties": {
  "query": {
   "type": "string",
   "description": "Input query"
  }
 }
}
```

## Response schema (JSON Schema)

```json
{
 "type": "object",
 "required": [
  "success"
 ],
 "properties": {
  "data": {
   "type": "object"
  },
  "success": {
   "type": "boolean"
  }
 }
}
```

## More

- Live health (JSON, refreshed every minute): https://www.zero.xyz/c/scrapfly-top-news-api-154e2c92/health.json
- [Zero catalog index](https://www.zero.xyz/llms.txt)
- [Other services from scrapfly.vercel.app](https://www.zero.xyz/host/scrapfly.vercel.app/llms.txt)
