Forecast API
Last updated
Last updated
GET
http://<your-kubecost-address>/forecasting/forecast/<monitoringEndpoint>
The Forecast API predicts a range of total future spending for any of Kubecost's three major monitoring data sets; Allocation, Assets, and CloudCosts, as established via the monitoringEndpoint
(more below).
Name | Type | Description |
---|---|---|
Regardless of the value of predictionWindow
, results will be returned in daily intervals.
predictedCost
will be the closest approximation of future costs for the day defined in the window
field. The bounds of the confidence interval are displayed with the values lowerConfidenceLimit
and upperConfidenceLimit
.
The Forecast Container powers multiple cost prediction features in Kubecost including Forecasting and Anomaly Detection. It reads the last 100 days of cost data to form a reliable model of prediction when querying with the Forecast API.
The Forecasting Container can be disabled by setting the Helm flag:
monitoringEndpoint
The Forecast API requires a configurable endpoint which establishes from which monitoring data you want to forecast:
Forecast future cloud cost spend for the next 60 days:
Dataset | Description | Endpoint |
---|---|---|
predictionWindow*
string
Range of future spend to predict. The larger the value of this parameter, the wider the confidence bounds may become. Should be formatted in number of days, ex: predictionWindow=30d
aggregate
string
Does not ever support job
, daemonSet
, or statefulSet
. Does not affect predicted cost values.
Allocated spend
/allocation
Kubernetes objects and resources
/assets
Cloud services
/cloudcost