@superatomai/sdk-node 0.0.36 → 0.0.37
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +942 -942
- package/dist/index.js +10 -6
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +10 -6
- package/dist/index.mjs.map +1 -1
- package/package.json +49 -48
package/dist/index.mjs
CHANGED
|
@@ -1984,6 +1984,7 @@ var DashboardsRequestPayloadSchema = z3.object({
|
|
|
1984
1984
|
published: z3.boolean().optional(),
|
|
1985
1985
|
createdBy: z3.number().optional(),
|
|
1986
1986
|
updatedBy: z3.number().optional(),
|
|
1987
|
+
allowedUsers: z3.array(z3.number()).optional(),
|
|
1987
1988
|
dashboard: DSLRendererPropsSchema.optional(),
|
|
1988
1989
|
// Query operation fields
|
|
1989
1990
|
filters: DashboardQueryFiltersSchema.optional(),
|
|
@@ -7480,6 +7481,7 @@ async function handleDashboardsRequest(data, collections, sendMessage) {
|
|
|
7480
7481
|
const published = requestData?.published;
|
|
7481
7482
|
const createdBy = requestData?.createdBy;
|
|
7482
7483
|
const updatedBy = requestData?.updatedBy;
|
|
7484
|
+
const allowedUsers = requestData?.allowedUsers;
|
|
7483
7485
|
const numericId = requestData?.id;
|
|
7484
7486
|
const filters = requestData?.filters;
|
|
7485
7487
|
const limit = requestData?.limit;
|
|
@@ -7495,10 +7497,10 @@ async function handleDashboardsRequest(data, collections, sendMessage) {
|
|
|
7495
7497
|
const dashboardManager2 = getDashboardManager();
|
|
7496
7498
|
switch (operation) {
|
|
7497
7499
|
case "create":
|
|
7498
|
-
await handleCreate2(id, dashboardId, dashboard, projectId, name, description, published, createdBy, executeCollection, dashboardManager2, sendMessage, from.id);
|
|
7500
|
+
await handleCreate2(id, dashboardId, dashboard, projectId, name, description, published, createdBy, allowedUsers, executeCollection, dashboardManager2, sendMessage, from.id);
|
|
7499
7501
|
break;
|
|
7500
7502
|
case "update":
|
|
7501
|
-
await handleUpdate2(id, numericId, dashboardId, dashboard, name, description, published, updatedBy, executeCollection, dashboardManager2, sendMessage, from.id);
|
|
7503
|
+
await handleUpdate2(id, numericId, dashboardId, dashboard, name, description, published, updatedBy, allowedUsers, executeCollection, dashboardManager2, sendMessage, from.id);
|
|
7502
7504
|
break;
|
|
7503
7505
|
case "delete":
|
|
7504
7506
|
await handleDelete2(id, numericId, dashboardId, executeCollection, dashboardManager2, sendMessage, from.id);
|
|
@@ -7526,7 +7528,7 @@ async function handleDashboardsRequest(data, collections, sendMessage) {
|
|
|
7526
7528
|
}, sendMessage);
|
|
7527
7529
|
}
|
|
7528
7530
|
}
|
|
7529
|
-
async function handleCreate2(id, dashboardId, dashboard, projectId, name, description, published, createdBy, executeCollection, dashboardManager2, sendMessage, clientId) {
|
|
7531
|
+
async function handleCreate2(id, dashboardId, dashboard, projectId, name, description, published, createdBy, allowedUsers, executeCollection, dashboardManager2, sendMessage, clientId) {
|
|
7530
7532
|
if (!dashboardId || dashboardId.trim().length === 0) {
|
|
7531
7533
|
sendResponse4(id, {
|
|
7532
7534
|
success: false,
|
|
@@ -7549,7 +7551,8 @@ async function handleCreate2(id, dashboardId, dashboard, projectId, name, descri
|
|
|
7549
7551
|
description,
|
|
7550
7552
|
dashboard,
|
|
7551
7553
|
published,
|
|
7552
|
-
createdBy
|
|
7554
|
+
createdBy,
|
|
7555
|
+
allowedUsers
|
|
7553
7556
|
});
|
|
7554
7557
|
if (result && result.success) {
|
|
7555
7558
|
logger.info(`[DB] Dashboard created successfully, ID: ${result.data?.id}`);
|
|
@@ -7588,7 +7591,7 @@ async function handleCreate2(id, dashboardId, dashboard, projectId, name, descri
|
|
|
7588
7591
|
}, sendMessage, clientId);
|
|
7589
7592
|
}
|
|
7590
7593
|
}
|
|
7591
|
-
async function handleUpdate2(id, numericId, dashboardId, dashboard, name, description, published, updatedBy, executeCollection, dashboardManager2, sendMessage, clientId) {
|
|
7594
|
+
async function handleUpdate2(id, numericId, dashboardId, dashboard, name, description, published, updatedBy, allowedUsers, executeCollection, dashboardManager2, sendMessage, clientId) {
|
|
7592
7595
|
if (!numericId) {
|
|
7593
7596
|
sendResponse4(id, {
|
|
7594
7597
|
success: false,
|
|
@@ -7603,7 +7606,8 @@ async function handleUpdate2(id, numericId, dashboardId, dashboard, name, descri
|
|
|
7603
7606
|
description,
|
|
7604
7607
|
dashboard,
|
|
7605
7608
|
published,
|
|
7606
|
-
updatedBy
|
|
7609
|
+
updatedBy,
|
|
7610
|
+
allowedUsers
|
|
7607
7611
|
});
|
|
7608
7612
|
if (result && result.success) {
|
|
7609
7613
|
logger.info(`[DB] Dashboard updated successfully, ID: ${numericId}`);
|