Retrieves the usage charts for the organization

GET /api/v2/billing/organizations/{organization_id}/charts

Retrieves the usage charts for the organization.

Query parameters

  • from string Required

    A datetime for the beginning of the desired range.

  • to string Required

    A datetime for the end of the desired range.

  • The desired bucketing strategy for the charts.

    Values are daily or monthly.

Responses

  • 200 application/json

    Successfully return the usage charts of an organization.

    Hide response attribute Show response attribute object
    • data array[object]

      The list of chart item.

      Hide data attributes Show data attributes object
      • timestamp integer(int64)

        Axis X position.

      • values array[object]

        The collection of values to plot the chart item.

        Hide values attributes Show values attributes object
        • id string

          The id of chart item value.

        • name string

          The name of the chart item value.

        • type string

          Item type.

        • value number(double)

          The actual value of the chart item value.

  • 401 text/plain

    Unauthorized

  • Not found.

  • Failed dependency.

  • Internal Server Error.

GET /api/v2/billing/organizations/{organization_id}/charts
curl \
 -X GET https://billing.elastic-cloud.com/api/v2/billing/organizations/{organization_id}/charts?from=2021-04-21T00%3A00%3A00%2B00%3A00&to=2021-04-21T00%3A00%3A00%2B00%3A00 \
 -H "Authorization: Bearer $ACCESS_TOKEN"
Response examples (200)
{
  "data": [
    {
      "timestamp": 42,
      "values": [
        {
          "id": "string",
          "name": "string",
          "type": "string",
          "value": 42.0
        }
      ]
    }
  ]
}