# LitmusEdgeManager 2.31.x API Documentation/Admin Console APIs/Admin Console Settings - LE, LEM, LUNS API Docs

## Domain Settings

**GET** `{{LEM_adminURL}}/admin/v1/domain`

# Domain Settings

Returns the configured LEM domain names: `LEM_BASE_DOMAIN_NAME` (main UI) and `LEM_REMOTE_DOMAIN_NAME` (edge remote-access endpoint).
## Endpoint

```http
GET {{LEM_adminURL}}/admin/v1/domain
```
## Authentication

HTTP Basic Auth. **Username** is your API token, **password** is empty. Tokens are managed under `System > Access Control > Tokens`.
## Errors

| HTTP status         | When it happens                                                                |
|---------------------|--------------------------------------------------------------------------------|
| `400 Bad Request`   | Missing or malformed query/body parameter.                                     |
| `401 Unauthorized`  | Missing or invalid credentials.                                                |
| `403 Forbidden`     | Token lacks permission for this operation.                                     |
| `404 Not Found`     | Target entity does not exist.                                                  |
| `5xx`               | Service is unreachable, restarting, or internally errored. Inspect device logs under `System > Support`. |

> **TLS note**: edge devices use a self-signed certificate by default. Either install the device CA in your client trust store or disable certificate verification when calling this endpoint directly.


### Response

**Status**: 200 OK

```json
{
    "LEM_REMOTE_DOMAIN_NAME": {
        "name": "LEM_REMOTE_DOMAIN_NAME",
        "descr": "Edge Remote",
        "value": "10.17.3.103"
    },
    "LEM_BASE_DOMAIN_NAME": {
        "name": "LEM_BASE_DOMAIN_NAME",
        "descr": "Base UI",
        "value": "10.17.3.103"
    }
}
```

---

## SSL Settings

**GET** `{{LEM_adminURL}}/admin/v1/domain/ssl`

# SSL Settings

Returns the available SSL modes (`LETSENCRYPT_WEBROOT`, `LETSENCRYPT_DNS_CF`, `USER`, `SELFSIGNED`) with each one's `value` indicating which is currently active.
## Endpoint

```http
GET {{LEM_adminURL}}/admin/v1/domain/ssl
```
## Authentication

HTTP Basic Auth. **Username** is your API token, **password** is empty. Tokens are managed under `System > Access Control > Tokens`.
## Errors

| HTTP status         | When it happens                                                                |
|---------------------|--------------------------------------------------------------------------------|
| `400 Bad Request`   | Missing or malformed query/body parameter.                                     |
| `401 Unauthorized`  | Missing or invalid credentials.                                                |
| `403 Forbidden`     | Token lacks permission for this operation.                                     |
| `404 Not Found`     | Target entity does not exist.                                                  |
| `5xx`               | Service is unreachable, restarting, or internally errored. Inspect device logs under `System > Support`. |

> **TLS note**: edge devices use a self-signed certificate by default. Either install the device CA in your client trust store or disable certificate verification when calling this endpoint directly.


### Response

**Status**: 200 OK

```json
{
    "LETSENCRYPT_WEBROOT": {
        "name": "LETSENCRYPT_WEBROOT",
        "descr": "Let's Encrypt Web root challenge",
        "value": false
    },
    "USER": {
        "name": "USER",
        "descr": "User custom settings",
        "value": false
    },
    "SELFSIGNED": {
        "name": "SELFSIGNED",
        "descr": "Self-sighed",
        "value": true
    },
    "LETSENCRYPT_DNS_CF": {
        "name": "LETSENCRYPT_DNS_CF",
        "descr": "Let's Encrypt DNS challenge",
        "value": false
    }
}
```

---

## Update SSL Settings

**POST** `{{LEM_adminURL}}/admin/v1/domain/ssl/self-signed`

# Update SSL Settings

Switches LEM's SSL mode -- the URL path indicates the target mode (e.g. `/self-signed`, `/user`, `/letsencrypt-webroot`). The response streams nginx config validation output.
## Endpoint

```http
POST {{LEM_adminURL}}/admin/v1/domain/ssl/self-signed
```
## Authentication

HTTP Basic Auth. **Username** is your API token, **password** is empty. Tokens are managed under `System > Access Control > Tokens`.
## Response

`200 OK` -- `text/plain`. nginx configuration reload output.

## Errors

| HTTP status         | When it happens                                                                |
|---------------------|--------------------------------------------------------------------------------|
| `400 Bad Request`   | Missing or malformed query/body parameter.                                     |
| `401 Unauthorized`  | Missing or invalid credentials.                                                |
| `403 Forbidden`     | Token lacks permission for this operation.                                     |
| `404 Not Found`     | Target entity does not exist.                                                  |
| `5xx`               | Service is unreachable, restarting, or internally errored. Inspect device logs under `System > Support`. |

> **TLS note**: edge devices use a self-signed certificate by default. Either install the device CA in your client trust store or disable certificate verification when calling this endpoint directly.


### Response

**Status**: 200 OK

```plain
Updating SSL settings SELFSIGNED ...
nginx: [warn] only the last index in "index" directive should be absolute in /etc/nginx/conf.d/http/lem-ui.conf:107
nginx: [warn] duplicate MIME type "text/html" in /etc/nginx/conf.d/http/lem-ui.conf:372
nginx: [warn] duplicate MIME type "text/html" in /etc/nginx/conf.d/http/lem-ui.conf:406
nginx: [warn] duplicate MIME type "text/html" in /etc/nginx/conf.d/http/lem-ui.conf:423
nginx: the configuration file /etc/nginx/nginx.conf syntax is ok
nginx: configuration file /etc/nginx/nginx.conf test is successful
SSL settings is updated.

```

---

## Cloud Credentials

**GET** `{{LEM_adminURL}}/admin/v1/cloud-settings/credentials`

# Cloud Credentials

Returns the cloud-provider credentials configured for LEM (GCP service account, local S3, etc.).
## Endpoint

```http
GET {{LEM_adminURL}}/admin/v1/cloud-settings/credentials
```
## Authentication

HTTP Basic Auth. **Username** is your API token, **password** is empty. Tokens are managed under `System > Access Control > Tokens`.
## Errors

| HTTP status         | When it happens                                                                |
|---------------------|--------------------------------------------------------------------------------|
| `400 Bad Request`   | Missing or malformed query/body parameter.                                     |
| `401 Unauthorized`  | Missing or invalid credentials.                                                |
| `403 Forbidden`     | Token lacks permission for this operation.                                     |
| `404 Not Found`     | Target entity does not exist.                                                  |
| `5xx`               | Service is unreachable, restarting, or internally errored. Inspect device logs under `System > Support`. |

> **TLS note**: edge devices use a self-signed certificate by default. Either install the device CA in your client trust store or disable certificate verification when calling this endpoint directly.


### Response

**Status**: 200 OK

```json
[
    {
        "type": "GCP",
        "attrs": {
            "clientEmail": "dev-gfm-vm@litmus-development.iam.gserviceaccount.com",
            "creds": null,
            "projectId": "litmus-development"
        }
    },
    {
        "type": "LOCAL",
        "attrs": {
            "secretKey": null,
            "accessKey": "aaaa"
        }
    }
]
```

---

## GCP SA Key Rotation Policy

**GET** `{{LEM_adminURL}}/admin/v1/cloud-settings/gce-key-rotation-interval`

# GCP SA Key Rotation Policy

Returns the GCP service-account key rotation interval (days).
## Endpoint

```http
GET {{LEM_adminURL}}/admin/v1/cloud-settings/gce-key-rotation-interval
```
## Authentication

HTTP Basic Auth. **Username** is your API token, **password** is empty. Tokens are managed under `System > Access Control > Tokens`.
## Response

```json
{ "interval": 180 }
```

## Errors

| HTTP status         | When it happens                                                                |
|---------------------|--------------------------------------------------------------------------------|
| `400 Bad Request`   | Missing or malformed query/body parameter.                                     |
| `401 Unauthorized`  | Missing or invalid credentials.                                                |
| `403 Forbidden`     | Token lacks permission for this operation.                                     |
| `404 Not Found`     | Target entity does not exist.                                                  |
| `5xx`               | Service is unreachable, restarting, or internally errored. Inspect device logs under `System > Support`. |

> **TLS note**: edge devices use a self-signed certificate by default. Either install the device CA in your client trust store or disable certificate verification when calling this endpoint directly.


### Response

**Status**: 200 OK

```json
{
    "interval": 180
}
```

---

## Update GCP SA Key Rotation Interval

**PUT** `{{LEM_adminURL}}/admin/v1/cloud-settings/gce-key-rotation-interval`

# Update GCP SA Key Rotation Interval

Updates the GCP service-account key rotation interval.
## Endpoint

```http
PUT {{LEM_adminURL}}/admin/v1/cloud-settings/gce-key-rotation-interval
```
## Authentication

HTTP Basic Auth. **Username** is your API token, **password** is empty. Tokens are managed under `System > Access Control > Tokens`.
## Request body

```json
{ "interval": 180 }
```

## Errors

| HTTP status         | When it happens                                                                |
|---------------------|--------------------------------------------------------------------------------|
| `400 Bad Request`   | Missing or malformed query/body parameter.                                     |
| `401 Unauthorized`  | Missing or invalid credentials.                                                |
| `403 Forbidden`     | Token lacks permission for this operation.                                     |
| `404 Not Found`     | Target entity does not exist.                                                  |
| `5xx`               | Service is unreachable, restarting, or internally errored. Inspect device logs under `System > Support`. |

> **TLS note**: edge devices use a self-signed certificate by default. Either install the device CA in your client trust store or disable certificate verification when calling this endpoint directly.


### Request Body

```json
{
    "interval": 180
}
```

### Response

**Status**: 200 OK

```json
{
    "code": "S",
    "message": null,
    "messageDetails": null
}
```

---

## Storage Settings

**GET** `{{LEM_adminURL}}/admin/v1/cloud-settings/storage`

# Storage Settings

Returns LEM's object-storage configuration: `type` (`LOCAL` / `GCS` / `S3`) and `defaultBucketName`.
## Endpoint

```http
GET {{LEM_adminURL}}/admin/v1/cloud-settings/storage
```
## Authentication

HTTP Basic Auth. **Username** is your API token, **password** is empty. Tokens are managed under `System > Access Control > Tokens`.
## Errors

| HTTP status         | When it happens                                                                |
|---------------------|--------------------------------------------------------------------------------|
| `400 Bad Request`   | Missing or malformed query/body parameter.                                     |
| `401 Unauthorized`  | Missing or invalid credentials.                                                |
| `403 Forbidden`     | Token lacks permission for this operation.                                     |
| `404 Not Found`     | Target entity does not exist.                                                  |
| `5xx`               | Service is unreachable, restarting, or internally errored. Inspect device logs under `System > Support`. |

> **TLS note**: edge devices use a self-signed certificate by default. Either install the device CA in your client trust store or disable certificate verification when calling this endpoint directly.


### Response

**Status**: 200 OK

```json
{
    "type": "LOCAL",
    "defaultBucketName": ""
}
```

---

## Interfaces

**GET** `{{LEM_adminURL}}/admin/v1/system/network/interfaces`

# Interfaces

Returns the LEM host's network interfaces with DHCP flag and addresses.
## Endpoint

```http
GET {{LEM_adminURL}}/admin/v1/system/network/interfaces
```
## Authentication

HTTP Basic Auth. **Username** is your API token, **password** is empty. Tokens are managed under `System > Access Control > Tokens`.
## Errors

| HTTP status         | When it happens                                                                |
|---------------------|--------------------------------------------------------------------------------|
| `400 Bad Request`   | Missing or malformed query/body parameter.                                     |
| `401 Unauthorized`  | Missing or invalid credentials.                                                |
| `403 Forbidden`     | Token lacks permission for this operation.                                     |
| `404 Not Found`     | Target entity does not exist.                                                  |
| `5xx`               | Service is unreachable, restarting, or internally errored. Inspect device logs under `System > Support`. |

> **TLS note**: edge devices use a self-signed certificate by default. Either install the device CA in your client trust store or disable certificate verification when calling this endpoint directly.


### Response

**Status**: 200 OK

```json
[
    {
        "name": "eth0",
        "dhcp": true,
        "addresses": [
            {
                "address": "10.17.3.103/22",
                "gateway": null
            }
        ]
    }
]
```

---

## DNS

**GET** `{{LEM_adminURL}}/admin/v1/system/network/dns`

# DNS

Returns the configured DNS resolvers per interface.
## Endpoint

```http
GET {{LEM_adminURL}}/admin/v1/system/network/dns
```
## Authentication

HTTP Basic Auth. **Username** is your API token, **password** is empty. Tokens are managed under `System > Access Control > Tokens`.
## Errors

| HTTP status         | When it happens                                                                |
|---------------------|--------------------------------------------------------------------------------|
| `400 Bad Request`   | Missing or malformed query/body parameter.                                     |
| `401 Unauthorized`  | Missing or invalid credentials.                                                |
| `403 Forbidden`     | Token lacks permission for this operation.                                     |
| `404 Not Found`     | Target entity does not exist.                                                  |
| `5xx`               | Service is unreachable, restarting, or internally errored. Inspect device logs under `System > Support`. |

> **TLS note**: edge devices use a self-signed certificate by default. Either install the device CA in your client trust store or disable certificate verification when calling this endpoint directly.


### Response

**Status**: 200 OK

```json
[
    {
        "name": "eth0",
        "addresses": []
    }
]
```

---

## NTP

**GET** `{{LEM_adminURL}}/admin/v1/system/network/ntp/servers`

# NTP

Returns the configured NTP servers.
## Endpoint

```http
GET {{LEM_adminURL}}/admin/v1/system/network/ntp/servers
```
## Authentication

HTTP Basic Auth. **Username** is your API token, **password** is empty. Tokens are managed under `System > Access Control > Tokens`.
## Response

```json
[ "0.pool.ntp.org", "1.pool.ntp.org", "2.pool.ntp.org", "3.pool.ntp.org" ]
```

## Errors

| HTTP status         | When it happens                                                                |
|---------------------|--------------------------------------------------------------------------------|
| `400 Bad Request`   | Missing or malformed query/body parameter.                                     |
| `401 Unauthorized`  | Missing or invalid credentials.                                                |
| `403 Forbidden`     | Token lacks permission for this operation.                                     |
| `404 Not Found`     | Target entity does not exist.                                                  |
| `5xx`               | Service is unreachable, restarting, or internally errored. Inspect device logs under `System > Support`. |

> **TLS note**: edge devices use a self-signed certificate by default. Either install the device CA in your client trust store or disable certificate verification when calling this endpoint directly.


### Response

**Status**: 200 OK

```json
[
    "0.pool.ntp.org",
    "1.pool.ntp.org",
    "2.pool.ntp.org",
    "3.pool.ntp.org"
]
```

---

## NTP Allow List

**GET** `{{LEM_adminURL}}/admin/v1/system/network/ntp/allow-list`

# NTP Allow List

Returns the IP allow-list for the bundled NTP server -- which clients may sync from LEM.
## Endpoint

```http
GET {{LEM_adminURL}}/admin/v1/system/network/ntp/allow-list
```
## Authentication

HTTP Basic Auth. **Username** is your API token, **password** is empty. Tokens are managed under `System > Access Control > Tokens`.
## Errors

| HTTP status         | When it happens                                                                |
|---------------------|--------------------------------------------------------------------------------|
| `400 Bad Request`   | Missing or malformed query/body parameter.                                     |
| `401 Unauthorized`  | Missing or invalid credentials.                                                |
| `403 Forbidden`     | Token lacks permission for this operation.                                     |
| `404 Not Found`     | Target entity does not exist.                                                  |
| `5xx`               | Service is unreachable, restarting, or internally errored. Inspect device logs under `System > Support`. |

> **TLS note**: edge devices use a self-signed certificate by default. Either install the device CA in your client trust store or disable certificate verification when calling this endpoint directly.


### Response

**Status**: 200 OK

```json
[]
```

---

## NTP Status

**GET** `{{LEM_adminURL}}/admin/v1/system/network/ntp/status`

# NTP Status

Returns the live NTP client status: current server, stratum, reference time, system-vs-NTP skew.
## Endpoint

```http
GET {{LEM_adminURL}}/admin/v1/system/network/ntp/status
```
## Authentication

HTTP Basic Auth. **Username** is your API token, **password** is empty. Tokens are managed under `System > Access Control > Tokens`.
## Errors

| HTTP status         | When it happens                                                                |
|---------------------|--------------------------------------------------------------------------------|
| `400 Bad Request`   | Missing or malformed query/body parameter.                                     |
| `401 Unauthorized`  | Missing or invalid credentials.                                                |
| `403 Forbidden`     | Token lacks permission for this operation.                                     |
| `404 Not Found`     | Target entity does not exist.                                                  |
| `5xx`               | Service is unreachable, restarting, or internally errored. Inspect device logs under `System > Support`. |

> **TLS note**: edge devices use a self-signed certificate by default. Either install the device CA in your client trust store or disable certificate verification when calling this endpoint directly.


### Response

**Status**: 200 OK

```json
{
    "ntpStatus": "ON",
    "ntpServer": "198.137.202.32",
    "ntpStratum": "3",
    "ntpRefTime": "Fri Nov 03 20:30:00 2023",
    "ntpSystemTime": "0.000005316 seconds slow of NTP time"
}
```

---

## Proxy Settings

**GET** `{{LEM_adminURL}}/admin/v1/config`

# Proxy Settings

Returns the HTTP/HTTPS proxy configuration LEM uses for outbound connections.
## Endpoint

```http
GET {{LEM_adminURL}}/admin/v1/config
```
## Authentication

HTTP Basic Auth. **Username** is your API token, **password** is empty. Tokens are managed under `System > Access Control > Tokens`.
## Errors

| HTTP status         | When it happens                                                                |
|---------------------|--------------------------------------------------------------------------------|
| `400 Bad Request`   | Missing or malformed query/body parameter.                                     |
| `401 Unauthorized`  | Missing or invalid credentials.                                                |
| `403 Forbidden`     | Token lacks permission for this operation.                                     |
| `404 Not Found`     | Target entity does not exist.                                                  |
| `5xx`               | Service is unreachable, restarting, or internally errored. Inspect device logs under `System > Support`. |

> **TLS note**: edge devices use a self-signed certificate by default. Either install the device CA in your client trust store or disable certificate verification when calling this endpoint directly.


### Response

**Status**: 200 OK

```plain
{ "http_proxy_host": "", "http_proxy_port": "", "https_proxy_host": "", "https_proxy_port": "", "non_proxy_hosts": ""}

```

---

## Email Settings

**GET** `{{LEM_adminURL}}/admin/v1/config/email-settings`

# Email Settings

Returns LEM's SMTP configuration for outbound email (alerts, reports, user invitations).
## Endpoint

```http
GET {{LEM_adminURL}}/admin/v1/config/email-settings
```
## Authentication

HTTP Basic Auth. **Username** is your API token, **password** is empty. Tokens are managed under `System > Access Control > Tokens`.
## Errors

| HTTP status         | When it happens                                                                |
|---------------------|--------------------------------------------------------------------------------|
| `400 Bad Request`   | Missing or malformed query/body parameter.                                     |
| `401 Unauthorized`  | Missing or invalid credentials.                                                |
| `403 Forbidden`     | Token lacks permission for this operation.                                     |
| `404 Not Found`     | Target entity does not exist.                                                  |
| `5xx`               | Service is unreachable, restarting, or internally errored. Inspect device logs under `System > Support`. |

> **TLS note**: edge devices use a self-signed certificate by default. Either install the device CA in your client trust store or disable certificate verification when calling this endpoint directly.


### Response

**Status**: 200 OK

```json
{
    "smtpHost": "smtp.gmail.com",
    "smtpPort": 587,
    "smtpUsername": "aaaa@gmail.com",
    "smtpPassword": "aaaa",
    "smtpEnable": true,
    "smtpAuth": true,
    "smtpStartTlsEnable": true,
    "smtpStartTlsRequired": true,
    "smtpSendFromEmail": "no-reply@lem.com",
    "smtpSendFromName": "LEM"
}
```

---

## Update Email Settings

**POST** `{{LEM_adminURL}}/admin/v1/config/email-settings`

# Update Email Settings

Updates LEM's SMTP configuration. Send the full record -- omitted fields are reset.
## Endpoint

```http
POST {{LEM_adminURL}}/admin/v1/config/email-settings
```
## Authentication

HTTP Basic Auth. **Username** is your API token, **password** is empty. Tokens are managed under `System > Access Control > Tokens`.
## Request body

```json
{
  "smtpEnable": true,
  "smtpHost": "smtp.gmail.com",
  "smtpPort": 587,
  "smtpStartTlsEnable": true,
  "smtpStartTlsRequired": true,
  "smtpAuth": true,
  "smtpUsername": "litmusloop@gmail.com",
  "smtpPassword": "<app-password>",
  "smtpSendFromEmail": "no-reply@lem.com",
  "smtpSendFromName": "LEM"
}
```

## Errors

| HTTP status         | When it happens                                                                |
|---------------------|--------------------------------------------------------------------------------|
| `400 Bad Request`   | Missing or malformed query/body parameter.                                     |
| `401 Unauthorized`  | Missing or invalid credentials.                                                |
| `403 Forbidden`     | Token lacks permission for this operation.                                     |
| `404 Not Found`     | Target entity does not exist.                                                  |
| `5xx`               | Service is unreachable, restarting, or internally errored. Inspect device logs under `System > Support`. |

> **TLS note**: edge devices use a self-signed certificate by default. Either install the device CA in your client trust store or disable certificate verification when calling this endpoint directly.


### Request Body

```json
{
    "smtpEnable": true,
    "smtpHost": "smtp.gmail.com",
    "smtpPort": 587,
    "smtpStartTlsEnable": true,
    "smtpStartTlsRequired": true,
    "smtpAuth": true,
    "smtpUsername": "litmusloop@gmail.com",
    "smtpPassword": "qepnwhigguxjdaja",
    "smtpSendFromEmail": "no-reply@lem.com",
    "smtpSendFromName": "LEM"
}
```

### Response

**Status**: 201 Created

---

## Offline License List

**GET** `{{LEM_adminURL}}/admin/v1/licenses2/offline`

# Offline License List

Returns the offline-license activation URL + host ID. Same shape as `License Server Mgmt > Offline License Info`.
## Endpoint

```http
GET {{LEM_adminURL}}/admin/v1/licenses2/offline
```
## Authentication

HTTP Basic Auth. **Username** is your API token, **password** is empty. Tokens are managed under `System > Access Control > Tokens`.
## Errors

| HTTP status         | When it happens                                                                |
|---------------------|--------------------------------------------------------------------------------|
| `400 Bad Request`   | Missing or malformed query/body parameter.                                     |
| `401 Unauthorized`  | Missing or invalid credentials.                                                |
| `403 Forbidden`     | Token lacks permission for this operation.                                     |
| `404 Not Found`     | Target entity does not exist.                                                  |
| `5xx`               | Service is unreachable, restarting, or internally errored. Inspect device logs under `System > Support`. |

> **TLS note**: edge devices use a self-signed certificate by default. Either install the device CA in your client trust store or disable certificate verification when calling this endpoint directly.


### Response

**Status**: 200 OK

```json
{
    "activationURL": "https://litmus.activate.id/",
    "hostid": "005056b9a28e"
}
```

---

## List Available Features

**GET** `{{LEM_adminURL}}/admin/v1/licenses2/features`

# List Available Features

Returns the LEM license's available features (catalog, core) with expiry and counts.
## Endpoint

```http
GET {{LEM_adminURL}}/admin/v1/licenses2/features
```
## Authentication

HTTP Basic Auth. **Username** is your API token, **password** is empty. Tokens are managed under `System > Access Control > Tokens`.
## Errors

| HTTP status         | When it happens                                                                |
|---------------------|--------------------------------------------------------------------------------|
| `400 Bad Request`   | Missing or malformed query/body parameter.                                     |
| `401 Unauthorized`  | Missing or invalid credentials.                                                |
| `403 Forbidden`     | Token lacks permission for this operation.                                     |
| `404 Not Found`     | Target entity does not exist.                                                  |
| `5xx`               | Service is unreachable, restarting, or internally errored. Inspect device logs under `System > Support`. |

> **TLS note**: edge devices use a self-signed certificate by default. Either install the device CA in your client trust store or disable certificate verification when calling this endpoint directly.


### Response

**Status**: 200 OK

```json
[
    {
        "name": "catalog",
        "expires": "2099-12-31T00:00:00Z",
        "count": 1,
        "limited": false
    },
    {
        "name": "core",
        "expires": "2099-12-31T00:00:00Z",
        "count": 1,
        "limited": false
    }
]
```

---

## License Type

**GET** `{{LEM_adminURL}}/admin/v1/licenses2/type`

# License Type

Returns the LEM license type: `FLOATING` or `NODE_LOCKED`.
## Endpoint

```http
GET {{LEM_adminURL}}/admin/v1/licenses2/type
```
## Authentication

HTTP Basic Auth. **Username** is your API token, **password** is empty. Tokens are managed under `System > Access Control > Tokens`.
## Response

```json
{ "licenseType": "FLOATING" }
```

## Errors

| HTTP status         | When it happens                                                                |
|---------------------|--------------------------------------------------------------------------------|
| `400 Bad Request`   | Missing or malformed query/body parameter.                                     |
| `401 Unauthorized`  | Missing or invalid credentials.                                                |
| `403 Forbidden`     | Token lacks permission for this operation.                                     |
| `404 Not Found`     | Target entity does not exist.                                                  |
| `5xx`               | Service is unreachable, restarting, or internally errored. Inspect device logs under `System > Support`. |

> **TLS note**: edge devices use a self-signed certificate by default. Either install the device CA in your client trust store or disable certificate verification when calling this endpoint directly.


### Response

**Status**: 200 OK

```json
{
    "licenseType": "FLOATING"
}
```

---

## Primary License

**GET** `{{LEM_adminURL}}/admin/v1/litmus-licensing/licenses?primary=true`

# Primary License

Returns the **primary** core license. Same payload as `License Server Mgmt > Core License List` -- exposed here for admin-settings convenience.
## Endpoint

```http
GET {{LEM_adminURL}}/admin/v1/litmus-licensing/licenses?primary=true
```
## Authentication

HTTP Basic Auth. **Username** is your API token, **password** is empty. Tokens are managed under `System > Access Control > Tokens`.
## Errors

| HTTP status         | When it happens                                                                |
|---------------------|--------------------------------------------------------------------------------|
| `400 Bad Request`   | Missing or malformed query/body parameter.                                     |
| `401 Unauthorized`  | Missing or invalid credentials.                                                |
| `403 Forbidden`     | Token lacks permission for this operation.                                     |
| `404 Not Found`     | Target entity does not exist.                                                  |
| `5xx`               | Service is unreachable, restarting, or internally errored. Inspect device logs under `System > Support`. |

> **TLS note**: edge devices use a self-signed certificate by default. Either install the device CA in your client trust store or disable certificate verification when calling this endpoint directly.


### Response

**Status**: 200 OK

```json
[
    {
        "akey": "0000-1111-2222-3333",
        "expiryDate": "2024-08-02T00:00:00Z",
        "name": "litmus-scale-1y-site",
        "totalCount": 1
    }
]
```

---

## License Components

**GET** `{{LEM_adminURL}}/admin/v1/litmus-licensing/licenses?primary=false`

# License Components

Returns the **feature** licenses (non-primary). Same payload as `License Server Mgmt > Feature License List`.
## Endpoint

```http
GET {{LEM_adminURL}}/admin/v1/litmus-licensing/licenses?primary=false
```
## Authentication

HTTP Basic Auth. **Username** is your API token, **password** is empty. Tokens are managed under `System > Access Control > Tokens`.
## Errors

| HTTP status         | When it happens                                                                |
|---------------------|--------------------------------------------------------------------------------|
| `400 Bad Request`   | Missing or malformed query/body parameter.                                     |
| `401 Unauthorized`  | Missing or invalid credentials.                                                |
| `403 Forbidden`     | Token lacks permission for this operation.                                     |
| `404 Not Found`     | Target entity does not exist.                                                  |
| `5xx`               | Service is unreachable, restarting, or internally errored. Inspect device logs under `System > Support`. |

> **TLS note**: edge devices use a self-signed certificate by default. Either install the device CA in your client trust store or disable certificate verification when calling this endpoint directly.


### Response

**Status**: 200 OK

```json
[
    {
        "expiryDate": "2024-08-02T00:00:00Z",
        "name": "le-analytics",
        "totalCount": 999999
    },
    {
        "expiryDate": "2024-08-02T00:00:00Z",
        "name": "ll-core",
        "totalCount": 1
    },
    {
        "expiryDate": "2024-08-02T00:00:00Z",
        "name": "le-opcua",
        "totalCount": 999999
    },
    {
        "expiryDate": "2024-08-02T00:00:00Z",
        "name": "le-core",
        "totalCount": 999999
    },
    {
        "expiryDate": "2024-08-02T00:00:00Z",
        "name": "le-marketplace",
        "totalCount": 999999
    },
    {
        "expiryDate": "2024-08-02T00:00:00Z",
        "name": "le-devices",
        "totalCount": 999999
    },
    {
        "expiryDate": "2024-08-02T00:00:00Z",
        "name": "le-updates",
        "totalCount": 999999
    },
    {
        "expiryDate": "2024-08-02T00:00:00Z",
        "name": "le-backup",
        "totalCount": 999999
    },
    {
        "expiryDate": "2024-08-02T00:00:00Z",
        "name": "le-dt",
        "totalCount": 999999
    },
    {
        "expiryDate": "2024-08-02T00:00:00Z",
        "name": "",
        "totalCount": 1
    },
    {
        "expiryDate": "2024-08-02T00:00:00Z",
        "name": "",
        "totalCount": 1
    },
    {
        "expiryDate": "2024-08-02T00:00:00Z",
        "limited": true,
        "name": "le-tags",
        "totalCount": 50000
    }
]
```

---

## Switch License Type

**POST** `{{LEM_adminURL}}/admin/v1/licenses2/type?licenseType=FLOATING`

# Switch License Type

Switches between `FLOATING` and `NODE_LOCKED` licensing.
## Endpoint

```http
POST {{LEM_adminURL}}/admin/v1/licenses2/type?licenseType=FLOATING
```
## Authentication

HTTP Basic Auth. **Username** is your API token, **password** is empty. Tokens are managed under `System > Access Control > Tokens`.
## Errors

| HTTP status         | When it happens                                                                |
|---------------------|--------------------------------------------------------------------------------|
| `400 Bad Request`   | Missing or malformed query/body parameter.                                     |
| `401 Unauthorized`  | Missing or invalid credentials.                                                |
| `403 Forbidden`     | Token lacks permission for this operation.                                     |
| `404 Not Found`     | Target entity does not exist.                                                  |
| `5xx`               | Service is unreachable, restarting, or internally errored. Inspect device logs under `System > Support`. |

> **TLS note**: edge devices use a self-signed certificate by default. Either install the device CA in your client trust store or disable certificate verification when calling this endpoint directly.


### Response

**Status**: 200 OK

```json
{
    "code": "S",
    "message": null,
    "messageDetails": null
}
```

---

## Get DigitialTwins Roles of User

**GET** `{{LEM_adminURL}}/admin/v1/user/asset-mgmt/roles?username=demo`

# Get DigitalTwins Roles of User

Returns the **asset-management** roles granted to one LEM user (governs access to the Digital Twins / Asset Management surface).
## Endpoint

```http
GET {{LEM_adminURL}}/admin/v1/user/asset-mgmt/roles?username=demo
```
## Authentication

HTTP Basic Auth. **Username** is your API token, **password** is empty. Tokens are managed under `System > Access Control > Tokens`.
## Response

```json
[ "asset-mgmt-admin" ]
```

## Errors

| HTTP status         | When it happens                                                                |
|---------------------|--------------------------------------------------------------------------------|
| `400 Bad Request`   | Missing or malformed query/body parameter.                                     |
| `401 Unauthorized`  | Missing or invalid credentials.                                                |
| `403 Forbidden`     | Token lacks permission for this operation.                                     |
| `404 Not Found`     | Target entity does not exist.                                                  |
| `5xx`               | Service is unreachable, restarting, or internally errored. Inspect device logs under `System > Support`. |

> **TLS note**: edge devices use a self-signed certificate by default. Either install the device CA in your client trust store or disable certificate verification when calling this endpoint directly.


### Response

**Status**: 200 OK

```json
[
    "asset-mgmt-admin"
]
```

---

## Grant DigitalTwins Role to User

**POST** `{{LEM_adminURL}}/admin/v1/user/asset-mgmt/grant`

# Grant DigitalTwins Role to User

Grants an asset-management role to an LEM user.
## Endpoint

```http
POST {{LEM_adminURL}}/admin/v1/user/asset-mgmt/grant
```
## Authentication

HTTP Basic Auth. **Username** is your API token, **password** is empty. Tokens are managed under `System > Access Control > Tokens`.
## Request body

```json
{ "username": "user", "roleName": "role" }
```

## Errors

| HTTP status         | When it happens                                                                |
|---------------------|--------------------------------------------------------------------------------|
| `400 Bad Request`   | Missing or malformed query/body parameter.                                     |
| `401 Unauthorized`  | Missing or invalid credentials.                                                |
| `403 Forbidden`     | Token lacks permission for this operation.                                     |
| `404 Not Found`     | Target entity does not exist.                                                  |
| `5xx`               | Service is unreachable, restarting, or internally errored. Inspect device logs under `System > Support`. |

> **TLS note**: edge devices use a self-signed certificate by default. Either install the device CA in your client trust store or disable certificate verification when calling this endpoint directly.


### Request Body

```json
{
  "username": "user",
  "roleName": "role"
}
```

### Response

**Status**: 200 OK

```json
{
    "code": "S",
    "message": null,
    "messageDetails": null
}
```

---

## Revoke DigitalTwins Role from User

**POST** `{{LEM_adminURL}}/admin/v1/user/asset-mgmt/revoke`

# Revoke DigitalTwins Role from User

Revokes an asset-management role from an LEM user.
## Endpoint

```http
POST {{LEM_adminURL}}/admin/v1/user/asset-mgmt/revoke
```
## Authentication

HTTP Basic Auth. **Username** is your API token, **password** is empty. Tokens are managed under `System > Access Control > Tokens`.
## Request body

```json
{ "username": "user", "roleName": "role" }
```

## Errors

| HTTP status         | When it happens                                                                |
|---------------------|--------------------------------------------------------------------------------|
| `400 Bad Request`   | Missing or malformed query/body parameter.                                     |
| `401 Unauthorized`  | Missing or invalid credentials.                                                |
| `403 Forbidden`     | Token lacks permission for this operation.                                     |
| `404 Not Found`     | Target entity does not exist.                                                  |
| `5xx`               | Service is unreachable, restarting, or internally errored. Inspect device logs under `System > Support`. |

> **TLS note**: edge devices use a self-signed certificate by default. Either install the device CA in your client trust store or disable certificate verification when calling this endpoint directly.


### Request Body

```json
{
  "username": "user",
  "roleName": "role"
}
```

### Response

**Status**: 200 OK

```json
{
    "code": "S",
    "message": null,
    "messageDetails": null
}
```

---

## User List

**GET** `{{LEM_adminURL}}/admin/v1/user/list`

# User List

Returns the LEM users with username, name, email, locked flag, creation timestamp, admin flag.
## Endpoint

```http
GET {{LEM_adminURL}}/admin/v1/user/list
```
## Authentication

HTTP Basic Auth. **Username** is your API token, **password** is empty. Tokens are managed under `System > Access Control > Tokens`.
## Errors

| HTTP status         | When it happens                                                                |
|---------------------|--------------------------------------------------------------------------------|
| `400 Bad Request`   | Missing or malformed query/body parameter.                                     |
| `401 Unauthorized`  | Missing or invalid credentials.                                                |
| `403 Forbidden`     | Token lacks permission for this operation.                                     |
| `404 Not Found`     | Target entity does not exist.                                                  |
| `5xx`               | Service is unreachable, restarting, or internally errored. Inspect device logs under `System > Support`. |

> **TLS note**: edge devices use a self-signed certificate by default. Either install the device CA in your client trust store or disable certificate verification when calling this endpoint directly.


### Response

**Status**: 200 OK

```json
[
    {
        "username": "demo",
        "firstName": "demo",
        "lastName": "Litmus",
        "email": "demo@lem.local",
        "locked": false,
        "lockReason": null,
        "createdAt": 1689971989046,
        "admin": true
    }
]
```

---

## Company Teams

**GET** `{{LEM_adminURL}}/admin/v1/user/company/teams`

# Company Teams

Returns the teams across companies with user counts. Use to build a permissions matrix view.
## Endpoint

```http
GET {{LEM_adminURL}}/admin/v1/user/company/teams
```
## Authentication

HTTP Basic Auth. **Username** is your API token, **password** is empty. Tokens are managed under `System > Access Control > Tokens`.
## Errors

| HTTP status         | When it happens                                                                |
|---------------------|--------------------------------------------------------------------------------|
| `400 Bad Request`   | Missing or malformed query/body parameter.                                     |
| `401 Unauthorized`  | Missing or invalid credentials.                                                |
| `403 Forbidden`     | Token lacks permission for this operation.                                     |
| `404 Not Found`     | Target entity does not exist.                                                  |
| `5xx`               | Service is unreachable, restarting, or internally errored. Inspect device logs under `System > Support`. |

> **TLS note**: edge devices use a self-signed certificate by default. Either install the device CA in your client trust store or disable certificate verification when calling this endpoint directly.


### Response

**Status**: 200 OK

```json
[
    {
        "companyName": "ccsj",
        "teamName": "OWNER",
        "usersAmount": 1
    },
    {
        "companyName": "hardware",
        "teamName": "OWNER",
        "usersAmount": 3
    },
    {
        "companyName": "pm",
        "teamName": "OWNER",
        "usersAmount": 2
    },
    {
        "companyName": "production",
        "teamName": "OWNER",
        "usersAmount": 2
    },
    {
        "companyName": "solutions",
        "teamName": "OWNER",
        "usersAmount": 4
    }
]
```

---

## Project Roles

**GET** `{{LEM_adminURL}}/admin/v1/user/project/roles`

# Project Roles

Returns per-(company, project, team) role grants with read/write flags and user counts.
## Endpoint

```http
GET {{LEM_adminURL}}/admin/v1/user/project/roles
```
## Authentication

HTTP Basic Auth. **Username** is your API token, **password** is empty. Tokens are managed under `System > Access Control > Tokens`.
## Errors

| HTTP status         | When it happens                                                                |
|---------------------|--------------------------------------------------------------------------------|
| `400 Bad Request`   | Missing or malformed query/body parameter.                                     |
| `401 Unauthorized`  | Missing or invalid credentials.                                                |
| `403 Forbidden`     | Token lacks permission for this operation.                                     |
| `404 Not Found`     | Target entity does not exist.                                                  |
| `5xx`               | Service is unreachable, restarting, or internally errored. Inspect device logs under `System > Support`. |

> **TLS note**: edge devices use a self-signed certificate by default. Either install the device CA in your client trust store or disable certificate verification when calling this endpoint directly.


### Response

**Status**: 200 OK

```json
[
    {
        "companyName": "hardware",
        "projectId": "2prp72ljt3e2149umck473xrl",
        "projectName": "Emerson",
        "teamName": "OWNER",
        "usersAmount": 3,
        "readRole": true,
        "writeRole": true
    },
    {
        "companyName": "hardware",
        "projectId": "cse9ecyxjifs7yhizoqiydyu3",
        "projectName": "Industrial",
        "teamName": "OWNER",
        "usersAmount": 3,
        "readRole": true,
        "writeRole": true
    },
    {
        "companyName": "pm",
        "projectId": "detk20ap42y5rcvfsdfe9790",
        "projectName": "LEProduction",
        "teamName": "OWNER",
        "usersAmount": 2,
        "readRole": true,
        "writeRole": true
    },
    {
        "companyName": "production",
        "projectId": "ea13siviozaattgjd5unuoya7",
        "projectName": "GA",
        "teamName": "OWNER",
        "usersAmount": 2,
        "readRole": true,
        "writeRole": true
    },
    {
        "companyName": "production",
        "projectId": "emdlptxsqpdravb1cyzya6ws2",
        "projectName": "kafka",
        "teamName": "OWNER",
        "usersAmount": 2,
        "readRole": true,
        "writeRole": true
    },
    {
        "companyName": "solutions",
        "projectId": "462j1mq70mph31wa100t1yuxa",
        "projectName": "demo",
        "teamName": "OWNER",
        "usersAmount": 4,
        "readRole": true,
        "writeRole": true
    }
]
```

---

## Create User

**POST** `{{LEM_adminURL}}/admin/v1/user`

# Create User

Creates a new LEM user.
## Endpoint

```http
POST {{LEM_adminURL}}/admin/v1/user
```
## Authentication

HTTP Basic Auth. **Username** is your API token, **password** is empty. Tokens are managed under `System > Access Control > Tokens`.
## Request body

```json
{
  "username": "aa",
  "firstName": "ab",
  "lastName": "ac",
  "email": "a@b.com"
}
```

## Errors

| HTTP status         | When it happens                                                                |
|---------------------|--------------------------------------------------------------------------------|
| `400 Bad Request`   | Missing or malformed query/body parameter.                                     |
| `401 Unauthorized`  | Missing or invalid credentials.                                                |
| `403 Forbidden`     | Token lacks permission for this operation.                                     |
| `404 Not Found`     | Target entity does not exist.                                                  |
| `5xx`               | Service is unreachable, restarting, or internally errored. Inspect device logs under `System > Support`. |

> **TLS note**: edge devices use a self-signed certificate by default. Either install the device CA in your client trust store or disable certificate verification when calling this endpoint directly.


### Request Body

```json
{
    "username": "aa",
    "firstName": "ab",
    "lastName": "ac",
    "email": "a@b.com"
}
```

### Response

**Status**: 200 OK

```json
{
    "code": "S",
    "message": null,
    "messageDetails": null
}
```

---

## Remove User

**DELETE** `{{LEM_adminURL}}/admin/v1/user/{{LEM_admin_username}}`

# Remove User

Removes an LEM user by username.
## Endpoint

```http
DELETE {{LEM_adminURL}}/admin/v1/user/{{LEM_admin_username}}
```
## Authentication

HTTP Basic Auth. **Username** is your API token, **password** is empty. Tokens are managed under `System > Access Control > Tokens`.
## Errors

| HTTP status         | When it happens                                                                |
|---------------------|--------------------------------------------------------------------------------|
| `400 Bad Request`   | Missing or malformed query/body parameter.                                     |
| `401 Unauthorized`  | Missing or invalid credentials.                                                |
| `403 Forbidden`     | Token lacks permission for this operation.                                     |
| `404 Not Found`     | Target entity does not exist.                                                  |
| `5xx`               | Service is unreachable, restarting, or internally errored. Inspect device logs under `System > Support`. |

> **TLS note**: edge devices use a self-signed certificate by default. Either install the device CA in your client trust store or disable certificate verification when calling this endpoint directly.


### Response

**Status**: 204 No Content

---

## Create Team

**POST** `{{LEM_adminURL}}/admin/v1/user/company/team?companyName={{company_name}}`

# Create Team

Creates a new team inside one company with an initial user list.
## Endpoint

```http
POST {{LEM_adminURL}}/admin/v1/user/company/team?companyName={{company_name}}
```
## Authentication

HTTP Basic Auth. **Username** is your API token, **password** is empty. Tokens are managed under `System > Access Control > Tokens`.
## Request body

```json
{ "name": "aa", "users": [] }
```

## Errors

| HTTP status         | When it happens                                                                |
|---------------------|--------------------------------------------------------------------------------|
| `400 Bad Request`   | Missing or malformed query/body parameter.                                     |
| `401 Unauthorized`  | Missing or invalid credentials.                                                |
| `403 Forbidden`     | Token lacks permission for this operation.                                     |
| `404 Not Found`     | Target entity does not exist.                                                  |
| `5xx`               | Service is unreachable, restarting, or internally errored. Inspect device logs under `System > Support`. |

> **TLS note**: edge devices use a self-signed certificate by default. Either install the device CA in your client trust store or disable certificate verification when calling this endpoint directly.


### Request Body

```json
{
    "name": "aa",
    "users": []
}
```

### Response

**Status**: 201 Created

```json
{
    "code": "S",
    "message": null,
    "messageDetails": null
}
```

---

## Remove Team

**DELETE** `{{LEM_adminURL}}/admin/v1/user/company/team?companyName={{company_name}}&teamName={{LEM_admin_teamname}}`

# Remove Team

Removes a team from a company.
## Endpoint

```http
DELETE {{LEM_adminURL}}/admin/v1/user/company/team?companyName={{company_name}}&teamName={{LEM_admin_teamname}}
```
## Authentication

HTTP Basic Auth. **Username** is your API token, **password** is empty. Tokens are managed under `System > Access Control > Tokens`.
## Errors

| HTTP status         | When it happens                                                                |
|---------------------|--------------------------------------------------------------------------------|
| `400 Bad Request`   | Missing or malformed query/body parameter.                                     |
| `401 Unauthorized`  | Missing or invalid credentials.                                                |
| `403 Forbidden`     | Token lacks permission for this operation.                                     |
| `404 Not Found`     | Target entity does not exist.                                                  |
| `5xx`               | Service is unreachable, restarting, or internally errored. Inspect device logs under `System > Support`. |

> **TLS note**: edge devices use a self-signed certificate by default. Either install the device CA in your client trust store or disable certificate verification when calling this endpoint directly.


### Response

**Status**: 204 No Content

---

## Mange Project Teams

**POST** `{{LEM_adminURL}}/admin/v1/user/project/grant/{{project_id}}`

# Manage Project Teams

Grants or updates a team's role in one project. Despite the Postman item's typo (`Mange`), the underlying call is `manage`.
## Endpoint

```http
POST {{LEM_adminURL}}/admin/v1/user/project/grant/{{project_id}}
```
## Authentication

HTTP Basic Auth. **Username** is your API token, **password** is empty. Tokens are managed under `System > Access Control > Tokens`.
## Request body

```json
{ "role": "Write", "teamName": "bb" }
```

## Errors

| HTTP status         | When it happens                                                                |
|---------------------|--------------------------------------------------------------------------------|
| `400 Bad Request`   | Missing or malformed query/body parameter.                                     |
| `401 Unauthorized`  | Missing or invalid credentials.                                                |
| `403 Forbidden`     | Token lacks permission for this operation.                                     |
| `404 Not Found`     | Target entity does not exist.                                                  |
| `5xx`               | Service is unreachable, restarting, or internally errored. Inspect device logs under `System > Support`. |

> **TLS note**: edge devices use a self-signed certificate by default. Either install the device CA in your client trust store or disable certificate verification when calling this endpoint directly.


### Request Body

```json
{
    "role": "Write",
    "teamName": "bb"
}
```

### Response

**Status**: 201 Created

```json
{
    "code": "S",
    "message": null,
    "messageDetails": null
}
```

---

## Get Tokens

**GET** `{{LEM_adminURL}}/admin/v1/long-term-token`

# Get Tokens

Returns the long-term tokens issued by LEM with metadata (name, hash, expiry, admin flag, scopes).
## Endpoint

```http
GET {{LEM_adminURL}}/admin/v1/long-term-token
```
## Authentication

HTTP Basic Auth. **Username** is your API token, **password** is empty. Tokens are managed under `System > Access Control > Tokens`.
## Errors

| HTTP status         | When it happens                                                                |
|---------------------|--------------------------------------------------------------------------------|
| `400 Bad Request`   | Missing or malformed query/body parameter.                                     |
| `401 Unauthorized`  | Missing or invalid credentials.                                                |
| `403 Forbidden`     | Token lacks permission for this operation.                                     |
| `404 Not Found`     | Target entity does not exist.                                                  |
| `5xx`               | Service is unreachable, restarting, or internally errored. Inspect device logs under `System > Support`. |

> **TLS note**: edge devices use a self-signed certificate by default. Either install the device CA in your client trust store or disable certificate verification when calling this endpoint directly.


### Response

**Status**: 200 OK

```json
[
    {
        "hash": "607008cf1c784a0dd56fe521d4a775e8",
        "name": "apiTokenAdmin",
        "expiresAt": 1724264785000,
        "createdOn": 1692728811000,
        "updatedOn": 1692728811000,
        "scopes": [],
        "valid": true,
        "admin": true
    },
    {
        "hash": "d0533b8f17bb58fc5387ced1c3b6cfc3",
        "name": "LEMexternal",
        "expiresAt": 1724264926000,
        "createdOn": 1692728960000,
        "updatedOn": 1692728960000,
        "scopes": [
            {
                "companyName": "solutions",
                "projectId": null,
                "deviceGroups": null
            }
        ],
        "valid": true,
        "admin": false
    },
    {
        "hash": "ec88905611e667b7baa781c8bf990a18",
        "name": "kafka",
        "expiresAt": 1723059790000,
        "createdOn": 1691523814000,
        "updatedOn": 1691523814000,
        "scopes": [],
        "valid": true,
        "admin": true
    }
]
```

---

## Create Admin Token

**POST** `{{LEM_adminURL}}/admin/v1/long-term-token`

# Create Admin Token

Creates a new long-term token with **admin** scope (full LEM access). The token value is returned **once** -- save it immediately.
## Endpoint

```http
POST {{LEM_adminURL}}/admin/v1/long-term-token
```
## Authentication

HTTP Basic Auth. **Username** is your API token, **password** is empty. Tokens are managed under `System > Access Control > Tokens`.
## Request body

```json
{
  "name": "AB",
  "expiresAt": 1730930379577,
  "admin": true,
  "scopes": []
}
```

## Response

```json
{ "token": "Weaaah87E4TqXbQ9NF8Qc6hVzW9iZ9lC" }
```

## Errors

| HTTP status         | When it happens                                                                |
|---------------------|--------------------------------------------------------------------------------|
| `400 Bad Request`   | Missing or malformed query/body parameter.                                     |
| `401 Unauthorized`  | Missing or invalid credentials.                                                |
| `403 Forbidden`     | Token lacks permission for this operation.                                     |
| `404 Not Found`     | Target entity does not exist.                                                  |
| `5xx`               | Service is unreachable, restarting, or internally errored. Inspect device logs under `System > Support`. |

> **TLS note**: edge devices use a self-signed certificate by default. Either install the device CA in your client trust store or disable certificate verification when calling this endpoint directly.


### Request Body

```json
{
    "name": "AB",
    "expiresAt": 1730930379577,
    "admin": true,
    "scopes": []
}
```

### Response

**Status**: 200 OK

```json
{
    "token": "Weaaah87E4TqXbQ9NF8Qc6hVzW9iZ9lC"
}
```

---

## Create Token With Scopes

**POST** `{{LEM_adminURL}}/admin/v1/long-term-token`

# Create Token With Scopes

Creates a long-term token scoped to specific companies. Pass `admin: false` and populate `scopes[]` with `(companyName, projectId, deviceGroups)` entries.
## Endpoint

```http
POST {{LEM_adminURL}}/admin/v1/long-term-token
```
## Authentication

HTTP Basic Auth. **Username** is your API token, **password** is empty. Tokens are managed under `System > Access Control > Tokens`.
## Request body

```json
{
  "name": "BBB",
  "expiresAt": 1730930431370,
  "admin": false,
  "scopes": [
    { "companyName": "solutions", "projectId": null, "deviceGroups": null },
    { "companyName": "production", "projectId": null, "deviceGroups": null }
  ]
}
```

## Errors

| HTTP status         | When it happens                                                                |
|---------------------|--------------------------------------------------------------------------------|
| `400 Bad Request`   | Missing or malformed query/body parameter.                                     |
| `401 Unauthorized`  | Missing or invalid credentials.                                                |
| `403 Forbidden`     | Token lacks permission for this operation.                                     |
| `404 Not Found`     | Target entity does not exist.                                                  |
| `5xx`               | Service is unreachable, restarting, or internally errored. Inspect device logs under `System > Support`. |

> **TLS note**: edge devices use a self-signed certificate by default. Either install the device CA in your client trust store or disable certificate verification when calling this endpoint directly.


### Request Body

```json
{
    "name": "BBB",
    "expiresAt": 1730930431370,
    "admin": false,
    "scopes": [
        {
            "companyName": "solutions",
            "projectId": null,
            "deviceGroups": null
        },
        {
            "companyName": "production",
            "projectId": null,
            "deviceGroups": null
        }
    ]
}
```

### Response

**Status**: 200 OK

```json
{
    "token": "vkzCL0qTqzE7PTeOnzJ0QsDQxD2BU5qi"
}
```

---

## Create Token For All Companies

**POST** `{{LEM_adminURL}}/admin/v1/long-term-token`

# Create Token For All Companies

Creates a long-term token with a wildcard scope (`companyName: null` = every company).
## Endpoint

```http
POST {{LEM_adminURL}}/admin/v1/long-term-token
```
## Authentication

HTTP Basic Auth. **Username** is your API token, **password** is empty. Tokens are managed under `System > Access Control > Tokens`.
## Request body

```json
{
  "name": "CA",
  "expiresAt": 1730930530855,
  "admin": false,
  "scopes": [ { "companyName": null, "projectId": null, "deviceGroups": null } ]
}
```

## Errors

| HTTP status         | When it happens                                                                |
|---------------------|--------------------------------------------------------------------------------|
| `400 Bad Request`   | Missing or malformed query/body parameter.                                     |
| `401 Unauthorized`  | Missing or invalid credentials.                                                |
| `403 Forbidden`     | Token lacks permission for this operation.                                     |
| `404 Not Found`     | Target entity does not exist.                                                  |
| `5xx`               | Service is unreachable, restarting, or internally errored. Inspect device logs under `System > Support`. |

> **TLS note**: edge devices use a self-signed certificate by default. Either install the device CA in your client trust store or disable certificate verification when calling this endpoint directly.


### Request Body

```json
{
    "name": "CA",
    "expiresAt": 1730930530855,
    "admin": false,
    "scopes": [
        {
            "companyName": null,
            "projectId": null,
            "deviceGroups": null
        }
    ]
}
```

### Response

**Status**: 200 OK

```json
{
    "token": "6V5VzEDo6GrH50L6iQOpfEIspJeZ6cxC"
}
```

---

## Remove Token

**DELETE** `{{LEM_adminURL}}/admin/v1/long-term-token/{{LEM_admin_tokenhash}}`

# Remove Token

Removes a long-term token by its hash.
## Endpoint

```http
DELETE {{LEM_adminURL}}/admin/v1/long-term-token/{{LEM_admin_tokenhash}}
```
## Authentication

HTTP Basic Auth. **Username** is your API token, **password** is empty. Tokens are managed under `System > Access Control > Tokens`.
## Errors

| HTTP status         | When it happens                                                                |
|---------------------|--------------------------------------------------------------------------------|
| `400 Bad Request`   | Missing or malformed query/body parameter.                                     |
| `401 Unauthorized`  | Missing or invalid credentials.                                                |
| `403 Forbidden`     | Token lacks permission for this operation.                                     |
| `404 Not Found`     | Target entity does not exist.                                                  |
| `5xx`               | Service is unreachable, restarting, or internally errored. Inspect device logs under `System > Support`. |

> **TLS note**: edge devices use a self-signed certificate by default. Either install the device CA in your client trust store or disable certificate verification when calling this endpoint directly.


### Response

**Status**: 204 No Content

---

## Upgrade Log

**GET** `{{LEM_adminURL}}/admin/v1/upgrade/log`

# Upgrade Log

Returns the current LEM upgrade-process status and recent log messages.
## Endpoint

```http
GET {{LEM_adminURL}}/admin/v1/upgrade/log
```
## Authentication

HTTP Basic Auth. **Username** is your API token, **password** is empty. Tokens are managed under `System > Access Control > Tokens`.
## Errors

| HTTP status         | When it happens                                                                |
|---------------------|--------------------------------------------------------------------------------|
| `400 Bad Request`   | Missing or malformed query/body parameter.                                     |
| `401 Unauthorized`  | Missing or invalid credentials.                                                |
| `403 Forbidden`     | Token lacks permission for this operation.                                     |
| `404 Not Found`     | Target entity does not exist.                                                  |
| `5xx`               | Service is unreachable, restarting, or internally errored. Inspect device logs under `System > Support`. |

> **TLS note**: edge devices use a self-signed certificate by default. Either install the device CA in your client trust store or disable certificate verification when calling this endpoint directly.


### Response

**Status**: 200 OK

```json
{
    "status": 0,
    "statusMessage": "Upgrade process is not running",
    "name": null,
    "messages": []
}
```

---

## Current Version

**GET** `{{LEM_adminURL}}/admin/v1/upgrade/current-version`

# Current Version

Returns the currently installed LEM version including a per-component version breakdown (UI / admin-console / others).
## Endpoint

```http
GET {{LEM_adminURL}}/admin/v1/upgrade/current-version
```
## Authentication

HTTP Basic Auth. **Username** is your API token, **password** is empty. Tokens are managed under `System > Access Control > Tokens`.
## Errors

| HTTP status         | When it happens                                                                |
|---------------------|--------------------------------------------------------------------------------|
| `400 Bad Request`   | Missing or malformed query/body parameter.                                     |
| `401 Unauthorized`  | Missing or invalid credentials.                                                |
| `403 Forbidden`     | Token lacks permission for this operation.                                     |
| `404 Not Found`     | Target entity does not exist.                                                  |
| `5xx`               | Service is unreachable, restarting, or internally errored. Inspect device logs under `System > Support`. |

> **TLS note**: edge devices use a self-signed certificate by default. Either install the device CA in your client trust store or disable certificate verification when calling this endpoint directly.


### Response

**Status**: 200 OK

```json
{
    "name": "current",
    "product": "generic",
    "description": "Litmus Edge Manager",
    "version": "2.14.0",
    "checksum": "",
    "uploadChecksum": null,
    "size": 0,
    "createdAt": 1695403640000,
    "appliedAt": 1695406269000,
    "components": [
        {
            "name": "edgemanager-UI",
            "description": "Litmus Edge Manager UI",
            "version": "0.100.5"
        },
        {
            "name": "edgemanager-admin-console",
            "description": "Litmus Edge Manager Admin console",
            "version": "0.86.1"
        },
        {
            "name": "edgemanager-mqtt-bind",
            "description": "Litmus Edge Manager MQTT service",
            "version": "2.14.2"
        },
        {
            "name": "edgemanager-clickhouse-sink",
            "description": "Litmus Edge Manager Clickhouse service",
            "version": "2.14.2"
        },
        {
            "name": "edgemanager-jobs",
            "description": "Litmus Edge Manager jobs service",
            "version": "2.14.10"
        },
        {
            "name": "edgemanager-cfg",
            "description": "Litmus Edge Manager configuration service",
            "version": "2.14.9"
        },
        {
            "name": "edgemanager-admin-api",
            "description": "Litmus Edge Manager Admin console API",
            "version": "2.14.9"
        },
        {
            "name": "edgemanager-api",
            "description": "Litmus Edge Manager API",
            "version": "a-2.14.17"
        },
        {
            "name": "edgemanager-mpcs-ui",
            "description": "Litmus Edge Manager Marketplace Catalog UI",
            "version": "0.23.12"
        },
        {
            "name": "edgemanager-mpcs-api",
            "description": "Litmus Edge Manager Marketplace Catalog",
            "version": "0.10.6"
        },
        {
            "name": "edgemanager-mpcs-rbac",
            "description": "Litmus Edge Manager Marketplace Catalog RBAC",
            "version": "0.2.1"
        },
        {
            "name": "edgemanager-activation",
            "description": "Litmus Edge Manager Activation API",
            "version": "2.14.4"
        },
        {
            "name": "edgemanager-alerts",
            "description": "Litmus Edge Manager Alerts API",
            "version": "2.14.1"
        },
        {
            "name": "edgemanager-emq-auth",
            "description": "MQTT authorization service",
            "version": "2.14.1"
        },
        {
            "name": "edgemanager-licensing",
            "description": "Litmus Edge Manager License service",
            "version": "1.7.6"
        },
        {
            "name": "edgemanager-consul",
            "description": "Litmus Edge Manager Hashicorp Consul",
            "version": "0.5.1"
        },
        {
            "name": "edgemanager-vault",
            "description": "Litmus Edge Manager Hashicorp Vault",
            "version": "0.6.14"
        },
        {
            "name": "edgemanager-kafka",
            "description": "Litmus Edge Manager Apache Kafka",
            "version": "0.2.11"
        },
        {
            "name": "emqx",
            "description": "MQTT server",
            "version": "4.4.19"
        },
        {
            "name": "minio",
            "description": "S3 compatible storage",
            "version": ""
        },
        {
            "name": "fabio",
            "description": "Fabio load balancer",
            "version": "1.5.13-go1.13.4"
        },
        {
            "name": "docker-registry",
            "description": "Docker-registry",
            "version": "2.7.1"
        },
        {
            "name": "edgemanager-nomad",
            "description": "Litmus Edge Manager Hashicorp Nomad",
            "version": "0.8.10"
        },
        {
            "name": "edgemanager-hazelcast",
            "description": "Litmus Edge Manager Hazelcast IMDG ",
            "version": "0.1.6"
        },
        {
            "name": "clickhouse",
            "description": "Clickhouse database",
            "version": "23.3.4.17"
        },
        {
            "name": "edgemanager-keycloak",
            "description": "Litmus Edge Manager Apache Keycloak",
            "version": "0.9.3"
        },
        {
            "name": "grafana",
            "description": "Grafana",
            "version": "9.3.4"
        },
        {
            "name": "grafana-clickhouse-plugin",
            "description": "Grafana clickhouse plugin",
            "version": "2.5.3"
        }
    ]
}
```

---

## Upgrade List

**GET** `{{LEM_adminURL}}/admin/v1/upgrade/list`

# Upgrade List

Returns the available upgrade bundles (`.upd` files uploaded to LEM but not yet applied).
## Endpoint

```http
GET {{LEM_adminURL}}/admin/v1/upgrade/list
```
## Authentication

HTTP Basic Auth. **Username** is your API token, **password** is empty. Tokens are managed under `System > Access Control > Tokens`.
## Errors

| HTTP status         | When it happens                                                                |
|---------------------|--------------------------------------------------------------------------------|
| `400 Bad Request`   | Missing or malformed query/body parameter.                                     |
| `401 Unauthorized`  | Missing or invalid credentials.                                                |
| `403 Forbidden`     | Token lacks permission for this operation.                                     |
| `404 Not Found`     | Target entity does not exist.                                                  |
| `5xx`               | Service is unreachable, restarting, or internally errored. Inspect device logs under `System > Support`. |

> **TLS note**: edge devices use a self-signed certificate by default. Either install the device CA in your client trust store or disable certificate verification when calling this endpoint directly.


### Response

**Status**: 200 OK

```json
[
    {
        "name": "edgemanager-2.14.0",
        "product": "generic",
        "description": "Litmus Edge Manager",
        "version": "2.14.0",
        "checksum": "4c1b79933c5bbe3dbabdbfe722a1ff61f9b010a9cc47cfa1c8a076f8aa43eda0",
        "uploadChecksum": "921843642343189f4eb26a8411a3f7443f0ba533543ce1ac6673045040dd5405",
        "size": 3309598720,
        "createdAt": 1695404414000,
        "appliedAt": 0,
        "components": [
            {
                "name": "edgemanager-UI",
                "description": "Litmus Edge Manager UI",
                "version": "0.100.5"
            },
            {
                "name": "edgemanager-admin-console",
                "description": "Litmus Edge Manager Admin console",
                "version": "0.86.1"
            },
            {
                "name": "edgemanager-mqtt-bind",
                "description": "Litmus Edge Manager MQTT service",
                "version": "2.14.2"
            },
            {
                "name": "edgemanager-clickhouse-sink",
                "description": "Litmus Edge Manager Clickhouse service",
                "version": "2.14.2"
            },
            {
                "name": "edgemanager-jobs",
                "description": "Litmus Edge Manager jobs service",
                "version": "2.14.10"
            },
            {
                "name": "edgemanager-cfg",
                "description": "Litmus Edge Manager configuration service",
                "version": "2.14.9"
            },
            {
                "name": "edgemanager-admin-api",
                "description": "Litmus Edge Manager Admin console API",
                "version": "2.14.9"
            },
            {
                "name": "edgemanager-api",
                "description": "Litmus Edge Manager API",
                "version": "a-2.14.17"
            },
            {
                "name": "edgemanager-mpcs-ui",
                "description": "Litmus Edge Manager Marketplace Catalog UI",
                "version": "0.23.12"
            },
            {
                "name": "edgemanager-mpcs-api",
                "description": "Litmus Edge Manager Marketplace Catalog",
                "version": "0.10.6"
            },
            {
                "name": "edgemanager-mpcs-rbac-api",
                "description": "Litmus Edge Manager Marketplace Catalog RBAC",
                "version": "0.2.1"
            },
            {
                "name": "edgemanager-activation",
                "description": "Litmus Edge Manager Activation API",
                "version": "2.14.4"
            },
            {
                "name": "edgemanager-alerts",
                "description": "Litmus Edge Manager Alerts API",
                "version": "2.14.1"
            },
            {
                "name": "edgemanager-emq-auth",
                "description": "MQTT authorization service",
                "version": "2.14.1"
            },
            {
                "name": "edgemanager-consul",
                "description": "Litmus Edge Manager Hashicorp Consul",
                "version": "0.5.1"
            },
            {
                "name": "edgemanager-vault",
                "description": "Litmus Edge Manager Hashicorp Vault",
                "version": "0.6.14"
            },
            {
                "name": "edgemanager-kafka",
                "description": "Litmus Edge Manager Apache Kafka",
                "version": "0.2.11"
            },
            {
                "name": "fabio",
                "description": "Fabio load balancer",
                "version": "1.5.13-go1.13.4"
            },
            {
                "name": "docker-registry",
                "description": "Docker-registry",
                "version": "2.7.1"
            },
            {
                "name": "edgemanager-nomad",
                "description": "Litmus Edge Manager Hashicorp Nomad",
                "version": "0.8.10"
            },
            {
                "name": "clickhouse",
                "description": "Clickhouse database",
                "version": "23.3.4.17"
            },
            {
                "name": "edgemanager-hazelcast",
                "description": "Litmus Edge Manager Hazelcast IMDG ",
                "version": "0.1.6"
            },
            {
                "name": "edgemanager-keycloak",
                "description": "Litmus Edge Manager Apache Keycloak",
                "version": "0.9.3"
            },
            {
                "name": "grafana",
                "description": "Grafana",
                "version": "9.3.4"
            },
            {
                "name": "grafana-clickhouse-plugin",
                "description": "Grafana clickhouse plugin",
                "version": "2.5.3"
            },
            {
                "name": "edgemanager-remote",
                "description": "Litmus Edge Manager remote access",
                "version": "0.2.33"
            }
        ]
    }
]
```

---

## Upload UPD File

**POST** `{{LEM_adminURL}}/admin/v1/upgrade`

# Upload UPD File

Uploads a LEM upgrade bundle (`.upd`). Multipart -- one binary file part.
## Endpoint

```http
POST {{LEM_adminURL}}/admin/v1/upgrade
```
## Authentication

HTTP Basic Auth. **Username** is your API token, **password** is empty. Tokens are managed under `System > Access Control > Tokens`.
## Request body

Multipart form-data with one binary file part (`.upd` archive).

## Errors

| HTTP status         | When it happens                                                                |
|---------------------|--------------------------------------------------------------------------------|
| `400 Bad Request`   | Missing or malformed query/body parameter.                                     |
| `401 Unauthorized`  | Missing or invalid credentials.                                                |
| `403 Forbidden`     | Token lacks permission for this operation.                                     |
| `404 Not Found`     | Target entity does not exist.                                                  |
| `5xx`               | Service is unreachable, restarting, or internally errored. Inspect device logs under `System > Support`. |

> **TLS note**: edge devices use a self-signed certificate by default. Either install the device CA in your client trust store or disable certificate verification when calling this endpoint directly.


### Request Body

---

## Current Version

**GET** `{{LEM_adminURL}}/admin/v1/upgrade/current-version`

# Current Version

Returns the currently installed LEM version + per-component breakdown. Same payload as `Upgrade > Current Version`, exposed here for support workflows.
## Endpoint

```http
GET {{LEM_adminURL}}/admin/v1/upgrade/current-version
```
## Authentication

HTTP Basic Auth. **Username** is your API token, **password** is empty. Tokens are managed under `System > Access Control > Tokens`.
## Errors

| HTTP status         | When it happens                                                                |
|---------------------|--------------------------------------------------------------------------------|
| `400 Bad Request`   | Missing or malformed query/body parameter.                                     |
| `401 Unauthorized`  | Missing or invalid credentials.                                                |
| `403 Forbidden`     | Token lacks permission for this operation.                                     |
| `404 Not Found`     | Target entity does not exist.                                                  |
| `5xx`               | Service is unreachable, restarting, or internally errored. Inspect device logs under `System > Support`. |

> **TLS note**: edge devices use a self-signed certificate by default. Either install the device CA in your client trust store or disable certificate verification when calling this endpoint directly.


### Response

**Status**: 200 OK

```json
{
    "name": "current",
    "product": "generic",
    "description": "Litmus Edge Manager",
    "version": "2.14.0",
    "checksum": "",
    "uploadChecksum": null,
    "size": 0,
    "createdAt": 1695403640000,
    "appliedAt": 1695406269000,
    "components": [
        {
            "name": "edgemanager-UI",
            "description": "Litmus Edge Manager UI",
            "version": "0.100.5"
        },
        {
            "name": "edgemanager-admin-console",
            "description": "Litmus Edge Manager Admin console",
            "version": "0.86.1"
        },
        {
            "name": "edgemanager-mqtt-bind",
            "description": "Litmus Edge Manager MQTT service",
            "version": "2.14.2"
        },
        {
            "name": "edgemanager-clickhouse-sink",
            "description": "Litmus Edge Manager Clickhouse service",
            "version": "2.14.2"
        },
        {
            "name": "edgemanager-jobs",
            "description": "Litmus Edge Manager jobs service",
            "version": "2.14.10"
        },
        {
            "name": "edgemanager-cfg",
            "description": "Litmus Edge Manager configuration service",
            "version": "2.14.9"
        },
        {
            "name": "edgemanager-admin-api",
            "description": "Litmus Edge Manager Admin console API",
            "version": "2.14.9"
        },
        {
            "name": "edgemanager-api",
            "description": "Litmus Edge Manager API",
            "version": "a-2.14.17"
        },
        {
            "name": "edgemanager-mpcs-ui",
            "description": "Litmus Edge Manager Marketplace Catalog UI",
            "version": "0.23.12"
        },
        {
            "name": "edgemanager-mpcs-api",
            "description": "Litmus Edge Manager Marketplace Catalog",
            "version": "0.10.6"
        },
        {
            "name": "edgemanager-mpcs-rbac",
            "description": "Litmus Edge Manager Marketplace Catalog RBAC",
            "version": "0.2.1"
        },
        {
            "name": "edgemanager-activation",
            "description": "Litmus Edge Manager Activation API",
            "version": "2.14.4"
        },
        {
            "name": "edgemanager-alerts",
            "description": "Litmus Edge Manager Alerts API",
            "version": "2.14.1"
        },
        {
            "name": "edgemanager-emq-auth",
            "description": "MQTT authorization service",
            "version": "2.14.1"
        },
        {
            "name": "edgemanager-licensing",
            "description": "Litmus Edge Manager License service",
            "version": "1.7.6"
        },
        {
            "name": "edgemanager-consul",
            "description": "Litmus Edge Manager Hashicorp Consul",
            "version": "0.5.1"
        },
        {
            "name": "edgemanager-vault",
            "description": "Litmus Edge Manager Hashicorp Vault",
            "version": "0.6.14"
        },
        {
            "name": "edgemanager-kafka",
            "description": "Litmus Edge Manager Apache Kafka",
            "version": "0.2.11"
        },
        {
            "name": "emqx",
            "description": "MQTT server",
            "version": "4.4.19"
        },
        {
            "name": "minio",
            "description": "S3 compatible storage",
            "version": ""
        },
        {
            "name": "fabio",
            "description": "Fabio load balancer",
            "version": "1.5.13-go1.13.4"
        },
        {
            "name": "docker-registry",
            "description": "Docker-registry",
            "version": "2.7.1"
        },
        {
            "name": "edgemanager-nomad",
            "description": "Litmus Edge Manager Hashicorp Nomad",
            "version": "0.8.10"
        },
        {
            "name": "edgemanager-hazelcast",
            "description": "Litmus Edge Manager Hazelcast IMDG ",
            "version": "0.1.6"
        },
        {
            "name": "clickhouse",
            "description": "Clickhouse database",
            "version": "23.3.4.17"
        },
        {
            "name": "edgemanager-keycloak",
            "description": "Litmus Edge Manager Apache Keycloak",
            "version": "0.9.3"
        },
        {
            "name": "grafana",
            "description": "Grafana",
            "version": "9.3.4"
        },
        {
            "name": "grafana-clickhouse-plugin",
            "description": "Grafana clickhouse plugin",
            "version": "2.5.3"
        }
    ]
}
```

---

## Run LEM Validation Script

**POST** `{{LEM_adminURL}}/admin/v1/system/lem-validate`

# Run LEM Validation Script

Runs LEM's self-validation suite. Returns a per-check report with HTTP status / TCP probe / etc. results.
## Endpoint

```http
POST {{LEM_adminURL}}/admin/v1/system/lem-validate
```
## Authentication

HTTP Basic Auth. **Username** is your API token, **password** is empty. Tokens are managed under `System > Access Control > Tokens`.
## Errors

| HTTP status         | When it happens                                                                |
|---------------------|--------------------------------------------------------------------------------|
| `400 Bad Request`   | Missing or malformed query/body parameter.                                     |
| `401 Unauthorized`  | Missing or invalid credentials.                                                |
| `403 Forbidden`     | Token lacks permission for this operation.                                     |
| `404 Not Found`     | Target entity does not exist.                                                  |
| `5xx`               | Service is unreachable, restarting, or internally errored. Inspect device logs under `System > Support`. |

> **TLS note**: edge devices use a self-signed certificate by default. Either install the device CA in your client trust store or disable certificate verification when calling this endpoint directly.


### Response

**Status**: 200 OK

```json
{
    "results": [
        {
            "duration": 6158674,
            "err": null,
            "expected": [
                "200"
            ],
            "found": [
                "200"
            ],
            "human": "",
            "meta": null,
            "property": "status",
            "resource-id": "http://127.0.0.1:18123",
            "resource-type": "HTTP",
            "result": 0,
            "successful": true,
            "summary-line": "HTTP: http://127.0.0.1:18123: status: matches expectation: [200]",
            "test-type": 0,
            "title": ""
        },
        {
            "duration": 616501,
            "err": null,
            "expected": [
                "true"
            ],
            "found": [
                "true"
            ],
            "human": "",
            "meta": null,
            "property": "exists",
            "resource-id": "dummy0",
            "resource-type": "Interface",
            "result": 0,
            "successful": true,
            "summary-line": "Interface: dummy0: exists: matches expectation: [true]",
            "test-type": 0,
            "title": ""
        },
        {
            "duration": 925067,
            "err": null,
            "expected": [
                "[\"169.254.1.1/32\"]"
            ],
            "found": [
                "[\"169.254.1.1/32\",\"fe80::947e:e8ff:febd:8bf8/64\"]"
            ],
            "human": "",
            "meta": null,
            "property": "addrs",
            "resource-id": "dummy0",
            "resource-type": "Interface",
            "result": 0,
            "successful": true,
            "summary-line": "Interface: dummy0: addrs: matches expectation: [[\"169.254.1.1/32\"]]",
            "test-type": 0,
            "title": ""
        },
        {
            "duration": 14996800,
            "err": null,
            "expected": [
                "200"
            ],
            "found": [
                "200"
            ],
            "human": "",
            "meta": null,
            "property": "status",
            "resource-id": "https://127.0.0.1:8446/tabix",
            "resource-type": "HTTP",
            "result": 0,
            "successful": true,
            "summary-line": "HTTP: https://127.0.0.1:8446/tabix: status: matches expectation: [200]",
            "test-type": 0,
            "title": ""
        },
        {
            "duration": 16982233,
            "err": null,
            "expected": [
                "200"
            ],
            "found": [
                "200"
            ],
            "human": "",
            "meta": null,
            "property": "status",
            "resource-id": "https://127.0.0.1/admin-ui/assets/version.json",
            "resource-type": "HTTP",
            "result": 0,
            "successful": true,
            "summary-line": "HTTP: https://127.0.0.1/admin-ui/assets/version.json: status: matches expectation: [200]",
            "test-type": 0,
            "title": ""
        },
        {
            "duration": 19646780,
            "err": null,
            "expected": [
                "0"
            ],
            "found": [
                "0"
            ],
            "human": "",
            "meta": null,
            "property": "exit-status",
            "resource-id": "/usr/bin/sudo /sbin/modprobe wireguard",
            "resource-type": "Command",
            "result": 0,
            "successful": true,
            "summary-line": "Command: /usr/bin/sudo /sbin/modprobe wireguard: exit-status: matches expectation: [0]",
            "test-type": 0,
            "title": ""
        },
        {
            "duration": 33954819,
            "err": null,
            "expected": [
                "0"
            ],
            "found": [
                "0"
            ],
            "human": "",
            "meta": null,
            "property": "exit-status",
            "resource-id": "/usr/bin/sudo  /sbin/iptables -nL | grep -q \"Chain DOCKER\"",
            "resource-type": "Command",
            "result": 0,
            "successful": true,
            "summary-line": "Command: /usr/bin/sudo  /sbin/iptables -nL | grep -q \"Chain DOCKER\": exit-status: matches expectation: [0]",
            "test-type": 0,
            "title": ""
        },
        {
            "duration": 37229845,
            "err": null,
            "expected": [
                "0"
            ],
            "found": [
                "0"
            ],
            "human": "",
            "meta": null,
            "property": "exit-status",
            "resource-id": "/opt/lem/bin/lem-nomad-job-status.sh",
            "resource-type": "Command",
            "result": 0,
            "successful": true,
            "summary-line": "Command: /opt/lem/bin/lem-nomad-job-status.sh: exit-status: matches expectation: [0]",
            "test-type": 0,
            "title": ""
        },
        {
            "duration": 42612,
            "err": null,
            "expected": [
                "docker-registry true",
                "fabio true",
                "lem-activation true",
                "lem-api true",
                "lem-binds true",
                "lem-emq-auth true",
                "lem-jobs true",
                "lem-mpcs true",
                "lem-alerts true",
                "grafana true",
                "prometheus true"
            ],
            "found": [
                "docker-registry true",
                "fabio true",
                "grafana true",
                "lem-activation true",
                "lem-alerts true",
                "lem-api true",
                "lem-binds true",
                "lem-emq-auth true",
                "lem-jobs true",
                "lem-mpcs true",
                "prometheus true"
            ],
            "human": "",
            "meta": null,
            "property": "stdout",
            "resource-id": "/opt/lem/bin/lem-nomad-job-status.sh",
            "resource-type": "Command",
            "result": 0,
            "successful": true,
            "summary-line": "Command: /opt/lem/bin/lem-nomad-job-status.sh: stdout: matches expectation: [docker-registry true fabio true lem-activation true lem-api true lem-binds true lem-emq-auth true lem-jobs true lem-mpcs true lem-alerts true grafana true prometheus true]",
            "test-type": 2,
            "title": ""
        },
        {
            "duration": 17685529,
            "err": null,
            "expected": [
                "true"
            ],
            "found": [
                "true"
            ],
            "human": "",
            "meta": null,
            "property": "enabled",
            "resource-id": "kafka",
            "resource-type": "Service",
            "result": 0,
            "successful": true,
            "summary-line": "Service: kafka: enabled: matches expectation: [true]",
            "test-type": 0,
            "title": ""
        },
        {
            "duration": 40245624,
            "err": null,
            "expected": [
                "true"
            ],
            "found": [
                "true"
            ],
            "human": "",
            "meta": null,
            "property": "running",
            "resource-id": "kafka",
            "resource-type": "Service",
            "result": 0,
            "successful": true,
            "summary-line": "Service: kafka: running: matches expectation: [true]",
            "test-type": 0,
            "title": ""
        },
        {
            "duration": 18418381,
            "err": null,
            "expected": [
                "true"
            ],
            "found": [
                "true"
            ],
            "human": "",
            "meta": null,
            "property": "enabled",
            "resource-id": "lem-admin",
            "resource-type": "Service",
            "result": 0,
            "successful": true,
            "summary-line": "Service: lem-admin: enabled: matches expectation: [true]",
            "test-type": 0,
            "title": ""
        },
        {
            "duration": 42883758,
            "err": null,
            "expected": [
                "true"
            ],
            "found": [
                "true"
            ],
            "human": "",
            "meta": null,
            "property": "running",
            "resource-id": "lem-admin",
            "resource-type": "Service",
            "result": 0,
            "successful": true,
            "summary-line": "Service: lem-admin: running: matches expectation: [true]",
            "test-type": 0,
            "title": ""
        },
        {
            "duration": 18486504,
            "err": null,
            "expected": [
                "true"
            ],
            "found": [
                "true"
            ],
            "human": "",
            "meta": null,
            "property": "enabled",
            "resource-id": "zookeeper",
            "resource-type": "Service",
            "result": 0,
            "successful": true,
            "summary-line": "Service: zookeeper: enabled: matches expectation: [true]",
            "test-type": 0,
            "title": ""
        },
        {
            "duration": 43807444,
            "err": null,
            "expected": [
                "true"
            ],
            "found": [
                "true"
            ],
            "human": "",
            "meta": null,
            "property": "running",
            "resource-id": "zookeeper",
            "resource-type": "Service",
            "result": 0,
            "successful": true,
            "summary-line": "Service: zookeeper: running: matches expectation: [true]",
            "test-type": 0,
            "title": ""
        },
        {
            "duration": 21278518,
            "err": null,
            "expected": [
                "true"
            ],
            "found": [
                "true"
            ],
            "human": "",
            "meta": null,
            "property": "enabled",
            "resource-id": "lem-remote",
            "resource-type": "Service",
            "result": 0,
            "successful": true,
            "summary-line": "Service: lem-remote: enabled: matches expectation: [true]",
            "test-type": 0,
            "title": ""
        },
        {
            "duration": 42833298,
            "err": null,
            "expected": [
                "true"
            ],
            "found": [
                "true"
            ],
            "human": "",
            "meta": null,
            "property": "running",
            "resource-id": "lem-remote",
            "resource-type": "Service",
            "result": 0,
            "successful": true,
            "summary-line": "Service: lem-remote: running: matches expectation: [true]",
            "test-type": 0,
            "title": ""
        },
        {
            "duration": 26996312,
            "err": null,
            "expected": [
                "true"
            ],
            "found": [
                "true"
            ],
            "human": "",
            "meta": null,
            "property": "enabled",
            "resource-id": "netdata",
            "resource-type": "Service",
            "result": 0,
            "successful": true,
            "summary-line": "Service: netdata: enabled: matches expectation: [true]",
            "test-type": 0,
            "title": ""
        },
        {
            "duration": 39923684,
            "err": null,
            "expected": [
                "true"
            ],
            "found": [
                "true"
            ],
            "human": "",
            "meta": null,
            "property": "running",
            "resource-id": "netdata",
            "resource-type": "Service",
            "result": 0,
            "successful": true,
            "summary-line": "Service: netdata: running: matches expectation: [true]",
            "test-type": 0,
            "title": ""
        },
        {
            "duration": 22344152,
            "err": null,
            "expected": [
                "true"
            ],
            "found": [
                "true"
            ],
            "human": "",
            "meta": null,
            "property": "enabled",
            "resource-id": "vault-server",
            "resource-type": "Service",
            "result": 0,
            "successful": true,
            "summary-line": "Service: vault-server: enabled: matches expectation: [true]",
            "test-type": 0,
            "title": ""
        },
        {
            "duration": 42985221,
            "err": null,
            "expected": [
                "true"
            ],
            "found": [
                "true"
            ],
            "human": "",
            "meta": null,
            "property": "running",
            "resource-id": "vault-server",
            "resource-type": "Service",
            "result": 0,
            "successful": true,
            "summary-line": "Service: vault-server: running: matches expectation: [true]",
            "test-type": 0,
            "title": ""
        },
        {
            "duration": 27903982,
            "err": null,
            "expected": [
                "true"
            ],
            "found": [
                "true"
            ],
            "human": "",
            "meta": null,
            "property": "enabled",
            "resource-id": "docker",
            "resource-type": "Service",
            "result": 0,
            "successful": true,
            "summary-line": "Service: docker: enabled: matches expectation: [true]",
            "test-type": 0,
            "title": ""
        },
        {
            "duration": 38857200,
            "err": null,
            "expected": [
                "true"
            ],
            "found": [
                "true"
            ],
            "human": "",
            "meta": null,
            "property": "running",
            "resource-id": "docker",
            "resource-type": "Service",
            "result": 0,
            "successful": true,
            "summary-line": "Service: docker: running: matches expectation: [true]",
            "test-type": 0,
            "title": ""
        },
        {
            "duration": 32542650,
            "err": null,
            "expected": [
                "true"
            ],
            "found": [
                "true"
            ],
            "human": "",
            "meta": null,
            "property": "enabled",
            "resource-id": "consul-template",
            "resource-type": "Service",
            "result": 0,
            "successful": true,
            "summary-line": "Service: consul-template: enabled: matches expectation: [true]",
            "test-type": 0,
            "title": ""
        },
        {
            "duration": 37968255,
            "err": null,
            "expected": [
                "true"
            ],
            "found": [
                "true"
            ],
            "human": "",
            "meta": null,
            "property": "running",
            "resource-id": "consul-template",
            "resource-type": "Service",
            "result": 0,
            "successful": true,
            "summary-line": "Service: consul-template: running: matches expectation: [true]",
            "test-type": 0,
            "title": ""
        },
        {
            "duration": 36395138,
            "err": null,
            "expected": [
                "true"
            ],
            "found": [
                "true"
            ],
            "human": "",
            "meta": null,
            "property": "enabled",
            "resource-id": "chrony",
            "resource-type": "Service",
            "result": 0,
            "successful": true,
            "summary-line": "Service: chrony: enabled: matches expectation: [true]",
            "test-type": 0,
            "title": ""
        },
        {
            "duration": 36753768,
            "err": null,
            "expected": [
                "true"
            ],
            "found": [
                "true"
            ],
            "human": "",
            "meta": null,
            "property": "running",
            "resource-id": "chrony",
            "resource-type": "Service",
            "result": 0,
            "successful": true,
            "summary-line": "Service: chrony: running: matches expectation: [true]",
            "test-type": 0,
            "title": ""
        },
        {
            "duration": 33865513,
            "err": null,
            "expected": [
                "true"
            ],
            "found": [
                "true"
            ],
            "human": "",
            "meta": null,
            "property": "enabled",
            "resource-id": "nomad-server",
            "resource-type": "Service",
            "result": 0,
            "successful": true,
            "summary-line": "Service: nomad-server: enabled: matches expectation: [true]",
            "test-type": 0,
            "title": ""
        },
        {
            "duration": 39213129,
            "err": null,
            "expected": [
                "true"
            ],
            "found": [
                "true"
            ],
            "human": "",
            "meta": null,
            "property": "running",
            "resource-id": "nomad-server",
            "resource-type": "Service",
            "result": 0,
            "successful": true,
            "summary-line": "Service: nomad-server: running: matches expectation: [true]",
            "test-type": 0,
            "title": ""
        },
        {
            "duration": 41366386,
            "err": null,
            "expected": [
                "true"
            ],
            "found": [
                "true"
            ],
            "human": "",
            "meta": null,
            "property": "enabled",
            "resource-id": "nginx",
            "resource-type": "Service",
            "result": 0,
            "successful": true,
            "summary-line": "Service: nginx: enabled: matches expectation: [true]",
            "test-type": 0,
            "title": ""
        },
        {
            "duration": 34190858,
            "err": null,
            "expected": [
                "true"
            ],
            "found": [
                "true"
            ],
            "human": "",
            "meta": null,
            "property": "running",
            "resource-id": "nginx",
            "resource-type": "Service",
            "result": 0,
            "successful": true,
            "summary-line": "Service: nginx: running: matches expectation: [true]",
            "test-type": 0,
            "title": ""
        },
        {
            "duration": 37436057,
            "err": null,
            "expected": [
                "true"
            ],
            "found": [
                "true"
            ],
            "human": "",
            "meta": null,
            "property": "enabled",
            "resource-id": "consul-server",
            "resource-type": "Service",
            "result": 0,
            "successful": true,
            "summary-line": "Service: consul-server: enabled: matches expectation: [true]",
            "test-type": 0,
            "title": ""
        },
        {
            "duration": 38373401,
            "err": null,
            "expected": [
                "true"
            ],
            "found": [
                "true"
            ],
            "human": "",
            "meta": null,
            "property": "running",
            "resource-id": "consul-server",
            "resource-type": "Service",
            "result": 0,
            "successful": true,
            "summary-line": "Service: consul-server: running: matches expectation: [true]",
            "test-type": 0,
            "title": ""
        },
        {
            "duration": 42657098,
            "err": null,
            "expected": [
                "true"
            ],
            "found": [
                "true"
            ],
            "human": "",
            "meta": null,
            "property": "enabled",
            "resource-id": "lem-cfg",
            "resource-type": "Service",
            "result": 0,
            "successful": true,
            "summary-line": "Service: lem-cfg: enabled: matches expectation: [true]",
            "test-type": 0,
            "title": ""
        },
        {
            "duration": 34502475,
            "err": null,
            "expected": [
                "true"
            ],
            "found": [
                "true"
            ],
            "human": "",
            "meta": null,
            "property": "running",
            "resource-id": "lem-cfg",
            "resource-type": "Service",
            "result": 0,
            "successful": true,
            "summary-line": "Service: lem-cfg: running: matches expectation: [true]",
            "test-type": 0,
            "title": ""
        },
        {
            "duration": 45052658,
            "err": null,
            "expected": [
                "true"
            ],
            "found": [
                "true"
            ],
            "human": "",
            "meta": null,
            "property": "enabled",
            "resource-id": "keycloak",
            "resource-type": "Service",
            "result": 0,
            "successful": true,
            "summary-line": "Service: keycloak: enabled: matches expectation: [true]",
            "test-type": 0,
            "title": ""
        },
        {
            "duration": 34613067,
            "err": null,
            "expected": [
                "true"
            ],
            "found": [
                "true"
            ],
            "human": "",
            "meta": null,
            "property": "running",
            "resource-id": "keycloak",
            "resource-type": "Service",
            "result": 0,
            "successful": true,
            "summary-line": "Service: keycloak: running: matches expectation: [true]",
            "test-type": 0,
            "title": ""
        },
        {
            "duration": 7436,
            "err": null,
            "expected": [
                "true"
            ],
            "found": [
                "true"
            ],
            "human": "",
            "meta": null,
            "property": "listening",
            "resource-id": "tcp6:8114",
            "resource-type": "Port",
            "result": 0,
            "successful": true,
            "summary-line": "Port: tcp6:8114: listening: matches expectation: [true]",
            "test-type": 0,
            "title": ""
        },
        {
            "duration": 5958,
            "err": null,
            "expected": [
                "[]"
            ],
            "found": [
                "[\"::\"]"
            ],
            "human": "",
            "meta": null,
            "property": "ip",
            "resource-id": "tcp6:8114",
            "resource-type": "Port",
            "result": 0,
            "successful": true,
            "summary-line": "Port: tcp6:8114: ip: matches expectation: [[]]",
            "test-type": 0,
            "title": ""
        },
        {
            "duration": 6610,
            "err": null,
            "expected": [
                "true"
            ],
            "found": [
                "true"
            ],
            "human": "",
            "meta": null,
            "property": "listening",
            "resource-id": "tcp:19000",
            "resource-type": "Port",
            "result": 0,
            "successful": true,
            "summary-line": "Port: tcp:19000: listening: matches expectation: [true]",
            "test-type": 0,
            "title": ""
        },
        {
            "duration": 12570,
            "err": null,
            "expected": [
                "[\"0.0.0.0\"]"
            ],
            "found": [
                "[\"0.0.0.0\"]"
            ],
            "human": "",
            "meta": null,
            "property": "ip",
            "resource-id": "tcp:19000",
            "resource-type": "Port",
            "result": 0,
            "successful": true,
            "summary-line": "Port: tcp:19000: ip: matches expectation: [[\"0.0.0.0\"]]",
            "test-type": 0,
            "title": ""
        },
        {
            "duration": 3478,
            "err": null,
            "expected": [
                "true"
            ],
            "found": [
                "true"
            ],
            "human": "",
            "meta": null,
            "property": "listening",
            "resource-id": "tcp:18123",
            "resource-type": "Port",
            "result": 0,
            "successful": true,
            "summary-line": "Port: tcp:18123: listening: matches expectation: [true]",
            "test-type": 0,
            "title": ""
        },
        {
            "duration": 6190,
            "err": null,
            "expected": [
                "[\"0.0.0.0\"]"
            ],
            "found": [
                "[\"0.0.0.0\"]"
            ],
            "human": "",
            "meta": null,
            "property": "ip",
            "resource-id": "tcp:18123",
            "resource-type": "Port",
            "result": 0,
            "successful": true,
            "summary-line": "Port: tcp:18123: ip: matches expectation: [[\"0.0.0.0\"]]",
            "test-type": 0,
            "title": ""
        },
        {
            "duration": 2842,
            "err": null,
            "expected": [
                "true"
            ],
            "found": [
                "true"
            ],
            "human": "",
            "meta": null,
            "property": "listening",
            "resource-id": "tcp:8113",
            "resource-type": "Port",
            "result": 0,
            "successful": true,
            "summary-line": "Port: tcp:8113: listening: matches expectation: [true]",
            "test-type": 0,
            "title": ""
        },
        {
            "duration": 6215,
            "err": null,
            "expected": [
                "[\"0.0.0.0\"]"
            ],
            "found": [
                "[\"0.0.0.0\"]"
            ],
            "human": "",
            "meta": null,
            "property": "ip",
            "resource-id": "tcp:8113",
            "resource-type": "Port",
            "result": 0,
            "successful": true,
            "summary-line": "Port: tcp:8113: ip: matches expectation: [[\"0.0.0.0\"]]",
            "test-type": 0,
            "title": ""
        },
        {
            "duration": 3073,
            "err": null,
            "expected": [
                "true"
            ],
            "found": [
                "true"
            ],
            "human": "",
            "meta": null,
            "property": "listening",
            "resource-id": "udp:51820",
            "resource-type": "Port",
            "result": 0,
            "successful": true,
            "summary-line": "Port: udp:51820: listening: matches expectation: [true]",
            "test-type": 0,
            "title": ""
        },
        {
            "duration": 6570,
            "err": null,
            "expected": [
                "[\"0.0.0.0\"]"
            ],
            "found": [
                "[\"0.0.0.0\"]"
            ],
            "human": "",
            "meta": null,
            "property": "ip",
            "resource-id": "udp:51820",
            "resource-type": "Port",
            "result": 0,
            "successful": true,
            "summary-line": "Port: udp:51820: ip: matches expectation: [[\"0.0.0.0\"]]",
            "test-type": 0,
            "title": ""
        },
        {
            "duration": 3025,
            "err": null,
            "expected": [
                "true"
            ],
            "found": [
                "true"
            ],
            "human": "",
            "meta": null,
            "property": "listening",
            "resource-id": "tcp6:5701",
            "resource-type": "Port",
            "result": 0,
            "successful": true,
            "summary-line": "Port: tcp6:5701: listening: matches expectation: [true]",
            "test-type": 0,
            "title": ""
        },
        {
            "duration": 4195,
            "err": null,
            "expected": [
                "[]"
            ],
            "found": [
                "[\"::\"]"
            ],
            "human": "",
            "meta": null,
            "property": "ip",
            "resource-id": "tcp6:5701",
            "resource-type": "Port",
            "result": 0,
            "successful": true,
            "summary-line": "Port: tcp6:5701: ip: matches expectation: [[]]",
            "test-type": 0,
            "title": ""
        },
        {
            "duration": 2897,
            "err": null,
            "expected": [
                "true"
            ],
            "found": [
                "true"
            ],
            "human": "",
            "meta": null,
            "property": "listening",
            "resource-id": "tcp6:19092",
            "resource-type": "Port",
            "result": 0,
            "successful": true,
            "summary-line": "Port: tcp6:19092: listening: matches expectation: [true]",
            "test-type": 0,
            "title": ""
        },
        {
            "duration": 3476,
            "err": null,
            "expected": [
                "[]"
            ],
            "found": [
                "[\"::\"]"
            ],
            "human": "",
            "meta": null,
            "property": "ip",
            "resource-id": "tcp6:19092",
            "resource-type": "Port",
            "result": 0,
            "successful": true,
            "summary-line": "Port: tcp6:19092: ip: matches expectation: [[]]",
            "test-type": 0,
            "title": ""
        },
        {
            "duration": 2730,
            "err": null,
            "expected": [
                "true"
            ],
            "found": [
                "true"
            ],
            "human": "",
            "meta": null,
            "property": "listening",
            "resource-id": "tcp:443",
            "resource-type": "Port",
            "result": 0,
            "successful": true,
            "summary-line": "Port: tcp:443: listening: matches expectation: [true]",
            "test-type": 0,
            "title": ""
        },
        {
            "duration": 11239,
            "err": null,
            "expected": [
                "[\"0.0.0.0\"]"
            ],
            "found": [
                "[\"0.0.0.0\"]"
            ],
            "human": "",
            "meta": null,
            "property": "ip",
            "resource-id": "tcp:443",
            "resource-type": "Port",
            "result": 0,
            "successful": true,
            "summary-line": "Port: tcp:443: ip: matches expectation: [[\"0.0.0.0\"]]",
            "test-type": 0,
            "title": ""
        },
        {
            "duration": 4066,
            "err": null,
            "expected": [
                "true"
            ],
            "found": [
                "true"
            ],
            "human": "",
            "meta": null,
            "property": "listening",
            "resource-id": "tcp6:4646",
            "resource-type": "Port",
            "result": 0,
            "successful": true,
            "summary-line": "Port: tcp6:4646: listening: matches expectation: [true]",
            "test-type": 0,
            "title": ""
        },
        {
            "duration": 4116,
            "err": null,
            "expected": [
                "[]"
            ],
            "found": [
                "[\"::\"]"
            ],
            "human": "",
            "meta": null,
            "property": "ip",
            "resource-id": "tcp6:4646",
            "resource-type": "Port",
            "result": 0,
            "successful": true,
            "summary-line": "Port: tcp6:4646: ip: matches expectation: [[]]",
            "test-type": 0,
            "title": ""
        },
        {
            "duration": 3122,
            "err": null,
            "expected": [
                "true"
            ],
            "found": [
                "true"
            ],
            "human": "",
            "meta": null,
            "property": "listening",
            "resource-id": "tcp:19999",
            "resource-type": "Port",
            "result": 0,
            "successful": true,
            "summary-line": "Port: tcp:19999: listening: matches expectation: [true]",
            "test-type": 0,
            "title": ""
        },
        {
            "duration": 6305,
            "err": null,
            "expected": [
                "[\"127.0.0.1\"]"
            ],
            "found": [
                "[\"127.0.0.1\"]"
            ],
            "human": "",
            "meta": null,
            "property": "ip",
            "resource-id": "tcp:19999",
            "resource-type": "Port",
            "result": 0,
            "successful": true,
            "summary-line": "Port: tcp:19999: ip: matches expectation: [[\"127.0.0.1\"]]",
            "test-type": 0,
            "title": ""
        },
        {
            "duration": 2626,
            "err": null,
            "expected": [
                "true"
            ],
            "found": [
                "true"
            ],
            "human": "",
            "meta": null,
            "property": "listening",
            "resource-id": "tcp:19004",
            "resource-type": "Port",
            "result": 0,
            "successful": true,
            "summary-line": "Port: tcp:19004: listening: matches expectation: [true]",
            "test-type": 0,
            "title": ""
        },
        {
            "duration": 5569,
            "err": null,
            "expected": [
                "[\"0.0.0.0\"]"
            ],
            "found": [
                "[\"0.0.0.0\"]"
            ],
            "human": "",
            "meta": null,
            "property": "ip",
            "resource-id": "tcp:19004",
            "resource-type": "Port",
            "result": 0,
            "successful": true,
            "summary-line": "Port: tcp:19004: ip: matches expectation: [[\"0.0.0.0\"]]",
            "test-type": 0,
            "title": ""
        },
        {
            "duration": 3140,
            "err": null,
            "expected": [
                "true"
            ],
            "found": [
                "true"
            ],
            "human": "",
            "meta": null,
            "property": "listening",
            "resource-id": "tcp:80",
            "resource-type": "Port",
            "result": 0,
            "successful": true,
            "summary-line": "Port: tcp:80: listening: matches expectation: [true]",
            "test-type": 0,
            "title": ""
        },
        {
            "duration": 4952,
            "err": null,
            "expected": [
                "[\"0.0.0.0\"]"
            ],
            "found": [
                "[\"0.0.0.0\"]"
            ],
            "human": "",
            "meta": null,
            "property": "ip",
            "resource-id": "tcp:80",
            "resource-type": "Port",
            "result": 0,
            "successful": true,
            "summary-line": "Port: tcp:80: ip: matches expectation: [[\"0.0.0.0\"]]",
            "test-type": 0,
            "title": ""
        },
        {
            "duration": 2543,
            "err": null,
            "expected": [
                "true"
            ],
            "found": [
                "true"
            ],
            "human": "",
            "meta": null,
            "property": "listening",
            "resource-id": "tcp:3306",
            "resource-type": "Port",
            "result": 0,
            "successful": true,
            "summary-line": "Port: tcp:3306: listening: matches expectation: [true]",
            "test-type": 0,
            "title": ""
        },
        {
            "duration": 5826,
            "err": null,
            "expected": [
                "[\"0.0.0.0\"]"
            ],
            "found": [
                "[\"0.0.0.0\"]"
            ],
            "human": "",
            "meta": null,
            "property": "ip",
            "resource-id": "tcp:3306",
            "resource-type": "Port",
            "result": 0,
            "successful": true,
            "summary-line": "Port: tcp:3306: ip: matches expectation: [[\"0.0.0.0\"]]",
            "test-type": 0,
            "title": ""
        },
        {
            "duration": 2801,
            "err": null,
            "expected": [
                "true"
            ],
            "found": [
                "true"
            ],
            "human": "",
            "meta": null,
            "property": "listening",
            "resource-id": "tcp6:2181",
            "resource-type": "Port",
            "result": 0,
            "successful": true,
            "summary-line": "Port: tcp6:2181: listening: matches expectation: [true]",
            "test-type": 0,
            "title": ""
        },
        {
            "duration": 3503,
            "err": null,
            "expected": [
                "[]"
            ],
            "found": [
                "[\"::\"]"
            ],
            "human": "",
            "meta": null,
            "property": "ip",
            "resource-id": "tcp6:2181",
            "resource-type": "Port",
            "result": 0,
            "successful": true,
            "summary-line": "Port: tcp6:2181: ip: matches expectation: [[]]",
            "test-type": 0,
            "title": ""
        },
        {
            "duration": 2771,
            "err": null,
            "expected": [
                "true"
            ],
            "found": [
                "true"
            ],
            "human": "",
            "meta": null,
            "property": "listening",
            "resource-id": "tcp6:8888",
            "resource-type": "Port",
            "result": 0,
            "successful": true,
            "summary-line": "Port: tcp6:8888: listening: matches expectation: [true]",
            "test-type": 0,
            "title": ""
        },
        {
            "duration": 5617,
            "err": null,
            "expected": [
                "[\"169.254.1.1\"]"
            ],
            "found": [
                "[\"169.254.1.1\"]"
            ],
            "human": "",
            "meta": null,
            "property": "ip",
            "resource-id": "tcp6:8888",
            "resource-type": "Port",
            "result": 0,
            "successful": true,
            "summary-line": "Port: tcp6:8888: ip: matches expectation: [[\"169.254.1.1\"]]",
            "test-type": 0,
            "title": ""
        },
        {
            "duration": 2913,
            "err": null,
            "expected": [
                "true"
            ],
            "found": [
                "true"
            ],
            "human": "",
            "meta": null,
            "property": "listening",
            "resource-id": "tcp6:9092",
            "resource-type": "Port",
            "result": 0,
            "successful": true,
            "summary-line": "Port: tcp6:9092: listening: matches expectation: [true]",
            "test-type": 0,
            "title": ""
        },
        {
            "duration": 3403,
            "err": null,
            "expected": [
                "[]"
            ],
            "found": [
                "[\"::\"]"
            ],
            "human": "",
            "meta": null,
            "property": "ip",
            "resource-id": "tcp6:9092",
            "resource-type": "Port",
            "result": 0,
            "successful": true,
            "summary-line": "Port: tcp6:9092: ip: matches expectation: [[]]",
            "test-type": 0,
            "title": ""
        },
        {
            "duration": 2725,
            "err": null,
            "expected": [
                "true"
            ],
            "found": [
                "true"
            ],
            "human": "",
            "meta": null,
            "property": "listening",
            "resource-id": "tcp:8200",
            "resource-type": "Port",
            "result": 0,
            "successful": true,
            "summary-line": "Port: tcp:8200: listening: matches expectation: [true]",
            "test-type": 0,
            "title": ""
        },
        {
            "duration": 5277,
            "err": null,
            "expected": [
                "[\"169.254.1.1\"]"
            ],
            "found": [
                "[\"169.254.1.1\"]"
            ],
            "human": "",
            "meta": null,
            "property": "ip",
            "resource-id": "tcp:8200",
            "resource-type": "Port",
            "result": 0,
            "successful": true,
            "summary-line": "Port: tcp:8200: ip: matches expectation: [[\"169.254.1.1\"]]",
            "test-type": 0,
            "title": ""
        },
        {
            "duration": 2922,
            "err": null,
            "expected": [
                "true"
            ],
            "found": [
                "true"
            ],
            "human": "",
            "meta": null,
            "property": "listening",
            "resource-id": "tcp6:9093",
            "resource-type": "Port",
            "result": 0,
            "successful": true,
            "summary-line": "Port: tcp6:9093: listening: matches expectation: [true]",
            "test-type": 0,
            "title": ""
        },
        {
            "duration": 3302,
            "err": null,
            "expected": [
                "[]"
            ],
            "found": [
                "[\"::\"]"
            ],
            "human": "",
            "meta": null,
            "property": "ip",
            "resource-id": "tcp6:9093",
            "resource-type": "Port",
            "result": 0,
            "successful": true,
            "summary-line": "Port: tcp6:9093: ip: matches expectation: [[]]",
            "test-type": 0,
            "title": ""
        },
        {
            "duration": 2782,
            "err": null,
            "expected": [
                "true"
            ],
            "found": [
                "true"
            ],
            "human": "",
            "meta": null,
            "property": "listening",
            "resource-id": "tcp:8500",
            "resource-type": "Port",
            "result": 0,
            "successful": true,
            "summary-line": "Port: tcp:8500: listening: matches expectation: [true]",
            "test-type": 0,
            "title": ""
        },
        {
            "duration": 5553,
            "err": null,
            "expected": [
                "[\"169.254.1.1\"]"
            ],
            "found": [
                "[\"169.254.1.1\"]"
            ],
            "human": "",
            "meta": null,
            "property": "ip",
            "resource-id": "tcp:8500",
            "resource-type": "Port",
            "result": 0,
            "successful": true,
            "summary-line": "Port: tcp:8500: ip: matches expectation: [[\"169.254.1.1\"]]",
            "test-type": 0,
            "title": ""
        },
        {
            "duration": 2812,
            "err": null,
            "expected": [
                "true"
            ],
            "found": [
                "true"
            ],
            "human": "",
            "meta": null,
            "property": "listening",
            "resource-id": "tcp:8446",
            "resource-type": "Port",
            "result": 0,
            "successful": true,
            "summary-line": "Port: tcp:8446: listening: matches expectation: [true]",
            "test-type": 0,
            "title": ""
        },
        {
            "duration": 5157,
            "err": null,
            "expected": [
                "[\"0.0.0.0\"]"
            ],
            "found": [
                "[\"0.0.0.0\"]"
            ],
            "human": "",
            "meta": null,
            "property": "ip",
            "resource-id": "tcp:8446",
            "resource-type": "Port",
            "result": 0,
            "successful": true,
            "summary-line": "Port: tcp:8446: ip: matches expectation: [[\"0.0.0.0\"]]",
            "test-type": 0,
            "title": ""
        },
        {
            "duration": 2853,
            "err": null,
            "expected": [
                "true"
            ],
            "found": [
                "true"
            ],
            "human": "",
            "meta": null,
            "property": "listening",
            "resource-id": "tcp6:8112",
            "resource-type": "Port",
            "result": 0,
            "successful": true,
            "summary-line": "Port: tcp6:8112: listening: matches expectation: [true]",
            "test-type": 0,
            "title": ""
        },
        {
            "duration": 4916,
            "err": null,
            "expected": [
                "[]"
            ],
            "found": [
                "[\"::\",\"::1\"]"
            ],
            "human": "",
            "meta": null,
            "property": "ip",
            "resource-id": "tcp6:8112",
            "resource-type": "Port",
            "result": 0,
            "successful": true,
            "summary-line": "Port: tcp6:8112: ip: matches expectation: [[]]",
            "test-type": 0,
            "title": ""
        },
        {
            "duration": 47869506,
            "err": null,
            "expected": [
                "true"
            ],
            "found": [
                "true"
            ],
            "human": "",
            "meta": null,
            "property": "enabled",
            "resource-id": "edgemanager-licensing",
            "resource-type": "Service",
            "result": 0,
            "successful": true,
            "summary-line": "Service: edgemanager-licensing: enabled: matches expectation: [true]",
            "test-type": 0,
            "title": ""
        },
        {
            "duration": 32021551,
            "err": null,
            "expected": [
                "true"
            ],
            "found": [
                "true"
            ],
            "human": "",
            "meta": null,
            "property": "running",
            "resource-id": "edgemanager-licensing",
            "resource-type": "Service",
            "result": 0,
            "successful": true,
            "summary-line": "Service: edgemanager-licensing: running: matches expectation: [true]",
            "test-type": 0,
            "title": ""
        },
        {
            "duration": 51622478,
            "err": null,
            "expected": [
                "true"
            ],
            "found": [
                "true"
            ],
            "human": "",
            "meta": null,
            "property": "enabled",
            "resource-id": "hazelcast",
            "resource-type": "Service",
            "result": 0,
            "successful": true,
            "summary-line": "Service: hazelcast: enabled: matches expectation: [true]",
            "test-type": 0,
            "title": ""
        },
        {
            "duration": 31590132,
            "err": null,
            "expected": [
                "true"
            ],
            "found": [
                "true"
            ],
            "human": "",
            "meta": null,
            "property": "running",
            "resource-id": "hazelcast",
            "resource-type": "Service",
            "result": 0,
            "successful": true,
            "summary-line": "Service: hazelcast: running: matches expectation: [true]",
            "test-type": 0,
            "title": ""
        },
        {
            "duration": 53542227,
            "err": null,
            "expected": [
                "true"
            ],
            "found": [
                "true"
            ],
            "human": "",
            "meta": null,
            "property": "enabled",
            "resource-id": "lem-ll",
            "resource-type": "Service",
            "result": 0,
            "successful": true,
            "summary-line": "Service: lem-ll: enabled: matches expectation: [true]",
            "test-type": 0,
            "title": ""
        },
        {
            "duration": 31503689,
            "err": null,
            "expected": [
                "true"
            ],
            "found": [
                "true"
            ],
            "human": "",
            "meta": null,
            "property": "running",
            "resource-id": "lem-ll",
            "resource-type": "Service",
            "result": 0,
            "successful": true,
            "summary-line": "Service: lem-ll: running: matches expectation: [true]",
            "test-type": 0,
            "title": ""
        },
        {
            "duration": 46812431,
            "err": null,
            "expected": [
                "true"
            ],
            "found": [
                "true"
            ],
            "human": "",
            "meta": null,
            "property": "enabled",
            "resource-id": "emqx",
            "resource-type": "Service",
            "result": 0,
            "successful": true,
            "summary-line": "Service: emqx: enabled: matches expectation: [true]",
            "test-type": 0,
            "title": ""
        },
        {
            "duration": 39160353,
            "err": null,
            "expected": [
                "true"
            ],
            "found": [
                "true"
            ],
            "human": "",
            "meta": null,
            "property": "running",
            "resource-id": "emqx",
            "resource-type": "Service",
            "result": 0,
            "successful": true,
            "summary-line": "Service: emqx: running: matches expectation: [true]",
            "test-type": 0,
            "title": ""
        },
        {
            "duration": 50379113,
            "err": null,
            "expected": [
                "true"
            ],
            "found": [
                "true"
            ],
            "human": "",
            "meta": null,
            "property": "enabled",
            "resource-id": "minio",
            "resource-type": "Service",
            "result": 0,
            "successful": true,
            "summary-line": "Service: minio: enabled: matches expectation: [true]",
            "test-type": 0,
            "title": ""
        },
        {
            "duration": 35226906,
            "err": null,
            "expected": [
                "true"
            ],
            "found": [
                "true"
            ],
            "human": "",
            "meta": null,
            "property": "running",
            "resource-id": "minio",
            "resource-type": "Service",
            "result": 0,
            "successful": true,
            "summary-line": "Service: minio: running: matches expectation: [true]",
            "test-type": 0,
            "title": ""
        },
        {
            "duration": 57949699,
            "err": null,
            "expected": [
                "true"
            ],
            "found": [
                "true"
            ],
            "human": "",
            "meta": null,
            "property": "enabled",
            "resource-id": "clickhouse-server",
            "resource-type": "Service",
            "result": 0,
            "successful": true,
            "summary-line": "Service: clickhouse-server: enabled: matches expectation: [true]",
            "test-type": 0,
            "title": ""
        },
        {
            "duration": 26654332,
            "err": null,
            "expected": [
                "true"
            ],
            "found": [
                "true"
            ],
            "human": "",
            "meta": null,
            "property": "running",
            "resource-id": "clickhouse-server",
            "resource-type": "Service",
            "result": 0,
            "successful": true,
            "summary-line": "Service: clickhouse-server: running: matches expectation: [true]",
            "test-type": 0,
            "title": ""
        },
        {
            "duration": 56152675,
            "err": null,
            "expected": [
                "true"
            ],
            "found": [
                "true"
            ],
            "human": "",
            "meta": null,
            "property": "enabled",
            "resource-id": "nomad-apps",
            "resource-type": "Service",
            "result": 0,
            "successful": true,
            "summary-line": "Service: nomad-apps: enabled: matches expectation: [true]",
            "test-type": 0,
            "title": ""
        },
        {
            "duration": 30035476,
            "err": null,
            "expected": [
                "true"
            ],
            "found": [
                "true"
            ],
            "human": "",
            "meta": null,
            "property": "running",
            "resource-id": "nomad-apps",
            "resource-type": "Service",
            "result": 0,
            "successful": true,
            "summary-line": "Service: nomad-apps: running: matches expectation: [true]",
            "test-type": 0,
            "title": ""
        },
        {
            "duration": 91761663,
            "err": null,
            "expected": [
                "0"
            ],
            "found": [
                "0"
            ],
            "human": "",
            "meta": null,
            "property": "exit-status",
            "resource-id": "/usr/bin/vault status",
            "resource-type": "Command",
            "result": 0,
            "successful": true,
            "summary-line": "Command: /usr/bin/vault status: exit-status: matches expectation: [0]",
            "test-type": 0,
            "title": ""
        },
        {
            "duration": 69537,
            "err": null,
            "expected": [
                "Initialized     true",
                "Sealed          false"
            ],
            "found": [
                "Initialized     true",
                "Sealed          false"
            ],
            "human": "",
            "meta": null,
            "property": "stdout",
            "resource-id": "/usr/bin/vault status",
            "resource-type": "Command",
            "result": 0,
            "successful": true,
            "summary-line": "Command: /usr/bin/vault status: stdout: matches expectation: [Initialized     true Sealed          false]",
            "test-type": 2,
            "title": ""
        },
        {
            "duration": 222934324,
            "err": null,
            "expected": [
                "0"
            ],
            "found": [
                "0"
            ],
            "human": "",
            "meta": null,
            "property": "exit-status",
            "resource-id": "/opt/lem/bin/lem-nomad-alloc-status.sh",
            "resource-type": "Command",
            "result": 0,
            "successful": true,
            "summary-line": "Command: /opt/lem/bin/lem-nomad-alloc-status.sh: exit-status: matches expectation: [0]",
            "test-type": 0,
            "title": ""
        },
        {
            "duration": 91033,
            "err": null,
            "expected": [
                "docker-registry registry true",
                "fabio fabio null",
                "lem-activation activation true",
                "lem-api lem-api true",
                "lem-binds mqtt-bind true",
                "lem-emq-auth auth true",
                "lem-jobs jobs true",
                "lem-mpcs mpcs true",
                "lem-mpcs mpcs-rbac true",
                "lem-sinks clickhouse-sink true",
                "lem-sinks events-sink true",
                "lem-alerts lem-alerts true",
                "grafana grafana true",
                "prometheus monitoring true"
            ],
            "found": [
                "docker-registry registry true",
                "fabio fabio null",
                "grafana grafana true",
                "lem-activation activation true",
                "lem-alerts lem-alerts true",
                "lem-api lem-api true",
                "lem-binds mqtt-bind true",
                "lem-emq-auth auth true",
                "lem-jobs jobs true",
                "lem-mpcs mpcs-rbac true",
                "lem-mpcs mpcs true",
                "lem-sinks clickhouse-sink true",
                "lem-sinks events-sink true",
                "prometheus monitoring true"
            ],
            "human": "",
            "meta": null,
            "property": "stdout",
            "resource-id": "/opt/lem/bin/lem-nomad-alloc-status.sh",
            "resource-type": "Command",
            "result": 0,
            "successful": true,
            "summary-line": "Command: /opt/lem/bin/lem-nomad-alloc-status.sh: stdout: matches expectation: [docker-registry registry true fabio fabio null lem-activation activation true lem-api lem-api true lem-binds mqtt-bind true lem-emq-auth auth true lem-jobs jobs true lem-mpcs mpcs true lem-mpcs mpcs-rbac true lem-sinks clickhouse-sink true lem-sinks events-sink true lem-alerts lem-alerts true grafana grafana true prometheus monitoring true]",
            "test-type": 2,
            "title": ""
        }
    ],
    "summary": {
        "failed-count": 0,
        "summary-line": "Count: 97, Failed: 0, Duration: 0.224s",
        "test-count": 97,
        "total-duration": 224342688
    }
}
```

---

## Get Support Bundle

**GET** `{{LEM_adminURL}}/admin/v1/support/bundle`

# Get Support Bundle

Generates and downloads a LEM support bundle (encrypted zip). Use Postman's **Send and Download** to save to disk.
## Endpoint

```http
GET {{LEM_adminURL}}/admin/v1/support/bundle
```
## Authentication

HTTP Basic Auth. **Username** is your API token, **password** is empty. Tokens are managed under `System > Access Control > Tokens`.
## Response

`200 OK` -- `application/zip` (password-protected).

## Errors

| HTTP status         | When it happens                                                                |
|---------------------|--------------------------------------------------------------------------------|
| `400 Bad Request`   | Missing or malformed query/body parameter.                                     |
| `401 Unauthorized`  | Missing or invalid credentials.                                                |
| `403 Forbidden`     | Token lacks permission for this operation.                                     |
| `404 Not Found`     | Target entity does not exist.                                                  |
| `5xx`               | Service is unreachable, restarting, or internally errored. Inspect device logs under `System > Support`. |

> **TLS note**: edge devices use a self-signed certificate by default. Either install the device CA in your client trust store or disable certificate verification when calling this endpoint directly.


---

## Export/Import Log

**GET** `{{LEM_adminURL}}/admin/v1/backup/log`

# Export / Import Log

Returns the most-recent backup/restore process log entries.
## Endpoint

```http
GET {{LEM_adminURL}}/admin/v1/backup/log
```
## Authentication

HTTP Basic Auth. **Username** is your API token, **password** is empty. Tokens are managed under `System > Access Control > Tokens`.
## Errors

| HTTP status         | When it happens                                                                |
|---------------------|--------------------------------------------------------------------------------|
| `400 Bad Request`   | Missing or malformed query/body parameter.                                     |
| `401 Unauthorized`  | Missing or invalid credentials.                                                |
| `403 Forbidden`     | Token lacks permission for this operation.                                     |
| `404 Not Found`     | Target entity does not exist.                                                  |
| `5xx`               | Service is unreachable, restarting, or internally errored. Inspect device logs under `System > Support`. |

> **TLS note**: edge devices use a self-signed certificate by default. Either install the device CA in your client trust store or disable certificate verification when calling this endpoint directly.


### Response

**Status**: 200 OK

```json
{
    "status": 0,
    "statusMessage": "Backup/restore process is not running",
    "messages": [
        {
            "timestamp": 0,
            "message": "Export data is started"
        },
        {
            "timestamp": 0,
            "message": "project 65bx240rrbpdfn1kxzn16kx0s is exported"
        },
        {
            "timestamp": 0,
            "message": "project cbgnxa480aerfk56xh7j3mkj1 is exported"
        }
    ]
}
```

---

## Export Configuration

**POST** `{{LEM_adminURL}}/admin/v1/backup/backup-settings`

# Export Configuration

Exports LEM's configuration as an encrypted zip. Multipart form-data with one `password` part. Use Postman's **Send and Download** to save the response to disk.
## Endpoint

```http
POST {{LEM_adminURL}}/admin/v1/backup/backup-settings
```
## Authentication

HTTP Basic Auth. **Username** is your API token, **password** is empty. Tokens are managed under `System > Access Control > Tokens`.
## Request body

Multipart form-data: `password` text field set to the encryption password.

## Errors

| HTTP status         | When it happens                                                                |
|---------------------|--------------------------------------------------------------------------------|
| `400 Bad Request`   | Missing or malformed query/body parameter.                                     |
| `401 Unauthorized`  | Missing or invalid credentials.                                                |
| `403 Forbidden`     | Token lacks permission for this operation.                                     |
| `404 Not Found`     | Target entity does not exist.                                                  |
| `5xx`               | Service is unreachable, restarting, or internally errored. Inspect device logs under `System > Support`. |

> **TLS note**: edge devices use a self-signed certificate by default. Either install the device CA in your client trust store or disable certificate verification when calling this endpoint directly.


### Request Body

---

## Export Data

**POST** `{{LEM_adminURL}}/admin/v1/backup/backup-data`

# Export Data

Exports LEM's data (project / device / message / event stores) as an encrypted zip.
## Endpoint

```http
POST {{LEM_adminURL}}/admin/v1/backup/backup-data
```
## Authentication

HTTP Basic Auth. **Username** is your API token, **password** is empty. Tokens are managed under `System > Access Control > Tokens`.
## Request body

Multipart form-data: `password` text field set to the encryption password.

## Errors

| HTTP status         | When it happens                                                                |
|---------------------|--------------------------------------------------------------------------------|
| `400 Bad Request`   | Missing or malformed query/body parameter.                                     |
| `401 Unauthorized`  | Missing or invalid credentials.                                                |
| `403 Forbidden`     | Token lacks permission for this operation.                                     |
| `404 Not Found`     | Target entity does not exist.                                                  |
| `5xx`               | Service is unreachable, restarting, or internally errored. Inspect device logs under `System > Support`. |

> **TLS note**: edge devices use a self-signed certificate by default. Either install the device CA in your client trust store or disable certificate verification when calling this endpoint directly.


### Request Body

---

## Import Configuration Settings

**POST** `{{LEM_adminURL}}/admin/v1/backup/restore-settings`

# Import Configuration Settings

Restores a configuration-only export. Multipart with the zip file and the password.
## Endpoint

```http
POST {{LEM_adminURL}}/admin/v1/backup/restore-settings
```
## Authentication

HTTP Basic Auth. **Username** is your API token, **password** is empty. Tokens are managed under `System > Access Control > Tokens`.
## Request body

Multipart form-data: `password` text + file part with the encrypted zip.

## Errors

| HTTP status         | When it happens                                                                |
|---------------------|--------------------------------------------------------------------------------|
| `400 Bad Request`   | Missing or malformed query/body parameter.                                     |
| `401 Unauthorized`  | Missing or invalid credentials.                                                |
| `403 Forbidden`     | Token lacks permission for this operation.                                     |
| `404 Not Found`     | Target entity does not exist.                                                  |
| `5xx`               | Service is unreachable, restarting, or internally errored. Inspect device logs under `System > Support`. |

> **TLS note**: edge devices use a self-signed certificate by default. Either install the device CA in your client trust store or disable certificate verification when calling this endpoint directly.


### Request Body

---

## Import Data

**POST** `{{LEM_adminURL}}/admin/v1/backup/restore-data`

# Import Data

Restores a data-only export.
## Endpoint

```http
POST {{LEM_adminURL}}/admin/v1/backup/restore-data
```
## Authentication

HTTP Basic Auth. **Username** is your API token, **password** is empty. Tokens are managed under `System > Access Control > Tokens`.
## Request body

Multipart form-data: `password` text + file part.

## Errors

| HTTP status         | When it happens                                                                |
|---------------------|--------------------------------------------------------------------------------|
| `400 Bad Request`   | Missing or malformed query/body parameter.                                     |
| `401 Unauthorized`  | Missing or invalid credentials.                                                |
| `403 Forbidden`     | Token lacks permission for this operation.                                     |
| `404 Not Found`     | Target entity does not exist.                                                  |
| `5xx`               | Service is unreachable, restarting, or internally errored. Inspect device logs under `System > Support`. |

> **TLS note**: edge devices use a self-signed certificate by default. Either install the device CA in your client trust store or disable certificate verification when calling this endpoint directly.


### Request Body

---

## LEM Backup List

**GET** `{{LEM_adminURL}}/admin/v1/lem-backup/list`

# LEM Backup List

Returns the LEM-level backup archive index (date-named zip files in object storage).
## Endpoint

```http
GET {{LEM_adminURL}}/admin/v1/lem-backup/list
```
## Authentication

HTTP Basic Auth. **Username** is your API token, **password** is empty. Tokens are managed under `System > Access Control > Tokens`.
## Errors

| HTTP status         | When it happens                                                                |
|---------------------|--------------------------------------------------------------------------------|
| `400 Bad Request`   | Missing or malformed query/body parameter.                                     |
| `401 Unauthorized`  | Missing or invalid credentials.                                                |
| `403 Forbidden`     | Token lacks permission for this operation.                                     |
| `404 Not Found`     | Target entity does not exist.                                                  |
| `5xx`               | Service is unreachable, restarting, or internally errored. Inspect device logs under `System > Support`. |

> **TLS note**: edge devices use a self-signed certificate by default. Either install the device CA in your client trust store or disable certificate verification when calling this endpoint directly.


### Response

**Status**: 200 OK

```json
[
    {
        "objectName": "em-2.16.4-daily-TUESDAY.zip",
        "objectSize": 1772895,
        "createdAt": 1716249603757
    },
    {
        "objectName": "em-2.20.0-daily-MONDAY.zip",
        "objectSize": 2190405,
        "createdAt": 1725840008348
    },
    {
        "objectName": "em-2.22.2-daily-FRIDAY.zip",
        "objectSize": 1580640,
        "createdAt": 1728604803897
    },
    {
        "objectName": "em-2.23.0-daily-FRIDAY.zip",
        "objectSize": 1675468,
        "createdAt": 1735862404094
    },
    {
        "objectName": "em-2.23.0-daily-MONDAY.zip",
        "objectSize": 1675679,
        "createdAt": 1736121611950
    },
    {
        "objectName": "em-2.23.0-daily-SATURDAY.zip",
        "objectSize": 1675654,
        "createdAt": 1735948815742
    },
    {
        "objectName": "em-2.23.0-daily-SUNDAY.zip",
        "objectSize": 1675674,
        "createdAt": 1736035211597
    },
    {
        "objectName": "em-2.23.0-daily-THURSDAY.zip",
        "objectSize": 1678605,
        "createdAt": 1736380807626
    },
    {
        "objectName": "em-2.23.0-daily-TUESDAY.zip",
        "objectSize": 1676110,
        "createdAt": 1736208008965
    },
    {
        "objectName": "em-2.23.0-daily-WEDNESDAY.zip",
        "objectSize": 1676292,
        "createdAt": 1736294404964
    }
]
```

---

## LEM Backup Log

**GET** `{{LEM_adminURL}}/admin/v1/lem-backup/log`

# LEM Backup Log

Returns the most-recent LEM backup-process log entries.
## Endpoint

```http
GET {{LEM_adminURL}}/admin/v1/lem-backup/log
```
## Authentication

HTTP Basic Auth. **Username** is your API token, **password** is empty. Tokens are managed under `System > Access Control > Tokens`.
## Errors

| HTTP status         | When it happens                                                                |
|---------------------|--------------------------------------------------------------------------------|
| `400 Bad Request`   | Missing or malformed query/body parameter.                                     |
| `401 Unauthorized`  | Missing or invalid credentials.                                                |
| `403 Forbidden`     | Token lacks permission for this operation.                                     |
| `404 Not Found`     | Target entity does not exist.                                                  |
| `5xx`               | Service is unreachable, restarting, or internally errored. Inspect device logs under `System > Support`. |

> **TLS note**: edge devices use a self-signed certificate by default. Either install the device CA in your client trust store or disable certificate verification when calling this endpoint directly.


### Response

**Status**: 200 OK

```json
{
    "status": 0,
    "statusMessage": "Process is not running",
    "messages": [
        {
            "timestamp": 1736380800004,
            "message": "Create backup process started.."
        },
        {
            "timestamp": 1736380800027,
            "message": "Backup configuration database"
        },
        {
            "timestamp": 1736380806713,
            "message": "Backup consul and vault"
        },
        {
            "timestamp": 1736380807032,
            "message": "Backup vault credentials"
        },
        {
            "timestamp": 1736380807044,
            "message": "Backup clickhouse users"
        },
        {
            "timestamp": 1736380807074,
            "message": "Backup kafka users"
        },
        {
            "timestamp": 1736380807079,
            "message": "Backup registry users"
        },
        {
            "timestamp": 1736380807088,
            "message": "Backup Litmus Licensing Server"
        },
        {
            "timestamp": 1736380807098,
            "message": "Backup templates"
        },
        {
            "timestamp": 1736380807664,
            "message": "Backup process completed.. Success"
        }
    ]
}
```

---

## Create Backup

**POST** `{{LEM_adminURL}}/admin/v1/lem-backup/create`

# Create Backup

Triggers a new LEM-level backup. The new archive appears in `LEM Backup List` once complete.
## Endpoint

```http
POST {{LEM_adminURL}}/admin/v1/lem-backup/create
```
## Authentication

HTTP Basic Auth. **Username** is your API token, **password** is empty. Tokens are managed under `System > Access Control > Tokens`.
## Errors

| HTTP status         | When it happens                                                                |
|---------------------|--------------------------------------------------------------------------------|
| `400 Bad Request`   | Missing or malformed query/body parameter.                                     |
| `401 Unauthorized`  | Missing or invalid credentials.                                                |
| `403 Forbidden`     | Token lacks permission for this operation.                                     |
| `404 Not Found`     | Target entity does not exist.                                                  |
| `5xx`               | Service is unreachable, restarting, or internally errored. Inspect device logs under `System > Support`. |

> **TLS note**: edge devices use a self-signed certificate by default. Either install the device CA in your client trust store or disable certificate verification when calling this endpoint directly.


### Response

**Status**: 200 OK

```json
{
    "code": "S",
    "message": "em-2.23.0-20250109234629.zip",
    "messageDetails": null
}
```

---

## Remove Backup File

**DELETE** `{{LEM_adminURL}}/admin/v1/lem-backup?name=em-2.23.0-20250109234629.zip`

# Remove Backup File

Deletes one backup archive by name.
## Endpoint

```http
DELETE {{LEM_adminURL}}/admin/v1/lem-backup?name=em-2.23.0-20250109234629.zip
```
## Authentication

HTTP Basic Auth. **Username** is your API token, **password** is empty. Tokens are managed under `System > Access Control > Tokens`.
## Errors

| HTTP status         | When it happens                                                                |
|---------------------|--------------------------------------------------------------------------------|
| `400 Bad Request`   | Missing or malformed query/body parameter.                                     |
| `401 Unauthorized`  | Missing or invalid credentials.                                                |
| `403 Forbidden`     | Token lacks permission for this operation.                                     |
| `404 Not Found`     | Target entity does not exist.                                                  |
| `5xx`               | Service is unreachable, restarting, or internally errored. Inspect device logs under `System > Support`. |

> **TLS note**: edge devices use a self-signed certificate by default. Either install the device CA in your client trust store or disable certificate verification when calling this endpoint directly.


### Response

**Status**: 200 OK

---

## Restore From Backup

**POST** `{{LEM_adminURL}}/admin/v1/lem-backup/restore?name=em-2.24.0-dev.202410170915.zip`

# Restore From Backup

Restores LEM from a backup archive. Halts LEM during restore. Treat as destructive.
## Endpoint

```http
POST {{LEM_adminURL}}/admin/v1/lem-backup/restore?name=em-2.24.0-dev.202410170915.zip
```
## Authentication

HTTP Basic Auth. **Username** is your API token, **password** is empty. Tokens are managed under `System > Access Control > Tokens`.
## Errors

| HTTP status         | When it happens                                                                |
|---------------------|--------------------------------------------------------------------------------|
| `400 Bad Request`   | Missing or malformed query/body parameter.                                     |
| `401 Unauthorized`  | Missing or invalid credentials.                                                |
| `403 Forbidden`     | Token lacks permission for this operation.                                     |
| `404 Not Found`     | Target entity does not exist.                                                  |
| `5xx`               | Service is unreachable, restarting, or internally errored. Inspect device logs under `System > Support`. |

> **TLS note**: edge devices use a self-signed certificate by default. Either install the device CA in your client trust store or disable certificate verification when calling this endpoint directly.


---

## List Experimental Features

**GET** `{{LEM_adminURL}}/admin/v1/feature?type=EXPERIMENTAL`

# List Experimental Features

Returns LEM's experimental feature catalog with enabled flags.
## Endpoint

```http
GET {{LEM_adminURL}}/admin/v1/feature?type=EXPERIMENTAL
```
## Authentication

HTTP Basic Auth. **Username** is your API token, **password** is empty. Tokens are managed under `System > Access Control > Tokens`.
## Errors

| HTTP status         | When it happens                                                                |
|---------------------|--------------------------------------------------------------------------------|
| `400 Bad Request`   | Missing or malformed query/body parameter.                                     |
| `401 Unauthorized`  | Missing or invalid credentials.                                                |
| `403 Forbidden`     | Token lacks permission for this operation.                                     |
| `404 Not Found`     | Target entity does not exist.                                                  |
| `5xx`               | Service is unreachable, restarting, or internally errored. Inspect device logs under `System > Support`. |

> **TLS note**: edge devices use a self-signed certificate by default. Either install the device CA in your client trust store or disable certificate verification when calling this endpoint directly.


### Response

**Status**: 200 OK

```json
[
    {
        "entryID": 1,
        "name": "EdgeEvents",
        "description": "Edge events management",
        "type": "EXPERIMENTAL",
        "enabled": 1,
        "createdOn": 1597449600000,
        "updatedOn": null
    },
    {
        "entryID": 2,
        "name": "DigitalTwin",
        "description": "Digital Twin models management",
        "type": "EXPERIMENTAL",
        "enabled": 1,
        "createdOn": 1597449600000,
        "updatedOn": 1689974876000
    }
]
```

---

## Enable/Disable Feature

**POST** `{{LEM_adminURL}}/admin/v1/feature?name=DigitalTwin&enabled=true`

# Enable / Disable Feature

Toggles one experimental feature by name. `enabled=true` enables; `false` disables.
## Endpoint

```http
POST {{LEM_adminURL}}/admin/v1/feature?name=DigitalTwin&enabled=true
```
## Authentication

HTTP Basic Auth. **Username** is your API token, **password** is empty. Tokens are managed under `System > Access Control > Tokens`.
## Errors

| HTTP status         | When it happens                                                                |
|---------------------|--------------------------------------------------------------------------------|
| `400 Bad Request`   | Missing or malformed query/body parameter.                                     |
| `401 Unauthorized`  | Missing or invalid credentials.                                                |
| `403 Forbidden`     | Token lacks permission for this operation.                                     |
| `404 Not Found`     | Target entity does not exist.                                                  |
| `5xx`               | Service is unreachable, restarting, or internally errored. Inspect device logs under `System > Support`. |

> **TLS note**: edge devices use a self-signed certificate by default. Either install the device CA in your client trust store or disable certificate verification when calling this endpoint directly.


### Response

**Status**: 200 OK

```json
{
    "code": "S",
    "message": null,
    "messageDetails": null
}
```

---

## System Reboot

**GET** `{{LEM_adminURL}}/admin/v1/system/reboot`

# System Reboot

Reboots the LEM host. Full LEM outage during the reboot. The endpoint is a `GET` (legacy); use sparingly.
## Endpoint

```http
GET {{LEM_adminURL}}/admin/v1/system/reboot
```
## Authentication

HTTP Basic Auth. **Username** is your API token, **password** is empty. Tokens are managed under `System > Access Control > Tokens`.
> **Operational note**: full LEM downtime. Coordinate with stakeholders before triggering.
## Errors

| HTTP status         | When it happens                                                                |
|---------------------|--------------------------------------------------------------------------------|
| `400 Bad Request`   | Missing or malformed query/body parameter.                                     |
| `401 Unauthorized`  | Missing or invalid credentials.                                                |
| `403 Forbidden`     | Token lacks permission for this operation.                                     |
| `404 Not Found`     | Target entity does not exist.                                                  |
| `5xx`               | Service is unreachable, restarting, or internally errored. Inspect device logs under `System > Support`. |

> **TLS note**: edge devices use a self-signed certificate by default. Either install the device CA in your client trust store or disable certificate verification when calling this endpoint directly.


---

## Subscription Settings

**GET** `{{LEM_adminURL}}/admin/v1/report/settings/subscribers`

# Subscription Settings

Returns the report-subscription recipients.
## Endpoint

```http
GET {{LEM_adminURL}}/admin/v1/report/settings/subscribers
```
## Authentication

HTTP Basic Auth. **Username** is your API token, **password** is empty. Tokens are managed under `System > Access Control > Tokens`.
## Errors

| HTTP status         | When it happens                                                                |
|---------------------|--------------------------------------------------------------------------------|
| `400 Bad Request`   | Missing or malformed query/body parameter.                                     |
| `401 Unauthorized`  | Missing or invalid credentials.                                                |
| `403 Forbidden`     | Token lacks permission for this operation.                                     |
| `404 Not Found`     | Target entity does not exist.                                                  |
| `5xx`               | Service is unreachable, restarting, or internally errored. Inspect device logs under `System > Support`. |

> **TLS note**: edge devices use a self-signed certificate by default. Either install the device CA in your client trust store or disable certificate verification when calling this endpoint directly.


### Response

**Status**: 200 OK

```json
[
    {
        "enable": true,
        "name": "Parth",
        "email": "parth@litmus.io"
    }
]
```

---

## Reports Stats

**GET** `{{LEM_adminURL}}/admin/v1/report/settings/stats`

# Reports Stats

Returns the report-generation configuration: enabled flag, frequency, and which metric categories are included.
## Endpoint

```http
GET {{LEM_adminURL}}/admin/v1/report/settings/stats
```
## Authentication

HTTP Basic Auth. **Username** is your API token, **password** is empty. Tokens are managed under `System > Access Control > Tokens`.
## Errors

| HTTP status         | When it happens                                                                |
|---------------------|--------------------------------------------------------------------------------|
| `400 Bad Request`   | Missing or malformed query/body parameter.                                     |
| `401 Unauthorized`  | Missing or invalid credentials.                                                |
| `403 Forbidden`     | Token lacks permission for this operation.                                     |
| `404 Not Found`     | Target entity does not exist.                                                  |
| `5xx`               | Service is unreachable, restarting, or internally errored. Inspect device logs under `System > Support`. |

> **TLS note**: edge devices use a self-signed certificate by default. Either install the device CA in your client trust store or disable certificate verification when calling this endpoint directly.


### Response

**Status**: 200 OK

```json
{
    "enable": true,
    "periodFrequency": "WEEKLY",
    "metrics": {
        "edgeDeviceMetrics": true,
        "activeUsersCompaniesProjects": true,
        "activationDeactivation": true,
        "catalogsApps": true,
        "softwareUpdates": true,
        "template": true,
        "licenses": true,
        "aiMlModels": true,
        "alertsTriggers": true,
        "cpuMemoryNetworkLoad": true,
        "diskUsage": true,
        "uptimeDowntime": true
    }
}
```

---

