Create Model

Create a forecast model.

Create Model

post
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

Body
namestring · min: 1Required

Name for the forecast model.

external_idstring · min: 1Optional

External identifier for the forecast model. If you have an ID for the location/store/property/product-group in your other platforms, use the same ID here to easily connect this specific forecast model.

forecast_windowstring · enumOptional

Number of days into the future to forecast.

Possible values:
labelstring[] · min: 1Optional

Set of labels you can use to better identify or group your forecast models.

algostring · enumOptional

Currently we offer one algorithm based on XGBoost. In the future we may offer additional algos.

Default: phq-xgboostPossible values:
Responses
201

Successful Response

application/json
post
/v1/forecasts/models

OpenAPI Spec

The OpenAPI spec for Forecasts API can be found here.

Guides

Last updated

Was this helpful?