# Latest News API (Open Government)

> Latest News API (Open Government) is a paid API for AI agents from latest-news-api.latest-news.workers.dev, paid per call via x402, $0.01/call, status unknown (last checked 2026-09-14).

Returns structured, AI-agent-ready headlines from open U.S. government sources across categories like space, climate, technology, exploration, station, and government.

## Facts

- Endpoint: GET https://latest-news-api.latest-news.workers.dev/v1/news
- Price: $0.01/call
- Payment: x402
- Status: unknown
- Last checked: 2026-09-14
- Activations on Zero: 0
- Tags: x402
- Canonical page: https://www.zero.xyz/c/latest-news-api-open-government-6a1403c8
- Structured record (JSON): https://api.zero.xyz/v1/capabilities/cap_W9NX0S62onV8JFeSHOwWh

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 latest-news-api-open-government-6a1403c8
```

Example prompt: Pull the latest open-government news headlines across space, climate, and technology — I need structured summaries with source links I can trust.

## When to prefer this

Choose this endpoint when you need structured, AI-agent-ready news from open U.S. government sources (NASA, federal agencies) with proper attribution and license metadata. It is ideal for pipelines that require legally clear public-domain content with source_url attribution. Prefer it over general news APIs when the domain must be restricted to official government or public-sector sources across space, climate, technology, exploration, station, or government categories.

## Known failure modes

- Payment not completed (x402 payment required — HTTP 402 returned if USDC micropayment not sent)
- Invalid or missing category parameter returns all categories by default
- Network/edge timeout from Cloudflare Workers may return 5xx
- Empty article list if no new articles have been fetched for a category
- Truncated summaries if upstream government sources are unavailable

## How this service works

x402-gated open-government news JSON API for AI agents. Categories: space, climate, technology, exploration, station, government.

## Output

A JSON object containing a dataset descriptor (id, name, license, categories, schema version), a flat list of articles, and a by_category map. Each article includes id, title, summary, source name, source URL, category, tags, fetched_at, published_at, attribution, and license note. Also includes a generated_at timestamp, article count, and self/openapi links.

## Request schema (JSON Schema)

```json
{
 "type": "object",
 "properties": {
  "properties": {
   "type": "string"
  }
 }
}
```

## Response schema (JSON Schema)

```json
{
 "type": "json",
 "example": {
  "ok": true,
  "data": {
   "dataset": {
    "id": "open-gov-news",
    "name": "Open Government News",
    "license": "U.S. federal / open-government sources with source_url attribution",
    "categories": [
     "space",
     "climate",
     "technology",
     "exploration",
     "station",
     "government"
    ],
    "description": "Structured headlines for AI agents from open/public-sector sources.",
    "schema_version": "2.0.0"
   },
   "articles": [
    {
     "id": "news_space_example",
     "url": "https://www.nasa.gov/",
     "tags": [
      "space",
      "nasa",
      "science"
     ],
     "title": "NASA mission update",
     "source": "NASA",
     "summary": "In space: agent note covering a NASA mission update. Read the original NASA article via source_url for full details.",
     "category": "space",
     "fetched_at": "2026-08-01T12:05:00.000Z",
     "source_url": "https://www.nasa.gov/",
     "attribution": "Source: NASA. Summary rewritten for AI agents; always open source_url for the original document.",
     "source_name": "NASA",
     "license_note": "U.S. federal government work (NASA). Generally public domain in the U.S.; credit NASA and link source_url.",
     "published_at": "2026-08-01T12:00:00.000Z"
    }
   ],
   "categories": [
    "space",
    "climate",
    "technology",
    "exploration",
    "station",
    "government"
   ],
   "by_category": {
    "space": [
     {
      "id": "news_space_example",
      "url": "https://www.nasa.gov/",
      "tags": [
       "space",
       "nasa",
       "science"
      ],
      "title": "NASA mission update",
      "source": "NASA",
      "summary": "In space: agent note covering a NASA mission update. Read the original NASA article via source_url for full details.",
      "category": "space",
      "fetched_at": "2026-08-01T12:05:00.000Z",
      "source_url": "https://www.nasa.gov/",
      "attribution": "Source: NASA. Summary rewritten for AI agents; always open source_url for the original document.",
      "source_name": "NASA",
      "license_note": "U.S. federal government work (NASA). Generally public domain in the U.S.; credit NASA and link source_url.",
      "published_at": "2026-08-01T12:00:00.000Z"
     }
    ]
   },
   "generated_at": "2026-08-01T12:05:00.000Z",
   "article_count": 1
  },
  "links": {
   "self": "https://latest-news-api.latest-news.workers.dev/v1/news",
   "openapi": "https://latest-news-api.latest-news.workers.dev/openapi.js
… (truncated)
```

## More

- Live health (JSON, refreshed every minute): https://www.zero.xyz/c/latest-news-api-open-government-6a1403c8/health.json
- [Zero catalog index](https://www.zero.xyz/llms.txt)
- [Other services from latest-news-api.latest-news.workers.dev](https://www.zero.xyz/host/latest-news-api.latest-news.workers.dev/llms.txt)
