Creating & Managing API Keys
Create a key with the right scopes, store it safely, and revoke it when it's no longer needed
Before you begin
- You need the Admin role.
- Your plan must include API access. If it doesn't, the API Keys page isn't available. See Tenant Profiles.
Creating a key
Open Integrations and go to API Keys.
Click Create API Key.
Enter a Key name that says who uses it, for example "Power BI - energy reports".
Choose Scopes: what the key may read. Pick the minimum your integration needs.
| Scope | Lets the key read |
|---|---|
telemetry:read | Latest and historical readings |
devices:read | The device list and details |
alarms:read | Alarm rules |
Choose Application access: All applications, or limit the key to a subset (pick at least one application).
Choose an Expiry: Never expires, 30 days, 90 days, 1 year, or Custom date.
Click Create API Key.
The Your new API key dialog shows the secret, a Copy button, and a Quick test command you can run in a terminal to confirm the key works. Click Done when you've stored it.
The secret is shown only once. Copy it into a secrets manager immediately. If you lose it, rotate the key.
Least-privilege examples
| Use | Scopes | Application access |
|---|---|---|
| Energy dashboard in Power BI | telemetry:read | Energy application only |
| Asset inventory sync | devices:read | All |
| Audit of alarm configuration | alarms:read | All |
The keys table
| Column | Shows |
|---|---|
| Name | Your label |
| Key | The key's visible prefix, so you can tell keys apart |
| Scopes | What it can read |
| Applications | All, or the chosen applications |
| Status | Active, Rotating (an old secret still works for a while), or Revoked |
| Last used | Its most recent request |
| Errors (24h) | Failed requests in the last day, so you can spot a broken integration |
| Expires | When it stops working |
| Created | When it was created |
| Actions | Rotate and Revoke |
Revoking a key
Click Revoke on the key's row.
Confirm in the Revoke API key dialog.
Revocation is immediate and permanent: requests with that key get 401 from then on. To give
the integration access again, create a new key.
Revoke keys that haven't been used for months. Every unused key is a risk with no benefit.
Troubleshooting
| Symptom | Cause | Fix |
|---|---|---|
| There's no API Keys page | Your plan doesn't include API access, or you aren't an Admin | Ask your administrator |
The integration gets 401 | The key was revoked or has expired, or the header is wrong | Check Status and Expires, then the request header. See Using Your API Key |
The integration gets 403 | The key lacks a scope, or the device is outside its application access | Create a key with the right scope and applications |
| Errors (24h) keeps rising | A system is using a broken or outdated key | Find it by the key name and update it |