Skip to content

Measured quantities over time, per meter

GET
https://billing.ezghcloud.com/v1/organizations/{orgId}/usage

Authorization

  • apiKeyoptionalHTTP
  • oauthoptionalHTTP
  • sessionCookieoptionalAPI key in cookie

Path parameters

  • orgIdstringrequired
    format: uuid

Query parameters

  • fromstringrequired

    A date (2026-09-01) or an hour-aligned UTC time (2026-09-01T10:00:00Z).

  • tostringrequired

    Exclusive, like from. Hourly windows are at most 14 days, others 13 months.

  • granularityoptionalhourordayormonth
    Default: "day"
  • groupByoptionalstring

    Up to two of project, meter, region, comma-separated.

  • filteroptionalstring

    key:value, comma-separated, keys as groupBy.

  • meteroptionalstring

    Only these meters, comma-separated.

Returns

200

OK

JSON
  • organizationIdstringrequired
  • fromstringrequired
    format: date-time
  • tostringrequired
    format: date-time
  • granularitystringrequired
  • ratedThroughstringrequired
    format: date-time
  • periodsarray ofobjectrequired
    4 properties
    • startstringrequired
      format: date-time
    • endstringrequired

      Exclusive.

      format: date-time
    • estimatedbooleanrequired

      Any of its groups is.

    • groupsarray ofobjectrequired
      5 properties
      • keysmap ofstringrequired

        Always includes meter.

      • quantitystringrequired

        In unit.

        pattern: ^-?[0-9]+(\.[0-9]+)?$
      • unitstring | nullrequired
      • eventCountintegerrequired
      • estimatedbooleanrequired

        Some of it is a level carried forward.

  • valuesmap ofarray<string>required

    Every value of each key in the window, whatever the filter.

  • labelsobjectrequired

    Display names for the IDs in the answer. IDs without one are left out.

    3 properties
    • servicesmap ofstringrequired
    • metersmap ofstringrequired
    • skusmap ofstringrequired
  • nextCursornullrequired

    One page: always null.

400

invalid_request: the request is malformed (with issues), or invalid_cursor.

JSON
  • errorobjectrequired
    3 properties
    • codestringrequired

      What went wrong, for programs: branch on this, never on message.

    • messagestringrequired

      What went wrong, for people.

    • issuesoptionalarray ofobject

      With invalid_request: each invalid field.

      2 properties
      • pathstringrequired
      • messagestringrequired

401

unauthenticated: no valid credential.

JSON
  • errorobjectrequired
    3 properties
    • codestringrequired

      What went wrong, for programs: branch on this, never on message.

    • messagestringrequired

      What went wrong, for people.

    • issuesoptionalarray ofobject

      With invalid_request: each invalid field.

      2 properties
      • pathstringrequired
      • messagestringrequired

403

access_denied: the caller isn't allowed to (the message names the action); forbidden_origin: a cookie-authenticated write from another site.

JSON
  • errorobjectrequired
    3 properties
    • codestringrequired

      What went wrong, for programs: branch on this, never on message.

    • messagestringrequired

      What went wrong, for people.

    • issuesoptionalarray ofobject

      With invalid_request: each invalid field.

      2 properties
      • pathstringrequired
      • messagestringrequired

404

not_found: the organization (or one the caller doesn't belong to), or the resource, doesn't exist.

JSON
  • errorobjectrequired
    3 properties
    • codestringrequired

      What went wrong, for programs: branch on this, never on message.

    • messagestringrequired

      What went wrong, for people.

    • issuesoptionalarray ofobject

      With invalid_request: each invalid field.

      2 properties
      • pathstringrequired
      • messagestringrequired

429

too_many_requests: slow down.

JSON
  • errorobjectrequired
    3 properties
    • codestringrequired

      What went wrong, for programs: branch on this, never on message.

    • messagestringrequired

      What went wrong, for people.

    • issuesoptionalarray ofobject

      With invalid_request: each invalid field.

      2 properties
      • pathstringrequired
      • messagestringrequired

500

internal_error: a bug; the details are in the logs, under the request ID.

JSON
  • errorobjectrequired
    3 properties
    • codestringrequired

      What went wrong, for programs: branch on this, never on message.

    • messagestringrequired

      What went wrong, for people.

    • issuesoptionalarray ofobject

      With invalid_request: each invalid field.

      2 properties
      • pathstringrequired
      • messagestringrequired

503

unavailable, ledger_unavailable or payments_unavailable: retry later.

JSON
  • errorobjectrequired
    3 properties
    • codestringrequired

      What went wrong, for programs: branch on this, never on message.

    • messagestringrequired

      What went wrong, for people.

    • issuesoptionalarray ofobject

      With invalid_request: each invalid field.

      2 properties
      • pathstringrequired
      • messagestringrequired
Navigation

Type to search…

↑↓ navigate↵ selectEsc close