Cost-model Cache API

The Kubecost cost-model container queries the k8s api-server to understand the resources which exist on the cluster. It then caches this information in memory. The following APIs are served by the cost-model container on each cluster, and provide a way to inspect the current state of the cache.

allNodes API

GET http://<your-kubecost-address>/model/allNodes

List of all nodes in the cluster.

allNamespaces API

GET http://<your-kubecost-address>/model/allNamespaces

List of all namespaces on the cluster.

allDeployments API

GET http://<your-kubecost-address>/model/allDeployments

List of all Deployments on the cluster.

Path Parameters

NameTypeDescription

namespace

string

Filter query by namespace.

allStatefulSets API

GET http://<your-kubecost-address>/model/allStatefulSets

List of all StatefulSets on the cluster.

Path Parameters

NameTypeDescription

namespace

string

Filter query by namespace.

allDaemonSets API

GET http://<your-kubecost-address>/model/allDaemonSets

List of all DaemonSets on the cluster.

allPods API

GET http://<your-kubecost-address>/model/allPods

List of all Pods on the cluster. Warning, this can be a very large response.

allPersistentVolumes API

GET http://<your-kubecost-address>/model/allPersistentVolumes

List of all PersistentVolumes on the cluster.

allStorageClasses API

GET http://<your-kubecost-address>/model/allStorageClasses

List of all StorageClasses on the cluster.

Last updated