Welcome to the TFC API. If you have any issues or feedback please get in touch with us at [email protected].
Model inference
Perform inference with foundation models.
query Parameters
modelThe forecasting model to use for inference. Note that only tabpfn-ts, moirai-2, chronos-2, and moirai-moe support exogenous variables.
cloudSpecify the cloud provider to use for inference. If none is set then any may be used depending on availability, including clouds not present in the below list (e.g. Oracle).
regionSpecify the region to use. If none is set then any may be used depending on availability, including regions not available for direct selection (such as ap or uk). Note that the region specifies the region for processing, but the request still passes through a control plane in the US.
Headers
AuthorizationThe Authorization header is used to authenticate with the API using your API key. Value is of the format Bearer YOUR_KEY_HERE.
Model inference › Request Body
horizonNumber of steps to forecast given the frequency.
freqFrequency of the time series.
The amount of history to use when forecasting. This is the number of steps to look back in the target series. More history can improve the forecast accuracy, but can also increase the computation time. By default this is set to the max of model capability or the length of the provided target series, whichever is shorter.
Apply additional co-variates provided by TFC. Only supported by the following models: Moirai-2, Chronos-2, Moriai-MoE and TabPFN-TS.
Optional model-specific configuration overrides.
Model inference › Responses
Success
Per-input-series predictions.
Submit job for forecasting
Perform historic inference for a range of forecast creation dates (fcds). These jobs can run longer and need to be retrieved with a separate endpoint and the returned job ID.
query Parameters
modelThe forecasting model to use for inference. Note that only tabpfn-ts, moirai, and moirai-moe support exogenous variables.
Headers
AuthorizationThe Authorization header is used to authenticate with the API using your API key. Value is of the format Bearer YOUR_KEY_HERE.
Submit job for forecasting › Request Body
horizonNumber of steps to forecast given the frequency.
freqFrequency of the time series.
The amount of history to use when forecasting. This is the number of steps to look back in the target series. More history can improve the forecast accuracy, but can also increase the computation time. By default this is set to the max of model capability or the length of the provided target series, whichever is shorter.
Apply additional co-variates provided by TFC. Only supported by the following models: Moirai-2, Chronos-2, Moriai-MoE and TabPFN-TS.
Optional model-specific configuration overrides.
Submit job for forecasting › Responses
Job submitted successfully. The returned job_id is used to poll GET /forecast-jobs/{job_id} for results.
job_idUnique identifier for the submitted job. Use it with GET /forecast-jobs/{job_id} to poll for results.
Retrieve job result
Retrieve the forecast result from a forecast job.
path Parameters
job_idHeaders
AuthorizationThe Authorization header is used to authenticate with the API using your API key. Value is of the format Bearer YOUR_KEY_HERE.
Retrieve job result › Responses
Job state. Switch on status — completed carries series, failed carries error, in_progress means keep polling.
Decision Table
| Variant | Matching Criteria |
|---|---|
| type = object · status="completed" · requires: series | |
| type = object · status="in_progress" | |
| type = object · status="failed" · requires: error |
statusPer-input-series predictions.
Warmup model
Warmup a model endpoint for better UX in embedded applications.
query Parameters
modelThe forecasting model to warmup.
cloudSpecify the cloud provider to use. If none is set then any may be used depending on availability, including clouds not present in the below list (e.g. Oracle).
regionSpecify the region to use. If none is set then any may be used depending on availability, including regions not available for direct selection (such as ap or uk). Note that the region specifies the region for processing, but the request still passes through a control plane in the US.
Headers
AuthorizationThe Authorization header is used to authenticate with the API using your API key. Value is of the format Bearer YOUR_KEY_HERE.
Warmup model › Responses
Rate Limiting Response
typeA URI reference that identifies the problem.
titleA short, human-readable summary of the problem.
statusThe HTTP status code.
instance
