Get Demand Data

Get previously uploaded demand data.

Get Demand Data

get

Returns the demand data that has been uploaded to the model. Supports filtering by date range.

By setting the Accept header, you can specify the format of the response. The default is JSON. Supported formats: application/json, text/csv, application/x-ndjson.

Authorizations
AuthorizationstringRequired

Enter your PredictHQ API key. The Bearer prefix is added automatically.

When calling the API directly, send: Authorization: Bearer <YOUR_API_KEY> as documented at https://docs.predicthq.com/api/overview/authenticating

Path parameters
model_idstringRequired

The unique identifier of the forecast model.

Query parameters
date.gtstring · dateOptional

Filters demand after the specified date (exclusive).

Expected format: YYYY-MM-DD

date.gtestring · dateOptional

Filters demand on or after the specified date.

Expected format: YYYY-MM-DD.

Example: 2025-01-01

date.ltstring · dateOptional

Filters demand before the specified date (exclusive).

Expected format: YYYY-MM-DD.

date.ltestring · dateOptional

Filters demand on or before the specified date.

Expected format: YYYY-MM-DD.

Example: 2025-01-07

limitintegerOptional

The maximum number of results to return per page. Defaults to 10.

Default: 10
offsetintegerOptional

The number of results to skip before returning. Used for pagination. Defaults to 0.

Default: 0
Responses
chevron-right
200

Successful Response

errorsstring[]Optional

List of error messages, if any.

Default: []
warningsstring[]Optional

List of warning messages, if any.

Default: []
countintegerRequired

Total number of results matching the query.

nextany ofOptional

URL for the next page of results. Null if no more results.

stringOptional
or
nullOptional
previousany ofOptional

URL for the previous page of results. Null if on the first page.

stringOptional
or
nullOptional
get
/v1/forecasts/models/{model_id}/demand

OpenAPI Spec

The OpenAPI spec for Forecasts API can be found herearrow-up-right.

Guides

Last updated

Was this helpful?