APITube Help Center

How to Get the Raw Article Body and HTML

Get article text and HTML with the raw endpoint

Kent Hudson

Written by Kent Hudson

July 5, 2026

Updated October 16, 2026

Open this example in the API Playground ↗

How to get the raw article body and HTML

Use /v1/news/raw to get article text in body and HTML in body_html. Results also include the title, link, author, and source. This endpoint is useful when you need the written content without the full set of article analysis fields.

curl "https://api.apitube.io/v1/news/raw?api_key=YOUR_API_KEY"

Send your key in api_key or X-API-Key. Both GET with URL parameters and POST with a JSON body are supported.

What does /v1/news/raw return?

The response includes status, request_id, results, and paging fields: limit, path, page, has_next_pages, next_page, has_previous_page, and previous_page.

{
  "status": "ok",
  "limit": 100,
  "path": "https://api.apitube.io/v1/news/raw?api_key=YOUR_API_KEY",
  "page": 1,
  "has_next_pages": true,
  "next_page": "https://api.apitube.io/v1/news/raw?api_key=YOUR_API_KEY&page=2",
  "has_previous_page": false,
  "previous_page": "",
  "request_id": "7d1f9a34-6c2e-4b58-a903-1e5c8d2f7b40",
  "results": [
    {
      "id": 1234567,
      "title": "...",
      "href": "https://example.com/some-story",
      "created_at": "2026-06-20T08:00:00",
      "description": "...",
      "body": "Full article text as plain text...",
      "body_html": "<p>Full article text as HTML...</p>",
      "author": "Jane Doe",
      "keywords": ["technology", "ai"],
      "source": {
        "id": 42,
        "domain": "example.com",
        "home_page_url": "https://example.com",
        "type": "news",
        "bias": "center",
        "rankings": { "opr": 4.2 },
        "location": { "country_name": "United States", "country_code": "us" },
        "favicon": "https://www.google.com/s2/favicons?domain=https://example.com"
      }
    }
  ]
}

In each result:

  • body is plain text, with HTML tags removed and whitespace collapsed.
  • body_html keeps HTML formatting in a compact form.
  • created_at is the article’s publication time.
  • keywords lists source-provided category strings, or an empty list if none are available.
  • source includes domain, home_page_url, type, bias, rankings.opr, location, and favicon.

Raw results do not include language, categories, topics, entities, or sentiment.

How to narrow raw results by date

Set published_at.start and published_at.end to an ISO date or timestamp:

curl "https://api.apitube.io/v1/news/raw?published_at.start=2026-06-01&published_at.end=2026-06-20&api_key=YOUR_API_KEY"

Use a single published_at value for one day. See how to filter news by date range.

How to filter raw results by source

Pass up to three numeric IDs in source.id, separated by commas. Use ignore.source.id to exclude sources:

curl "https://api.apitube.io/v1/news/raw?source.id=42,57&api_key=YOUR_API_KEY"

The raw endpoint accepts source IDs rather than domain-name filtering.

How to sort and paginate raw results

Set sort.by to id, published_at, or created_at, and sort.order to asc or desc. The default is id descending.

Use page and per_page to fetch more results. Maximum page sizes are 250 on Professional and Corporate, 200 on Basic, 50 on Starter, and 10 on Free. A higher value returns ER0171.

curl "https://api.apitube.io/v1/news/raw?sort.by=published_at&sort.order=desc&per_page=50&api_key=YOUR_API_KEY"

How much does a raw request cost?

One credit if the response contains at least one article. The number of returned articles does not change that price. An empty result costs no credits.

Common Questions

How is /v1/news/raw different from /v1/news/article?

Raw results focus on id, title, href, created_at, description, author, keywords, source, and the body fields. For entities, sentiment, categories, and other analysis, fetch the full article by ID.

Why is the body truncated or marked “Upgrade subscription plan”?

Free plans and test keys return previews of body and body_html, with an upgrade or test-mode marker. Use a live key on a paid plan for full text.

Can I export raw results to CSV or RSS?

No. /v1/news/raw returns JSON only. CSV, XLSX, RSS, and other exports are available on search endpoints.

Which errors can the raw endpoint return?

Common errors are 401 ER0201/ER0202 for a missing or invalid key, 402 ER0176 for no credits, and 400 ER0171 for a page size above your plan’s limit. Keep request_id when reporting a problem.


Related Articles