Documentation → Earnings dates
Documentation

Earnings dates

Reporting dates with a confidence value. /calendar/* is the read side; /earnings/* additionally exposes the source situation and the operational side.

What it is good for is on the product page: Earnings dates

POST /calendar/for-identifiers

Calendar For Identifiers

Given an array of tickers and/or ISINs, return their calendar events within a window (today + days, or an explicit from/to range). ISINs are resolved to tickers via ticker_reference.

No parameters.

Request body CalendarForIdentifiersRequest

NameTypeMeaning
identifiersarray
required
Identifiers
daysinteger
optional · default 14
Days
from_datestring
optional
From Date
to_datestring
optional
To Date
categorystring
optional
Category
limitinteger
optional · default 5000
Limit

Example

curl -X POST "$API/calendar/for-identifiers" \
  -H "X-API-Key: $KEY" \
  -H "Content-Type: application/json" \
  -d '{ … }'
GET /calendar/upcoming

Calendar Upcoming

Upcoming calendar events (from calendar_events) within a date window — today, next 5d, 14d, or an explicit from/to range — enriched with ticker / name / ISIN.

NameTypeMeaning
daysinteger, in query
optional · default 7
Look ahead this many days from today
from_datestring, in query
optional
Override window start (YYYY-MM-DD)
to_datestring, in query
optional
Override window end (YYYY-MM-DD)
categorystring, in query
optional
e.g. Ergebnisberichte, Dividenden, Hauptversammlungen
limitinteger, in query
optional · default 500

Example

curl "$API/calendar/upcoming?days=14&category=earnings" \
  -H "X-API-Key: $KEY"
{
  "events": [
    { "isin": "FI0009000681", "name": "Nokia",
      "date": "2026-09-17", "category": "earnings",
      "confidence": 0.94, "sources": ["yf_info", "nasdaq", "marketscreener"] }
  ]
}
GET /earnings/cache

List Cache

List all tickers currently in the earnings MongoDB cache.

Ticker mit widerspruechlicher Identitaet werden ausgelassen und nur gezaehlt -- sie stehen im Cache, sind aber keiner Firma sicher zuzuordnen.

No parameters.

Example

curl "$API/earnings/cache" \
  -H "X-API-Key: $KEY"
DELETE /earnings/cache/{ticker}

Invalidate Cache

Manually invalidate the cached earnings for a ticker. The next call to /confidence or /fetch will re-fetch live data.

NameTypeMeaning
tickerstring, in path
required

Example

curl -X DELETE "$API/earnings/cache/SAP" \
  -H "X-API-Key: $KEY"
GET /earnings/calendar/{identifier}

Earnings Calendar

Return the earnings calendar for a ticker, filtered by confidence.

This endpoint reads from MongoDB only — no live fetch. If the ticker is not yet cached, call first:

  • GET /earnings/fetch/{identifier}?origin=yf (fast, always saves)
  • GET /earnings/confidence/{identifier} (all sources, saves if conf ≥ 0.9)

Accepts: ticker, ISIN, CIK, WKN (prefix notation for all-digit WKNs: wkn:623100).

NameTypeMeaning
identifierstring, in path
required
min_confidencenumber, in query
optional · default 0.9
Minimum confidence threshold (default 0.9). Only reads from MongoDB cache.

Example

curl "$API/earnings/calendar/SAP" \
  -H "X-API-Key: $KEY"
GET /earnings/confidence/{identifier}

Earnings Confidence

Fetch earnings from all sources and compute cross-source confidence scores. Results are cached in MongoDB for cache_hours hours.

ScoreMeaning
< 0.65Single source — provisional
0.65–0.891–2 sources — verify before acting
0.90–0.952 high-quality sources agree ✓
> 0.953+ sources agree — high reliability ✓✓
NameTypeMeaning
identifierstring, in path
required
force_refreshboolean, in query
optional · default False
Bypass cache and re-fetch
cache_hoursinteger, in query
optional · default 24
Max cache age in hours

Example

curl "$API/earnings/confidence/SAP" \
  -H "X-API-Key: $KEY"
GET /earnings/coverage

Earnings Coverage

The state of the dates lane in one call.

Answers: how many tickers have any dates at all, how many are confirmed, how large the repair backlog is, and which source actually delivers. This is the endpoint on which repair progress can be read off.

No parameters.

Example

curl "$API/earnings/coverage" \
  -H "X-API-Key: $KEY"
POST /earnings/fetch/batch

Earnings Fetch Batch

Batch-fetch earnings for multiple identifiers in parallel (max 5 concurrent).

Accepts a list of identifiers — each can be ticker, ISIN, WKN (with wkn: prefix), CIK, or any format supported by the single-fetch endpoint.

origin applies to all items in the batch.

No parameters.

Request body BatchFetchRequest

NameTypeMeaning
itemsarray
required
Items
originstring
optional · default all
Origin

Example

curl -X POST "$API/earnings/fetch/batch" \
  -H "X-API-Key: $KEY" \
  -H "Content-Type: application/json" \
  -d '{ … }'
POST /earnings/fetch/bulk

Earnings Fetch Bulk

Start a background job that fetches earnings for a large list of identifiers.

Returns immediately with a job_id — poll GET /earnings/jobs/{job_id} for progress.

  • identifiers: plain list of tickers, ISINs, WKNs, or CIKs (no limit)
  • origin: yf (fast, always saves) or all (5 sources, saves if confidence ≥ 0.9)
  • concurrency: parallel fetches (default 10, max 50)

``json {

"identifiers": ["AAPL", "MSFT", "DE0006231004", "isin:US5949181045"],
"origin": "yf",
"concurrency": 20

} ``

No parameters.

Request body BulkFetchRequest

NameTypeMeaning
identifiersarray
required
Identifiers
originstring
optional · default tiered
Origin
concurrencyinteger
optional · default 10
Concurrency

Example

curl -X POST "$API/earnings/fetch/bulk" \
  -H "X-API-Key: $KEY" \
  -H "Content-Type: application/json" \
  -d '{ … }'
GET /earnings/fetch/{identifier}

Earnings Fetch

Collect earnings data and save it to MongoDB.

origin=tiered (default) yfinance first; if it returns nothing, or

less than confidence 0.9, the remaining five sources
follow. On a single lookup confirmation is worth the
cost, so unlike in bulk mode this escalates even on a
hit.

origin=yf yfinance.info only. A diagnostic mode. Unsuitable for

bulk runs, because only a single source is asked and an
empty result then looks like a genuine "no date" — use
tiered for that.

origin=massive massive.com /v3/reference/tickers/{ticker}/earnings.

Returns full history plus all future quarters.

origin=all All six sources, always contacted.

Data is stored as soon as at least one date has been found; the quality sits in the quality sub-document (confirmed from confidence 0.9). A hit from only one source is therefore not lost, but stays recognisable as such.

Accepts any identifier:

FormatExample
ISINDE0006231004
CIK320193
TickerAAPL, IFX.DE
WKN (auto)A14YUR
WKN (digits)wkn:623100
Explicitisin:DE0006231004
NameTypeMeaning
identifierstring, in path
required
originstring, in query
optional · default tiered
'tiered' → yfinance zuerst, bei Leerlauf/geringer Konfidenz die restlichen vier. 'yf' → nur yfinance.info — Diagnose-Modus. 'all' → immer alle fuenf Quellen.

Example

curl "$API/earnings/fetch/SAP" \
  -H "X-API-Key: $KEY"
GET /earnings/jobs

List Jobs

List the most recent bulk jobs (newest first).

NameTypeMeaning
limitinteger, in query
optional · default 20

Example

curl "$API/earnings/jobs" \
  -H "X-API-Key: $KEY"
GET /earnings/jobs/{job_id}

Get Job Status

Poll the status of a bulk fetch / refresh job.

status values:

  • pending — queued, not yet started
  • running — in progress (done / total shows progress)
  • done — finished (check failed for partial errors)
NameTypeMeaning
job_idstring, in path
required

Example

curl "$API/earnings/jobs/job_7f3c" \
  -H "X-API-Key: $KEY"
POST /earnings/refresh/cached

Earnings Refresh Cached

Start a background job that re-fetches earnings for every ticker already in the MongoDB earnings_cache.

  • stale_only: when true, only re-fetch entries older than stale_hours
  • stale_hours: age threshold in hours (default 24)
  • origin / concurrency: same as /fetch/bulk

Returns immediately with a job_id.

No parameters.

Request body RefreshCachedRequest

NameTypeMeaning
originstring
optional · default tiered
Origin
concurrencyinteger
optional · default 10
Concurrency
stale_onlyboolean
optional · default False
Stale Only
stale_hoursinteger
optional · default 24
Stale Hours

Example

curl -X POST "$API/earnings/refresh/cached" \
  -H "X-API-Key: $KEY" \
  -H "Content-Type: application/json" \
  -d '{ … }'
POST /earnings/sync/from-isins

Earnings Sync From Isins

Start a background job that fetches earnings for all ticker_reference entries that already have an ISIN and match the requested security types.

Defaults:

  • market="stocks"
  • active=true
  • type_filters=["CS", "ADRC"]
  • include_untyped_stocks=false

ADRS is accepted as an alias and normalized to ADRC.

No parameters.

Request body SyncFromIsinsRequest

NameTypeMeaning
originstring
optional · default tiered
Origin
concurrencyinteger
optional · default 10
Concurrency
marketstring
optional · default stocks
Market
activeboolean
optional · default True
Active
type_filtersarray
optional · default ['CS', 'ADRC']
Type Filters
include_untyped_stocksboolean
optional · default False
Include Untyped Stocks

Example

curl -X POST "$API/earnings/sync/from-isins" \
  -H "X-API-Key: $KEY" \
  -H "Content-Type: application/json" \
  -d '{ … }'
POST /earnings/sync/from-tickers

Earnings Sync From Tickers

Start a background job that fetches earnings for every ticker stored in the ticker_reference collection (populated via POST /tickers/sync).

Filters narrow down which tickers are included (default: active stocks). Returns immediately with a job_id — poll GET /earnings/jobs/{job_id}.

No parameters.

Request body SyncFromTickersRequest

NameTypeMeaning
originstring
optional · default tiered
Origin
concurrencyinteger
optional · default 10
Concurrency
marketstring
optional · default stocks
Market
type_filterstring
optional
Type Filter
activeboolean
optional · default True
Active

Example

curl -X POST "$API/earnings/sync/from-tickers" \
  -H "X-API-Key: $KEY" \
  -H "Content-Type: application/json" \
  -d '{ … }'
POST /earnings/sync/repair

Earnings Sync Repair

Fetches dates for tickers that have none yet, or only unconfirmed ones.

Two passes:

  • only_empty=true (default) — documents without any date at all. The
$exists predicate on dates.0 structurally excludes documents that
already carry dates, so they cannot consume budget.
  • only_unconfirmed=true — documents that have dates but whose
quality.confirmed is false. Here the fetch escalates until a second
source confirms.

Resumable without offsets: the worklist is derived from probe_at and quality.empty_streak, sorted by probe_at ascending. Aborting mid-run costs nothing — the next call derives the remaining tickers afresh. When nothing is due any more the answer is 422; the cron loop treats that as success and therefore terminates on its own.

No parameters.

Request body RepairRequest

NameTypeMeaning
originstring
optional · default tiered
Origin
concurrencyinteger
optional · default 4
Concurrency
only_emptyboolean
optional · default True
Only Empty
only_unconfirmedboolean
optional · default False
Only Unconfirmed
max_empty_streakinteger
optional · default 6
Max Empty Streak
limitinteger
optional · default 2000
Limit

Example

curl -X POST "$API/earnings/sync/repair" \
  -H "X-API-Key: $KEY" \
  -H "Content-Type: application/json" \
  -d '{ … }'
POST /earnings/sync/stale

Earnings Sync Stale

Incremental earnings sync. Walks ticker_reference and re-fetches only the tickers whose cached earnings in earnings_cache are missing or older than max_age_days (checked against earnings_cache.fetched_at).

Identifier resolution per ticker:

1. ticker_reference.isinisin:<ISIN>
2. fallback yahoo_profiles.yahoo_symbol (joined on ticker) → ticker:<SYMBOL>
3. last resort: the raw ticker        → ticker:<TICKER>

Fetches in tiers (origin=tiered). Returns a job_id — poll GET /earnings/jobs/{job_id}.

No parameters.

Request body SyncStaleRequest

NameTypeMeaning
originstring
optional · default tiered
Origin
max_age_daysinteger
optional · default 14
Max Age Days
concurrencyinteger
optional · default 4
Concurrency
marketstring
optional · default stocks
Market
activeboolean
optional · default True
Active
type_filterstring
optional
Type Filter
limitinteger
optional
Limit

Example

curl -X POST "$API/earnings/sync/stale" \
  -H "X-API-Key: $KEY" \
  -H "Content-Type: application/json" \
  -d '{ … }'