Skip to main content

API Keys

API tokens let your scripts and automation tools authenticate to the Anzenna API. This guide walks you through generating a token, scoping its permissions, and using it to make authenticated requests.

Admin access required

API keys are managed under Settings > Access, which is available to workspace admins. If you don't see the Access section, ask a workspace admin to generate a token for you or grant you the admin role.


Generate a Token

  1. Navigate to Settings > Access and select the API Keys tab ( /u/access/api-keys).

  2. Click the Create Token ( +) button in the toolbar.

API Keys tab under Settings > Access

Step 1: Name the token

Give the token a descriptive name so you can identify it later, for example the tool or workflow that will use it (Tines Integration, Nightly Export). The name is only used for display and can't be changed after creation.

Naming a new API token

Step 2: Set permissions

Choose the minimal permissions the token needs. Use the presets to apply one access level across every scope at once, or set each scope individually:

  • None: no access (start here and grant only what's needed)

  • Read-only: fetch data without making changes

  • Read and write: fetch data and perform actions

Setting API token permissions with the Read-only preset

Permissions are granted per scope. Each scope can be set to None, Read-only, or Read and write independently:

ScopeGrants access to
AdminView and control all aspects of the platform
TrainingMonitor training completion and manage assignments
DetectionDetection events and security alerts
RiskRisk scores and risk assessments
RemediationView and set up remediation tasks
DeviceDevice information and statuses
Shadow ITUnauthorized applications and services
Password CompromiseReports of exposed or compromised passwords
OAuthOAuth applications and permissions
Browser AppBrowser extension data and activity
IdentityIdentity events, authentication activity, and breach alerts
PersonDetails about individuals in your organization
EmailEmail flows and metadata
WebhookSend webhook events

Once at least one scope is granted, click Generate Key.

Step 3: Copy your token

Anzenna displays the token value once. Copy it now and store it in a secrets manager. You won't be able to see it again. Anzenna tokens are prefixed with anzak1-.

Copying the newly generated API token
Keep your token secret

Never commit tokens to source control or paste them into public places such as GitHub, client-side code, or public repositories. If a token is exposed, delete it (see

Manage Tokens

) and generate a new one.


Use the Token

Pass the token as a bearer token in the Authorization header on every request. The API base URL is https://api.anzenna.ai.

Authorization: Bearer <your-api-token>
Example request:
curl -X POST https://api.anzenna.ai/api-key/v1/events \
-H "Content-Type: application/json" \
-H "Authorization: Bearer $ANZENNA_API_TOKEN" \
-d '{"query": "risk_score > 4.0"}'
tip

Browse the full list of endpoints and try them interactively in the

Anzenna API reference

. For an end-to-end example of enriching webhook payloads via the API, see

Webhook Notifications

.


Manage Tokens

The API Keys tab lists every token with its State, Created date, Last Used date, and Expires At date. The Last Used column is handy for spotting tokens that are no longer in active use.

  • Expiry. Every token has an Expires At date. Once a token is past that date, API calls made with it are rejected. Replace the token before it lapses to avoid interrupting your integration.

  • Revoke. To revoke a token before it expires, click the menu on its row and choose Delete Token. Deletion is immediate and cannot be undone. Any integration using that token will stop working right away.

  • Rotate. Rotate tokens periodically and delete ones that are no longer in use.


Need help? Contact

Anzenna Support

for assistance.