Retrieve usage
/api/v1/meters/{id}/usageReturns the usage of a meter for each hour or day in a range, for one customer or, when you name no customer, for all your customers in this mode added together. A day is a UTC day. Only periods with usage are listed. If the counting rules of the meter changed inside a period, the period is listed once for each set of rules, with start and end showing where each applies. from and to are whole hours for granularity hour, at most 744 hours apart, and whole days for granularity day, at most 366 days apart. groupBy splits each period by the values of the meter's dimensionKeys.
Authorization
bearerAuth An access token from POST /api/v1/oauth/token, sent as Authorization: Bearer <token>.
In: header
Path Parameters
The meter's ID.
uuidQuery Parameters
The customer's ID. Give this or customerExternalId, not both. Leave both out for all customers.
The customer's externalId. Give this or customer, not both. Leave both out for all customers.
The start of the range, an ISO 8601 time on a whole UTC hour or day, as the granularity says.
The end of the range, not included, in the same form as from. It must be after from.
hour or day. day when left out.
Dimension keys of the meter to split the usage by, separated by commas, each at most once.
Header Parameters
The API version to use for this request, a date such as 2026-11-06. Without it the request uses your default version for the mode of your key. An unknown version answers 400 api_version_invalid.
Value in
- "2026-11-06"
Response Body
application/json
application/json
application/json
application/json
application/json
curl -X GET "https://api-malipo.flex.co.tz/api/v1/meters/497f6eca-6276-4993-bfeb-53cbbbba6f08/usage?customerExternalId=user-4821&from=2026-11-01T00%3A00%3A00Z&to=2026-12-01T00%3A00%3A00Z&granularity=day&groupBy=region%2Cplan" \ -H "Authorization: Bearer <token>" \ -H "FlexMalipo-Version: 2026-11-06"{ "meter": "08cfef1f-f291-40f5-b1b8-05ac0989f419", "customer": "0ac6320b-fa4d-4235-8d23-413a2b863bad", "aggregation": "SUM", "granularity": "day", "from": "2019-08-24T14:15:22Z", "to": "2019-08-24T14:15:22Z", "data": [ { "start": "2019-08-24T14:15:22Z", "end": "2019-08-24T14:15:22Z", "value": 42.5, "dimensions": { "region": "eu" } } ]}