Authentication
Authenticate every API request with your AlertOps API key.
Every API call needs an API key. How you send it depends on the API version.
V2: api-key header
Send your key in a request header named api-key.
curl "https://api.alertops.com/api/v2/users" \
-H "api-key: <YOUR_API_KEY>" \
-H "Content-Type: application/json"- Where to find it: in the AlertOps app, open your User Profile.
- Permissions: the key inherits the roles, permissions and entitlements of that user. An Application Administrator key has full read and write access. A Basic User key is restricted.
- No API key on your profile? Contact AlertOps Support.
V1: APIKey parameter (legacy)
V1 takes the key inside the request itself.
- GET requests: add it as a query parameter, for example
?APIKey={APIKey}. - POST requests: include
"APIKey": "<YOUR_API_KEY>"in the JSON body. - Where to find it: V1 API tokens are in Account Settings.
Query strings can end up in proxy and server logs. Use V2 and the api-key header wherever you can.
Unauthorized response
A missing or invalid key returns 401 Unauthorized:
{
"reason": "Invalid API Key"
}Keep keys safe
- Treat an API key like a password. Store it in a secrets manager or environment variable, not in source code.
- Use the key of a user with only the permissions the integration needs.
- The Try it console on these pages keeps your key in this browser tab only. It is never saved or sent anywhere except api.alertops.com.