Skip to main content
Triggr reads Microsoft 365 identity-threat data from Petra Security: tenants, incidents, failed attacks and usage. One key covers every tenant in your Petra organisation.

Set up Petra Security

1

Create an API key

Sign in to the Petra portal as an Admin, go to Settings > API Keys and click Create API Key. Enter a description such as Triggr and click Create API Key again.
2

Copy the key

Copy the key, which starts with petra_. Petra shows it only once.
See Petra’s API authentication guide.

Connect it in Triggr

1

Open the configuration

Go to Integrations > Petra Security and click Configure on the Base Configuration card.
The Base Configuration card with Status Not Configured, Admin Consent Not Required and a Configure button.
2

Enter the key

Paste the key into API Key and click Save Configuration.
The Petra Security configuration window with an API Key field and its help text, an Allow insecure TLS switch under Advanced, and a Save Configuration button.

Tenant IDs and action inputs

Run List Tenants to get each tenant’s petraTenantId and microsoftTenantId. The Petra ID is also in the portal URL: app.petrasecurity.com/tenant/<petraTenantId>. Enter dates as 2026-03-01 or a UTC date-time ending in Z. Petra’s API reference describes what each action returns.

Troubleshooting

Check the key is pasted in full, starts with petra_, still exists under Settings > API Keys, and comes from the organisation that holds your tenants.
Use a tenant ID from List Tenants. Get Billable Users needs the Petra ID, not the Microsoft one.
Petra rejected a date. Use YYYY-MM-DD or a UTC date-time ending in Z.
Get Billable Users and Get Failed Attacks allow one request a minute; other actions allow 10. Spread out calls when looping over many tenants.