API key
- Go to your account page on Listen and open the Developer section. Admins can create API keys.
- Select Create API key. Copy the key. The key is shown only once.
- Use it in your request in the
x-api-keyheader.
/api/public/v1/...), such as studies, questions, wallets, and responses. It also works with the legacy endpoints (/api/public/responses, /api/public/list_surveys, and /api/public/studies/{study_id}/questions).
How keys work
- A key has the same access as the user who created it. Access checks use that user’s permissions.
- If that user is no longer a member of the organization, requests with the key return
403with the codeforbidden. - An organization can have up to 25 API keys. You can’t create another key until you delete an unused one.
- The full key is shown only once, when you create it. Listen stores only a hash of the key. If you lose a key, create a new one and delete the old one.
Revoke a key
- In the Developer section, select the delete icon next to the key.
- Select Delete to confirm.