User external properties

Overview

User external properties are represented in the 'ext' field of the user entity.
It stores options not used by the server in system processes but usable by applications, scripts, and product layer microservices.

Requests

HTTP verb Endpoint Description

GET

/rest/v1/user/ext

Getting user external properties

PUT

/rest/v1/user/ext

Replacing user external properties

PATCH

/rest/v1/user/ext

Modifying user external properties

For all requests:
Domain type: any

Getting user external properties

Returns the contents of the user account 'ext' field, excluding the 'ct' and 'lwt' fields.

The contents are arbitrary.

Request

Example request
GET /rest/v1/user/ext HTTP/1.1

Response

Example response
HTTP/1.1 200 OK

{
  "eraAppearance": {
    "color": "",
    "mode": "advanced",
    "theme": "light"
  },
  "r21adminData": {
    "mode": "advanced",
    "theme": "light"
  }
}

Replacing user external properties

Completely replaces the contents of the user account 'ext' field.

The passed contents completely replace the previous value.

The value 'null' is not saved.

The 'ct' and 'lwt' keys are filtered out.

Request

Example request
PUT /rest/v1/user/ext HTTP/1.1
Content-Type: application/json

{
  "x" => "Test X",
  "y" => 2
}

Response

Example response
HTTP/1.1 200 OK

{
  "x": "Test X"
  "y": 2
}

Modifying user external properties

Sets the contents of the user account 'ext' field.

The passed contents are merged with the previous value.
To add a value for a specific key, it is enough to pass only that key in the contents.

A key can be removed by passing the value 'null' for the object key.

The 'ct' and 'lwt' keys are filtered out.

Request

Example request
PATCH /rest/v1/user/ext HTTP/1.1
Content-Type: application/json

{
  "x" => "Test"
}

Response

Example response
HTTP/1.1 200 OK

{
  "eraAppearance": {
    "color": "",
    "mode": "advanced",
    "theme": "light"
  },
  "r21adminData": {
    "mode": "advanced",
    "theme": "light"
  },
  "x": "Test"
}