Skip to content

HPE GreenLake Consumption Analytics Reports API (1.0.0)

API reference documentation for the HPE GreenLake Consumption Analytics Reports API

Overview
Languages
Servers
Production - US West

https://us-west.api.greenlake.hpe.com/

Mock server

https://developer.greenlake.hpe.com/_mock/docs/greenlake/services/consumption-analytics/public/openapi/consumption-analytics-latest/v2/public-reports-v2/

Reports

Reference documentation for reporting operations.

Operations

List report definitions

Request

List the report definitions that are available.

Security
glcUserBearerAuth
Query
limitinteger(int64)[ 0 .. 100 ]

The maximum number of items to return.

Default 10
offsetinteger(int64)

The number of items to skip before starting to collect the result set.

Default "0"
curl -i -X GET \
  https://us-west.api.greenlake.hpe.com/consumption-analytics/v2/reports \
  -H 'Authorization: Bearer <YOUR_JWT_HERE>'

Responses

Success

Bodyapplication/json
countinteger(int32)
itemsArray of objects(ReportIdentifierV2)
offsetinteger(int32)
totalinteger(int32)
Response
application/json

success

{ "count": 2, "total": 2, "offset": 0, "items": [ {}, {} ] }

Generate report from definition

Request

Generates the report based on report definition provided in the request body.

Security
glcUserBearerAuth
Bodyapplication/jsonrequired

The request body containing the details for executing the report.

columnsArray of objects(PublicReportColumn)required

The list of columns to include in the report. Each column specifies a field and optional aggregation function.

columns[].​fieldNamestringrequired

The reference name of the field to include in the report column. Example system fields: 'sys_Provider_s', 'sys_Cost_f'. Example tag and custom fields: 'ext_f8693b3b4c321cc6c7b711be5733f288_s', 'ext_b8697b3b4c391cc6c7b711be5733f333_f'.

columns[].​aggFunctionstring

The aggregation function to apply to the field. Required for metric fields when data needs to be summarized. Examples include SUM, AVG, COUNT, and so on.

Enum"NONE""SUM""COUNT"
filterobject(PublicReportFilter)required
filter.​dateFilterobject(PublicReportDateFilter)required
filter.​dateFilter.​typestringrequired

Defines whether the filter uses a relative date range or an absolute date range.

Enum"ABSOLUTE""RELATIVE"
filter.​dateFilter.​endDatestring(date)

The end date of the filter range. Used when the type is ABSOLUTE.

filter.​dateFilter.​relativeRangestring

A predefined time period relative to the current date. Used when the type is set to RELATIVE.

Enum"YESTERDAY""LAST_7_DAYS""LAST_14_DAYS"
filter.​dateFilter.​startDatestring(date)

The start date of the filter range. Used when the type is ABSOLUTE.

filter.​fieldFiltersArray of objects(PublicReportFieldCriteria)

An optional list of field-level filter conditions that apply to the report. Each condition specifies a field, comparison operator, and one or more values.

curl -i -X POST \
  https://us-west.api.greenlake.hpe.com/consumption-analytics/v2/reports/execute \
  -H 'Authorization: Bearer <YOUR_JWT_HERE>' \
  -H 'Content-Type: application/json' \
  -d '{
    "filter": {
      "dateFilter": {
        "type": "RELATIVE",
        "relativeRange": "LAST_7_DAYS"
      },
      "fieldFilters": [
        {
          "name": "sys_Provider_s",
          "operator": "STARTS_WITH",
          "values": [
            "H"
          ]
        }
      ]
    },
    "columns": [
      {
        "fieldName": "sys_Provider_s"
      },
      {
        "fieldName": "sys_MeterName_s"
      },
      {
        "fieldName": "sys_Cost_f",
        "aggFunction": "SUM"
      }
    ]
  }'

Responses

Report generated successfully

Bodyapplication/json
itemsArray of objects
totalCountinteger(int32)
Response
application/json

success

{ "totalCount": 2, "items": [ {}, {} ] }

Generate report for saved definition

Request

Executes a report for a saved definition; specify the date range in the request body.

Security
glcUserBearerAuth
Path
idstring(uuid)[ 32 .. 36 ] characters^[0-9a-fA-F]{8}-?[0-9a-fA-F]{4}-?[0-9a-fA-F]{...required

The ID of the report to export.

Example: 7021d69d-de13-44bd-97e1-dbb05eef0759
Bodyapplication/jsonrequired
endDatestring(date)

The inclusive end date of the absolute date range (YYYY-MM-DD). Required when relativeDate is not provided.

Example: "2026-03-31"
relativeDatestring

A predefined time period relative to today. Takes precedence over startDate and endDate when both are provided.

Enum"YESTERDAY""LAST_7_DAYS""LAST_14_DAYS"
startDatestring(date)

The inclusive start date of the absolute date range (YYYY-MM-DD). Required when relativeDate is not provided.

Example: "2026-01-01"
curl -i -X POST \
  https://us-west.api.greenlake.hpe.com/consumption-analytics/v2/reports/7021d69d-de13-44bd-97e1-dbb05eef0759/execute \
  -H 'Authorization: Bearer <YOUR_JWT_HERE>' \
  -H 'Content-Type: application/json' \
  -d '{
    "startDate": "2026-01-01",
    "endDate": "2026-03-31"
  }'

Responses

The exported report as a JSON file

Bodyapplication/json
itemsArray of objects
totalCountinteger(int32)
Response
application/json

success

{ "totalCount": 2, "items": [ {}, {} ] }