latestOpenAPI 3.1.0Apache License Version 2.02026-08-17498525913.3 KB

40169ccdec5c

api-key-controller

Save API key for user (saveApiKey)

Creates an API key for the given user and returns the token ONCE as 'ApiKey <value>'.

Available for any authorized user.

post/api/apiKey

Request body

createdTimeinteger

Entity creation timestamp in milliseconds since Unix epoch

expirationTimeinteger

Expiration time of the API key.

descriptionstring required

API Key description.

enabledboolean

Enabled/disabled API key.

expiredboolean

Indicates if the API key is expired based on current time. Returns false if expirationTime is 0 (no expiry).

Example request

{
  "id": {
    "id": "784f394c-42b6-435a-983c-b7beff2784f9",
    "entityType": "API_KEY"
  },
  "createdTime": 1746028547220,
  "tenantId": {
    "id": "784f394c-42b6-435a-983c-b7beff2784f9",
    "entityType": "TENANT"
  },
  "userId": {
    "id": "784f394c-42b6-435a-983c-b7beff2784f9",
    "entityType": "USER"
  },
  "description": "API Key description",
  "enabled": true
}

Response

OK

createdTimeinteger

Entity creation timestamp in milliseconds since Unix epoch

expirationTimeinteger

Expiration time of the API key.

descriptionstring required

API Key description.

enabledboolean

Enabled/disabled API key.

valuestring required

API key value

expiredboolean

Indicates if the API key is expired based on current time. Returns false if expirationTime is 0 (no expiry).

Example response

{
  "id": {
    "id": "784f394c-42b6-435a-983c-b7beff2784f9",
    "entityType": "API_KEY"
  },
  "createdTime": 1746028547220,
  "tenantId": {
    "id": "784f394c-42b6-435a-983c-b7beff2784f9",
    "entityType": "TENANT"
  },
  "userId": {
    "id": "784f394c-42b6-435a-983c-b7beff2784f9",
    "entityType": "USER"
  },
  "description": "API Key description",
  "enabled": true
}