{
"error": {
"code": "UNAUTHORIZED",
"message": "Invalid API key",
"details": "The provided API key is invalid or has been revoked"
}
}
{
"error": {
"code": "UNAUTHORIZED",
"message": "Invalid API key",
"details": "The provided API key is invalid or has been revoked"
}
}
{
"error": {
"code": "UNAUTHORIZED",
"message": "Invalid API key",
"details": "The provided API key is invalid or has been revoked"
}
}
{
"error": {
"code": "UNAUTHORIZED",
"message": "Invalid API key",
"details": "The provided API key is invalid or has been revoked"
}
}
Endpoints
Get Billable Users
Retrieve the list of billable users for a specific Petra tenant. A user is considered billable if they have non-empty assignedLicenseSkuIds and are not deleted (deletedAt is null).
The Petra tenant ID to get billable users for. The endpoint verifies that the requested tenant belongs to the organization associated with the API key.
The prorated number of billable units for this tenant in the current month. This value accounts for mid-month onboarding and is the number used for billing.
{"docsConfig":{"theme":"mint","$schema":"https://mintlify.com/docs.json","name":"Petra Security Docs","colors":{"primary":"#AE6654","light":"#E1C09E","dark":"#AE6654"},"logo":{"light":"https://mintcdn.com/petrasecurity-7f411ce9/xhwggn1Webj24oba/logo/light-group.svg?fit=max\u0026auto=format\u0026n=xhwggn1Webj24oba\u0026q=85\u0026s=bcb6096cc95673da0210cd35cab62266","dark":"https://mintcdn.com/petrasecurity-7f411ce9/xhwggn1Webj24oba/logo/dark-group.svg?fit=max\u0026auto=format\u0026n=xhwggn1Webj24oba\u0026q=85\u0026s=291d7abdafea5c702cded7e0ccfe9109"},"favicon":"https://mintcdn.com/petrasecurity-7f411ce9/804PMvzD5nFDNqZk/favicon.png?fit=max\u0026auto=format\u0026n=804PMvzD5nFDNqZk\u0026q=85\u0026s=e8b9e056a6422ed2998faf9649a268c0","api":{"openapi":"api-reference/openapi.json","playground":{"display":"interactive"}},"navbar":{"links":[{"href":"https://www.petrasecurity.com/research","label":"Research"}],"primary":{"type":"button","label":"Dashboard","href":"https://app.petrasecurity.com"}},"seo":{"metatags":{"canonical":"https://www.petrasecurity.com/docs","robots":"index, follow"}},"integrations":{"posthog":{"apiKey":"phc_9Nbz8UiN0da62l0QMCrMSFxEprCHPQzLeDmUhMF9hG8"}},"styling":{"latex":false},"navigation":{"global":{"anchors":[{"anchor":"Research","icon":"newspaper","href":"https://www.petrasecurity.com/research"},{"anchor":"Support","icon":"envelope","href":"mailto:support@petrasecurity.com"}]},"pages":[]}},"deployment":{"deploymentMetadataValue":{"subdomain":"petrasecurity-7f411ce9","hasAudioNarration":false,"actualSubdomain":"petrasecurity-7f411ce9","customDomains":["docs.petrasecurity.com"],"gitSource":{"type":"github","owner":"petra-security","repo":"docs","deployBranch":"main","contentDirectory":"","isPrivate":true,"mountPath":"","label":""},"chroma":{"liveDeploymentHistoryId":"6ae4e2512a1bb30bba7f9d4e","collectionId":"26fd9ddb-1597-4165-85b5-1a0804c9f857","schemaVersion":"v3","latestBuiltDeploymentHistoryId":"6ae4e2512a1bb30bba7f9d4e"},"entitlements":{"AI_CHAT":{"status":"ENABLED"},"WEB_MCP":{"status":"ENABLED"},"NARRATION":{"status":"ENABLED"}},"buildId":"6aee63006689ddcee8208579","clientVersion":"0.0.4076","searchFilterCounts":[{"language":"default","tag":"Guides","count":43},{"language":"default","tag":"How to","count":32},{"language":"default","tag":"Get Started","count":9},{"language":"default","tag":"API Reference","count":9},{"language":"default","tag":"Settings","count":8},{"language":"default","tag":"Investigate","count":7},{"language":"default","tag":"Reporting","count":7},{"language":"default","tag":"Endpoints","count":6},{"language":"default","tag":"Integrations","count":4},{"language":"default","tag":"API Documentation","count":3}]},"assistantConfig":{},"basePath":"/docs","hasChatPermissions":true,"hasWebMcpPermissions":true,"toggles":[{"name":"kill-isr","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"agent-mintlify-slack","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"agent-integrations-settings","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"rbac-expansion","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"automations-pr-grouping","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"custom-prefix","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"analytics-v7","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"user-flows-analytics","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"no-publish-flow","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"workos-onboarding","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"llms-txt-v2","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"snapshot-serving-live","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"stripTemperatureMiddleware","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"support-platform-pylon-zendesk","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"snapshot-serving","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"instant-rollback","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"granular-notifications-server","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"granular-notifications","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"automations-fable","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"fixed-ai-action-pricing","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"automation-resolve-merge-conflict","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"scoped-publishing","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"mintql","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"page-level-analytics","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"editor-version-history-v2","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"billing-page-v2","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"full-page-search","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"workspace-projects","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"assistant-v5","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"fork-pr-previews","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"revalidation-jwt","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"workos-sso-scim","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"hobby-abuse-scan","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"dashboard-inbox","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"workos-signup","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"turbopuffer-dual-write","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"workos-enabled","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"approve-review-flow","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"editor-metadata","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"sso-setup-deadline-banner","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"turbopuffer-serve","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"live-agents","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"comment-mode","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false}],"googleFontsInlined":false},"customCss":[],"page":{"pagePath":"api-reference/endpoints/get-billable-users","slug":"/api-reference/endpoints/get-billable-users","pageMetadata":{"title":"Get Billable Users","openapi":"GET /v1/billable-users","description":"Retrieve the list of billable users for a specific Petra tenant. A user is considered billable if they have non-empty assignedLicenseSkuIds and are not deleted (deletedAt is null).","href":"/api-reference/endpoints/get-billable-users"},"description":{"compiledSource":"\"use strict\";\nconst {jsx: _jsx} = arguments[0];\nconst {useMDXComponents: _provideComponents} = arguments[0];\nfunction _createMdxContent(props) {\n const _components = {\n p: \"p\",\n ..._provideComponents(),\n ...props.components\n };\n return _jsx(_components.p, {\n children: \"Retrieve the list of billable users for a specific Petra tenant. A user is considered billable if they have non-empty assignedLicenseSkuIds and are not deleted (deletedAt is null).\"\n });\n}\nfunction MDXContent(props = {}) {\n const {wrapper: MDXLayout} = {\n ..._provideComponents(),\n ...props.components\n };\n return MDXLayout ? _jsx(MDXLayout, {\n ...props,\n children: _jsx(_createMdxContent, {\n ...props\n })\n }) : _createMdxContent(props);\n}\nreturn {\n default: MDXContent\n};\n","frontmatter":{},"scope":{}},"pageType":"default","mdx":{"mdxSource":{"compiledSource":"\"use strict\";const{Fragment:_Fragment,jsx:_jsx,jsxs:_jsxs}=arguments[0];const{useMDXComponents:_provideComponents}=arguments[0];function _createMdxContent(props){const _components={a:`a`,strong:`strong`,..._provideComponents(),...props.components},{Note}=_components;if(!Note)_missingMdxReference(`Note`,true);return _jsxs(_Fragment,{children:[_jsxs(Note,{children:[`For common API errors, see `,_jsx(_components.a,{href:`/api-reference/troubleshooting`,children:`API Troubleshooting`}),`.`]}),`\n`,_jsxs(Note,{children:[`This route is limited to `,_jsx(_components.strong,{children:`1 request per minute`}),`.`]})]})}function MDXContent(props={}){const{wrapper:MDXLayout}={..._provideComponents(),...props.components};return MDXLayout?_jsx(MDXLayout,{...props,children:_jsx(_createMdxContent,{...props})}):_createMdxContent(props)}return{default:MDXContent};function _missingMdxReference(id,component){throw new Error(`Expected `+(component?`component`:`object`)+\" `\"+id+\"` to be defined: you likely forgot to import, pass, or provide it.\")}","frontmatter":{},"scope":{"config":{},"pageMetadata":{"title":"Get Billable Users","openapi":"GET /v1/billable-users","description":"Retrieve the list of billable users for a specific Petra tenant. A user is considered billable if they have non-empty assignedLicenseSkuIds and are not deleted (deletedAt is null).","href":"/api-reference/endpoints/get-billable-users"}}},"mdxSourceWithNoJs":null},"mdxExtracts":{"tableOfContents":[],"codeExamples":{}},"jsLinks":[],"openApiReferenceData":{"operation":{"summary":"Get billable users","description":"Retrieve the list of billable users for a specific Petra tenant. A user is considered billable if they have non-empty assignedLicenseSkuIds and are not deleted (deletedAt is null).","tags":[],"operationId":"getBillableUsers","parameters":["193fe428-bd17-4db0-9ed9-7a5a834188e7"],"responses":{"200":"dccc7a28-2d01-467d-9a9c-cb637c9a010c","401":"c738a3b1-5527-4051-87d0-72dd59527b1a","403":"e8c4d28a-e9a2-40f8-b96a-323d1c35fc0b","429":"5a301751-fc84-4cc6-a0a3-86253a0fbd67","500":"f00c23d6-9ee6-4644-85b4-4cfa3fa8e008"},"security":["ef760229-b448-4930-bdf3-28c6505a193d"],"method":"get","type":"path","servers":["85e9853c-be4d-489c-ae3d-0804cd5ea855"],"path":"/v1/billable-users","baseUrlOptions":["https://api.petrasecurity.com"],"title":"Get billable users","codeSamples":[],"requiredOnlyExamples":false,"requestExampleType":"generated","responseExampleType":"generated"},"dependencies":{"parameters":{"193fe428-bd17-4db0-9ed9-7a5a834188e7":{"name":"tenantId","in":"query","required":true,"description":"The Petra tenant ID to get billable users for. The endpoint verifies that the requested tenant belongs to the organization associated with the API key.","schema":{"type":"string","isRequired":true,"description":"The Petra tenant ID to get billable users for. The endpoint verifies that the requested tenant belongs to the organization associated with the API key.","uniqueKey":"","typeLabel":"string"}}},"responses":{"dccc7a28-2d01-467d-9a9c-cb637c9a010c":{"description":"Successful response","content":{"application/json":{"schema":{"type":"object","properties":{"tenantId":{"type":"string","description":"The Petra tenant ID","uniqueKey":"tenantId","typeLabel":"string"},"tenantDisplayName":{"type":"string","description":"The display name of the tenant","uniqueKey":"tenantDisplayName","typeLabel":"string"},"microsoftTenantId":{"type":"string","description":"The Microsoft tenant ID associated with this Petra tenant","uniqueKey":"microsoftTenantId","typeLabel":"string"},"reportGeneratedAt":{"type":"string","format":"date-time","description":"ISO 8601 timestamp indicating when this report was generated","uniqueKey":"reportGeneratedAt","typeLabel":"string\u003cdate-time>"},"totalBillableUsers":{"type":"integer","description":"The total count of billable users in the tenant","uniqueKey":"totalBillableUsers","typeLabel":"integer"},"projectedBillableUnitsThisMonth":{"type":"integer","description":"The prorated number of billable units for this tenant in the current month. This value accounts for mid-month onboarding and is the number used for billing.","uniqueKey":"projectedBillableUnitsThisMonth","typeLabel":"integer"},"users":{"type":"array","description":"Array of billable user objects","items":{"type":"object","properties":{"id":{"type":"string","description":"The unique identifier for the user","uniqueKey":"users.items.[INDEX].id","typeLabel":"string"},"displayName":{"type":"string","description":"The display name of the user","uniqueKey":"users.items.[INDEX].displayName","typeLabel":"string"},"userPrincipalName":{"type":"string","description":"The user principal name (typically the user's email/login)","uniqueKey":"users.items.[INDEX].userPrincipalName","typeLabel":"string"},"mail":{"type":"string","description":"The user's email address","uniqueKey":"users.items.[INDEX].mail","typeLabel":"string"},"accountEnabled":{"type":"boolean","description":"Whether the user account is currently enabled","uniqueKey":"users.items.[INDEX].accountEnabled","typeLabel":"boolean"},"assignedLicenseSkuIds":{"type":"array","description":"Array of SKU IDs for licenses assigned to this user","items":{"type":"string","uniqueKey":"users.items.[INDEX].assignedLicenseSkuIds.items.[INDEX]","typeLabel":"string"},"uniqueKey":"users.items.[INDEX].assignedLicenseSkuIds","typeLabel":"string[]"}},"uniqueKey":"users.items.[INDEX]","typeLabel":"object"},"uniqueKey":"users","typeLabel":"object[]"}},"example":{"tenantId":"petra-tenant-123","tenantDisplayName":"Acme Corporation","microsoftTenantId":"abcd1234-5678-90ef-ghij-klmnopqrstuv","reportGeneratedAt":"2026-01-06T12:00:00.000Z","totalBillableUsers":42,"projectedBillableUnitsThisMonth":28,"users":[{"id":"user-id-1","displayName":"John Doe","userPrincipalName":"john.doe@example.com","mail":"john.doe@example.com","accountEnabled":true,"assignedLicenseSkuIds":["sku-id-1","sku-id-2"]}]},"uniqueKey":"","typeLabel":"object"},"examples":{"Example":{"title":"Example","value":{"tenantId":"petra-tenant-123","tenantDisplayName":"Acme Corporation","microsoftTenantId":"abcd1234-5678-90ef-ghij-klmnopqrstuv","reportGeneratedAt":"2026-01-06T12:00:00.000Z","totalBillableUsers":42,"projectedBillableUnitsThisMonth":28,"users":[{"id":"user-id-1","displayName":"John Doe","userPrincipalName":"john.doe@example.com","mail":"john.doe@example.com","accountEnabled":true,"assignedLicenseSkuIds":["sku-id-1","sku-id-2"]}]}}},"exampleType":"generated"}},"exampleType":"generated"},"c738a3b1-5527-4051-87d0-72dd59527b1a":{"description":"Unauthorized - Invalid or missing API key","content":{"application/json":{"schema":{"type":"object","required":["error"],"properties":{"error":{"type":"object","required":["code","message"],"properties":{"code":{"type":"string","description":"Error code","isRequired":true,"uniqueKey":"error.code","typeLabel":"string"},"message":{"type":"string","description":"Human-readable error message","isRequired":true,"uniqueKey":"error.message","typeLabel":"string"},"details":{"type":"string","description":"Additional error details","uniqueKey":"error.details","typeLabel":"string"}},"isRequired":true,"uniqueKey":"error","typeLabel":"object"}},"example":{"error":{"code":"UNAUTHORIZED","message":"Invalid API key","details":"The provided API key is invalid or has been revoked"}},"uniqueKey":"","typeLabel":"object"},"examples":{"Example":{"title":"Example","value":{"error":{"code":"UNAUTHORIZED","message":"Invalid API key","details":"The provided API key is invalid or has been revoked"}}}},"exampleType":"generated"}},"exampleType":"generated"},"e8c4d28a-e9a2-40f8-b96a-323d1c35fc0b":{"description":"Forbidden - Tenant does not belong to your organization","content":{"application/json":{"schema":{"type":"object","required":["error"],"properties":{"error":{"type":"object","required":["code","message"],"properties":{"code":{"type":"string","description":"Error code","isRequired":true,"uniqueKey":"error.code","typeLabel":"string"},"message":{"type":"string","description":"Human-readable error message","isRequired":true,"uniqueKey":"error.message","typeLabel":"string"},"details":{"type":"string","description":"Additional error details","uniqueKey":"error.details","typeLabel":"string"}},"isRequired":true,"uniqueKey":"error","typeLabel":"object"}},"example":{"error":{"code":"UNAUTHORIZED","message":"Invalid API key","details":"The provided API key is invalid or has been revoked"}},"uniqueKey":"","typeLabel":"object"},"examples":{"Example":{"title":"Example","value":{"error":{"code":"UNAUTHORIZED","message":"Invalid API key","details":"The provided API key is invalid or has been revoked"}}}},"exampleType":"generated"}},"exampleType":"generated"},"5a301751-fc84-4cc6-a0a3-86253a0fbd67":{"description":"Too Many Requests - Rate limit exceeded for this route","content":{"application/json":{"schema":{"type":"object","required":["error"],"properties":{"error":{"type":"object","required":["code","message"],"properties":{"code":{"type":"string","description":"Error code","isRequired":true,"uniqueKey":"error.code","typeLabel":"string"},"message":{"type":"string","description":"Human-readable error message","isRequired":true,"uniqueKey":"error.message","typeLabel":"string"},"details":{"type":"string","description":"Additional error details","uniqueKey":"error.details","typeLabel":"string"}},"isRequired":true,"uniqueKey":"error","typeLabel":"object"}},"example":{"error":{"code":"UNAUTHORIZED","message":"Invalid API key","details":"The provided API key is invalid or has been revoked"}},"uniqueKey":"","typeLabel":"object"},"examples":{"Example":{"title":"Example","value":{"error":{"code":"UNAUTHORIZED","message":"Invalid API key","details":"The provided API key is invalid or has been revoked"}}}},"exampleType":"generated"}},"exampleType":"generated"},"f00c23d6-9ee6-4644-85b4-4cfa3fa8e008":{"description":"Internal Server Error","content":{"application/json":{"schema":{"type":"object","required":["error"],"properties":{"error":{"type":"object","required":["code","message"],"properties":{"code":{"type":"string","description":"Error code","isRequired":true,"uniqueKey":"error.code","typeLabel":"string"},"message":{"type":"string","description":"Human-readable error message","isRequired":true,"uniqueKey":"error.message","typeLabel":"string"},"details":{"type":"string","description":"Additional error details","uniqueKey":"error.details","typeLabel":"string"}},"isRequired":true,"uniqueKey":"error","typeLabel":"object"}},"example":{"error":{"code":"UNAUTHORIZED","message":"Invalid API key","details":"The provided API key is invalid or has been revoked"}},"uniqueKey":"","typeLabel":"object"},"examples":{"Example":{"title":"Example","value":{"error":{"code":"UNAUTHORIZED","message":"Invalid API key","details":"The provided API key is invalid or has been revoked"}}}},"exampleType":"generated"}},"exampleType":"generated"}},"security":{"ef760229-b448-4930-bdf3-28c6505a193d":{"bearerAuth":{"type":"http","scheme":"bearer","description":"Bearer token authentication. Include your API key in the Authorization header as 'Bearer YOUR_API_KEY'","scopes":[]}}},"servers":{"85e9853c-be4d-489c-ae3d-0804cd5ea855":{"url":"https://api.petrasecurity.com","description":"Production server"}},"processedSecurityOptions":[{"schemes":[{"scheme":{"type":"http","scheme":"bearer","description":"Bearer token authentication. Include your API key in the Authorization header as 'Bearer YOUR_API_KEY'","scopes":[]},"schema":{"title":"Bearer Auth","type":"string","isRequired":true,"description":"Bearer token authentication. Include your API key in the Authorization header as 'Bearer YOUR_API_KEY'","format":"bearer","typeLabel":"string\u003cbearer>","deprecated":false},"schemeName":"bearerAuth","name":"Authorization"}],"title":"bearerAuth"}]},"originalFileLocation":"api-reference/openapi.json"},"subdomain":"petrasecurity-7f411ce9","siteName":"Petra Security Docs","title":"Get Billable Users - Petra Security Docs","navMaps":{"firstHrefInVersion":{},"firstHrefInLanguage":{}},"lastModified":"2026-05-27T03:36:49.658Z","originalFileLocation":"api-reference/endpoints/get-billable-users.mdx"},"headHtml":"\u003cscript data-mint-head>(function(){var d=document.documentElement,p=null;if(!p){try{p=localStorage.getItem(\"isDarkMode\")}catch(e){}if(p==='true')p='dark';else if(p==='false')p='light';if(p!=='light'\u0026\u0026p!=='dark'\u0026\u0026p!=='system')p=\"system\"}var r=p==='system'?(matchMedia(\"(prefers-color-scheme: dark)\").matches?'dark':'light'):p;d.classList.remove(r==='dark'?'light':'dark');d.classList.add(r);d.setAttribute(\"data-theme-preference\",p)})();\u003c/script>\u003cmeta data-mint-head name=\"description\" content=\"Retrieve the list of billable users for a specific Petra tenant. A user is considered billable if they have non-empty assignedLicenseSkuIds and are not deleted (deletedAt is null).\">\u003cmeta data-mint-head name=\"application-name\" content=\"Petra Security Docs\">\u003cmeta data-mint-head name=\"generator\" content=\"Mintlify\">\u003cmeta data-mint-head name=\"robots\" content=\"index, follow\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"192x192\" href=\"/docs/mintlify-assets/_mintlify/favicons/petrasecurity-7f411ce9/cyxbo4YDwlRH7S8y/_generated/favicon/android-chrome-192x192.png\" media=\"(prefers-color-scheme: light)\">\u003clink data-mint-head rel=\"apple-touch-icon\" type=\"image/png\" sizes=\"180x180\" href=\"/docs/mintlify-assets/_mintlify/favicons/petrasecurity-7f411ce9/cyxbo4YDwlRH7S8y/_generated/favicon/apple-touch-icon.png\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"16x16\" href=\"/docs/mintlify-assets/_mintlify/favicons/petrasecurity-7f411ce9/cyxbo4YDwlRH7S8y/_generated/favicon/favicon-16x16.png\" media=\"(prefers-color-scheme: light)\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"32x32\" href=\"/docs/mintlify-assets/_mintlify/favicons/petrasecurity-7f411ce9/cyxbo4YDwlRH7S8y/_generated/favicon/favicon-32x32.png\" media=\"(prefers-color-scheme: light)\">\u003clink data-mint-head rel=\"shortcut icon\" type=\"image/x-icon\" href=\"/docs/mintlify-assets/_mintlify/favicons/petrasecurity-7f411ce9/cyxbo4YDwlRH7S8y/_generated/favicon/favicon.ico\" media=\"(prefers-color-scheme: light)\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"192x192\" href=\"/docs/mintlify-assets/_mintlify/favicons/petrasecurity-7f411ce9/cyxbo4YDwlRH7S8y/_generated/favicon-dark/android-chrome-192x192.png\" media=\"(prefers-color-scheme: dark)\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"16x16\" href=\"/docs/mintlify-assets/_mintlify/favicons/petrasecurity-7f411ce9/cyxbo4YDwlRH7S8y/_generated/favicon-dark/favicon-16x16.png\" media=\"(prefers-color-scheme: dark)\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"32x32\" href=\"/docs/mintlify-assets/_mintlify/favicons/petrasecurity-7f411ce9/cyxbo4YDwlRH7S8y/_generated/favicon-dark/favicon-32x32.png\" media=\"(prefers-color-scheme: dark)\">\u003clink data-mint-head rel=\"shortcut icon\" type=\"image/x-icon\" href=\"/docs/mintlify-assets/_mintlify/favicons/petrasecurity-7f411ce9/cyxbo4YDwlRH7S8y/_generated/favicon-dark/favicon.ico\" media=\"(prefers-color-scheme: dark)\">\u003cmeta data-mint-head property=\"og:title\" content=\"Get Billable Users - Petra Security Docs\">\u003cmeta data-mint-head property=\"og:description\" content=\"Retrieve the list of billable users for a specific Petra tenant. A user is considered billable if they have non-empty assignedLicenseSkuIds and are not deleted (deletedAt is null).\">\u003cmeta data-mint-head property=\"og:site_name\" content=\"Petra Security Docs\">\u003cmeta data-mint-head property=\"og:url\" content=\"https://www.petrasecurity.com/docs/api-reference/endpoints/get-billable-users\">\u003cmeta data-mint-head property=\"og:type\" content=\"website\">\u003cmeta data-mint-head property=\"og:image\" content=\"https://petrasecurity-7f411ce9.mintlify.site/docs/_mintlify/api/og/v2?division=Endpoints\u0026amp;title=Get+Billable+Users\u0026amp;description=Retrieve+the+list+of+billable+users+for+a+specific+Petra+tenant.+A+user+is+considered+billable+if+they+have+non-empty+assignedLicenseSkuIds+and+are+not+deleted+\u0026amp;theme=31c2f7c2d5d7b20c1ba92feb\u0026amp;signature=eb946c00c0a361102f7bb9db8d5847dee6b5ae7a4317dd6144273aa31649df8b\">\u003cmeta data-mint-head property=\"og:image:width\" content=\"1200\">\u003cmeta data-mint-head property=\"og:image:height\" content=\"630\">\u003cmeta data-mint-head name=\"twitter:card\" content=\"summary_large_image\">\u003cmeta data-mint-head name=\"twitter:title\" content=\"Get Billable Users - Petra Security Docs\">\u003cmeta data-mint-head name=\"twitter:description\" content=\"Retrieve the list of billable users for a specific Petra tenant. A user is considered billable if they have non-empty assignedLicenseSkuIds and are not deleted (deletedAt is null).\">\u003cmeta data-mint-head name=\"twitter:image\" content=\"https://petrasecurity-7f411ce9.mintlify.site/docs/_mintlify/api/og/v2?division=Endpoints\u0026amp;title=Get+Billable+Users\u0026amp;description=Retrieve+the+list+of+billable+users+for+a+specific+Petra+tenant.+A+user+is+considered+billable+if+they+have+non-empty+assignedLicenseSkuIds+and+are+not+deleted+\u0026amp;theme=31c2f7c2d5d7b20c1ba92feb\u0026amp;signature=eb946c00c0a361102f7bb9db8d5847dee6b5ae7a4317dd6144273aa31649df8b\">\u003cmeta data-mint-head name=\"twitter:image:width\" content=\"1200\">\u003cmeta data-mint-head name=\"twitter:image:height\" content=\"630\">\u003cmeta data-mint-head name=\"msapplication-config\" content=\"/docs/mintlify-assets/_mintlify/favicons/petrasecurity-7f411ce9/cyxbo4YDwlRH7S8y/_generated/favicon/browserconfig.xml\">\u003cmeta data-mint-head name=\"apple-mobile-web-app-title\" content=\"Petra Security Docs\">\u003cmeta data-mint-head name=\"msapplication-TileColor\" content=\"#AE6654\">\u003clink data-mint-head rel=\"canonical\" href=\"https://www.petrasecurity.com/docs/api-reference/endpoints/get-billable-users\">\u003clink data-mint-head rel=\"alternate\" type=\"application/xml\" href=\"/docs/sitemap.xml\">\u003clink data-mint-head rel=\"alternate\" type=\"text/markdown\" href=\"/docs/api-reference/endpoints/get-billable-users.md\">\u003cscript data-mint-head type=\"application/ld+json\">{\"@context\":\"https://schema.org\",\"@graph\":[{\"@type\":\"Organization\",\"@id\":\"https://www.petrasecurity.com/#organization\",\"name\":\"Petra Security Docs\",\"url\":\"https://www.petrasecurity.com\",\"logo\":{\"@type\":\"ImageObject\",\"url\":\"https://mintcdn.com/petrasecurity-7f411ce9/xhwggn1Webj24oba/logo/light-group.svg?fit=max\u0026auto=format\u0026n=xhwggn1Webj24oba\u0026q=85\u0026s=bcb6096cc95673da0210cd35cab62266\"}},{\"@type\":\"WebSite\",\"@id\":\"https://www.petrasecurity.com/docs#website\",\"name\":\"Petra Security Docs\",\"url\":\"https://www.petrasecurity.com/docs\",\"publisher\":{\"@id\":\"https://www.petrasecurity.com/#organization\"}},{\"@type\":\"WebPage\",\"@id\":\"https://www.petrasecurity.com/docs/api-reference/endpoints/get-billable-users#webpage\",\"url\":\"https://www.petrasecurity.com/docs/api-reference/endpoints/get-billable-users\",\"name\":\"Get Billable Users\",\"description\":\"Retrieve the list of billable users for a specific Petra tenant. A user is considered billable if they have non-empty assignedLicenseSkuIds and are not deleted (deletedAt is null).\",\"dateModified\":\"2026-05-27T03:36:49.658Z\",\"isPartOf\":{\"@id\":\"https://www.petrasecurity.com/docs#website\"},\"breadcrumb\":{\"@id\":\"https://www.petrasecurity.com/docs/api-reference/endpoints/get-billable-users#breadcrumb\"}},{\"@type\":\"BreadcrumbList\",\"@id\":\"https://www.petrasecurity.com/docs/api-reference/endpoints/get-billable-users#breadcrumb\",\"itemListElement\":[{\"@type\":\"ListItem\",\"position\":1,\"name\":\"Endpoints\",\"item\":\"https://www.petrasecurity.com/docs/api-reference/endpoints/get-tenants\"},{\"@type\":\"ListItem\",\"position\":2,\"name\":\"Get Billable Users\",\"item\":\"https://www.petrasecurity.com/docs/api-reference/endpoints/get-billable-users\"}]},{\"@type\":[\"TechArticle\",\"APIReference\"],\"@id\":\"https://www.petrasecurity.com/docs/api-reference/endpoints/get-billable-users#apireference\",\"headline\":\"Get Billable Users\",\"name\":\"Get Billable Users\",\"description\":\"Retrieve the list of billable users for a specific Petra tenant. A user is considered billable if they have non-empty assignedLicenseSkuIds and are not deleted (deletedAt is null).\",\"url\":\"https://www.petrasecurity.com/docs/api-reference/endpoints/get-billable-users\",\"mainEntityOfPage\":{\"@id\":\"https://www.petrasecurity.com/docs/api-reference/endpoints/get-billable-users#webpage\"},\"dateModified\":\"2026-05-27T03:36:49.658Z\",\"publisher\":{\"@id\":\"https://www.petrasecurity.com/#organization\"},\"isPartOf\":{\"@id\":\"https://www.petrasecurity.com/docs#website\"}}]}\u003c/script>\u003cscript data-mint-head type=\"application/ld+json\">{\"@context\":\"https://schema.org\",\"@type\":\"WebSite\",\"name\":\"Petra Security Docs\",\"creator\":{\"@type\":\"Organization\",\"name\":\"Mintlify\",\"url\":\"https://mintlify.com\"}}\u003c/script>","siteName":"Petra Security Docs","nav":{"global":{"anchors":[{"anchor":"Research","icon":"newspaper","href":"https://www.petrasecurity.com/research"},{"anchor":"Support","icon":"envelope","href":"mailto:support@petrasecurity.com"}]},"tabs":[{"tab":"Guides","pages":[{"title":"Guides","href":"/welcome"}]},{"tab":"API Reference","groups":[{"group":"API Documentation","pages":[{"title":"Introduction","href":"/api-reference/introduction"},{"title":"Authentication","href":"/api-reference/authentication"},{"title":"API Troubleshooting","href":"/api-reference/troubleshooting"}]},{"group":"Endpoints","pages":[{"title":"Get Tenants","openapi":"GET /v1/tenants","href":"/api-reference/endpoints/get-tenants"},{"title":"Get Usage","openapi":"GET /v1/usage","description":"Retrieve tenant usage stats, including billable date range and number of licensed users.","href":"/api-reference/endpoints/get-usage"},{"title":"Get Billable Users","openapi":"GET /v1/billable-users","href":"/api-reference/endpoints/get-billable-users"},{"title":"Get Incidents","openapi":"GET /v1/incidents","description":"Retrieve security incidents ordered by creation date (newest first).","href":"/api-reference/endpoints/get-incidents"},{"title":"Get Failed Attacks","openapi":"GET /v1/failed-attacks","href":"/api-reference/endpoints/get-failed-attacks"},{"title":"Get Posture Reports","openapi":"GET /v1/posture-reports","href":"/api-reference/endpoints/get-posture-reports"}]}]}]},"basePath":"","title":"Get Billable Users - Petra Security Docs","buildId":"dpl_ATnXPMW25DMPUr9VBw6kL6MfBt6T","deploymentId":"dpl_ATnXPMW25DMPUr9VBw6kL6MfBt6T","dynamics":["c2aa737661","2b790eda92","b0f84f53ff","a9bb46feb3"],"chunks":["OpenApiReferenceProvider-CNqlzjVB.js","utils-BqFiXZ79.js","cloneDeep-izs3Hzxb.js","_Uint8Array-BVIqJ90l.js","isObjectLike-C8vmzPEN.js","isArray-Dcu1dQ5t.js","utils-CnR4QBe6.js","toString-BX-iyh8G.js","isSymbol-CSH9U2Gm.js","addUniqueKeysToSchema-BY2ZM1OO.js","snippetPresets-x-8ACO8V.js","style-to-object-BY3JEAdk.js","v4-DIgz8zy6.js","ApiExamples-Ch-SJE05.js","isEqual-BfaiBbcl.js","usePlaygroundInputsStore-CqqG_0NE.js","shallow-BXrZ2b0C.js","getApiPlaygroundDisplay-n7J_wkjq.js","CodeSnippet-CQsp4vyQ.js","CodeSnippets-BfuHqvZx.js","Page-CTxrMSpo.js","getPastedJson-BjrGIK1i.js","icon-7iLZnVOC.js","MethodPill-TBS1m84e.js","DuplicateIcon-BNMrV4Vs.js","createIcon-C5kCqeU2.js","DynamicMarkdown-Bq09mRwR.js","SectionHeading-G4Bflf5Q.js","axios-vUo_bRtp.js","Markdown-BTUds0aX.js","clsx-6wHzaN2_.js","lib-DuNMoZ05.js","lib-B8HbPgcC.js","html-void-elements-mCSPHezU.js","dist-BPypQKlo.js","katex-YMM-FMeD.js","marked.esm-CZWythHk.js","AssistantPageLink-o6bee4ro.js"]}