baba/apiOpenAPI schema

Documentation

View .md

Bulk export

GET /api/v1/export streams historical articles and clusters for a date range, as JSONL or CSV. It is an Enterprise scope, meant for backfills, model training sets and archives rather than for reading the day's news.

The range

from and to are inclusive UTC dates, at most 366 days apart. Up to 500 article records come back per page, grouped by storyId.

X-Export-Snapshot fixes the insertion cutoff for the whole walk, so a story filed while you page does not appear halfway through. Corrections and current cluster state are read live, so those can change between pages.

Full publisher article bodies are never included.

Paging a range

Send X-Next-Cursor from the previous response back as cursor, with from, to and lang unchanged. An empty X-Next-Cursor marks the final page.

Export walk
curl -s --get 'https://news.itsbaba.com/api/v1/export' \
  --header "Authorization: Bearer $BABA_NEWS_API_KEY" \
  --data-urlencode 'from=2026-01-01' \
  --data-urlencode 'to=2026-03-31' \
  --data-urlencode 'format=jsonl' \
  --dump-header headers.txt

Columns

ColumnMeaning
recordIdRow id. Strictly increasing, and what the cursor advances on.
storyIdCluster id. Rows that share it belong to one story.
articleIdArticle id inside the cluster.
sourceNewsroom key.
langRecord language, which equals the requested lang.
headlineHeadline for that article.
summaryMachine-written summary.
topicDesk id.
publishedAtPublication timestamp, UTC.
updatedAtLast body change, or null.
stateCurrent cluster state, read at export time.
missingSidesSides absent from the cluster, as a JSON array.
framingFraming object, or null.
urlbaba URL for the article.
One JSONL record
{"recordId":"918233","storyId":"44","articleId":"812","source":"ynet","lang":"en","headline":"Cabinet approves the deal","summary":"Ministers voted after midnight.","topic":"politics","publishedAt":"2026-08-14 05:11:00+00","updatedAt":null,"state":"consensus","missingSides":["haredi"],"framing":null,"url":"https://news.itsbaba.com/812/cabinet-approves-the-deal"}

Format notes

JSONL is one JSON object per line, newline terminated, and is the default. CSV carries a header row, quotes every field containing a comma or a quote, and encodes missingSides and framing as JSON strings inside the cell.

lang selects stored records only. There is no fallback in export: asking for he returns Hebrew rows and omits articles with no Hebrew record, which is what you want when building a training set and not what you want when reading the news.