Get Tenant Keys
GET /api/v1/tenants/{tenantId}/keys
Description
Retrieve keys associated with a specific tenant.
Path Parameters
| Name | Type | Description |
|---|---|---|
tenantId | string | The ID of the tenant (path) |
Query Parameters
| Name | Type | Description |
|---|---|---|
keyByTypes | string | Allowed fields separated by comma: TENANT_PRODUCT,TENANT_SERVICE (query) |
keyByStatuses | string | Allowed fields separated by comma: ACTIVE,DISABLED,REVOKED,REFRESHED,EXPIRED (query) |
order | string | Available values: ASC, DESC (query) |
page | string | Page number (query) |
limit | string | Number of items per page (query) |
Example
GET /api/v1/tenants/{tenantId}/keys?keyByTypes=TENANT_PRODUCT,TENANT_SERVICE&keyByStatuses=ACTIVE,DISABLED&order=ASC&page=1&limit=10
Response Code: 200 - OK
Description
Request was successful.
Response Fields
| Field | Type | Description |
|---|---|---|
| status | boolean | Indicates if the operation was successful |
| data | array | Array of keys associated with the tenant |
| page | integer | Current page number |
| limit | integer | Number of items per page |
| total | integer | Total number of items |
Example
{
"status": true,
"data": [
{
"keyId": "key123",
"type": "TENANT_PRODUCT",
"status": "ACTIVE",
"createdAt": "2023-01-01T00:00:00Z"
},
{
"keyId": "key456",
"type": "TENANT_SERVICE",
"status": "DISABLED",
"createdAt": "2023-01-01T00:00:00Z"
}
],
"page": 1,
"limit": 10,
"total": 2
}
Headers
| Content-Type | Value |
|---|---|
| apiKey | {{apiKey}} |
🔑 Authentication bearer
| Param | Value | Type |
|---|---|---|
| token | {{accessCode}} | string |
LANGUAGE
CURL REQUEST
curl --request GET \
--url /api/v1/tenants/{tenantId}/keys \
--header 'accept: application/json' \
--header 'content-type: application/json'
RESPONSE
Click Try It! to start a request and see the response here!