Skip to main content
GET
/
v1
/
usage
Get tenant usage
curl --request GET \
  --url https://api.petrasecurity.com/v1/usage \
  --header 'Authorization: Bearer <token>'
{
  "asOf": "2023-12-25",
  "reportGeneratedAt": "2023-11-07T05:31:56Z",
  "organizationName": "<string>",
  "totalTenants": 123,
  "tenants": [
    {
      "petraTenantId": "<string>",
      "microsoftTenantId": "<string>",
      "onboardingDate": "2023-12-25",
      "displayName": "<string>",
      "service": "Monitoring",
      "isPaused": true,
      "firstBillableDate": "2023-12-25",
      "billableStatus": "Trial",
      "totalLicensedUsers": 123,
      "billableUsersThisMonth": 123,
      "proratingPercentageThisMonth": 123
    }
  ]
}

Documentation Index

Fetch the complete documentation index at: https://docs.petrasecurity.com/llms.txt

Use this file to discover all available pages before exploring further.

For common API errors, see API Troubleshooting.

Authorizations

Authorization
string
header
required

Bearer token authentication. Include your API key in the Authorization header as 'Bearer YOUR_API_KEY'

Query Parameters

asOf
string<date>

Date in ISO format (YYYY-MM-DD) to get usage data for. Defaults to current date if not provided.

Response

Successful response

asOf
string<date>
reportGeneratedAt
string<date-time>
organizationName
string
totalTenants
integer
tenants
object[]