From 4e15820af3b834a8c15a4370c98076cf18ac2a13 Mon Sep 17 00:00:00 2001 From: Viacheslav Klimov Date: Mon, 27 Jul 2026 14:25:01 +0100 Subject: [PATCH] Update PE OpenAPI spec in master (from master) --- pe/docs/AiChatControllerApi.md | 6 +- pe/docs/AlarmControllerApi.md | 2 +- pe/docs/Dashboard.md | 2 +- pe/docs/DashboardInfo.md | 2 +- pe/docs/EntityGroupControllerApi.md | 8 +- pe/docs/HomeDashboard.md | 2 +- pe/docs/Job.md | 4 + pe/docs/JobConfiguration.md | 2 + pe/docs/JobResult.md | 2 + pe/docs/LoginWhiteLabelingParams.md | 2 + pe/docs/NotificationRequest.md | 1 + pe/docs/NotificationRequestInfo.md | 1 + pe/docs/NotificationTemplate.md | 1 + pe/docs/NotificationTemplateConfig.md | 1 + pe/docs/PageDataDashboardInfo.md | 2 +- pe/docs/PageDataJob.md | 4 + pe/docs/PageDataNotificationRequestInfo.md | 1 + pe/docs/PageDataNotificationTemplate.md | 1 + pe/docs/PageDataReport.md | 2 + pe/docs/PageDataReportInfo.md | 2 + pe/docs/Report.md | 2 + pe/docs/ReportControllerApi.md | 51 +++ pe/docs/ReportInfo.md | 2 + pe/docs/ReportJobConfiguration.md | 2 + pe/docs/ReportJobResult.md | 2 + pe/docs/ReportRequest.md | 1 + pe/docs/ReportTaskResult.md | 2 + pe/docs/WhiteLabelingParams.md | 2 + pe/spec/openapi.json | 376 +++++++++++++++++- .../org/thingsboard/client/ApiClient.java | 4 +- .../client/api/ThingsboardApi.java | 199 ++++++++- .../thingsboard/client/model/Dashboard.java | 4 +- .../client/model/DashboardInfo.java | 4 +- .../client/model/HomeDashboard.java | 4 +- .../model/LoginWhiteLabelingParams.java | 74 +++- .../model/NotificationTemplateConfig.java | 42 +- .../org/thingsboard/client/model/Report.java | 78 +++- .../thingsboard/client/model/ReportInfo.java | 78 +++- .../client/model/ReportJobConfiguration.java | 38 +- .../client/model/ReportRequest.java | 38 +- .../client/model/WhiteLabelingParams.java | 74 +++- 41 files changed, 1057 insertions(+), 68 deletions(-) diff --git a/pe/docs/AiChatControllerApi.md b/pe/docs/AiChatControllerApi.md index a4278a85..3111fde1 100644 --- a/pe/docs/AiChatControllerApi.md +++ b/pe/docs/AiChatControllerApi.md @@ -7,7 +7,7 @@ com.fasterxml.jackson.databind.JsonNode createChat(@Nonnull Object body) // crea void deleteChat(@Nonnull UUID chatId) // deleteChat com.fasterxml.jackson.databind.JsonNode getChatMessages(@Nonnull UUID chatId) // getChatMessages com.fasterxml.jackson.databind.JsonNode listChats(@Nonnull ChatType chatType) // listChats -List sendChatMessage(@Nonnull UUID chatId, @Nonnull String xAuthorization, @Nonnull String body, @Nullable String acceptLanguage) // sendChatMessage +List sendChatMessage(@Nonnull UUID chatId, @Nonnull String xAuthorization, @Nonnull Object body, @Nullable String acceptLanguage) // sendChatMessage void updateChat(@Nonnull UUID chatId, @Nonnull Object body) // updateChat ``` @@ -103,7 +103,7 @@ listChats ## sendChatMessage ``` -List sendChatMessage(@Nonnull UUID chatId, @Nonnull String xAuthorization, @Nonnull String body, @Nullable String acceptLanguage) +List sendChatMessage(@Nonnull UUID chatId, @Nonnull String xAuthorization, @Nonnull Object body, @Nullable String acceptLanguage) ``` **POST** `/api/ai/chats/{chatId}/messages` @@ -117,7 +117,7 @@ sendChatMessage |------------- | ------------- | ------------- | -------------| | **chatId** | **UUID** | | | | **xAuthorization** | **String** | | | -| **body** | **String** | | | +| **body** | **Object** | | | | **acceptLanguage** | **String** | | [optional] | ### Return type diff --git a/pe/docs/AlarmControllerApi.md b/pe/docs/AlarmControllerApi.md index 8411c255..9c3902bc 100644 --- a/pe/docs/AlarmControllerApi.md +++ b/pe/docs/AlarmControllerApi.md @@ -370,7 +370,7 @@ Alarm saveAlarm(@Nonnull Alarm alarm) Create or Update Alarm (saveAlarm) -Creates or Updates the Alarm. When creating alarm, platform generates Alarm Id as [time-based UUID](https://en.wikipedia.org/wiki/Universally_unique_identifier#Version_1_(date-time_and_MAC_address)). The newly created Alarm id will be present in the response. Specify existing Alarm id to update the alarm. Referencing non-existing Alarm Id will cause 'Not Found' error. Platform also deduplicate the alarms based on the entity id of originator and alarm 'type'. For example, if the user or system component create the alarm with the type 'HighTemperature' for device 'Device A' the new active alarm is created. If the user tries to create 'HighTemperature' alarm for the same device again, the previous alarm will be updated (the 'end_ts' will be set to current timestamp). If the user clears the alarm (see 'Clear Alarm(clearAlarm)'), than new alarm with the same type and same device may be created. Remove 'id', 'tenantId' and optionally 'customerId' from the request body example (below) to create new Alarm entity. Available for users with 'TENANT_ADMIN' or 'CUSTOMER_USER' authority. Security check is performed to verify that the user has 'WRITE' permission for the entity (entities). +Creates or Updates the Alarm. When creating alarm, platform generates Alarm Id as [time-based UUID](https://en.wikipedia.org/wiki/Universally_unique_identifier#Version_1_(date-time_and_MAC_address)). The newly created Alarm id will be present in the response. Specify existing Alarm id to update the alarm. Referencing non-existing Alarm Id will cause 'Not Found' error. Platform also deduplicate the alarms based on the entity id of originator and alarm 'type'. For example, if the user or system component create the alarm with the type 'HighTemperature' for device 'Device A' the new active alarm is created. If the user tries to create 'HighTemperature' alarm for the same device again, the previous alarm will be updated (the 'end_ts' will be set to current timestamp). If the user clears the alarm (see 'Clear Alarm(clearAlarm)'), than new alarm with the same type and same device may be created. Remove 'id', 'tenantId' and optionally 'customerId' from the request body example (below) to create new Alarm entity. The alarm originator is an immutable routing key: when updating an existing alarm, the 'originator' in the request body must match the stored alarm's originator. A request that references an existing alarm id but carries a different originator is treated as a lookup miss and causes a 'Not Found' error. Available for users with 'TENANT_ADMIN' or 'CUSTOMER_USER' authority. Security check is performed to verify that the user has 'WRITE' permission for the entity (entities). ### Parameters diff --git a/pe/docs/Dashboard.md b/pe/docs/Dashboard.md index 65f03ac1..840d9269 100644 --- a/pe/docs/Dashboard.md +++ b/pe/docs/Dashboard.md @@ -18,7 +18,7 @@ | **assignedCustomers** | **Set\** | List of assigned customers with their info. | [optional] | | **mobileHide** | **Boolean** | Hide dashboard from mobile devices. Useful if the dashboard is not designed for small screens. | [optional] [readonly] | | **mobileOrder** | **Integer** | Order on mobile devices. Useful to adjust sorting of the dashboards for mobile applications | [optional] [readonly] | -| **_configuration** | **com.fasterxml.jackson.databind.JsonNode** | | [optional] | +| **_configuration** | **com.fasterxml.jackson.databind.JsonNode** | JSON object with main configuration of the dashboard: layouts, widgets, aliases, etc. The JSON structure of the dashboard configuration is quite complex. The easiest way to learn it is to export existing dashboard to JSON. | [optional] | | **resources** | **List\** | | [optional] | | **version** | **Long** | | [optional] | diff --git a/pe/docs/DashboardInfo.md b/pe/docs/DashboardInfo.md index 7a273b2d..c03ae226 100644 --- a/pe/docs/DashboardInfo.md +++ b/pe/docs/DashboardInfo.md @@ -18,7 +18,7 @@ | **assignedCustomers** | **Set\** | List of assigned customers with their info. | [optional] | | **mobileHide** | **Boolean** | Hide dashboard from mobile devices. Useful if the dashboard is not designed for small screens. | [optional] [readonly] | | **mobileOrder** | **Integer** | Order on mobile devices. Useful to adjust sorting of the dashboards for mobile applications | [optional] [readonly] | -| **_configuration** | **com.fasterxml.jackson.databind.JsonNode** | | [optional] | +| **_configuration** | **com.fasterxml.jackson.databind.JsonNode** | JSON object with main configuration of the dashboard: layouts, widgets, aliases, etc. The JSON structure of the dashboard configuration is quite complex. The easiest way to learn it is to export existing dashboard to JSON. | [optional] | | **resources** | **List\** | | [optional] | | **version** | **Long** | | [optional] | | **groups** | **List\** | Groups | [optional] | diff --git a/pe/docs/EntityGroupControllerApi.md b/pe/docs/EntityGroupControllerApi.md index 6d163e42..5659e235 100644 --- a/pe/docs/EntityGroupControllerApi.md +++ b/pe/docs/EntityGroupControllerApi.md @@ -930,16 +930,16 @@ void shareEntityGroupToChildOwnerUserGroup(@Nonnull String entityGroupId, @Nonnu Share the Entity Group with User group (shareEntityGroupToChildOwnerUserGroup) -Share the entity group with specified user group using specified role. Available for users with 'TENANT_ADMIN' or 'CUSTOMER_USER' authority. Security check is performed to verify that the user has 'WRITE' permission for specified group. +Share the entity group with the specified user group using the specified role. Unlike the 'shareEntityGroup' API method, this method is designed for sharing 'down' the owner hierarchy and does not require 'WRITE' permission for the shared entity group or the target user group. In particular, it allows the current user to re-share an entity group that was shared with them by the parent owner: for example, a customer user may re-share a tenant-owned dashboard group with a user group of their sub-customer. The following security checks are performed: * the target user group must belong to the current user's owner or to one of its sub-customers; * the current user must have the 'SHARE_GROUP' operation granted for the shared entity group: either as a generic permission for the corresponding entity group resource (applies only if the shared entity group belongs to the current user's owner hierarchy), or as a group permission created when the entity group was shared with the current user's user group using a group role that includes the 'SHARE_GROUP' operation; * the specified role must be a group role that is readable by the current user, so it must belong to the current user's owner or to one of its sub-customers; * the operations of the specified role must be a subset of the operations the current user was granted for the shared entity group (always passes if the current user was granted the 'ALL' operation). If the specified role also includes the 'SHARE_GROUP' operation, the members of the target user group will be able to re-share the entity group further down their own owner hierarchy in the same way. Available for users with 'TENANT_ADMIN' or 'CUSTOMER_USER' authority. ### Parameters | Name | Type | Description | Notes | |------------- | ------------- | ------------- | -------------| -| **entityGroupId** | **String** | A string value representing the Entity Group Id that you would like to share. For example, '784f394c-42b6-435a-983c-b7beff2784f9' | | -| **userGroupId** | **String** | A string value representing the Entity(User) Group Id that you would like to share with. For example, '784f394c-42b6-435a-983c-b7beff2784f9' | | -| **roleId** | **String** | A string value representing the Role Id that describes set of permissions you would like to share (read, write, etc). For example, '784f394c-42b6-435a-983c-b7beff2784f9' | | +| **entityGroupId** | **String** | ID of the entity group to share | | +| **userGroupId** | **String** | ID of the user group to share the entity group with. The user group must belong to the current user's owner or to one of its sub-customers | | +| **roleId** | **String** | ID of the group role that defines the set of operations to grant to the target user group | | ### Return type diff --git a/pe/docs/HomeDashboard.md b/pe/docs/HomeDashboard.md index 2933d5f6..c866b798 100644 --- a/pe/docs/HomeDashboard.md +++ b/pe/docs/HomeDashboard.md @@ -18,7 +18,7 @@ | **assignedCustomers** | **Set\** | List of assigned customers with their info. | [optional] | | **mobileHide** | **Boolean** | Hide dashboard from mobile devices. Useful if the dashboard is not designed for small screens. | [optional] [readonly] | | **mobileOrder** | **Integer** | Order on mobile devices. Useful to adjust sorting of the dashboards for mobile applications | [optional] [readonly] | -| **_configuration** | **com.fasterxml.jackson.databind.JsonNode** | | [optional] | +| **_configuration** | **com.fasterxml.jackson.databind.JsonNode** | JSON object with main configuration of the dashboard: layouts, widgets, aliases, etc. The JSON structure of the dashboard configuration is quite complex. The easiest way to learn it is to export existing dashboard to JSON. | [optional] | | **resources** | **List\** | | [optional] | | **version** | **Long** | | [optional] | | **hideDashboardToolbar** | **Boolean** | Hide dashboard toolbar flag. Useful for rendering dashboards on mobile. | [optional] | diff --git a/pe/docs/Job.md b/pe/docs/Job.md index 648ef474..cb526571 100644 --- a/pe/docs/Job.md +++ b/pe/docs/Job.md @@ -66,6 +66,7 @@ | reportTemplateId | ReportTemplateId | | [optional] | | userId | UserId | | [optional] | | timezone | String | | [optional] | +| makePublic | Boolean | | [optional] | | targets | List | | [optional] | | notificationTemplateId | NotificationTemplateId | | [optional] | | notificationRequests | List | | [optional] | @@ -163,7 +164,9 @@ | format | TbReportFormat | | | | name | String | | | | userId | UserId | | | +| publicKey | String | | [optional] | | ownerId | EntityId | JSON object with Customer or Tenant Id | [optional] [readonly] | +| _public | Boolean | | [optional] | #### NotificationTemplate | Name | Type | Description | Notes | @@ -221,6 +224,7 @@ | reportTemplateId | ReportTemplateId | | [optional] | | userId | UserId | | [optional] | | timezone | String | | [optional] | +| makePublic | Boolean | | [optional] | #### DeliveryMethodNotificationTemplate | Name | Type | Description | Notes | diff --git a/pe/docs/JobConfiguration.md b/pe/docs/JobConfiguration.md index c99209aa..bcf8f456 100644 --- a/pe/docs/JobConfiguration.md +++ b/pe/docs/JobConfiguration.md @@ -42,6 +42,7 @@ | reportTemplateId | ReportTemplateId | | [optional] | | userId | UserId | | [optional] | | timezone | String | | [optional] | +| makePublic | Boolean | | [optional] | | targets | List | | [optional] | | notificationTemplateId | NotificationTemplateId | | [optional] | | notificationRequests | List | | [optional] | @@ -160,6 +161,7 @@ | reportTemplateId | ReportTemplateId | | [optional] | | userId | UserId | | [optional] | | timezone | String | | [optional] | +| makePublic | Boolean | | [optional] | #### DeliveryMethodNotificationTemplate | Name | Type | Description | Notes | diff --git a/pe/docs/JobResult.md b/pe/docs/JobResult.md index 06d451fa..a54a65da 100644 --- a/pe/docs/JobResult.md +++ b/pe/docs/JobResult.md @@ -60,7 +60,9 @@ Job execution result | format | TbReportFormat | | | | name | String | | | | userId | UserId | | | +| publicKey | String | | [optional] | | ownerId | EntityId | JSON object with Customer or Tenant Id | [optional] [readonly] | +| _public | Boolean | | [optional] | #### TbReportFormat (enum) `PDF` | `CSV` diff --git a/pe/docs/LoginWhiteLabelingParams.md b/pe/docs/LoginWhiteLabelingParams.md index 547f1dfe..13a2e911 100644 --- a/pe/docs/LoginWhiteLabelingParams.md +++ b/pe/docs/LoginWhiteLabelingParams.md @@ -11,9 +11,11 @@ A JSON value representing the login white labeling configuration |------------ | ------------- | ------------- | -------------| | **logoImageUrl** | **String** | Logo image URL | [optional] | | **logoImageHeight** | **Integer** | The height of a logo container. Logo image will be automatically scaled. | [optional] | +| **collapsedLogoImageUrl** | **String** | Logo shown when side menu is collapsed | [optional] | | **appTitle** | **String** | White-labeled name of the platform | [optional] | | **favicon** | **Favicon** | JSON object that contains website icon url and type | [optional] | | **paletteSettings** | **PaletteSettings** | Complex JSON that describes structure of the Angular Material Palette. See [theming](https://material.angular.io/guide/theming) for more details | [optional] | +| **primaryColorPanels** | **Boolean** | Whether primary-color panels (top toolbar, side navigation, dialog and entity-details headers) use the primary palette color as background. When false, they render on a white background | [optional] | | **helpLinkBaseUrl** | **String** | Base URL for help link | [optional] | | **uiHelpBaseUrl** | **String** | Base URL for the repository with the UI help components (markdown) | [optional] | | **enableHelpLinks** | **Boolean** | Enable or Disable help links | [optional] | diff --git a/pe/docs/NotificationRequest.md b/pe/docs/NotificationRequest.md index e4000b35..00f5ee0d 100644 --- a/pe/docs/NotificationRequest.md +++ b/pe/docs/NotificationRequest.md @@ -72,6 +72,7 @@ | reportTemplateId | ReportTemplateId | | [optional] | | userId | UserId | | [optional] | | timezone | String | | [optional] | +| makePublic | Boolean | | [optional] | #### EntityType (enum) `TENANT` | `CUSTOMER` | `USER` | `DASHBOARD` | `ASSET` | `DEVICE` | `ALARM` | `ENTITY_GROUP` | `CONVERTER` | `INTEGRATION` | … (46 values total) diff --git a/pe/docs/NotificationRequestInfo.md b/pe/docs/NotificationRequestInfo.md index 3aa9ba58..3e5f84ec 100644 --- a/pe/docs/NotificationRequestInfo.md +++ b/pe/docs/NotificationRequestInfo.md @@ -77,6 +77,7 @@ | reportTemplateId | ReportTemplateId | | [optional] | | userId | UserId | | [optional] | | timezone | String | | [optional] | +| makePublic | Boolean | | [optional] | #### EntityType (enum) `TENANT` | `CUSTOMER` | `USER` | `DASHBOARD` | `ASSET` | `DEVICE` | `ALARM` | `ENTITY_GROUP` | `CONVERTER` | `INTEGRATION` | … (46 values total) diff --git a/pe/docs/NotificationTemplate.md b/pe/docs/NotificationTemplate.md index 42c9884c..b70b1de3 100644 --- a/pe/docs/NotificationTemplate.md +++ b/pe/docs/NotificationTemplate.md @@ -31,6 +31,7 @@ | reportTemplateId | ReportTemplateId | | [optional] | | userId | UserId | | [optional] | | timezone | String | | [optional] | +| makePublic | Boolean | | [optional] | #### DeliveryMethodNotificationTemplate | Name | Type | Description | Notes | diff --git a/pe/docs/NotificationTemplateConfig.md b/pe/docs/NotificationTemplateConfig.md index f68ac2f6..ae10a077 100644 --- a/pe/docs/NotificationTemplateConfig.md +++ b/pe/docs/NotificationTemplateConfig.md @@ -12,6 +12,7 @@ | **reportTemplateId** | **ReportTemplateId** | | [optional] | | **userId** | **UserId** | | [optional] | | **timezone** | **String** | | [optional] | +| **makePublic** | **Boolean** | | [optional] | diff --git a/pe/docs/PageDataDashboardInfo.md b/pe/docs/PageDataDashboardInfo.md index b65637b6..42af2a42 100644 --- a/pe/docs/PageDataDashboardInfo.md +++ b/pe/docs/PageDataDashboardInfo.md @@ -32,7 +32,7 @@ | assignedCustomers | Set | List of assigned customers with their info. | [optional] | | mobileHide | Boolean | Hide dashboard from mobile devices. Useful if the dashboard is not designed for small screens. | [optional] [readonly] | | mobileOrder | Integer | Order on mobile devices. Useful to adjust sorting of the dashboards for mobile applications | [optional] [readonly] | -| _configuration | com.fasterxml.jackson.databind.JsonNode | | [optional] | +| _configuration | com.fasterxml.jackson.databind.JsonNode | JSON object with main configuration of the dashboard: layouts, widgets, aliases, etc. The JSON structure of the dashboard configuration is quite complex. The easiest way to learn it is to export existing dashboard to JSON. | [optional] | | resources | List | | [optional] | | version | Long | | [optional] | | groups | List | Groups | [optional] | diff --git a/pe/docs/PageDataJob.md b/pe/docs/PageDataJob.md index 8f04ad19..2f4c61a8 100644 --- a/pe/docs/PageDataJob.md +++ b/pe/docs/PageDataJob.md @@ -74,6 +74,7 @@ | reportTemplateId | ReportTemplateId | | [optional] | | userId | UserId | | [optional] | | timezone | String | | [optional] | +| makePublic | Boolean | | [optional] | | targets | List | | [optional] | | notificationTemplateId | NotificationTemplateId | | [optional] | | notificationRequests | List | | [optional] | @@ -171,7 +172,9 @@ | format | TbReportFormat | | | | name | String | | | | userId | UserId | | | +| publicKey | String | | [optional] | | ownerId | EntityId | JSON object with Customer or Tenant Id | [optional] [readonly] | +| _public | Boolean | | [optional] | #### NotificationTemplate | Name | Type | Description | Notes | @@ -229,6 +232,7 @@ | reportTemplateId | ReportTemplateId | | [optional] | | userId | UserId | | [optional] | | timezone | String | | [optional] | +| makePublic | Boolean | | [optional] | #### DeliveryMethodNotificationTemplate | Name | Type | Description | Notes | diff --git a/pe/docs/PageDataNotificationRequestInfo.md b/pe/docs/PageDataNotificationRequestInfo.md index c40e6808..16d299a0 100644 --- a/pe/docs/PageDataNotificationRequestInfo.md +++ b/pe/docs/PageDataNotificationRequestInfo.md @@ -85,6 +85,7 @@ | reportTemplateId | ReportTemplateId | | [optional] | | userId | UserId | | [optional] | | timezone | String | | [optional] | +| makePublic | Boolean | | [optional] | #### EntityType (enum) `TENANT` | `CUSTOMER` | `USER` | `DASHBOARD` | `ASSET` | `DEVICE` | `ALARM` | `ENTITY_GROUP` | `CONVERTER` | `INTEGRATION` | … (46 values total) diff --git a/pe/docs/PageDataNotificationTemplate.md b/pe/docs/PageDataNotificationTemplate.md index e11ac754..a6595c7b 100644 --- a/pe/docs/PageDataNotificationTemplate.md +++ b/pe/docs/PageDataNotificationTemplate.md @@ -39,6 +39,7 @@ | reportTemplateId | ReportTemplateId | | [optional] | | userId | UserId | | [optional] | | timezone | String | | [optional] | +| makePublic | Boolean | | [optional] | #### DeliveryMethodNotificationTemplate | Name | Type | Description | Notes | diff --git a/pe/docs/PageDataReport.md b/pe/docs/PageDataReport.md index bc71b36f..dd2417c4 100644 --- a/pe/docs/PageDataReport.md +++ b/pe/docs/PageDataReport.md @@ -29,7 +29,9 @@ | format | TbReportFormat | | | | name | String | | | | userId | UserId | | | +| publicKey | String | | [optional] | | ownerId | EntityId | JSON object with Customer or Tenant Id | [optional] [readonly] | +| _public | Boolean | | [optional] | #### TbReportFormat (enum) `PDF` | `CSV` diff --git a/pe/docs/PageDataReportInfo.md b/pe/docs/PageDataReportInfo.md index 1b52a617..fb552f33 100644 --- a/pe/docs/PageDataReportInfo.md +++ b/pe/docs/PageDataReportInfo.md @@ -29,10 +29,12 @@ | format | TbReportFormat | | | | name | String | | | | userId | UserId | | | +| publicKey | String | | [optional] | | templateInfo | EntityInfo | | [optional] | | customerTitle | String | | [optional] | | userName | String | | [optional] | | ownerId | EntityId | JSON object with Customer or Tenant Id | [optional] [readonly] | +| _public | Boolean | | [optional] | #### TbReportFormat (enum) `PDF` | `CSV` diff --git a/pe/docs/Report.md b/pe/docs/Report.md index 7e32756d..c52dc28d 100644 --- a/pe/docs/Report.md +++ b/pe/docs/Report.md @@ -15,7 +15,9 @@ | **format** | **TbReportFormat** | | | | **name** | **String** | | | | **userId** | **UserId** | | | +| **publicKey** | **String** | | [optional] | | **ownerId** | **EntityId** | JSON object with Customer or Tenant Id | [optional] [readonly] | +| **_public** | **Boolean** | | [optional] | diff --git a/pe/docs/ReportControllerApi.md b/pe/docs/ReportControllerApi.md index 14c75ad7..a927c11b 100644 --- a/pe/docs/ReportControllerApi.md +++ b/pe/docs/ReportControllerApi.md @@ -6,12 +6,14 @@ Report createReport(@Nullable CreateReportRequest createReportRequest) // createReport void deleteReport(@Nonnull String reportId) // Delete Report (deleteReport) File downloadReport(@Nonnull UUID reportId) // downloadReport +File downloadReportByPublicKey(@Nonnull String publicKey) // Download report by public key (downloadReportByPublicKey) Report getReportById(@Nonnull String reportId) // Get Report (getReportById) PageDataReportInfo getReportInfos(@Nonnull Integer pageSize, @Nonnull Integer page, @Nullable UUID reportTemplateId, @Nullable UUID userId, @Nullable Boolean includeCustomers, @Nullable String textSearch, @Nullable String sortProperty, @Nullable String sortOrder) // getReportInfos List getReportInfosByIds(@Nonnull List strReportIds) // getReportInfosByIds PageDataReport getReports(@Nonnull Integer pageSize, @Nonnull Integer page, @Nullable String textSearch, @Nullable String sortProperty, @Nullable String sortOrder, @Nullable Boolean includeCustomers) // getReports Job requestReport(@Nonnull ReportRequest reportRequest) // requestReport File testReportAndDownload(@Nonnull ReportRequest reportRequest) // Download test report (testReportAndDownload) +Report updateReportPublicStatus(@Nonnull UUID reportId, @Nonnull Boolean isPublic) // Update Report public status (updateReportPublicStatus) ``` @@ -83,6 +85,30 @@ downloadReport **File** +## downloadReportByPublicKey + +``` +File downloadReportByPublicKey(@Nonnull String publicKey) +``` + +**GET** `/api/v2/report/public/{publicKey}/download` + +Download report by public key (downloadReportByPublicKey) + +Downloads the report identified by its public key. This endpoint is intentionally public: it requires no authentication and is accessible to anyone in possession of the report's random public key. It only returns data for reports that have been explicitly made public (see updateReportPublicStatus). + + +### Parameters + +| Name | Type | Description | Notes | +|------------- | ------------- | ------------- | -------------| +| **publicKey** | **String** | The random public key of the report | | + +### Return type + +**File** + + ## getReportById ``` @@ -230,3 +256,28 @@ Generate and download test report. Available for users with 'TENANT_ADMIN' or ' **File** + +## updateReportPublicStatus + +``` +Report updateReportPublicStatus(@Nonnull UUID reportId, @Nonnull Boolean isPublic) +``` + +**PUT** `/api/v2/report/{reportId}/public/{isPublic}` + +Update Report public status (updateReportPublicStatus) + +Updates the public status of the report. When public, the report can be downloaded without authentication via the public link. Available for users with 'TENANT_ADMIN' or 'CUSTOMER_USER' authority. + + +### Parameters + +| Name | Type | Description | Notes | +|------------- | ------------- | ------------- | -------------| +| **reportId** | **UUID** | A string value representing the report id. For example, '784f394c-42b6-435a-983c-b7beff2784f9' | | +| **isPublic** | **Boolean** | Whether the report should be publicly downloadable without authentication | | + +### Return type + +**Report** + diff --git a/pe/docs/ReportInfo.md b/pe/docs/ReportInfo.md index f0c6e553..12fc28d4 100644 --- a/pe/docs/ReportInfo.md +++ b/pe/docs/ReportInfo.md @@ -15,10 +15,12 @@ | **format** | **TbReportFormat** | | | | **name** | **String** | | | | **userId** | **UserId** | | | +| **publicKey** | **String** | | [optional] | | **templateInfo** | **EntityInfo** | | [optional] | | **customerTitle** | **String** | | [optional] | | **userName** | **String** | | [optional] | | **ownerId** | **EntityId** | JSON object with Customer or Tenant Id | [optional] [readonly] | +| **_public** | **Boolean** | | [optional] | diff --git a/pe/docs/ReportJobConfiguration.md b/pe/docs/ReportJobConfiguration.md index b77d6f07..4a7af441 100644 --- a/pe/docs/ReportJobConfiguration.md +++ b/pe/docs/ReportJobConfiguration.md @@ -12,6 +12,7 @@ | **reportTemplateId** | **ReportTemplateId** | | [optional] | | **userId** | **UserId** | | [optional] | | **timezone** | **String** | | [optional] | +| **makePublic** | **Boolean** | | [optional] | | **targets** | **List\** | | [optional] | | **notificationTemplateId** | **NotificationTemplateId** | | [optional] | | **notificationRequests** | **List\** | | [optional] | @@ -139,6 +140,7 @@ | reportTemplateId | ReportTemplateId | | [optional] | | userId | UserId | | [optional] | | timezone | String | | [optional] | +| makePublic | Boolean | | [optional] | #### DeliveryMethodNotificationTemplate | Name | Type | Description | Notes | diff --git a/pe/docs/ReportJobResult.md b/pe/docs/ReportJobResult.md index e75d8b16..08d27a65 100644 --- a/pe/docs/ReportJobResult.md +++ b/pe/docs/ReportJobResult.md @@ -42,7 +42,9 @@ | format | TbReportFormat | | | | name | String | | | | userId | UserId | | | +| publicKey | String | | [optional] | | ownerId | EntityId | JSON object with Customer or Tenant Id | [optional] [readonly] | +| _public | Boolean | | [optional] | #### TaskResult | Name | Type | Description | Notes | diff --git a/pe/docs/ReportRequest.md b/pe/docs/ReportRequest.md index 5eac2291..d7320890 100644 --- a/pe/docs/ReportRequest.md +++ b/pe/docs/ReportRequest.md @@ -11,6 +11,7 @@ | **reportTemplateConfig** | **ReportTemplateConfig** | Json object representing the report template config. | [optional] | | **timezone** | **String** | Timezone used for report generation. | [optional] | | **userId** | **String** | A string value representing the user id. | [optional] | +| **makePublic** | **Boolean** | A boolean value indicating whether the generated report should be made public. | [optional] | | **originator** | **EntityId** | Json object representing the originator id. | [optional] | | **targets** | **List\** | | [optional] | | **notificationTemplateId** | **NotificationTemplateId** | | [optional] | diff --git a/pe/docs/ReportTaskResult.md b/pe/docs/ReportTaskResult.md index 0648628b..25d9c20b 100644 --- a/pe/docs/ReportTaskResult.md +++ b/pe/docs/ReportTaskResult.md @@ -38,7 +38,9 @@ | format | TbReportFormat | | | | name | String | | | | userId | UserId | | | +| publicKey | String | | [optional] | | ownerId | EntityId | JSON object with Customer or Tenant Id | [optional] [readonly] | +| _public | Boolean | | [optional] | #### TbReportFormat (enum) `PDF` | `CSV` diff --git a/pe/docs/WhiteLabelingParams.md b/pe/docs/WhiteLabelingParams.md index bcf5dc3e..f248858b 100644 --- a/pe/docs/WhiteLabelingParams.md +++ b/pe/docs/WhiteLabelingParams.md @@ -11,9 +11,11 @@ A JSON value representing the white labeling configuration |------------ | ------------- | ------------- | -------------| | **logoImageUrl** | **String** | Logo image URL | [optional] | | **logoImageHeight** | **Integer** | The height of a logo container. Logo image will be automatically scaled. | [optional] | +| **collapsedLogoImageUrl** | **String** | Logo shown when side menu is collapsed | [optional] | | **appTitle** | **String** | White-labeled name of the platform | [optional] | | **favicon** | **Favicon** | JSON object that contains website icon url and type | [optional] | | **paletteSettings** | **PaletteSettings** | Complex JSON that describes structure of the Angular Material Palette. See [theming](https://material.angular.io/guide/theming) for more details | [optional] | +| **primaryColorPanels** | **Boolean** | Whether primary-color panels (top toolbar, side navigation, dialog and entity-details headers) use the primary palette color as background. When false, they render on a white background | [optional] | | **helpLinkBaseUrl** | **String** | Base URL for help link | [optional] | | **uiHelpBaseUrl** | **String** | Base URL for the repository with the UI help components (markdown) | [optional] | | **enableHelpLinks** | **Boolean** | Enable or Disable help links | [optional] | diff --git a/pe/spec/openapi.json b/pe/spec/openapi.json index 089da166..d271fd44 100644 --- a/pe/spec/openapi.json +++ b/pe/spec/openapi.json @@ -16,7 +16,7 @@ }, "servers": [ { - "url": "http://localhost:8080", + "url": "http://localhost:38971", "description": "Generated server url" } ], @@ -4409,11 +4409,6 @@ ], "requestBody": { "content": { - "text/plain": { - "schema": { - "type": "string" - } - }, "application/json": { "schema": { "$ref": "#/components/schemas/JsonNode" @@ -4542,7 +4537,6 @@ } } }, - "deprecated": true, "security": [ { "HttpLoginForm": [] @@ -7753,7 +7747,7 @@ "alarm-controller" ], "summary": "Create or Update Alarm (saveAlarm)", - "description": "Creates or Updates the Alarm. When creating alarm, platform generates Alarm Id as [time-based UUID](https://en.wikipedia.org/wiki/Universally_unique_identifier#Version_1_(date-time_and_MAC_address)). The newly created Alarm id will be present in the response. Specify existing Alarm id to update the alarm. Referencing non-existing Alarm Id will cause 'Not Found' error. \n\nPlatform also deduplicate the alarms based on the entity id of originator and alarm 'type'. For example, if the user or system component create the alarm with the type 'HighTemperature' for device 'Device A' the new active alarm is created. If the user tries to create 'HighTemperature' alarm for the same device again, the previous alarm will be updated (the 'end_ts' will be set to current timestamp). If the user clears the alarm (see 'Clear Alarm(clearAlarm)'), than new alarm with the same type and same device may be created. Remove 'id', 'tenantId' and optionally 'customerId' from the request body example (below) to create new Alarm entity. \n\nAvailable for users with 'TENANT_ADMIN' or 'CUSTOMER_USER' authority. Security check is performed to verify that the user has 'WRITE' permission for the entity (entities).", + "description": "Creates or Updates the Alarm. When creating alarm, platform generates Alarm Id as [time-based UUID](https://en.wikipedia.org/wiki/Universally_unique_identifier#Version_1_(date-time_and_MAC_address)). The newly created Alarm id will be present in the response. Specify existing Alarm id to update the alarm. Referencing non-existing Alarm Id will cause 'Not Found' error. \n\nPlatform also deduplicate the alarms based on the entity id of originator and alarm 'type'. For example, if the user or system component create the alarm with the type 'HighTemperature' for device 'Device A' the new active alarm is created. If the user tries to create 'HighTemperature' alarm for the same device again, the previous alarm will be updated (the 'end_ts' will be set to current timestamp). If the user clears the alarm (see 'Clear Alarm(clearAlarm)'), than new alarm with the same type and same device may be created. Remove 'id', 'tenantId' and optionally 'customerId' from the request body example (below) to create new Alarm entity. \n\nThe alarm originator is an immutable routing key: when updating an existing alarm, the 'originator' in the request body must match the stored alarm's originator. A request that references an existing alarm id but carries a different originator is treated as a lookup miss and causes a 'Not Found' error. \n\nAvailable for users with 'TENANT_ADMIN' or 'CUSTOMER_USER' authority. Security check is performed to verify that the user has 'WRITE' permission for the entity (entities).", "operationId": "saveAlarm", "requestBody": { "description": "A JSON value representing the alarm.", @@ -49564,13 +49558,13 @@ "entity-group-controller" ], "summary": "Share the Entity Group with User group (shareEntityGroupToChildOwnerUserGroup)", - "description": "Share the entity group with specified user group using specified role. \n\nAvailable for users with 'TENANT_ADMIN' or 'CUSTOMER_USER' authority. Security check is performed to verify that the user has 'WRITE' permission for specified group.", + "description": "Share the entity group with the specified user group using the specified role. Unlike the 'shareEntityGroup' API method, this method is designed for sharing 'down' the owner hierarchy and does not require 'WRITE' permission for the shared entity group or the target user group. In particular, it allows the current user to re-share an entity group that was shared with them by the parent owner: for example, a customer user may re-share a tenant-owned dashboard group with a user group of their sub-customer.\n\nThe following security checks are performed:\n\n* the target user group must belong to the current user's owner or to one of its sub-customers;\n* the current user must have the 'SHARE_GROUP' operation granted for the shared entity group: either as a generic permission for the corresponding entity group resource (applies only if the shared entity group belongs to the current user's owner hierarchy), or as a group permission created when the entity group was shared with the current user's user group using a group role that includes the 'SHARE_GROUP' operation;\n* the specified role must be a group role that is readable by the current user, so it must belong to the current user's owner or to one of its sub-customers;\n* the operations of the specified role must be a subset of the operations the current user was granted for the shared entity group (always passes if the current user was granted the 'ALL' operation).\n\nIf the specified role also includes the 'SHARE_GROUP' operation, the members of the target user group will be able to re-share the entity group further down their own owner hierarchy in the same way.\n\nAvailable for users with 'TENANT_ADMIN' or 'CUSTOMER_USER' authority.", "operationId": "shareEntityGroupToChildOwnerUserGroup", "parameters": [ { "name": "entityGroupId", "in": "path", - "description": "A string value representing the Entity Group Id that you would like to share. For example, '784f394c-42b6-435a-983c-b7beff2784f9'", + "description": "ID of the entity group to share", "required": true, "schema": { "type": "string" @@ -49579,7 +49573,7 @@ { "name": "userGroupId", "in": "path", - "description": "A string value representing the Entity(User) Group Id that you would like to share with. For example, '784f394c-42b6-435a-983c-b7beff2784f9'", + "description": "ID of the user group to share the entity group with. The user group must belong to the current user's owner or to one of its sub-customers", "required": true, "schema": { "type": "string" @@ -49588,7 +49582,7 @@ { "name": "roleId", "in": "path", - "description": "A string value representing the Role Id that describes set of permissions you would like to share (read, write, etc). For example, '784f394c-42b6-435a-983c-b7beff2784f9'", + "description": "ID of the group role that defines the set of operations to grant to the target user group", "required": true, "schema": { "type": "string" @@ -79935,6 +79929,153 @@ ] } }, + "/api/v2/report/public/{publicKey}/download": { + "get": { + "tags": [ + "report-controller" + ], + "summary": "Download report by public key (downloadReportByPublicKey)", + "description": "Downloads the report identified by its public key. This endpoint is intentionally public: it requires no authentication and is accessible to anyone in possession of the report's random public key. It only returns data for reports that have been explicitly made public (see updateReportPublicStatus).", + "operationId": "downloadReportByPublicKey", + "parameters": [ + { + "name": "publicKey", + "in": "path", + "description": "The random public key of the report", + "required": true, + "schema": { + "type": "string" + } + } + ], + "responses": { + "200": { + "description": "OK", + "content": { + "application/json": { + "schema": { + "type": "string", + "format": "binary" + } + } + } + }, + "400": { + "description": "Bad Request", + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/ThingsboardErrorResponse" + }, + "examples": { + "error-code-400": { + "summary": "Bad Request", + "value": { + "status": 400, + "message": "Invalid UUID string: 123", + "errorCode": 31, + "timestamp": 1609459200000 + } + } + } + } + } + }, + "401": { + "description": "Unauthorized", + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/ThingsboardErrorResponse" + }, + "examples": { + "error-code-401": { + "summary": "Unauthorized", + "value": { + "status": 401, + "message": "Authentication failed", + "errorCode": 10, + "timestamp": 1609459200000 + } + } + } + } + } + }, + "403": { + "description": "Forbidden", + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/ThingsboardErrorResponse" + }, + "examples": { + "error-code-403": { + "summary": "Forbidden", + "value": { + "status": 403, + "message": "You don't have permission to perform this operation!", + "errorCode": 20, + "timestamp": 1609459200000 + } + } + } + } + } + }, + "404": { + "description": "Not Found", + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/ThingsboardErrorResponse" + }, + "examples": { + "error-code-404": { + "summary": "Not Found", + "value": { + "status": 404, + "message": "Requested item wasn't found!", + "errorCode": 32, + "timestamp": 1609459200000 + } + } + } + } + } + }, + "429": { + "description": "Too Many Requests", + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/ThingsboardErrorResponse" + }, + "examples": { + "error-code-429": { + "summary": "Too Many Requests", + "value": { + "status": 429, + "message": "Too many requests for current tenant!", + "errorCode": 33, + "timestamp": 1609459200000 + } + } + } + } + } + } + }, + "security": [ + { + "HttpLoginForm": [] + }, + { + "ApiKeyForm": [] + } + ] + } + }, "/api/v2/report/request": { "post": { "tags": [ @@ -80654,6 +80795,162 @@ ] } }, + "/api/v2/report/{reportId}/public/{isPublic}": { + "put": { + "tags": [ + "report-controller" + ], + "summary": "Update Report public status (updateReportPublicStatus)", + "description": "Updates the public status of the report. When public, the report can be downloaded without authentication via the public link. \n\nAvailable for users with 'TENANT_ADMIN' or 'CUSTOMER_USER' authority.", + "operationId": "updateReportPublicStatus", + "parameters": [ + { + "name": "reportId", + "in": "path", + "description": "A string value representing the report id. For example, '784f394c-42b6-435a-983c-b7beff2784f9'", + "required": true, + "schema": { + "type": "string", + "format": "uuid" + } + }, + { + "name": "isPublic", + "in": "path", + "description": "Whether the report should be publicly downloadable without authentication", + "required": true, + "schema": { + "type": "boolean" + } + } + ], + "responses": { + "200": { + "description": "OK", + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/Report" + } + } + } + }, + "400": { + "description": "Bad Request", + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/ThingsboardErrorResponse" + }, + "examples": { + "error-code-400": { + "summary": "Bad Request", + "value": { + "status": 400, + "message": "Invalid UUID string: 123", + "errorCode": 31, + "timestamp": 1609459200000 + } + } + } + } + } + }, + "401": { + "description": "Unauthorized", + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/ThingsboardErrorResponse" + }, + "examples": { + "error-code-401": { + "summary": "Unauthorized", + "value": { + "status": 401, + "message": "Authentication failed", + "errorCode": 10, + "timestamp": 1609459200000 + } + } + } + } + } + }, + "403": { + "description": "Forbidden", + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/ThingsboardErrorResponse" + }, + "examples": { + "error-code-403": { + "summary": "Forbidden", + "value": { + "status": 403, + "message": "You don't have permission to perform this operation!", + "errorCode": 20, + "timestamp": 1609459200000 + } + } + } + } + } + }, + "404": { + "description": "Not Found", + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/ThingsboardErrorResponse" + }, + "examples": { + "error-code-404": { + "summary": "Not Found", + "value": { + "status": 404, + "message": "Requested item wasn't found!", + "errorCode": 32, + "timestamp": 1609459200000 + } + } + } + } + } + }, + "429": { + "description": "Too Many Requests", + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/ThingsboardErrorResponse" + }, + "examples": { + "error-code-429": { + "summary": "Too Many Requests", + "value": { + "status": 429, + "message": "Too many requests for current tenant!", + "errorCode": 33, + "timestamp": 1609459200000 + } + } + } + } + } + } + }, + "security": [ + { + "HttpLoginForm": [] + }, + { + "ApiKeyForm": [] + } + ] + } + }, "/api/v2/reportInfos": { "get": { "tags": [ @@ -123872,7 +124169,8 @@ "readOnly": true }, "configuration": { - "$ref": "#/components/schemas/JsonNode" + "$ref": "#/components/schemas/JsonNode", + "description": "JSON object with main configuration of the dashboard: layouts, widgets, aliases, etc. The JSON structure of the dashboard configuration is quite complex. The easiest way to learn it is to export existing dashboard to JSON." }, "resources": { "type": "array", @@ -124080,7 +124378,8 @@ "readOnly": true }, "configuration": { - "$ref": "#/components/schemas/JsonNode" + "$ref": "#/components/schemas/JsonNode", + "description": "JSON object with main configuration of the dashboard: layouts, widgets, aliases, etc. The JSON structure of the dashboard configuration is quite complex. The easiest way to learn it is to export existing dashboard to JSON." }, "resources": { "type": "array", @@ -130275,7 +130574,8 @@ "readOnly": true }, "configuration": { - "$ref": "#/components/schemas/JsonNode" + "$ref": "#/components/schemas/JsonNode", + "description": "JSON object with main configuration of the dashboard: layouts, widgets, aliases, etc. The JSON structure of the dashboard configuration is quite complex. The easiest way to learn it is to export existing dashboard to JSON." }, "resources": { "type": "array", @@ -131675,6 +131975,11 @@ "format": "int32", "description": "The height of a logo container. Logo image will be automatically scaled." }, + "collapsedLogoImageUrl": { + "type": "string", + "description": "Logo shown when side menu is collapsed", + "example": "https://company.com/images/collapsed-logo.png" + }, "appTitle": { "type": "string", "description": "White-labeled name of the platform", @@ -131688,6 +131993,10 @@ "$ref": "#/components/schemas/PaletteSettings", "description": "Complex JSON that describes structure of the Angular Material Palette. See [theming](https://material.angular.io/guide/theming) for more details" }, + "primaryColorPanels": { + "type": "boolean", + "description": "Whether primary-color panels (top toolbar, side navigation, dialog and entity-details headers) use the primary palette color as background. When false, they render on a white background" + }, "helpLinkBaseUrl": { "type": "string", "description": "Base URL for help link" @@ -133902,6 +134211,9 @@ }, "timezone": { "type": "string" + }, + "makePublic": { + "type": "boolean" } }, "required": [ @@ -138463,10 +138775,16 @@ "userId": { "$ref": "#/components/schemas/UserId" }, + "publicKey": { + "type": "string" + }, "ownerId": { "$ref": "#/components/schemas/EntityId", "description": "JSON object with Customer or Tenant Id", "readOnly": true + }, + "public": { + "type": "boolean" } }, "required": [ @@ -138729,6 +139047,9 @@ "userId": { "$ref": "#/components/schemas/UserId" }, + "publicKey": { + "type": "string" + }, "templateInfo": { "$ref": "#/components/schemas/EntityInfo" }, @@ -138742,6 +139063,9 @@ "$ref": "#/components/schemas/EntityId", "description": "JSON object with Customer or Tenant Id", "readOnly": true + }, + "public": { + "type": "boolean" } }, "required": [ @@ -138769,6 +139093,9 @@ "timezone": { "type": "string" }, + "makePublic": { + "type": "boolean" + }, "targets": { "type": "array", "items": { @@ -138816,6 +139143,7 @@ "id": "784f394c-42b6-435a-983c-b7beff2784f9" }, "timezone": null, + "makePublic": null, "targets": null, "notificationTemplateId": { "entityType": "NOTIFICATION_TEMPLATE", @@ -138918,10 +139246,12 @@ "entityType": "USER", "id": "784f394c-42b6-435a-983c-b7beff2784f9" }, + "publicKey": null, "ownerId": { "entityType": "DEVICE", "id": "784f394c-42b6-435a-983c-b7beff2784f9" - } + }, + "public": null } } }, @@ -139085,6 +139415,11 @@ "description": "A string value representing the user id.", "example": "784f394c-42b6-435a-983c-b7beff2784f9" }, + "makePublic": { + "type": "boolean", + "description": "A boolean value indicating whether the generated report should be made public.", + "example": false + }, "originator": { "$ref": "#/components/schemas/EntityId", "description": "Json object representing the originator id." @@ -146678,6 +147013,11 @@ "format": "int32", "description": "The height of a logo container. Logo image will be automatically scaled." }, + "collapsedLogoImageUrl": { + "type": "string", + "description": "Logo shown when side menu is collapsed", + "example": "https://company.com/images/collapsed-logo.png" + }, "appTitle": { "type": "string", "description": "White-labeled name of the platform", @@ -146691,6 +147031,10 @@ "$ref": "#/components/schemas/PaletteSettings", "description": "Complex JSON that describes structure of the Angular Material Palette. See [theming](https://material.angular.io/guide/theming) for more details" }, + "primaryColorPanels": { + "type": "boolean", + "description": "Whether primary-color panels (top toolbar, side navigation, dialog and entity-details headers) use the primary palette color as background. When false, they render on a white background" + }, "helpLinkBaseUrl": { "type": "string", "description": "Base URL for help link" diff --git a/pe/src/main/java/org/thingsboard/client/ApiClient.java b/pe/src/main/java/org/thingsboard/client/ApiClient.java index 9eb6f0f7..d450e022 100644 --- a/pe/src/main/java/org/thingsboard/client/ApiClient.java +++ b/pe/src/main/java/org/thingsboard/client/ApiClient.java @@ -173,7 +173,7 @@ public static List parameterToPairs( public ApiClient() { this.builder = createDefaultHttpClientBuilder(); this.mapper = createDefaultObjectMapper(); - updateBaseUri("http://localhost:8080"); + updateBaseUri("http://localhost:38971"); interceptor = null; readTimeout = null; connectTimeout = null; @@ -191,7 +191,7 @@ public ApiClient() { public ApiClient(HttpClient.Builder builder, ObjectMapper mapper, String baseUri) { this.builder = builder; this.mapper = mapper; - updateBaseUri(baseUri != null ? baseUri : "http://localhost:8080"); + updateBaseUri(baseUri != null ? baseUri : "http://localhost:38971"); interceptor = null; readTimeout = null; connectTimeout = null; diff --git a/pe/src/main/java/org/thingsboard/client/api/ThingsboardApi.java b/pe/src/main/java/org/thingsboard/client/api/ThingsboardApi.java index cd27a0e5..8779c957 100644 --- a/pe/src/main/java/org/thingsboard/client/api/ThingsboardApi.java +++ b/pe/src/main/java/org/thingsboard/client/api/ThingsboardApi.java @@ -10435,6 +10435,82 @@ private HttpRequest.Builder downloadReportRequestBuilder(@Nonnull UUID reportId, return localVarRequestBuilder; } + /** + * Download report by public key (downloadReportByPublicKey) + * Downloads the report identified by its public key. This endpoint is intentionally public: it requires no authentication and is accessible to anyone in possession of the report's random public key. It only returns data for reports that have been explicitly made public (see updateReportPublicStatus). + * @param publicKey The random public key of the report (required) + * @return File + * @throws ApiException if fails to make API call + */ + public File downloadReportByPublicKey(@Nonnull String publicKey) throws ApiException { + ApiResponse localVarResponse = downloadReportByPublicKeyWithHttpInfo(publicKey, null); + return localVarResponse.getData(); + } + + /** + * Download report by public key (downloadReportByPublicKey) + * Downloads the report identified by its public key. This endpoint is intentionally public: it requires no authentication and is accessible to anyone in possession of the report's random public key. It only returns data for reports that have been explicitly made public (see updateReportPublicStatus). + * @param publicKey The random public key of the report (required) + * @param headers Optional headers to include in the request + * @return ApiResponse<File> + * @throws ApiException if fails to make API call + */ + public ApiResponse downloadReportByPublicKeyWithHttpInfo(@Nonnull String publicKey, Map headers) throws ApiException { + HttpRequest.Builder localVarRequestBuilder = downloadReportByPublicKeyRequestBuilder(publicKey, headers); + try { + HttpResponse localVarResponse = memberVarHttpClient.send( + localVarRequestBuilder.build(), + HttpResponse.BodyHandlers.ofInputStream()); + if (memberVarResponseInterceptor != null) { + memberVarResponseInterceptor.accept(localVarResponse); + } + InputStream localVarResponseBody = null; + try { + if (localVarResponse.statusCode()/ 100 != 2) { + throw getApiException("downloadReportByPublicKey", localVarResponse); + } + localVarResponseBody = ApiClient.getResponseBody(localVarResponse); + if (localVarResponseBody == null) { + return new ApiResponse(localVarResponse.statusCode(), localVarResponse.headers().map(), null); + } + File responseValue = downloadFileFromResponse(localVarResponse, localVarResponseBody); + return new ApiResponse(localVarResponse.statusCode(), localVarResponse.headers().map(), responseValue); + } finally { + if (localVarResponseBody != null) { + localVarResponseBody.close(); + } + } + } catch (IOException e) { + throw new ApiException(e); + } + catch (InterruptedException e) { + Thread.currentThread().interrupt(); + throw new ApiException(e); + } + } + + private HttpRequest.Builder downloadReportByPublicKeyRequestBuilder(@Nonnull String publicKey, Map headers) throws ApiException { + // verify the required parameter 'publicKey' is set + if (publicKey == null) { + throw new ApiException(400, "Missing the required parameter 'publicKey' when calling downloadReportByPublicKey"); + } + HttpRequest.Builder localVarRequestBuilder = HttpRequest.newBuilder(); + String localVarPath = "/api/v2/report/public/{publicKey}/download" + .replace("{publicKey}", ApiClient.urlEncode(publicKey.toString())); + localVarRequestBuilder.uri(URI.create(memberVarBaseUri + localVarPath)); + localVarRequestBuilder.header("Accept", "application/json"); + localVarRequestBuilder.method("GET", HttpRequest.BodyPublishers.noBody()); + if (memberVarReadTimeout != null) { + localVarRequestBuilder.timeout(memberVarReadTimeout); + } + // Add custom headers if provided + localVarRequestBuilder = HttpRequestBuilderExtensions.withAdditionalHeaders(localVarRequestBuilder, headers); + if (memberVarInterceptor != null) { + memberVarInterceptor.accept(localVarRequestBuilder); + } + return localVarRequestBuilder; + } + /** * Download Resource (downloadResource) * Download Resource based on the provided Resource Id. Available for users with 'SYS_ADMIN' or 'TENANT_ADMIN' authority. @@ -54571,7 +54647,7 @@ private HttpRequest.Builder saveAiModelRequestBuilder(@Nonnull AiModel aiModel, /** * Create or Update Alarm (saveAlarm) - * Creates or Updates the Alarm. When creating alarm, platform generates Alarm Id as [time-based UUID](https://en.wikipedia.org/wiki/Universally_unique_identifier#Version_1_(date-time_and_MAC_address)). The newly created Alarm id will be present in the response. Specify existing Alarm id to update the alarm. Referencing non-existing Alarm Id will cause 'Not Found' error. Platform also deduplicate the alarms based on the entity id of originator and alarm 'type'. For example, if the user or system component create the alarm with the type 'HighTemperature' for device 'Device A' the new active alarm is created. If the user tries to create 'HighTemperature' alarm for the same device again, the previous alarm will be updated (the 'end_ts' will be set to current timestamp). If the user clears the alarm (see 'Clear Alarm(clearAlarm)'), than new alarm with the same type and same device may be created. Remove 'id', 'tenantId' and optionally 'customerId' from the request body example (below) to create new Alarm entity. Available for users with 'TENANT_ADMIN' or 'CUSTOMER_USER' authority. Security check is performed to verify that the user has 'WRITE' permission for the entity (entities). + * Creates or Updates the Alarm. When creating alarm, platform generates Alarm Id as [time-based UUID](https://en.wikipedia.org/wiki/Universally_unique_identifier#Version_1_(date-time_and_MAC_address)). The newly created Alarm id will be present in the response. Specify existing Alarm id to update the alarm. Referencing non-existing Alarm Id will cause 'Not Found' error. Platform also deduplicate the alarms based on the entity id of originator and alarm 'type'. For example, if the user or system component create the alarm with the type 'HighTemperature' for device 'Device A' the new active alarm is created. If the user tries to create 'HighTemperature' alarm for the same device again, the previous alarm will be updated (the 'end_ts' will be set to current timestamp). If the user clears the alarm (see 'Clear Alarm(clearAlarm)'), than new alarm with the same type and same device may be created. Remove 'id', 'tenantId' and optionally 'customerId' from the request body example (below) to create new Alarm entity. The alarm originator is an immutable routing key: when updating an existing alarm, the 'originator' in the request body must match the stored alarm's originator. A request that references an existing alarm id but carries a different originator is treated as a lookup miss and causes a 'Not Found' error. Available for users with 'TENANT_ADMIN' or 'CUSTOMER_USER' authority. Security check is performed to verify that the user has 'WRITE' permission for the entity (entities). * @param alarm A JSON value representing the alarm. (required) * @return Alarm * @throws ApiException if fails to make API call @@ -54583,7 +54659,7 @@ public Alarm saveAlarm(@Nonnull Alarm alarm) throws ApiException { /** * Create or Update Alarm (saveAlarm) - * Creates or Updates the Alarm. When creating alarm, platform generates Alarm Id as [time-based UUID](https://en.wikipedia.org/wiki/Universally_unique_identifier#Version_1_(date-time_and_MAC_address)). The newly created Alarm id will be present in the response. Specify existing Alarm id to update the alarm. Referencing non-existing Alarm Id will cause 'Not Found' error. Platform also deduplicate the alarms based on the entity id of originator and alarm 'type'. For example, if the user or system component create the alarm with the type 'HighTemperature' for device 'Device A' the new active alarm is created. If the user tries to create 'HighTemperature' alarm for the same device again, the previous alarm will be updated (the 'end_ts' will be set to current timestamp). If the user clears the alarm (see 'Clear Alarm(clearAlarm)'), than new alarm with the same type and same device may be created. Remove 'id', 'tenantId' and optionally 'customerId' from the request body example (below) to create new Alarm entity. Available for users with 'TENANT_ADMIN' or 'CUSTOMER_USER' authority. Security check is performed to verify that the user has 'WRITE' permission for the entity (entities). + * Creates or Updates the Alarm. When creating alarm, platform generates Alarm Id as [time-based UUID](https://en.wikipedia.org/wiki/Universally_unique_identifier#Version_1_(date-time_and_MAC_address)). The newly created Alarm id will be present in the response. Specify existing Alarm id to update the alarm. Referencing non-existing Alarm Id will cause 'Not Found' error. Platform also deduplicate the alarms based on the entity id of originator and alarm 'type'. For example, if the user or system component create the alarm with the type 'HighTemperature' for device 'Device A' the new active alarm is created. If the user tries to create 'HighTemperature' alarm for the same device again, the previous alarm will be updated (the 'end_ts' will be set to current timestamp). If the user clears the alarm (see 'Clear Alarm(clearAlarm)'), than new alarm with the same type and same device may be created. Remove 'id', 'tenantId' and optionally 'customerId' from the request body example (below) to create new Alarm entity. The alarm originator is an immutable routing key: when updating an existing alarm, the 'originator' in the request body must match the stored alarm's originator. A request that references an existing alarm id but carries a different originator is treated as a lookup miss and causes a 'Not Found' error. Available for users with 'TENANT_ADMIN' or 'CUSTOMER_USER' authority. Security check is performed to verify that the user has 'WRITE' permission for the entity (entities). * @param alarm A JSON value representing the alarm. (required) * @param headers Optional headers to include in the request * @return ApiResponse<Alarm> @@ -60672,10 +60748,8 @@ private HttpRequest.Builder sendAddonAccessErrorRequestBuilder(@Nonnull String a * @param acceptLanguage (optional) * @return List<Object> * @throws ApiException if fails to make API call - * @deprecated */ - @Deprecated - public List sendChatMessage(@Nonnull UUID chatId, @Nonnull String xAuthorization, @Nonnull String body, @Nullable String acceptLanguage) throws ApiException { + public List sendChatMessage(@Nonnull UUID chatId, @Nonnull String xAuthorization, @Nullable Object body, @Nullable String acceptLanguage) throws ApiException { ApiResponse> localVarResponse = sendChatMessageWithHttpInfo(chatId, xAuthorization, body, acceptLanguage, null); return localVarResponse.getData(); } @@ -60690,10 +60764,8 @@ public List sendChatMessage(@Nonnull UUID chatId, @Nonnull String xAutho * @param headers Optional headers to include in the request * @return ApiResponse<List<Object>> * @throws ApiException if fails to make API call - * @deprecated */ - @Deprecated - public ApiResponse> sendChatMessageWithHttpInfo(@Nonnull UUID chatId, @Nonnull String xAuthorization, @Nonnull String body, @Nullable String acceptLanguage, Map headers) throws ApiException { + public ApiResponse> sendChatMessageWithHttpInfo(@Nonnull UUID chatId, @Nonnull String xAuthorization, @Nullable Object body, @Nullable String acceptLanguage, Map headers) throws ApiException { HttpRequest.Builder localVarRequestBuilder = sendChatMessageRequestBuilder(chatId, xAuthorization, body, acceptLanguage, headers); try { HttpResponse localVarResponse = memberVarHttpClient.send( @@ -60728,7 +60800,7 @@ public ApiResponse> sendChatMessageWithHttpInfo(@Nonnull UUID chatI } } - private HttpRequest.Builder sendChatMessageRequestBuilder(@Nonnull UUID chatId, @Nonnull String xAuthorization, @Nonnull String body, @Nullable String acceptLanguage, Map headers) throws ApiException { + private HttpRequest.Builder sendChatMessageRequestBuilder(@Nonnull UUID chatId, @Nonnull String xAuthorization, @Nullable Object body, @Nullable String acceptLanguage, Map headers) throws ApiException { // verify the required parameter 'chatId' is set if (chatId == null) { throw new ApiException(400, "Missing the required parameter 'chatId' when calling sendChatMessage"); @@ -60751,9 +60823,14 @@ private HttpRequest.Builder sendChatMessageRequestBuilder(@Nonnull UUID chatId, if (acceptLanguage != null) { localVarRequestBuilder.header("Accept-Language", acceptLanguage.toString()); } - localVarRequestBuilder.header("Content-Type", "text/plain"); + localVarRequestBuilder.header("Content-Type", "application/json"); localVarRequestBuilder.header("Accept", "text/event-stream, application/json"); - localVarRequestBuilder.method("POST", HttpRequest.BodyPublishers.ofString(body)); + try { + byte[] localVarPostBody = memberVarObjectMapper.writeValueAsBytes(body); + localVarRequestBuilder.method("POST", HttpRequest.BodyPublishers.ofByteArray(localVarPostBody)); + } catch (IOException e) { + throw new ApiException(e); + } if (memberVarReadTimeout != null) { localVarRequestBuilder.timeout(memberVarReadTimeout); } @@ -62036,10 +62113,10 @@ private HttpRequest.Builder shareEntityGroupRequestBuilder(@Nonnull String entit /** * Share the Entity Group with User group (shareEntityGroupToChildOwnerUserGroup) - * Share the entity group with specified user group using specified role. Available for users with 'TENANT_ADMIN' or 'CUSTOMER_USER' authority. Security check is performed to verify that the user has 'WRITE' permission for specified group. - * @param entityGroupId A string value representing the Entity Group Id that you would like to share. For example, '784f394c-42b6-435a-983c-b7beff2784f9' (required) - * @param userGroupId A string value representing the Entity(User) Group Id that you would like to share with. For example, '784f394c-42b6-435a-983c-b7beff2784f9' (required) - * @param roleId A string value representing the Role Id that describes set of permissions you would like to share (read, write, etc). For example, '784f394c-42b6-435a-983c-b7beff2784f9' (required) + * Share the entity group with the specified user group using the specified role. Unlike the 'shareEntityGroup' API method, this method is designed for sharing 'down' the owner hierarchy and does not require 'WRITE' permission for the shared entity group or the target user group. In particular, it allows the current user to re-share an entity group that was shared with them by the parent owner: for example, a customer user may re-share a tenant-owned dashboard group with a user group of their sub-customer. The following security checks are performed: * the target user group must belong to the current user's owner or to one of its sub-customers; * the current user must have the 'SHARE_GROUP' operation granted for the shared entity group: either as a generic permission for the corresponding entity group resource (applies only if the shared entity group belongs to the current user's owner hierarchy), or as a group permission created when the entity group was shared with the current user's user group using a group role that includes the 'SHARE_GROUP' operation; * the specified role must be a group role that is readable by the current user, so it must belong to the current user's owner or to one of its sub-customers; * the operations of the specified role must be a subset of the operations the current user was granted for the shared entity group (always passes if the current user was granted the 'ALL' operation). If the specified role also includes the 'SHARE_GROUP' operation, the members of the target user group will be able to re-share the entity group further down their own owner hierarchy in the same way. Available for users with 'TENANT_ADMIN' or 'CUSTOMER_USER' authority. + * @param entityGroupId ID of the entity group to share (required) + * @param userGroupId ID of the user group to share the entity group with. The user group must belong to the current user's owner or to one of its sub-customers (required) + * @param roleId ID of the group role that defines the set of operations to grant to the target user group (required) * @throws ApiException if fails to make API call */ public void shareEntityGroupToChildOwnerUserGroup(@Nonnull String entityGroupId, @Nonnull String userGroupId, @Nonnull String roleId) throws ApiException { @@ -62048,10 +62125,10 @@ public void shareEntityGroupToChildOwnerUserGroup(@Nonnull String entityGroupId, /** * Share the Entity Group with User group (shareEntityGroupToChildOwnerUserGroup) - * Share the entity group with specified user group using specified role. Available for users with 'TENANT_ADMIN' or 'CUSTOMER_USER' authority. Security check is performed to verify that the user has 'WRITE' permission for specified group. - * @param entityGroupId A string value representing the Entity Group Id that you would like to share. For example, '784f394c-42b6-435a-983c-b7beff2784f9' (required) - * @param userGroupId A string value representing the Entity(User) Group Id that you would like to share with. For example, '784f394c-42b6-435a-983c-b7beff2784f9' (required) - * @param roleId A string value representing the Role Id that describes set of permissions you would like to share (read, write, etc). For example, '784f394c-42b6-435a-983c-b7beff2784f9' (required) + * Share the entity group with the specified user group using the specified role. Unlike the 'shareEntityGroup' API method, this method is designed for sharing 'down' the owner hierarchy and does not require 'WRITE' permission for the shared entity group or the target user group. In particular, it allows the current user to re-share an entity group that was shared with them by the parent owner: for example, a customer user may re-share a tenant-owned dashboard group with a user group of their sub-customer. The following security checks are performed: * the target user group must belong to the current user's owner or to one of its sub-customers; * the current user must have the 'SHARE_GROUP' operation granted for the shared entity group: either as a generic permission for the corresponding entity group resource (applies only if the shared entity group belongs to the current user's owner hierarchy), or as a group permission created when the entity group was shared with the current user's user group using a group role that includes the 'SHARE_GROUP' operation; * the specified role must be a group role that is readable by the current user, so it must belong to the current user's owner or to one of its sub-customers; * the operations of the specified role must be a subset of the operations the current user was granted for the shared entity group (always passes if the current user was granted the 'ALL' operation). If the specified role also includes the 'SHARE_GROUP' operation, the members of the target user group will be able to re-share the entity group further down their own owner hierarchy in the same way. Available for users with 'TENANT_ADMIN' or 'CUSTOMER_USER' authority. + * @param entityGroupId ID of the entity group to share (required) + * @param userGroupId ID of the user group to share the entity group with. The user group must belong to the current user's owner or to one of its sub-customers (required) + * @param roleId ID of the group role that defines the set of operations to grant to the target user group (required) * @param headers Optional headers to include in the request * @return ApiResponse<Void> * @throws ApiException if fails to make API call @@ -64891,6 +64968,90 @@ private HttpRequest.Builder updateMobileAppBundleOauth2ClientsRequestBuilder(@No return localVarRequestBuilder; } + /** + * Update Report public status (updateReportPublicStatus) + * Updates the public status of the report. When public, the report can be downloaded without authentication via the public link. Available for users with 'TENANT_ADMIN' or 'CUSTOMER_USER' authority. + * @param reportId A string value representing the report id. For example, '784f394c-42b6-435a-983c-b7beff2784f9' (required) + * @param isPublic Whether the report should be publicly downloadable without authentication (required) + * @return Report + * @throws ApiException if fails to make API call + */ + public Report updateReportPublicStatus(@Nonnull UUID reportId, @Nonnull Boolean isPublic) throws ApiException { + ApiResponse localVarResponse = updateReportPublicStatusWithHttpInfo(reportId, isPublic, null); + return localVarResponse.getData(); + } + + /** + * Update Report public status (updateReportPublicStatus) + * Updates the public status of the report. When public, the report can be downloaded without authentication via the public link. Available for users with 'TENANT_ADMIN' or 'CUSTOMER_USER' authority. + * @param reportId A string value representing the report id. For example, '784f394c-42b6-435a-983c-b7beff2784f9' (required) + * @param isPublic Whether the report should be publicly downloadable without authentication (required) + * @param headers Optional headers to include in the request + * @return ApiResponse<Report> + * @throws ApiException if fails to make API call + */ + public ApiResponse updateReportPublicStatusWithHttpInfo(@Nonnull UUID reportId, @Nonnull Boolean isPublic, Map headers) throws ApiException { + HttpRequest.Builder localVarRequestBuilder = updateReportPublicStatusRequestBuilder(reportId, isPublic, headers); + try { + HttpResponse localVarResponse = memberVarHttpClient.send( + localVarRequestBuilder.build(), + HttpResponse.BodyHandlers.ofInputStream()); + if (memberVarResponseInterceptor != null) { + memberVarResponseInterceptor.accept(localVarResponse); + } + InputStream localVarResponseBody = null; + try { + if (localVarResponse.statusCode()/ 100 != 2) { + throw getApiException("updateReportPublicStatus", localVarResponse); + } + localVarResponseBody = ApiClient.getResponseBody(localVarResponse); + if (localVarResponseBody == null) { + return new ApiResponse(localVarResponse.statusCode(), localVarResponse.headers().map(), null); + } + String responseBody = new String(localVarResponseBody.readAllBytes()); + Report responseValue = responseBody.isBlank()? null: memberVarObjectMapper.readValue(responseBody, new TypeReference() {}); + return new ApiResponse(localVarResponse.statusCode(), localVarResponse.headers().map(), responseValue); + } finally { + if (localVarResponseBody != null) { + localVarResponseBody.close(); + } + } + } catch (IOException e) { + throw new ApiException(e); + } + catch (InterruptedException e) { + Thread.currentThread().interrupt(); + throw new ApiException(e); + } + } + + private HttpRequest.Builder updateReportPublicStatusRequestBuilder(@Nonnull UUID reportId, @Nonnull Boolean isPublic, Map headers) throws ApiException { + // verify the required parameter 'reportId' is set + if (reportId == null) { + throw new ApiException(400, "Missing the required parameter 'reportId' when calling updateReportPublicStatus"); + } + // verify the required parameter 'isPublic' is set + if (isPublic == null) { + throw new ApiException(400, "Missing the required parameter 'isPublic' when calling updateReportPublicStatus"); + } + HttpRequest.Builder localVarRequestBuilder = HttpRequest.newBuilder(); + String localVarPath = "/api/v2/report/{reportId}/public/{isPublic}" + .replace("{reportId}", ApiClient.urlEncode(reportId.toString())) + .replace("{isPublic}", ApiClient.urlEncode(isPublic.toString())); + localVarRequestBuilder.uri(URI.create(memberVarBaseUri + localVarPath)); + localVarRequestBuilder.header("Accept", "application/json"); + localVarRequestBuilder.method("PUT", HttpRequest.BodyPublishers.noBody()); + if (memberVarReadTimeout != null) { + localVarRequestBuilder.timeout(memberVarReadTimeout); + } + // Add custom headers if provided + localVarRequestBuilder = HttpRequestBuilderExtensions.withAdditionalHeaders(localVarRequestBuilder, headers); + if (memberVarInterceptor != null) { + memberVarInterceptor.accept(localVarRequestBuilder); + } + return localVarRequestBuilder; + } + /** * updateResourceData * diff --git a/pe/src/main/java/org/thingsboard/client/model/Dashboard.java b/pe/src/main/java/org/thingsboard/client/model/Dashboard.java index eb02a7dc..1a3053d9 100644 --- a/pe/src/main/java/org/thingsboard/client/model/Dashboard.java +++ b/pe/src/main/java/org/thingsboard/client/model/Dashboard.java @@ -111,7 +111,7 @@ public class Dashboard { public static final String JSON_PROPERTY_CONFIGURATION = "configuration"; @Nullable - private com.fasterxml.jackson.databind.JsonNode _configuration = null; + private com.fasterxml.jackson.databind.JsonNode _configuration; public static final String JSON_PROPERTY_RESOURCES = "resources"; @Nullable @@ -353,7 +353,7 @@ public Dashboard _configuration(@Nullable com.fasterxml.jackson.databind.JsonNod } /** - * Get _configuration + * JSON object with main configuration of the dashboard: layouts, widgets, aliases, etc. The JSON structure of the dashboard configuration is quite complex. The easiest way to learn it is to export existing dashboard to JSON. * @return _configuration */ @Nullable diff --git a/pe/src/main/java/org/thingsboard/client/model/DashboardInfo.java b/pe/src/main/java/org/thingsboard/client/model/DashboardInfo.java index 260d727f..9eb842fc 100644 --- a/pe/src/main/java/org/thingsboard/client/model/DashboardInfo.java +++ b/pe/src/main/java/org/thingsboard/client/model/DashboardInfo.java @@ -114,7 +114,7 @@ public class DashboardInfo { public static final String JSON_PROPERTY_CONFIGURATION = "configuration"; @Nullable - private com.fasterxml.jackson.databind.JsonNode _configuration = null; + private com.fasterxml.jackson.databind.JsonNode _configuration; public static final String JSON_PROPERTY_RESOURCES = "resources"; @Nullable @@ -366,7 +366,7 @@ public DashboardInfo _configuration(@Nullable com.fasterxml.jackson.databind.Jso } /** - * Get _configuration + * JSON object with main configuration of the dashboard: layouts, widgets, aliases, etc. The JSON structure of the dashboard configuration is quite complex. The easiest way to learn it is to export existing dashboard to JSON. * @return _configuration */ @Nullable diff --git a/pe/src/main/java/org/thingsboard/client/model/HomeDashboard.java b/pe/src/main/java/org/thingsboard/client/model/HomeDashboard.java index 93a53ee1..6abb9fe1 100644 --- a/pe/src/main/java/org/thingsboard/client/model/HomeDashboard.java +++ b/pe/src/main/java/org/thingsboard/client/model/HomeDashboard.java @@ -112,7 +112,7 @@ public class HomeDashboard { public static final String JSON_PROPERTY_CONFIGURATION = "configuration"; @Nullable - private com.fasterxml.jackson.databind.JsonNode _configuration = null; + private com.fasterxml.jackson.databind.JsonNode _configuration; public static final String JSON_PROPERTY_RESOURCES = "resources"; @Nullable @@ -358,7 +358,7 @@ public HomeDashboard _configuration(@Nullable com.fasterxml.jackson.databind.Jso } /** - * Get _configuration + * JSON object with main configuration of the dashboard: layouts, widgets, aliases, etc. The JSON structure of the dashboard configuration is quite complex. The easiest way to learn it is to export existing dashboard to JSON. * @return _configuration */ @Nullable diff --git a/pe/src/main/java/org/thingsboard/client/model/LoginWhiteLabelingParams.java b/pe/src/main/java/org/thingsboard/client/model/LoginWhiteLabelingParams.java index 43b284eb..0e9a0a82 100644 --- a/pe/src/main/java/org/thingsboard/client/model/LoginWhiteLabelingParams.java +++ b/pe/src/main/java/org/thingsboard/client/model/LoginWhiteLabelingParams.java @@ -42,9 +42,11 @@ @JsonPropertyOrder({ LoginWhiteLabelingParams.JSON_PROPERTY_LOGO_IMAGE_URL, LoginWhiteLabelingParams.JSON_PROPERTY_LOGO_IMAGE_HEIGHT, + LoginWhiteLabelingParams.JSON_PROPERTY_COLLAPSED_LOGO_IMAGE_URL, LoginWhiteLabelingParams.JSON_PROPERTY_APP_TITLE, LoginWhiteLabelingParams.JSON_PROPERTY_FAVICON, LoginWhiteLabelingParams.JSON_PROPERTY_PALETTE_SETTINGS, + LoginWhiteLabelingParams.JSON_PROPERTY_PRIMARY_COLOR_PANELS, LoginWhiteLabelingParams.JSON_PROPERTY_HELP_LINK_BASE_URL, LoginWhiteLabelingParams.JSON_PROPERTY_UI_HELP_BASE_URL, LoginWhiteLabelingParams.JSON_PROPERTY_ENABLE_HELP_LINKS, @@ -73,6 +75,10 @@ public class LoginWhiteLabelingParams { @Nullable private Integer logoImageHeight; + public static final String JSON_PROPERTY_COLLAPSED_LOGO_IMAGE_URL = "collapsedLogoImageUrl"; + @Nullable + private String collapsedLogoImageUrl; + public static final String JSON_PROPERTY_APP_TITLE = "appTitle"; @Nullable private String appTitle; @@ -85,6 +91,10 @@ public class LoginWhiteLabelingParams { @Nullable private PaletteSettings paletteSettings; + public static final String JSON_PROPERTY_PRIMARY_COLOR_PANELS = "primaryColorPanels"; + @Nullable + private Boolean primaryColorPanels; + public static final String JSON_PROPERTY_HELP_LINK_BASE_URL = "helpLinkBaseUrl"; @Nullable private String helpLinkBaseUrl; @@ -212,6 +222,30 @@ public void setLogoImageHeight(@Nullable Integer logoImageHeight) { } + public LoginWhiteLabelingParams collapsedLogoImageUrl(@Nullable String collapsedLogoImageUrl) { + this.collapsedLogoImageUrl = collapsedLogoImageUrl; + return this; + } + + /** + * Logo shown when side menu is collapsed + * @return collapsedLogoImageUrl + */ + @Nullable + @JsonProperty(value = JSON_PROPERTY_COLLAPSED_LOGO_IMAGE_URL, required = false) + @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS) + public String getCollapsedLogoImageUrl() { + return collapsedLogoImageUrl; + } + + + @JsonProperty(value = JSON_PROPERTY_COLLAPSED_LOGO_IMAGE_URL, required = false) + @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS) + public void setCollapsedLogoImageUrl(@Nullable String collapsedLogoImageUrl) { + this.collapsedLogoImageUrl = collapsedLogoImageUrl; + } + + public LoginWhiteLabelingParams appTitle(@Nullable String appTitle) { this.appTitle = appTitle; return this; @@ -284,6 +318,30 @@ public void setPaletteSettings(@Nullable PaletteSettings paletteSettings) { } + public LoginWhiteLabelingParams primaryColorPanels(@Nullable Boolean primaryColorPanels) { + this.primaryColorPanels = primaryColorPanels; + return this; + } + + /** + * Whether primary-color panels (top toolbar, side navigation, dialog and entity-details headers) use the primary palette color as background. When false, they render on a white background + * @return primaryColorPanels + */ + @Nullable + @JsonProperty(value = JSON_PROPERTY_PRIMARY_COLOR_PANELS, required = false) + @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS) + public Boolean getPrimaryColorPanels() { + return primaryColorPanels; + } + + + @JsonProperty(value = JSON_PROPERTY_PRIMARY_COLOR_PANELS, required = false) + @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS) + public void setPrimaryColorPanels(@Nullable Boolean primaryColorPanels) { + this.primaryColorPanels = primaryColorPanels; + } + + public LoginWhiteLabelingParams helpLinkBaseUrl(@Nullable String helpLinkBaseUrl) { this.helpLinkBaseUrl = helpLinkBaseUrl; return this; @@ -696,9 +754,11 @@ public boolean equals(Object o) { LoginWhiteLabelingParams loginWhiteLabelingParams = (LoginWhiteLabelingParams) o; return Objects.equals(this.logoImageUrl, loginWhiteLabelingParams.logoImageUrl) && Objects.equals(this.logoImageHeight, loginWhiteLabelingParams.logoImageHeight) && + Objects.equals(this.collapsedLogoImageUrl, loginWhiteLabelingParams.collapsedLogoImageUrl) && Objects.equals(this.appTitle, loginWhiteLabelingParams.appTitle) && Objects.equals(this.favicon, loginWhiteLabelingParams.favicon) && Objects.equals(this.paletteSettings, loginWhiteLabelingParams.paletteSettings) && + Objects.equals(this.primaryColorPanels, loginWhiteLabelingParams.primaryColorPanels) && Objects.equals(this.helpLinkBaseUrl, loginWhiteLabelingParams.helpLinkBaseUrl) && Objects.equals(this.uiHelpBaseUrl, loginWhiteLabelingParams.uiHelpBaseUrl) && Objects.equals(this.enableHelpLinks, loginWhiteLabelingParams.enableHelpLinks) && @@ -720,7 +780,7 @@ public boolean equals(Object o) { @Override public int hashCode() { - return Objects.hash(logoImageUrl, logoImageHeight, appTitle, favicon, paletteSettings, helpLinkBaseUrl, uiHelpBaseUrl, enableHelpLinks, whiteLabelingEnabled, showNameVersion, platformName, platformVersion, customCss, hideConnectivityDialog, overrideTrendzName, pageBackgroundColor, darkForeground, domainId, baseUrl, prohibitDifferentUrl, adminSettingsId, showNameBottom); + return Objects.hash(logoImageUrl, logoImageHeight, collapsedLogoImageUrl, appTitle, favicon, paletteSettings, primaryColorPanels, helpLinkBaseUrl, uiHelpBaseUrl, enableHelpLinks, whiteLabelingEnabled, showNameVersion, platformName, platformVersion, customCss, hideConnectivityDialog, overrideTrendzName, pageBackgroundColor, darkForeground, domainId, baseUrl, prohibitDifferentUrl, adminSettingsId, showNameBottom); } @Override @@ -729,9 +789,11 @@ public String toString() { sb.append("class LoginWhiteLabelingParams {\n"); sb.append(" logoImageUrl: ").append(toIndentedString(logoImageUrl)).append("\n"); sb.append(" logoImageHeight: ").append(toIndentedString(logoImageHeight)).append("\n"); + sb.append(" collapsedLogoImageUrl: ").append(toIndentedString(collapsedLogoImageUrl)).append("\n"); sb.append(" appTitle: ").append(toIndentedString(appTitle)).append("\n"); sb.append(" favicon: ").append(toIndentedString(favicon)).append("\n"); sb.append(" paletteSettings: ").append(toIndentedString(paletteSettings)).append("\n"); + sb.append(" primaryColorPanels: ").append(toIndentedString(primaryColorPanels)).append("\n"); sb.append(" helpLinkBaseUrl: ").append(toIndentedString(helpLinkBaseUrl)).append("\n"); sb.append(" uiHelpBaseUrl: ").append(toIndentedString(uiHelpBaseUrl)).append("\n"); sb.append(" enableHelpLinks: ").append(toIndentedString(enableHelpLinks)).append("\n"); @@ -806,6 +868,11 @@ public String toUrlQueryString(String prefix) { joiner.add(String.format(java.util.Locale.ROOT, "%slogoImageHeight%s=%s", prefix, suffix, ApiClient.urlEncode(ApiClient.valueToString(getLogoImageHeight())))); } + // add `collapsedLogoImageUrl` to the URL query string + if (getCollapsedLogoImageUrl() != null) { + joiner.add(String.format(java.util.Locale.ROOT, "%scollapsedLogoImageUrl%s=%s", prefix, suffix, ApiClient.urlEncode(ApiClient.valueToString(getCollapsedLogoImageUrl())))); + } + // add `appTitle` to the URL query string if (getAppTitle() != null) { joiner.add(String.format(java.util.Locale.ROOT, "%sappTitle%s=%s", prefix, suffix, ApiClient.urlEncode(ApiClient.valueToString(getAppTitle())))); @@ -821,6 +888,11 @@ public String toUrlQueryString(String prefix) { joiner.add(getPaletteSettings().toUrlQueryString(prefix + "paletteSettings" + suffix)); } + // add `primaryColorPanels` to the URL query string + if (getPrimaryColorPanels() != null) { + joiner.add(String.format(java.util.Locale.ROOT, "%sprimaryColorPanels%s=%s", prefix, suffix, ApiClient.urlEncode(ApiClient.valueToString(getPrimaryColorPanels())))); + } + // add `helpLinkBaseUrl` to the URL query string if (getHelpLinkBaseUrl() != null) { joiner.add(String.format(java.util.Locale.ROOT, "%shelpLinkBaseUrl%s=%s", prefix, suffix, ApiClient.urlEncode(ApiClient.valueToString(getHelpLinkBaseUrl())))); diff --git a/pe/src/main/java/org/thingsboard/client/model/NotificationTemplateConfig.java b/pe/src/main/java/org/thingsboard/client/model/NotificationTemplateConfig.java index 0219cf0c..8516d77f 100644 --- a/pe/src/main/java/org/thingsboard/client/model/NotificationTemplateConfig.java +++ b/pe/src/main/java/org/thingsboard/client/model/NotificationTemplateConfig.java @@ -47,7 +47,8 @@ NotificationTemplateConfig.JSON_PROPERTY_ATTACH_REPORT, NotificationTemplateConfig.JSON_PROPERTY_REPORT_TEMPLATE_ID, NotificationTemplateConfig.JSON_PROPERTY_USER_ID, - NotificationTemplateConfig.JSON_PROPERTY_TIMEZONE + NotificationTemplateConfig.JSON_PROPERTY_TIMEZONE, + NotificationTemplateConfig.JSON_PROPERTY_MAKE_PUBLIC }) @Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", comments = "Generator version: 7.20.0") public class NotificationTemplateConfig { @@ -71,6 +72,10 @@ public class NotificationTemplateConfig { @Nullable private String timezone; + public static final String JSON_PROPERTY_MAKE_PUBLIC = "makePublic"; + @Nullable + private Boolean makePublic; + public NotificationTemplateConfig() { } @@ -202,6 +207,30 @@ public void setTimezone(@Nullable String timezone) { } + public NotificationTemplateConfig makePublic(@Nullable Boolean makePublic) { + this.makePublic = makePublic; + return this; + } + + /** + * Get makePublic + * @return makePublic + */ + @Nullable + @JsonProperty(value = JSON_PROPERTY_MAKE_PUBLIC, required = false) + @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS) + public Boolean getMakePublic() { + return makePublic; + } + + + @JsonProperty(value = JSON_PROPERTY_MAKE_PUBLIC, required = false) + @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS) + public void setMakePublic(@Nullable Boolean makePublic) { + this.makePublic = makePublic; + } + + /** * Return true if this NotificationTemplateConfig object is equal to o. */ @@ -218,12 +247,13 @@ public boolean equals(Object o) { Objects.equals(this.attachReport, notificationTemplateConfig.attachReport) && Objects.equals(this.reportTemplateId, notificationTemplateConfig.reportTemplateId) && Objects.equals(this.userId, notificationTemplateConfig.userId) && - Objects.equals(this.timezone, notificationTemplateConfig.timezone); + Objects.equals(this.timezone, notificationTemplateConfig.timezone) && + Objects.equals(this.makePublic, notificationTemplateConfig.makePublic); } @Override public int hashCode() { - return Objects.hash(deliveryMethodsTemplates, attachReport, reportTemplateId, userId, timezone); + return Objects.hash(deliveryMethodsTemplates, attachReport, reportTemplateId, userId, timezone, makePublic); } @Override @@ -235,6 +265,7 @@ public String toString() { sb.append(" reportTemplateId: ").append(toIndentedString(reportTemplateId)).append("\n"); sb.append(" userId: ").append(toIndentedString(userId)).append("\n"); sb.append(" timezone: ").append(toIndentedString(timezone)).append("\n"); + sb.append(" makePublic: ").append(toIndentedString(makePublic)).append("\n"); sb.append("}"); return sb.toString(); } @@ -312,6 +343,11 @@ public String toUrlQueryString(String prefix) { joiner.add(String.format(java.util.Locale.ROOT, "%stimezone%s=%s", prefix, suffix, ApiClient.urlEncode(ApiClient.valueToString(getTimezone())))); } + // add `makePublic` to the URL query string + if (getMakePublic() != null) { + joiner.add(String.format(java.util.Locale.ROOT, "%smakePublic%s=%s", prefix, suffix, ApiClient.urlEncode(ApiClient.valueToString(getMakePublic())))); + } + return joiner.toString(); } } diff --git a/pe/src/main/java/org/thingsboard/client/model/Report.java b/pe/src/main/java/org/thingsboard/client/model/Report.java index 876e49b1..b0207eb1 100644 --- a/pe/src/main/java/org/thingsboard/client/model/Report.java +++ b/pe/src/main/java/org/thingsboard/client/model/Report.java @@ -53,7 +53,9 @@ Report.JSON_PROPERTY_FORMAT, Report.JSON_PROPERTY_NAME, Report.JSON_PROPERTY_USER_ID, - Report.JSON_PROPERTY_OWNER_ID + Report.JSON_PROPERTY_PUBLIC_KEY, + Report.JSON_PROPERTY_OWNER_ID, + Report.JSON_PROPERTY_PUBLIC }) @Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", comments = "Generator version: 7.20.0") public class Report { @@ -89,10 +91,18 @@ public class Report { @Nonnull private UserId userId; + public static final String JSON_PROPERTY_PUBLIC_KEY = "publicKey"; + @Nullable + private String publicKey; + public static final String JSON_PROPERTY_OWNER_ID = "ownerId"; @Nullable private EntityId ownerId; + public static final String JSON_PROPERTY_PUBLIC = "public"; + @Nullable + private Boolean _public; + public Report() { } @@ -288,6 +298,30 @@ public void setUserId(@Nonnull UserId userId) { } + public Report publicKey(@Nullable String publicKey) { + this.publicKey = publicKey; + return this; + } + + /** + * Get publicKey + * @return publicKey + */ + @Nullable + @JsonProperty(value = JSON_PROPERTY_PUBLIC_KEY, required = false) + @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS) + public String getPublicKey() { + return publicKey; + } + + + @JsonProperty(value = JSON_PROPERTY_PUBLIC_KEY, required = false) + @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS) + public void setPublicKey(@Nullable String publicKey) { + this.publicKey = publicKey; + } + + /** * JSON object with Customer or Tenant Id * @return ownerId @@ -302,6 +336,30 @@ public EntityId getOwnerId() { + public Report _public(@Nullable Boolean _public) { + this._public = _public; + return this; + } + + /** + * Get _public + * @return _public + */ + @Nullable + @JsonProperty(value = JSON_PROPERTY_PUBLIC, required = false) + @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS) + public Boolean getPublic() { + return _public; + } + + + @JsonProperty(value = JSON_PROPERTY_PUBLIC, required = false) + @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS) + public void setPublic(@Nullable Boolean _public) { + this._public = _public; + } + + /** * Return true if this Report object is equal to o. */ @@ -322,12 +380,14 @@ public boolean equals(Object o) { Objects.equals(this.format, report.format) && Objects.equals(this.name, report.name) && Objects.equals(this.userId, report.userId) && - Objects.equals(this.ownerId, report.ownerId); + Objects.equals(this.publicKey, report.publicKey) && + Objects.equals(this.ownerId, report.ownerId) && + Objects.equals(this._public, report._public); } @Override public int hashCode() { - return Objects.hash(id, createdTime, tenantId, customerId, templateId, format, name, userId, ownerId); + return Objects.hash(id, createdTime, tenantId, customerId, templateId, format, name, userId, publicKey, ownerId, _public); } @Override @@ -342,7 +402,9 @@ public String toString() { sb.append(" format: ").append(toIndentedString(format)).append("\n"); sb.append(" name: ").append(toIndentedString(name)).append("\n"); sb.append(" userId: ").append(toIndentedString(userId)).append("\n"); + sb.append(" publicKey: ").append(toIndentedString(publicKey)).append("\n"); sb.append(" ownerId: ").append(toIndentedString(ownerId)).append("\n"); + sb.append(" _public: ").append(toIndentedString(_public)).append("\n"); sb.append("}"); return sb.toString(); } @@ -430,11 +492,21 @@ public String toUrlQueryString(String prefix) { joiner.add(getUserId().toUrlQueryString(prefix + "userId" + suffix)); } + // add `publicKey` to the URL query string + if (getPublicKey() != null) { + joiner.add(String.format(java.util.Locale.ROOT, "%spublicKey%s=%s", prefix, suffix, ApiClient.urlEncode(ApiClient.valueToString(getPublicKey())))); + } + // add `ownerId` to the URL query string if (getOwnerId() != null) { joiner.add(getOwnerId().toUrlQueryString(prefix + "ownerId" + suffix)); } + // add `public` to the URL query string + if (getPublic() != null) { + joiner.add(String.format(java.util.Locale.ROOT, "%spublic%s=%s", prefix, suffix, ApiClient.urlEncode(ApiClient.valueToString(getPublic())))); + } + return joiner.toString(); } } diff --git a/pe/src/main/java/org/thingsboard/client/model/ReportInfo.java b/pe/src/main/java/org/thingsboard/client/model/ReportInfo.java index 46ec43b1..78898c1c 100644 --- a/pe/src/main/java/org/thingsboard/client/model/ReportInfo.java +++ b/pe/src/main/java/org/thingsboard/client/model/ReportInfo.java @@ -54,10 +54,12 @@ ReportInfo.JSON_PROPERTY_FORMAT, ReportInfo.JSON_PROPERTY_NAME, ReportInfo.JSON_PROPERTY_USER_ID, + ReportInfo.JSON_PROPERTY_PUBLIC_KEY, ReportInfo.JSON_PROPERTY_TEMPLATE_INFO, ReportInfo.JSON_PROPERTY_CUSTOMER_TITLE, ReportInfo.JSON_PROPERTY_USER_NAME, - ReportInfo.JSON_PROPERTY_OWNER_ID + ReportInfo.JSON_PROPERTY_OWNER_ID, + ReportInfo.JSON_PROPERTY_PUBLIC }) @Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", comments = "Generator version: 7.20.0") public class ReportInfo { @@ -93,6 +95,10 @@ public class ReportInfo { @Nonnull private UserId userId; + public static final String JSON_PROPERTY_PUBLIC_KEY = "publicKey"; + @Nullable + private String publicKey; + public static final String JSON_PROPERTY_TEMPLATE_INFO = "templateInfo"; @Nullable private EntityInfo templateInfo; @@ -109,6 +115,10 @@ public class ReportInfo { @Nullable private EntityId ownerId; + public static final String JSON_PROPERTY_PUBLIC = "public"; + @Nullable + private Boolean _public; + public ReportInfo() { } @@ -304,6 +314,30 @@ public void setUserId(@Nonnull UserId userId) { } + public ReportInfo publicKey(@Nullable String publicKey) { + this.publicKey = publicKey; + return this; + } + + /** + * Get publicKey + * @return publicKey + */ + @Nullable + @JsonProperty(value = JSON_PROPERTY_PUBLIC_KEY, required = false) + @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS) + public String getPublicKey() { + return publicKey; + } + + + @JsonProperty(value = JSON_PROPERTY_PUBLIC_KEY, required = false) + @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS) + public void setPublicKey(@Nullable String publicKey) { + this.publicKey = publicKey; + } + + public ReportInfo templateInfo(@Nullable EntityInfo templateInfo) { this.templateInfo = templateInfo; return this; @@ -390,6 +424,30 @@ public EntityId getOwnerId() { + public ReportInfo _public(@Nullable Boolean _public) { + this._public = _public; + return this; + } + + /** + * Get _public + * @return _public + */ + @Nullable + @JsonProperty(value = JSON_PROPERTY_PUBLIC, required = false) + @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS) + public Boolean getPublic() { + return _public; + } + + + @JsonProperty(value = JSON_PROPERTY_PUBLIC, required = false) + @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS) + public void setPublic(@Nullable Boolean _public) { + this._public = _public; + } + + /** * Return true if this ReportInfo object is equal to o. */ @@ -410,15 +468,17 @@ public boolean equals(Object o) { Objects.equals(this.format, reportInfo.format) && Objects.equals(this.name, reportInfo.name) && Objects.equals(this.userId, reportInfo.userId) && + Objects.equals(this.publicKey, reportInfo.publicKey) && Objects.equals(this.templateInfo, reportInfo.templateInfo) && Objects.equals(this.customerTitle, reportInfo.customerTitle) && Objects.equals(this.userName, reportInfo.userName) && - Objects.equals(this.ownerId, reportInfo.ownerId); + Objects.equals(this.ownerId, reportInfo.ownerId) && + Objects.equals(this._public, reportInfo._public); } @Override public int hashCode() { - return Objects.hash(id, createdTime, tenantId, customerId, templateId, format, name, userId, templateInfo, customerTitle, userName, ownerId); + return Objects.hash(id, createdTime, tenantId, customerId, templateId, format, name, userId, publicKey, templateInfo, customerTitle, userName, ownerId, _public); } @Override @@ -433,10 +493,12 @@ public String toString() { sb.append(" format: ").append(toIndentedString(format)).append("\n"); sb.append(" name: ").append(toIndentedString(name)).append("\n"); sb.append(" userId: ").append(toIndentedString(userId)).append("\n"); + sb.append(" publicKey: ").append(toIndentedString(publicKey)).append("\n"); sb.append(" templateInfo: ").append(toIndentedString(templateInfo)).append("\n"); sb.append(" customerTitle: ").append(toIndentedString(customerTitle)).append("\n"); sb.append(" userName: ").append(toIndentedString(userName)).append("\n"); sb.append(" ownerId: ").append(toIndentedString(ownerId)).append("\n"); + sb.append(" _public: ").append(toIndentedString(_public)).append("\n"); sb.append("}"); return sb.toString(); } @@ -524,6 +586,11 @@ public String toUrlQueryString(String prefix) { joiner.add(getUserId().toUrlQueryString(prefix + "userId" + suffix)); } + // add `publicKey` to the URL query string + if (getPublicKey() != null) { + joiner.add(String.format(java.util.Locale.ROOT, "%spublicKey%s=%s", prefix, suffix, ApiClient.urlEncode(ApiClient.valueToString(getPublicKey())))); + } + // add `templateInfo` to the URL query string if (getTemplateInfo() != null) { joiner.add(getTemplateInfo().toUrlQueryString(prefix + "templateInfo" + suffix)); @@ -544,6 +611,11 @@ public String toUrlQueryString(String prefix) { joiner.add(getOwnerId().toUrlQueryString(prefix + "ownerId" + suffix)); } + // add `public` to the URL query string + if (getPublic() != null) { + joiner.add(String.format(java.util.Locale.ROOT, "%spublic%s=%s", prefix, suffix, ApiClient.urlEncode(ApiClient.valueToString(getPublic())))); + } + return joiner.toString(); } } diff --git a/pe/src/main/java/org/thingsboard/client/model/ReportJobConfiguration.java b/pe/src/main/java/org/thingsboard/client/model/ReportJobConfiguration.java index c329f6ef..afb8e511 100644 --- a/pe/src/main/java/org/thingsboard/client/model/ReportJobConfiguration.java +++ b/pe/src/main/java/org/thingsboard/client/model/ReportJobConfiguration.java @@ -57,6 +57,7 @@ ReportJobConfiguration.JSON_PROPERTY_REPORT_TEMPLATE_ID, ReportJobConfiguration.JSON_PROPERTY_USER_ID, ReportJobConfiguration.JSON_PROPERTY_TIMEZONE, + ReportJobConfiguration.JSON_PROPERTY_MAKE_PUBLIC, ReportJobConfiguration.JSON_PROPERTY_TARGETS, ReportJobConfiguration.JSON_PROPERTY_NOTIFICATION_TEMPLATE_ID, ReportJobConfiguration.JSON_PROPERTY_NOTIFICATION_REQUESTS, @@ -86,6 +87,10 @@ public class ReportJobConfiguration extends JobConfiguration { @Nullable private String timezone; + public static final String JSON_PROPERTY_MAKE_PUBLIC = "makePublic"; + @Nullable + private Boolean makePublic; + public static final String JSON_PROPERTY_TARGETS = "targets"; @Nullable private List targets = new ArrayList<>(); @@ -193,6 +198,30 @@ public void setTimezone(@Nullable String timezone) { } + public ReportJobConfiguration makePublic(@Nullable Boolean makePublic) { + this.makePublic = makePublic; + return this; + } + + /** + * Get makePublic + * @return makePublic + */ + @Nullable + @JsonProperty(value = JSON_PROPERTY_MAKE_PUBLIC, required = false) + @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS) + public Boolean getMakePublic() { + return makePublic; + } + + + @JsonProperty(value = JSON_PROPERTY_MAKE_PUBLIC, required = false) + @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS) + public void setMakePublic(@Nullable Boolean makePublic) { + this.makePublic = makePublic; + } + + public ReportJobConfiguration targets(@Nullable List targets) { this.targets = targets; return this; @@ -428,6 +457,7 @@ public boolean equals(Object o) { return Objects.equals(this.reportTemplateId, reportJobConfiguration.reportTemplateId) && Objects.equals(this.userId, reportJobConfiguration.userId) && Objects.equals(this.timezone, reportJobConfiguration.timezone) && + Objects.equals(this.makePublic, reportJobConfiguration.makePublic) && Objects.equals(this.targets, reportJobConfiguration.targets) && Objects.equals(this.notificationTemplateId, reportJobConfiguration.notificationTemplateId) && Objects.equals(this.notificationRequests, reportJobConfiguration.notificationRequests) && @@ -441,7 +471,7 @@ public boolean equals(Object o) { @Override public int hashCode() { - return Objects.hash(reportTemplateId, userId, timezone, targets, notificationTemplateId, notificationRequests, originator, ruleNode, outputTbMsgProto, queueName, schedulerEventInfo, super.hashCode()); + return Objects.hash(reportTemplateId, userId, timezone, makePublic, targets, notificationTemplateId, notificationRequests, originator, ruleNode, outputTbMsgProto, queueName, schedulerEventInfo, super.hashCode()); } @Override @@ -452,6 +482,7 @@ public String toString() { sb.append(" reportTemplateId: ").append(toIndentedString(reportTemplateId)).append("\n"); sb.append(" userId: ").append(toIndentedString(userId)).append("\n"); sb.append(" timezone: ").append(toIndentedString(timezone)).append("\n"); + sb.append(" makePublic: ").append(toIndentedString(makePublic)).append("\n"); sb.append(" targets: ").append(toIndentedString(targets)).append("\n"); sb.append(" notificationTemplateId: ").append(toIndentedString(notificationTemplateId)).append("\n"); sb.append(" notificationRequests: ").append(toIndentedString(notificationRequests)).append("\n"); @@ -542,6 +573,11 @@ public String toUrlQueryString(String prefix) { joiner.add(String.format(java.util.Locale.ROOT, "%stimezone%s=%s", prefix, suffix, ApiClient.urlEncode(ApiClient.valueToString(getTimezone())))); } + // add `makePublic` to the URL query string + if (getMakePublic() != null) { + joiner.add(String.format(java.util.Locale.ROOT, "%smakePublic%s=%s", prefix, suffix, ApiClient.urlEncode(ApiClient.valueToString(getMakePublic())))); + } + // add `targets` to the URL query string if (getTargets() != null) { for (int i = 0; i < getTargets().size(); i++) { diff --git a/pe/src/main/java/org/thingsboard/client/model/ReportRequest.java b/pe/src/main/java/org/thingsboard/client/model/ReportRequest.java index 57f3f2cc..436f074f 100644 --- a/pe/src/main/java/org/thingsboard/client/model/ReportRequest.java +++ b/pe/src/main/java/org/thingsboard/client/model/ReportRequest.java @@ -48,6 +48,7 @@ ReportRequest.JSON_PROPERTY_REPORT_TEMPLATE_CONFIG, ReportRequest.JSON_PROPERTY_TIMEZONE, ReportRequest.JSON_PROPERTY_USER_ID, + ReportRequest.JSON_PROPERTY_MAKE_PUBLIC, ReportRequest.JSON_PROPERTY_ORIGINATOR, ReportRequest.JSON_PROPERTY_TARGETS, ReportRequest.JSON_PROPERTY_NOTIFICATION_TEMPLATE_ID @@ -70,6 +71,10 @@ public class ReportRequest { @Nullable private String userId; + public static final String JSON_PROPERTY_MAKE_PUBLIC = "makePublic"; + @Nullable + private Boolean makePublic; + public static final String JSON_PROPERTY_ORIGINATOR = "originator"; @Nullable private EntityId originator; @@ -181,6 +186,30 @@ public void setUserId(@Nullable String userId) { } + public ReportRequest makePublic(@Nullable Boolean makePublic) { + this.makePublic = makePublic; + return this; + } + + /** + * A boolean value indicating whether the generated report should be made public. + * @return makePublic + */ + @Nullable + @JsonProperty(value = JSON_PROPERTY_MAKE_PUBLIC, required = false) + @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS) + public Boolean getMakePublic() { + return makePublic; + } + + + @JsonProperty(value = JSON_PROPERTY_MAKE_PUBLIC, required = false) + @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS) + public void setMakePublic(@Nullable Boolean makePublic) { + this.makePublic = makePublic; + } + + public ReportRequest originator(@Nullable EntityId originator) { this.originator = originator; return this; @@ -277,6 +306,7 @@ public boolean equals(Object o) { Objects.equals(this.reportTemplateConfig, reportRequest.reportTemplateConfig) && Objects.equals(this.timezone, reportRequest.timezone) && Objects.equals(this.userId, reportRequest.userId) && + Objects.equals(this.makePublic, reportRequest.makePublic) && Objects.equals(this.originator, reportRequest.originator) && Objects.equals(this.targets, reportRequest.targets) && Objects.equals(this.notificationTemplateId, reportRequest.notificationTemplateId); @@ -284,7 +314,7 @@ public boolean equals(Object o) { @Override public int hashCode() { - return Objects.hash(reportTemplateId, reportTemplateConfig, timezone, userId, originator, targets, notificationTemplateId); + return Objects.hash(reportTemplateId, reportTemplateConfig, timezone, userId, makePublic, originator, targets, notificationTemplateId); } @Override @@ -295,6 +325,7 @@ public String toString() { sb.append(" reportTemplateConfig: ").append(toIndentedString(reportTemplateConfig)).append("\n"); sb.append(" timezone: ").append(toIndentedString(timezone)).append("\n"); sb.append(" userId: ").append(toIndentedString(userId)).append("\n"); + sb.append(" makePublic: ").append(toIndentedString(makePublic)).append("\n"); sb.append(" originator: ").append(toIndentedString(originator)).append("\n"); sb.append(" targets: ").append(toIndentedString(targets)).append("\n"); sb.append(" notificationTemplateId: ").append(toIndentedString(notificationTemplateId)).append("\n"); @@ -365,6 +396,11 @@ public String toUrlQueryString(String prefix) { joiner.add(String.format(java.util.Locale.ROOT, "%suserId%s=%s", prefix, suffix, ApiClient.urlEncode(ApiClient.valueToString(getUserId())))); } + // add `makePublic` to the URL query string + if (getMakePublic() != null) { + joiner.add(String.format(java.util.Locale.ROOT, "%smakePublic%s=%s", prefix, suffix, ApiClient.urlEncode(ApiClient.valueToString(getMakePublic())))); + } + // add `originator` to the URL query string if (getOriginator() != null) { joiner.add(getOriginator().toUrlQueryString(prefix + "originator" + suffix)); diff --git a/pe/src/main/java/org/thingsboard/client/model/WhiteLabelingParams.java b/pe/src/main/java/org/thingsboard/client/model/WhiteLabelingParams.java index 3face142..1ca14178 100644 --- a/pe/src/main/java/org/thingsboard/client/model/WhiteLabelingParams.java +++ b/pe/src/main/java/org/thingsboard/client/model/WhiteLabelingParams.java @@ -41,9 +41,11 @@ @JsonPropertyOrder({ WhiteLabelingParams.JSON_PROPERTY_LOGO_IMAGE_URL, WhiteLabelingParams.JSON_PROPERTY_LOGO_IMAGE_HEIGHT, + WhiteLabelingParams.JSON_PROPERTY_COLLAPSED_LOGO_IMAGE_URL, WhiteLabelingParams.JSON_PROPERTY_APP_TITLE, WhiteLabelingParams.JSON_PROPERTY_FAVICON, WhiteLabelingParams.JSON_PROPERTY_PALETTE_SETTINGS, + WhiteLabelingParams.JSON_PROPERTY_PRIMARY_COLOR_PANELS, WhiteLabelingParams.JSON_PROPERTY_HELP_LINK_BASE_URL, WhiteLabelingParams.JSON_PROPERTY_UI_HELP_BASE_URL, WhiteLabelingParams.JSON_PROPERTY_ENABLE_HELP_LINKS, @@ -65,6 +67,10 @@ public class WhiteLabelingParams { @Nullable private Integer logoImageHeight; + public static final String JSON_PROPERTY_COLLAPSED_LOGO_IMAGE_URL = "collapsedLogoImageUrl"; + @Nullable + private String collapsedLogoImageUrl; + public static final String JSON_PROPERTY_APP_TITLE = "appTitle"; @Nullable private String appTitle; @@ -77,6 +83,10 @@ public class WhiteLabelingParams { @Nullable private PaletteSettings paletteSettings; + public static final String JSON_PROPERTY_PRIMARY_COLOR_PANELS = "primaryColorPanels"; + @Nullable + private Boolean primaryColorPanels; + public static final String JSON_PROPERTY_HELP_LINK_BASE_URL = "helpLinkBaseUrl"; @Nullable private String helpLinkBaseUrl; @@ -176,6 +186,30 @@ public void setLogoImageHeight(@Nullable Integer logoImageHeight) { } + public WhiteLabelingParams collapsedLogoImageUrl(@Nullable String collapsedLogoImageUrl) { + this.collapsedLogoImageUrl = collapsedLogoImageUrl; + return this; + } + + /** + * Logo shown when side menu is collapsed + * @return collapsedLogoImageUrl + */ + @Nullable + @JsonProperty(value = JSON_PROPERTY_COLLAPSED_LOGO_IMAGE_URL, required = false) + @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS) + public String getCollapsedLogoImageUrl() { + return collapsedLogoImageUrl; + } + + + @JsonProperty(value = JSON_PROPERTY_COLLAPSED_LOGO_IMAGE_URL, required = false) + @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS) + public void setCollapsedLogoImageUrl(@Nullable String collapsedLogoImageUrl) { + this.collapsedLogoImageUrl = collapsedLogoImageUrl; + } + + public WhiteLabelingParams appTitle(@Nullable String appTitle) { this.appTitle = appTitle; return this; @@ -248,6 +282,30 @@ public void setPaletteSettings(@Nullable PaletteSettings paletteSettings) { } + public WhiteLabelingParams primaryColorPanels(@Nullable Boolean primaryColorPanels) { + this.primaryColorPanels = primaryColorPanels; + return this; + } + + /** + * Whether primary-color panels (top toolbar, side navigation, dialog and entity-details headers) use the primary palette color as background. When false, they render on a white background + * @return primaryColorPanels + */ + @Nullable + @JsonProperty(value = JSON_PROPERTY_PRIMARY_COLOR_PANELS, required = false) + @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS) + public Boolean getPrimaryColorPanels() { + return primaryColorPanels; + } + + + @JsonProperty(value = JSON_PROPERTY_PRIMARY_COLOR_PANELS, required = false) + @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS) + public void setPrimaryColorPanels(@Nullable Boolean primaryColorPanels) { + this.primaryColorPanels = primaryColorPanels; + } + + public WhiteLabelingParams helpLinkBaseUrl(@Nullable String helpLinkBaseUrl) { this.helpLinkBaseUrl = helpLinkBaseUrl; return this; @@ -492,9 +550,11 @@ public boolean equals(Object o) { WhiteLabelingParams whiteLabelingParams = (WhiteLabelingParams) o; return Objects.equals(this.logoImageUrl, whiteLabelingParams.logoImageUrl) && Objects.equals(this.logoImageHeight, whiteLabelingParams.logoImageHeight) && + Objects.equals(this.collapsedLogoImageUrl, whiteLabelingParams.collapsedLogoImageUrl) && Objects.equals(this.appTitle, whiteLabelingParams.appTitle) && Objects.equals(this.favicon, whiteLabelingParams.favicon) && Objects.equals(this.paletteSettings, whiteLabelingParams.paletteSettings) && + Objects.equals(this.primaryColorPanels, whiteLabelingParams.primaryColorPanels) && Objects.equals(this.helpLinkBaseUrl, whiteLabelingParams.helpLinkBaseUrl) && Objects.equals(this.uiHelpBaseUrl, whiteLabelingParams.uiHelpBaseUrl) && Objects.equals(this.enableHelpLinks, whiteLabelingParams.enableHelpLinks) && @@ -509,7 +569,7 @@ public boolean equals(Object o) { @Override public int hashCode() { - return Objects.hash(logoImageUrl, logoImageHeight, appTitle, favicon, paletteSettings, helpLinkBaseUrl, uiHelpBaseUrl, enableHelpLinks, whiteLabelingEnabled, showNameVersion, platformName, platformVersion, customCss, hideConnectivityDialog, overrideTrendzName); + return Objects.hash(logoImageUrl, logoImageHeight, collapsedLogoImageUrl, appTitle, favicon, paletteSettings, primaryColorPanels, helpLinkBaseUrl, uiHelpBaseUrl, enableHelpLinks, whiteLabelingEnabled, showNameVersion, platformName, platformVersion, customCss, hideConnectivityDialog, overrideTrendzName); } @Override @@ -518,9 +578,11 @@ public String toString() { sb.append("class WhiteLabelingParams {\n"); sb.append(" logoImageUrl: ").append(toIndentedString(logoImageUrl)).append("\n"); sb.append(" logoImageHeight: ").append(toIndentedString(logoImageHeight)).append("\n"); + sb.append(" collapsedLogoImageUrl: ").append(toIndentedString(collapsedLogoImageUrl)).append("\n"); sb.append(" appTitle: ").append(toIndentedString(appTitle)).append("\n"); sb.append(" favicon: ").append(toIndentedString(favicon)).append("\n"); sb.append(" paletteSettings: ").append(toIndentedString(paletteSettings)).append("\n"); + sb.append(" primaryColorPanels: ").append(toIndentedString(primaryColorPanels)).append("\n"); sb.append(" helpLinkBaseUrl: ").append(toIndentedString(helpLinkBaseUrl)).append("\n"); sb.append(" uiHelpBaseUrl: ").append(toIndentedString(uiHelpBaseUrl)).append("\n"); sb.append(" enableHelpLinks: ").append(toIndentedString(enableHelpLinks)).append("\n"); @@ -588,6 +650,11 @@ public String toUrlQueryString(String prefix) { joiner.add(String.format(java.util.Locale.ROOT, "%slogoImageHeight%s=%s", prefix, suffix, ApiClient.urlEncode(ApiClient.valueToString(getLogoImageHeight())))); } + // add `collapsedLogoImageUrl` to the URL query string + if (getCollapsedLogoImageUrl() != null) { + joiner.add(String.format(java.util.Locale.ROOT, "%scollapsedLogoImageUrl%s=%s", prefix, suffix, ApiClient.urlEncode(ApiClient.valueToString(getCollapsedLogoImageUrl())))); + } + // add `appTitle` to the URL query string if (getAppTitle() != null) { joiner.add(String.format(java.util.Locale.ROOT, "%sappTitle%s=%s", prefix, suffix, ApiClient.urlEncode(ApiClient.valueToString(getAppTitle())))); @@ -603,6 +670,11 @@ public String toUrlQueryString(String prefix) { joiner.add(getPaletteSettings().toUrlQueryString(prefix + "paletteSettings" + suffix)); } + // add `primaryColorPanels` to the URL query string + if (getPrimaryColorPanels() != null) { + joiner.add(String.format(java.util.Locale.ROOT, "%sprimaryColorPanels%s=%s", prefix, suffix, ApiClient.urlEncode(ApiClient.valueToString(getPrimaryColorPanels())))); + } + // add `helpLinkBaseUrl` to the URL query string if (getHelpLinkBaseUrl() != null) { joiner.add(String.format(java.util.Locale.ROOT, "%shelpLinkBaseUrl%s=%s", prefix, suffix, ApiClient.urlEncode(ApiClient.valueToString(getHelpLinkBaseUrl()))));