---
title: "Get Kubernetes cost"
method: GET
path: "/api/v1/kubernetes/cost-and-usage"
tags: ["Kubernetes"]
---

# Get Kubernetes cost

`GET /api/v1/kubernetes/cost-and-usage`

The call is used to retrieve kubernetes data grouped and filtered by different values

## Query parameters

- `groupBy` string, required
- `startDate` string, date, required
- `endDate` string, date, required
- `periodGranLevel	` string, required
- `costUsageType` string, required
- `usageType` string
- `metricType` string
- `isNetUnblended` boolean
- `isAmortized` string
- `isNetAmortized` string
- `wheres` string
- `filters` string
- `excludeFilters` string

## Headers

- `Authorization` string, required
- `apikey` string, required

## Response `200`

- object
  - `data` object
  - `groupBy` string
  - `usageDate` string
  - `accountId` string
  - `clusterName` string
  - `totalCost` integer
  - `totalUsage` string
  - `nextPage` string

---

[API](https://skmtc.net/umbrellacost/apis/admin.md) · [All operations](https://skmtc.net/umbrellacost/apis/admin/llms.txt) · [OpenAPI document](https://skmtc-service-staging.skmtc.workers.dev/v1/apis/umbrellacost/admin/revisions/b0a65610726b/schema)
