Entitlement consumption
Tracks usage of entitled features in a tenant, used for the consumption metrics in the admin console in a tenant.
Endpoints
Lists of execution records by tenant.
Facts
| Rate limit | Tier 1 (1000 requests per minute) |
Query Parameters
- actionToBlock string
- filter string
The advanced filtering to use for the query. Refer to RFC 7644 for the syntax.
example
taskName eq "automation_run_ended" or taskName eq "report_triggered" or or taskName eq "dataVolumeAggregated"The following fields are supported:
scope,resourcetype,resourceaction,resourceid,capacitylimit,localusage,globalusage,overage,blocked,periodstart,periodend,consumptionreportid,blockedeventtime,overageeventtime,taskname,taskdescription,userid,tenantid,customerfacing,actiontoblock - limit integer
Limit the returned result set
- offset integer
Offset for pagination - how many elements to skip
- page string
The cursor to the page of data.
- periodsToInclude array of strings
Specifies which periods to include regardless of the period type, start and end specified
Values may be any of: "current""previous"
- sort array of strings
Values may be any of: "periodstart""-periodstart""+periodstart""periodend""-periodend""+periodend"
Responses
200
The executions list has been successfully returned
- application/json object
properties that should be added to every list response
application/json properties
- totalCount integerRequired
total count of entries in the collection as a whole
- currentPageCount integerRequired
count of entries on the currently shown page
- data array of objects
data properties
- unit string
Unit of measurement for the resource consumption
- scope array of strings
Values may be any of: "user""tenant""resourceId""resourceType""resourceAction"
- userId string
The user id.
- blocked boolean
- overage boolean
- segments array of objects
additional optional properties
- object object
-
- taskName string
The resource task name.
- tenantId string
The tenant id.
- periodEnd string
The end of the associated period.
- localUsage number
The local usage.
- periodType string
Can be one of: "day""month""year""""fixed""minute"
- resourceId string
The resource id.
- updateTime string
The RFC3339 timestamp when the resource was updated.
- enforcement array of objects
Contains a list of resources that are blocked when quota for this is reached.
enforcement properties
- resourceType string
Resource type to be blocked
- actionToBlock string
Resource action type to be blocked
-
- globalUsage number
The global usage.
- periodStart string
The start of the associated period.
- resourceType string
The resource type.
Can be one of: "app""automations""space""data.volume.consumption"
- scopeMapping string
The map to the resource scope.
- capacityLimit number
The capacity limit.
- closeToOverage boolean
- customerFacing boolean
The field to determine if a resource should be visible on the client.
- guardrailLimit number
The guardrail limit.
- resourceAction string
The resource action.
Can be one of: "report.generated""reload""scheduledReload""executed""aggregation""import""updated""deployed""3rd_party_executed""standard_executed"
- taskDescription string
The resource task description.
- blockedEventTime string
RFC3339 timestamp when a block event was last emitted for this execution.
- overageEventTime string
RFC3339 timestamp when a overage event was last emitted for this execution.
- consumptionReportId string
The id of the consumption report
-
- links object
links properties
- next object
next properties
- href string
URL to particular set of elements
- type string
Page type, can be next or prev
Can be one of: "prev""next"
- token string
Page unique token
-
- prev object
prev properties
- href string
URL to particular set of elements
- type string
Page type, can be next or prev
Can be one of: "prev""next"
- token string
Page unique token
-
- self object
Object with Href to a particular element or set of elements
self properties
- href string
-
-
- overage boolean
- closeToOverage boolean
- globalUsageAvailable boolean
-
404
Resource does not exist.
- application/json object
application/json properties
- errors array of objects
errors properties
- code string
Error code specific to usage-tracker.
- meta object
meta properties for an error.
- title string
Error title.
- detail string
Error cause.
-
- traceId string
-
500
Internal server error.
- application/json object
application/json properties
- errors array of objects
errors properties
- code string
Error code specific to usage-tracker.
- meta object
meta properties for an error.
- title string
Error title.
- detail string
Error cause.
-
- traceId string
-
default
Error response.
- application/json object
application/json properties
- errors array of objects
errors properties
- code string
Error code specific to usage-tracker.
- meta object
meta properties for an error.
- title string
Error title.
- detail string
Error cause.
-
- traceId string
-
import { createQlikApi } from '@qlik/api'
const qlik = createQlikApi({ hostConfig: { host: 'https://{tenant}.{region}.qlikcloud.com', apiKey: '<access-token>', },})
await qlik.consumption.getConsumptionExecutions( {},)qlik consumption executionscurl "https://{tenant}.{region}.qlikcloud.com/api/v1/consumption/executions" \-H "Authorization: Bearer <access_token>"Example Response
{ "totalCount": 1, "currentPageCount": 1, "data": [ { "unit": "string", "scope": [ "tenant", "resourceType" ], "userId": "string", "blocked": false, "overage": false, "segments": [ { "QDI": 10 }, { "APP": 10 } ], "taskName": "task_name", "tenantId": "string", "periodEnd": "2022-01-31", "localUsage": 20, "periodType": "month", "resourceId": "228ac375-086e-4652-b9c0-fa8689bac75f", "updateTime": "string", "enforcement": [ { "resourceType": "string", "actionToBlock": "string" } ], "globalUsage": 29, "periodStart": "2022-01-01", "resourceType": "app", "scopeMapping": "string", "capacityLimit": 50, "closeToOverage": false, "customerFacing": true, "guardrailLimit": 20, "resourceAction": "reload", "taskDescription": "some description", "blockedEventTime": "string", "overageEventTime": "string", "consumptionReportId": "01xQ1chLoHkOikyzUGcHJquteNrAfketW" } ], "links": { "next": { "href": "http://localhost:8787/v1/items?limit=12", "type": "next", "token": "JwAAAAJfaWQAGQAAADVjZjUwM2NjMjVkYzlhMTM1MzYwZTVjZAAA" }, "prev": { "href": "http://localhost:8787/v1/items?limit=12", "type": "next", "token": "JwAAAAJfaWQAGQAAADVjZjUwM2NjMjVkYzlhMTM1MzYwZTVjZAAA" }, "self": { "href": "http://localhost:8787/v1/items/5da5825325dc9a0dd0260af9" } }, "overage": false, "closeToOverage": false, "globalUsageAvailable": true}