---
title: "Gets the billing cost time series."
method: GET
path: "/billing/cost/time-series"
tags: ["Billing"]
---

# Gets the billing cost time series.

`GET /billing/cost/time-series`

## Query parameters

- `startDate` string, date-time, required
- `endDate` string, date-time, required
- `grouping` 'Hour' | 'Day' | 'Week' | 'Month' | 'Minute', required — The time interval used to aggregate a time series.
- `customerId` string, uuid
- `customerMail` string
- `organizationId` string
- `includeNonBillable` boolean

## Response `200`

OK

- GetCostTimeSeriesEndpointOutput — The output for the cost time series endpoint.
  - `timeSeries` GetCostTimeSeriesEndpointCostDataPoint[], required — The time series data points.
    - `periodStart` string, date-time, required
    - `grossCost` number, double, required
    - `discount` number, double, required
    - `netCost` number, double, required
    - `responseCount` integer, required
  - `totalGrossCost` number, double, required — The total gross cost across all data points.
  - `totalDiscount` number, double, required — The total discount across all data points.
  - `totalNetCost` number, double, required — The total net cost across all data points.

## Other responses

- `400` — Bad Request
- `401` — Unauthenticated
- `403` — Forbidden

---

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