For the complete documentation index, see llms.txt. This page is also available as Markdown.

Usage

Usage service handles licencing

Show usage

put

Retrieve a single usage

Path parameters
metricstringRequired

Usage metric

Example: Consequatur nam.
Query parameters
accountIdentifierstringRequired

Account identifier

Example: Rem earum ut ut voluptatum quidem eius.
Responses
200

OK response.

application/json
statusstringRequiredExample: Aut et vel id quo.
put/api/enforcement/client/usage/{metric}
PUT /api/enforcement/client/usage/{metric}?accountIdentifier=Rem+earum+ut+ut+voluptatum+quidem+eius. HTTP/1.1
Host: localhost:80
Accept: */*
{
  "data": {
    "ansible": {
      "uniqueHosts30d": 3681136019911911400
    },
    "count": 3643502814306413000
  },
  "status": "Sunt molestiae facere temporibus repellendus hic reprehenderit."
}

Show licence

get

Check whether the account is currently licenced

Header parameters
Harness-AccountstringRequired

Account identifier

Example: Mollitia sed laudantium animi in quia doloremque.
Responses
200

OK response.

application/json
accountstring · min: 1 · max: 128Required

Account identifier

Example: hn
isLicencedbooleanRequired

True when this account is currently licenced to execute apply operations

Example: false
isPaidbooleanRequired

True when this account is a paid account

Example: true
reasonstringOptional

If the account is not licenced, this is the reason why

Example: Explicabo quasi non magnam debitis.
startTimeinteger · int64Required

The unix timestamp of the current period over which usage was calculated

Example: 4931644747963660000
totalinteger · int64Required

The total number of successful apply operations this account is licenced to perform

Example: 4979462508537017000
usedinteger · int64Required

The count of successful apply operations already performed

Example: 4167969778573592000
get/api/usage/check-licence
GET /api/usage/check-licence HTTP/1.1
Host: localhost:80
Harness-Account: Mollitia sed laudantium animi in quia doloremque.
Accept: */*
{
  "account": "x6h",
  "activeWorkspaces": {
    "total": 3431452212837257700,
    "used": 8050654051313454000
  },
  "ansible": {
    "total": 3231037647155435500,
    "used": 3694293662675364400
  },
  "isLicenced": true,
  "isPaid": false,
  "reason": "Facere praesentium nesciunt possimus.",
  "startTime": 4514877314331004400,
  "total": 2571575050103393300,
  "used": 8692624268400836000
}

Last updated

Was this helpful?