Authentication
Listing keys requires an API key with theapi_keys:read scope; creating and revoking keys requires api_keys:write. These scopes can only be granted to API keys, not to OAuth connections.
See API Key Authentication to create the first key in AGO.
What a key can create
A key never gives more access than it has:- Scopes: the new key can only have scopes the creating key holds. A
writescope lets it give the matchingreadscope, and only a key with*can give*. - IP allowlist: when the creating key only accepts some IP addresses, the new key gets the same allowlist by default. You can give it a narrower one, such as a single address from the same range, but not a wider one.
- Expiry: when the creating key expires, or was rotated and is in its grace period, the new key gets the same end date by default. You can choose an earlier date, but not a later one.
- Owner: the new key has the same owner as the key that creates it. Features that act as the key’s owner, such as
resolutions:write, act as that person.
apps:invoke scope cannot be created through the API: create them from the app’s page.
Create a key
The response has status
201 and contains the new key in key. Store it right away: it is returned only once.
Errors
List keys
Get a key
404 for a key outside your key’s direct managed children.
Revoke a key
is_active set to false. A revoked key cannot be restored. Returns 404 for a key outside your key’s direct managed children.