Skip to main content
Glama
Petra Security MCP Server

Petra Security MCP Server

by WYRE-AI

petra_list_billable_users

Read-onlyIdempotent

Lists the individual billable Microsoft 365 users for one tenant, with display name, UPN, mail, enabled flag, license SKU IDs, and total/projected billable counts.

Instructions

List the individual billable users for ONE tenant (users with an assigned Microsoft license that are not deleted), with display name, UPN, mail, enabled flag and license SKU IDs, plus totalBillableUsers and projectedBillableUnitsThisMonth. This is the user-level detail behind petra_get_usage. A Microsoft tenant ID is resolved to the Petra tenant ID automatically.

Tool call template

Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {
      "tenantId": "<tenantId>"
    },
    "name": "petra_list_billable_users"
  }
}

Input Schema

NameRequiredDescriptionDefault
tenantIdYesPetra tenant ID (from petra_list_tenants, or the app.petrasecurity.com/tenant/<id> URL) or the Microsoft tenant ID; Petra resolves either.
enabledOnlyNoOnly return users whose account is enabled (filtered locally). Totals still reflect Petra’s count.

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.1.0

TDQS

A4.1/5.0
Behavior4/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

Annotations already declare readOnly, idempotent, non-destructive and open-world, so the safety profile is covered. The description adds real behavioral context beyond that: only licensed, non-deleted users are included, Microsoft tenant IDs are resolved to Petra IDs automatically, and enabledOnly filters locally while totals still reflect Petra's full count — a nuance that would otherwise cause misinterpretation of results.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness4/5

Is the description appropriately sized, front-loaded, and free of redundancy?

Three dense sentences, front-loaded with the core action and scope, then the relationship to the sibling, then the ID-resolution behavior. The field enumeration is long but earns its place because no output schema exists; nothing reads as filler.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness4/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

With only two fully described parameters and no output schema, the description correctly compensates by listing return fields and clarifying totals versus filtered results. The remaining gap is operational: no mention of pagination, result caps, or rate limits for tenants with very large user counts, which matters for an open-world list tool.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters3/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema description coverage is 100%, and both parameters are fully documented there, including that tenantId accepts a Petra or Microsoft tenant ID and the local-filter behavior of enabledOnly. The description restates the tenant resolution but adds no syntax, format, or edge-case detail beyond the schema, so the baseline 3 applies.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

States a specific verb and resource (list individual billable users for ONE tenant) and narrows the population precisely: users with an assigned Microsoft license that are not deleted. It also names the sibling relationship ("user-level detail behind petra_get_usage") and enumerates the returned fields, so an agent can distinguish it from the aggregate usage tool without opening a schema.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines4/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

Gives clear context: use this when per-user billing detail is needed rather than the aggregate from petra_get_usage, and reinforces the single-tenant scope ("ONE tenant"). It stops short of explicit when-not-to-use guidance or naming which other sibling to pick for other user-related questions.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.