empty_scopes means a request to create an API key sent an empty scopes list. Read this page if you create keys from code or a provisioning script.
What happened
Route:POST /v1/keys.
The body had "scopes": []. OpenType does not create a key without scopes. No key was created.
How to fix
Request the scopes the key needs, and no more. Every scope you request must also be held by you, or the call fails withscope_exceeds_creator.
Common sets:
Duplicates are removed and the list is sorted in the response. A key’s scopes are fixed when it is created; to change them, create a new key.
Example
keys_write. The secret in the response is shown once: store it now.
201:
Related
- Scopes - every scope and the routes it unlocks.
- API keys in the console - create a key with a preset scope set.
- scope_exceeds_creator - you asked for a scope you do not hold.
- Problem codes - every code, its status, and whether a retry can help.