APITube Help Center

Can I access historical news archives?

Query past news through the same everything search using the published_at date range, then sort and paginate to walk any window

Tasha Tatum

Written by Tasha Tatum

July 4, 2026

Open this example in the API Playground ↗

Can I access historical news archives?

Yes. APITube serves historical news from the same /v1/news/everything search you use for recent articles — there is no separate “archive” endpoint. You reach older articles by setting a date range with published_at.start and published_at.end, then sorting and paginating through the window. Any past period your query matches is available the same way today’s news is.

Because history uses the normal search, every other filter works alongside it: you can pull articles about one company, in one language, or from one country for a fixed date range, then page through the results in publish-time order.

Is there a separate archive endpoint?

No. Historical articles and fresh articles live behind one endpoint, /v1/news/everything. What makes a request “historical” is the date filter, not a different URL. Send your API key as the api_key query parameter or the X-API-Key header, add a published_at.start / published_at.end range, and you are querying the archive:

curl "https://api.apitube.io/v1/news/everything?published_at.start=2024-01-01&published_at.end=2024-01-31&api_key=YOUR_API_KEY"

This returns articles published in January 2024. The date filter is part of the shared filter chain, so it combines with keyword, source, entity, language and every other filter in a single request — see how to filter news by date range for the parameter itself.

What date formats does the range accept?

published_at.start and published_at.end accept both absolute and relative dates, so you can pin an exact window or express it relative to now:

  • Absolute: 2024-01-01 (YYYY-MM-DD), 01-01-2024 (DD-MM-YYYY), 01.01.2024 (DD.MM.YYYY), full ISO 8601 (2024-01-01T00:00:00Z), or a Unix timestamp in seconds.
  • Relative: NOW, NOW-1WEEK, NOW-6MONTHS, NOW-1YEAR, or the short forms 1w, 6m, 3d, 5y (a bare value means the past). NOW/DAY rounds down to the start of the day.

The complete syntax for both parameters is listed in the official parameters reference. Each date value must be 1 to 30 characters. An unparseable published_at.start returns HTTP 400 with error ER0104, and an unparseable published_at.end returns ER0106; a value longer than 30 characters returns ER0105 (start) or ER0107 (end). The example below pulls the last twelve months:

curl "https://api.apitube.io/v1/news/everything?published_at.start=NOW-1YEAR&published_at.end=NOW&api_key=YOUR_API_KEY"

How do I page through a long historical window?

By default results come back newest-first (sort.by defaults to published_at, sort.order to desc). To walk a period from oldest to newest instead, set sort.order=asc, then move through the results with page and per_page. per_page defaults to 100 and its maximum is 250 — a larger value returns error ER0171 — so a full month is retrieved in batches:

curl "https://api.apitube.io/v1/news/everything?published_at.start=2024-01-01&published_at.end=2024-01-31&sort.by=published_at&sort.order=asc&per_page=250&page=1&api_key=YOUR_API_KEY"

Increment page (2, 3, 4 …) to keep reading the same window. page must be an integer, or the request returns ER0172. On the Free plan, pagination stops after the first 5 pages (ER0173), which caps a single query at 5 × 250 = 1,250 articles; a paid plan pages deeper. For the full pagination model, see how to paginate through results.

How far back does the archive go for my query?

APITube does not expose a single fixed “N years” number through the API, and coverage depth varies by topic, language and source. The reliable way to find the earliest available article for your specific query is to sort ascending and read the oldest result — request one article, oldest-first:

curl "https://api.apitube.io/v1/news/everything?sort.by=published_at&sort.order=asc&per_page=1&api_key=YOUR_API_KEY"

The published_at of that single article is the earliest date the archive holds for your filters. Add any filters (a source, a language, an entity) before running it to measure depth for exactly the slice you care about, rather than trusting a headline figure.

How do I count how much history exists in a period?

Use /v1/news/count with the same date range to get the number of matching articles without downloading them. Because you are passing a date filter, the endpoint returns the real count for that window on a live key:

curl "https://api.apitube.io/v1/news/count?published_at.start=2023-01-01&published_at.end=2023-12-31&api_key=YOUR_API_KEY"

Stepping the range month by month is a quick way to profile how article volume changes over time before you commit to downloading. See how to count matching articles for the endpoint’s details and the test-key caveat.

Common Questions

Can I pull the entire archive in one request?

No. A single response is capped at per_page=250 articles, so a large historical window is always retrieved across multiple pages. The practical pattern is to fix a date range with published_at.start / published_at.end, sort ascending, and loop page until the results run out — then move the window and repeat. For bulk historical extraction, narrow each window (by day, week, source, or language) so each slice fits inside the pagination limits.

Why am I limited to 5 pages of history?

The 5-page cap (ER0173) applies only to the Free plan. It limits every query — historical or recent — to the first 5 pages of results. With per_page=250 that is up to 1,250 articles per query; to page further into an archive window, upgrade to a paid plan. The date filter itself is not restricted on Free — only how deep you can paginate.

Partly. /v1/news/trends accepts a date range but caps it at a 30-day window (a longer range returns an error). The full-article search on /v1/news/everything has no such date-range cap, so for reading history beyond 30 days you query articles directly rather than trends. Use trends for short-window topic and entity movement, and everything for arbitrary historical periods.

What does published_at without start or end do?

Passing a single published_at value (instead of the .start / .end pair) filters to a one-day window: APITube treats it as the start of that day and matches articles published within the following 24 hours. An unparseable single published_at returns ER0109. Use published_at.start and published_at.end when you need any window other than exactly one day.


Related Articles