Skip to Content
API ReferenceObservationsLatest observation

Latest Observation

GET /v1/observations/latest returns the latest row for an indicator and optional region. This endpoint requires an API key or x402 payment.

Request

curl "https://api.creativeforesight.io/v1/observations/latest?indicator=UNRATE&region=US" \ -H "Authorization: Bearer $FORESIGHT_API_KEY"

Query parameters

ParameterTypeRequiredDescription
indicatorstringYesIndicator code, such as UNRATE or cf:labor_composite.
sourcestringNoSource slug for duplicate provider codes.
regionstringNoRegion code. Uses the indicator default region when omitted.
as_ofdateNoThe latest value that had been published by the end of this day (UTC). See point-in-time reads.

Latest observation object

FieldTypeDescription
indicatorstringIndicator code.
regionstringRegion code.
period_startdateFirst day of the period.
period_enddate or nullLast day of the period.
period_typestring or nulldaily, weekly, monthly, quarterly or annual.
valuenumberLatest value.
unitstring or nullUnit, from the unit vocabulary.
revisioninteger or nullHow many earlier values this period has had. 0 is the first value Foresight holds.
is_preliminaryboolean or nulltrue when the source marks the value preliminary or an early estimate it will revise on schedule.
estimatestring or nullThe source’s name for this estimate, where it publishes a run of them: advance, second or third for BEA’s national accounts.
source_updated_atdate-time or nullWhen the source last updated the data this value comes from (FRED’s series update time, BEA’s table revision date), when the source states one.

Response

{ "data": { "indicator": "UNRATE", "region": "US", "period_start": "2026-10-01", "period_end": "2026-10-31", "period_type": "monthly", "value": 4.1, "unit": "percent" }, "meta": { "indicator": "UNRATE", "region": "US", "unit": "percent", "total": 1, "limit": 1, "offset": 0, "source_attribution": "Contains FRED® data © Federal Reserve Bank of St. Louis" } }

If the series is not held for the region you ask for, the answer is 404 naming the regions it is held for and, when one exists, the indicator to use instead (details.available_regions, details.suggested_indicator). A lower-case series code (unrate) finds the same series as its upper-case code.

Errors

StatusCodeMeaning
400INVALID_PARAMETERRequired or optional query parameters are invalid.
401INVALID_API_KEYThe request did not include a valid API key and was not a settled x402 request.
404RESOURCE_NOT_FOUNDThe requested indicator or region was not found.
429RATE_LIMIT_EXCEEDEDThe API key exceeded its one-minute request limit.
500INTERNAL_SERVER_ERRORLatest observation data could not be loaded.
Last updated on