Skip to content

List API keys

Request

List API keys belonging to the caller's organisation. Secrets are never returned.

Security
api_key
curl -i -X GET \
  https://coreapi.hoxton.ai/_mock/v1/api-keys \
  -H 'Authorization: YOUR_API_KEY_HERE'

Responses

OK.

Bodyapplication/json
Array [
apiKeyIdstring, (uuid)read-onlyrequired
createdAtstring, (date-time)read-only
createdBystringread-only
expiresAtstring or null, (date-time)
lastUsedAtstring or null, (date-time)read-only
namestringrequired
organisationIdstring, (uuid)read-onlyrequired
prefixstringread-onlyrequired
revokedAtstring or null, (date-time)read-only
rolestringread-only

The role whose permissions the key is granted.

siteIdsArray of strings, (uuid)read-only

Sites the key is scoped to. Populated for member and analyst keys; empty for admin and manager keys.

]
Response
[ { "apiKeyId": "37ba0474-c0bb-4910-bfb5-d6cebb614366", "createdAt": "2019-08-24T14:15:22Z", "createdBy": "string", "expiresAt": "2019-08-24T14:15:22Z", "lastUsedAt": "2019-08-24T14:15:22Z", "name": "string", "organisationId": "c9b3f279-e3b5-4204-ad99-646257417f98", "prefix": "string", "revokedAt": "2019-08-24T14:15:22Z", "role": "string", "siteIds": [] } ]