@uniformdev/mesh-sdk 20.49.2 → 20.49.3-alpha.47

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/dist/index.esm.js CHANGED
@@ -7,7 +7,7 @@ var __privateAdd = (obj, member, value) => member.has(obj) ? __typeError("Cannot
7
7
 
8
8
  // src/clients/IntegrationDefinitionClient.ts
9
9
  import { ApiClient } from "@uniformdev/context/api";
10
- var _url;
10
+ var _url, _credentialsUrl;
11
11
  var _IntegrationDefinitionClient = class _IntegrationDefinitionClient extends ApiClient {
12
12
  constructor(options) {
13
13
  super(options);
@@ -18,7 +18,7 @@ var _IntegrationDefinitionClient = class _IntegrationDefinitionClient extends Ap
18
18
  const fetchUri = this.createUrl(__privateGet(_IntegrationDefinitionClient, _url), { ...options, teamId });
19
19
  return await this.apiClient(fetchUri);
20
20
  }
21
- /** Creates or updates a mesh app definition on a team */
21
+ /** Creates or updates a mesh app definition on a team. Identity-delegation credentials must be minted separately via {@link rotateCredential}. */
22
22
  async upsert(body) {
23
23
  const fetchUri = this.createUrl(__privateGet(_IntegrationDefinitionClient, _url));
24
24
  return await this.apiClient(fetchUri, {
@@ -35,9 +35,37 @@ var _IntegrationDefinitionClient = class _IntegrationDefinitionClient extends Ap
35
35
  expectNoContent: true
36
36
  });
37
37
  }
38
+ /**
39
+ * Mints or rotates an identity-delegation credential for an integration definition. The plaintext
40
+ * `appSecret` is returned exactly once and is not retrievable afterwards — Uniform stores only
41
+ * the hash. A successful response invalidates any previously-issued secret of the same kind.
42
+ * Caller must be a team admin.
43
+ */
44
+ async rotateCredential(body) {
45
+ const fetchUri = this.createUrl(__privateGet(_IntegrationDefinitionClient, _credentialsUrl));
46
+ return await this.apiClient(fetchUri, {
47
+ method: "POST",
48
+ body: JSON.stringify({ ...body, teamId: this.options.teamId })
49
+ });
50
+ }
51
+ /**
52
+ * Revokes an identity-delegation credential. Future delegation grants and refreshes will fail
53
+ * until a new credential is minted; in-flight delegation tokens remain valid until natural
54
+ * expiry (up to ~15 minutes). Caller must be a team admin.
55
+ */
56
+ async revokeCredential(body) {
57
+ const fetchUri = this.createUrl(__privateGet(_IntegrationDefinitionClient, _credentialsUrl));
58
+ await this.apiClient(fetchUri, {
59
+ method: "DELETE",
60
+ body: JSON.stringify({ ...body, teamId: this.options.teamId }),
61
+ expectNoContent: true
62
+ });
63
+ }
38
64
  };
39
65
  _url = new WeakMap();
66
+ _credentialsUrl = new WeakMap();
40
67
  __privateAdd(_IntegrationDefinitionClient, _url, "/api/v1/integration-definitions");
68
+ __privateAdd(_IntegrationDefinitionClient, _credentialsUrl, "/api/v1/integration-credentials");
41
69
  var IntegrationDefinitionClient = _IntegrationDefinitionClient;
42
70
 
43
71
  // src/clients/IntegrationInstallationClient.ts
@@ -86,6 +114,14 @@ _url2 = new WeakMap();
86
114
  __privateAdd(_IntegrationInstallationClient, _url2, "/api/v1/integration-installations");
87
115
  var IntegrationInstallationClient = _IntegrationInstallationClient;
88
116
 
117
+ // src/delegation/csrfConstants.ts
118
+ var CSRF_HEADER_NAME = "x-mesh-csrf";
119
+ var CSRF_HEADER_VALUE = "1";
120
+
121
+ // src/delegation/delegationExpired.ts
122
+ var DELEGATION_EXPIRED_CODE = "delegation_expired";
123
+ var DELEGATION_SESSION_EXPIRED_MESSAGE = "Delegation session expired.";
124
+
89
125
  // src/locations/aiAgents.ts
90
126
  var functionCallSystemParameters = ["pageHtml"];
91
127
  function parseFunctionCall(request) {
@@ -131,7 +167,7 @@ var getLogger = (prefix, debug) => {
131
167
  };
132
168
 
133
169
  // src/temp/version.ts
134
- var UNIFORM_MESH_SDK_VERSION = "20.49.2";
170
+ var UNIFORM_MESH_SDK_VERSION = "20.74.3";
135
171
 
136
172
  // src/framepost/constants.ts
137
173
  var DEFAULT_REQUEST_TIMEOUT = 5e3;
@@ -488,54 +524,167 @@ async function connectToParent({
488
524
  });
489
525
  client.onRequest("metadata-value", onMetadataUpdated);
490
526
  client.onRequest("external-value-update", onValueExternallyUpdated);
527
+ const parent = {
528
+ resize: async ({ height }) => {
529
+ await client.request("resize", { height });
530
+ },
531
+ setValue: async (value) => {
532
+ await client.request("setValue", value);
533
+ },
534
+ openDialog: async (message) => {
535
+ const res = await client.request(
536
+ "openDialog",
537
+ message
538
+ );
539
+ const dialogId = res == null ? void 0 : res.dialogId;
540
+ if (!dialogId) {
541
+ return;
542
+ }
543
+ return new Promise((resolve, reject) => {
544
+ dialogResponseHandlers[dialogId] = { resolve, reject };
545
+ });
546
+ },
547
+ closeDialog: async (message) => {
548
+ await client.request("closeDialog", message);
549
+ },
550
+ getDataResource: async (message) => {
551
+ return await client.request("getDataResource", message, {
552
+ timeout: 3e4
553
+ });
554
+ },
555
+ navigate: async (message) => {
556
+ await client.request("navigate", message);
557
+ },
558
+ reloadLocation: async () => {
559
+ await client.request("reload");
560
+ },
561
+ editConnectedData: async (message) => {
562
+ return await client.request(
563
+ "editConnectedData",
564
+ message,
565
+ {
566
+ timeout: (
567
+ // 24 hours in ms
568
+ 864e5
569
+ )
570
+ }
571
+ );
572
+ },
573
+ getSessionToken: async () => {
574
+ return await client.request("getSessionToken", void 0, {
575
+ // Delegation may wait on consent UI + token API; default framepost timeout (5s) is too short.
576
+ timeout: 12e4
577
+ });
578
+ },
579
+ editorState: createEditorStateApi(client)
580
+ };
491
581
  return {
492
582
  initData,
493
- parent: {
494
- resize: async ({ height }) => {
495
- await client.request("resize", { height });
496
- },
497
- setValue: async (value) => {
498
- await client.request("setValue", value);
499
- },
500
- openDialog: async (message) => {
501
- const res = await client.request(
502
- "openDialog",
503
- message
504
- );
505
- const dialogId = res == null ? void 0 : res.dialogId;
506
- if (!dialogId) {
507
- return;
508
- }
509
- return new Promise((resolve, reject) => {
510
- dialogResponseHandlers[dialogId] = { resolve, reject };
511
- });
512
- },
513
- closeDialog: async (message) => {
514
- await client.request("closeDialog", message);
515
- },
516
- getDataResource: async (message) => {
517
- return await client.request("getDataResource", message, {
518
- timeout: 3e4
519
- });
520
- },
521
- navigate: async (message) => {
522
- await client.request("navigate", message);
523
- },
524
- reloadLocation: async () => {
525
- await client.request("reload");
526
- },
527
- editConnectedData: async (message) => {
528
- return await client.request(
529
- "editConnectedData",
530
- message,
531
- {
532
- timeout: (
533
- // 24 hours in ms
534
- 864e5
535
- )
536
- }
537
- );
583
+ parent
584
+ };
585
+ }
586
+ function createEditorStateApi(client) {
587
+ let cachedRootNodeId;
588
+ return {
589
+ async getRootNodeId() {
590
+ if (cachedRootNodeId) {
591
+ return cachedRootNodeId;
538
592
  }
593
+ const result = await client.request("editorState.getRootNodeId");
594
+ cachedRootNodeId = result;
595
+ return result;
596
+ },
597
+ // Read operations
598
+ async exportTree(params) {
599
+ const result = await client.request("editorState.exportTree", params);
600
+ cachedRootNodeId != null ? cachedRootNodeId : cachedRootNodeId = result == null ? void 0 : result._id;
601
+ return result;
602
+ },
603
+ async exportSubtree(params) {
604
+ return await client.request("editorState.exportSubtree", params);
605
+ },
606
+ async exportMetadata() {
607
+ return await client.request("editorState.exportMetadata");
608
+ },
609
+ async exportRootNodeMetadata() {
610
+ return await client.request("editorState.exportRootNodeMetadata");
611
+ },
612
+ async getNodeById(params) {
613
+ return await client.request("editorState.getNodeById", params);
614
+ },
615
+ async getNodeChildren(params) {
616
+ return await client.request("editorState.getNodeChildren", params);
617
+ },
618
+ async getNodeProperty(params) {
619
+ return await client.request("editorState.getNodeProperty", params);
620
+ },
621
+ async getNodeProperties(params) {
622
+ return await client.request("editorState.getNodeProperties", params);
623
+ },
624
+ async getParentInfo(params) {
625
+ return await client.request("editorState.getParentInfo", params);
626
+ },
627
+ // Selection
628
+ async getSelectedNodeId() {
629
+ return await client.request("editorState.getSelectedNodeId");
630
+ },
631
+ async setSelectedNodeId(params) {
632
+ await client.request("editorState.setSelectedNodeId", params);
633
+ },
634
+ async getSelectedParameterId() {
635
+ return await client.request("editorState.getSelectedParameterId");
636
+ },
637
+ async setSelectedParameterId(params) {
638
+ await client.request("editorState.setSelectedParameterId", params);
639
+ },
640
+ async getPristine() {
641
+ return await client.request("editorState.getPristine");
642
+ },
643
+ // Write operations
644
+ async insertNode(params) {
645
+ return await client.request("editorState.insertNode", params);
646
+ },
647
+ async deleteNode(params) {
648
+ await client.request("editorState.deleteNode", params);
649
+ },
650
+ async moveNode(params) {
651
+ await client.request("editorState.moveNode", params);
652
+ },
653
+ async updateNodeProperty(params) {
654
+ await client.request("editorState.updateNodeProperty", params);
655
+ },
656
+ async updateRootMetadata(params) {
657
+ await client.request("editorState.updateRootMetadata", params);
658
+ },
659
+ async updateRootNode(params) {
660
+ await client.request("editorState.updateRootNode", params);
661
+ },
662
+ // Pattern operations
663
+ async insertPattern(params) {
664
+ return await client.request("editorState.insertPattern", params);
665
+ },
666
+ async isPatternPropertyOverridden(params) {
667
+ return await client.request("editorState.isPatternPropertyOverridden", params);
668
+ },
669
+ async resetPatternPropertyOverride(params) {
670
+ await client.request("editorState.resetPatternPropertyOverride", params);
671
+ },
672
+ async setPropertyLocalizability(params) {
673
+ await client.request("editorState.setPropertyLocalizability", params);
674
+ },
675
+ // Locale operations
676
+ async enableLocale(params) {
677
+ await client.request("editorState.enableLocale", params);
678
+ },
679
+ async disableLocale(params) {
680
+ await client.request("editorState.disableLocale", params);
681
+ },
682
+ async setCurrentLocale(params) {
683
+ await client.request("editorState.setCurrentLocale", params);
684
+ },
685
+ // Dynamic input operations
686
+ async setDynamicInputPreviewValue(params) {
687
+ await client.request("editorState.setDynamicInputPreviewValue", params);
539
688
  }
540
689
  };
541
690
  }
@@ -733,7 +882,8 @@ async function initializeUniformMeshSDK({
733
882
  sdk.events.emit("onValueChanged", { newValue: value });
734
883
  await parent.setValue({ uniformMeshLocationValue: value, closeDialog: true });
735
884
  }
736
- } : void 0
885
+ } : void 0,
886
+ editorState: parent.editorState
737
887
  };
738
888
  return location;
739
889
  },
@@ -816,7 +966,8 @@ async function initializeUniformMeshSDK({
816
966
  },
817
967
  closeCurrentLocationDialog: async () => {
818
968
  await parent.closeDialog({ dialogId: void 0, dialogType: "currentLocation" });
819
- }
969
+ },
970
+ getSessionToken: () => parent.getSessionToken()
820
971
  };
821
972
  window.UniformMeshSDK = sdk;
822
973
  initializing = false;
@@ -838,6 +989,10 @@ var hasRole = (role, user) => {
838
989
  return user.roles.some((userRole) => userRole.name === role || userRole.id === role);
839
990
  };
840
991
  export {
992
+ CSRF_HEADER_NAME,
993
+ CSRF_HEADER_VALUE,
994
+ DELEGATION_EXPIRED_CODE,
995
+ DELEGATION_SESSION_EXPIRED_MESSAGE,
841
996
  IntegrationDefinitionClient,
842
997
  IntegrationInstallationClient,
843
998
  functionCallSystemParameters,
package/dist/index.js CHANGED
@@ -1,3 +1,4 @@
1
+ if (typeof process !== 'undefined' && process.emitWarning) { process.emitWarning('@uniformdev/mesh-sdk CommonJS entry is deprecated and will be removed in v21; Node.js 18 support will also be removed in v21 (Node.js 20+ required). Import the ESM build instead.', { type: 'DeprecationWarning', code: 'UNIFORM_MESH_SDK_CJS' }); }
1
2
  "use strict";
2
3
  var __create = Object.create;
3
4
  var __defProp = Object.defineProperty;
@@ -34,8 +35,12 @@ var __privateGet = (obj, member, getter) => (__accessCheck(obj, member, "read fr
34
35
  var __privateAdd = (obj, member, value) => member.has(obj) ? __typeError("Cannot add the same private member more than once") : member instanceof WeakSet ? member.add(obj) : member.set(obj, value);
35
36
 
36
37
  // src/index.ts
37
- var src_exports = {};
38
- __export(src_exports, {
38
+ var index_exports = {};
39
+ __export(index_exports, {
40
+ CSRF_HEADER_NAME: () => CSRF_HEADER_NAME,
41
+ CSRF_HEADER_VALUE: () => CSRF_HEADER_VALUE,
42
+ DELEGATION_EXPIRED_CODE: () => DELEGATION_EXPIRED_CODE,
43
+ DELEGATION_SESSION_EXPIRED_MESSAGE: () => DELEGATION_SESSION_EXPIRED_MESSAGE,
39
44
  IntegrationDefinitionClient: () => IntegrationDefinitionClient,
40
45
  IntegrationInstallationClient: () => IntegrationInstallationClient,
41
46
  functionCallSystemParameters: () => functionCallSystemParameters,
@@ -44,11 +49,11 @@ __export(src_exports, {
44
49
  initializeUniformMeshSDK: () => initializeUniformMeshSDK,
45
50
  parseFunctionCall: () => parseFunctionCall
46
51
  });
47
- module.exports = __toCommonJS(src_exports);
52
+ module.exports = __toCommonJS(index_exports);
48
53
 
49
54
  // src/clients/IntegrationDefinitionClient.ts
50
55
  var import_api = require("@uniformdev/context/api");
51
- var _url;
56
+ var _url, _credentialsUrl;
52
57
  var _IntegrationDefinitionClient = class _IntegrationDefinitionClient extends import_api.ApiClient {
53
58
  constructor(options) {
54
59
  super(options);
@@ -59,7 +64,7 @@ var _IntegrationDefinitionClient = class _IntegrationDefinitionClient extends im
59
64
  const fetchUri = this.createUrl(__privateGet(_IntegrationDefinitionClient, _url), { ...options, teamId });
60
65
  return await this.apiClient(fetchUri);
61
66
  }
62
- /** Creates or updates a mesh app definition on a team */
67
+ /** Creates or updates a mesh app definition on a team. Identity-delegation credentials must be minted separately via {@link rotateCredential}. */
63
68
  async upsert(body) {
64
69
  const fetchUri = this.createUrl(__privateGet(_IntegrationDefinitionClient, _url));
65
70
  return await this.apiClient(fetchUri, {
@@ -76,9 +81,37 @@ var _IntegrationDefinitionClient = class _IntegrationDefinitionClient extends im
76
81
  expectNoContent: true
77
82
  });
78
83
  }
84
+ /**
85
+ * Mints or rotates an identity-delegation credential for an integration definition. The plaintext
86
+ * `appSecret` is returned exactly once and is not retrievable afterwards — Uniform stores only
87
+ * the hash. A successful response invalidates any previously-issued secret of the same kind.
88
+ * Caller must be a team admin.
89
+ */
90
+ async rotateCredential(body) {
91
+ const fetchUri = this.createUrl(__privateGet(_IntegrationDefinitionClient, _credentialsUrl));
92
+ return await this.apiClient(fetchUri, {
93
+ method: "POST",
94
+ body: JSON.stringify({ ...body, teamId: this.options.teamId })
95
+ });
96
+ }
97
+ /**
98
+ * Revokes an identity-delegation credential. Future delegation grants and refreshes will fail
99
+ * until a new credential is minted; in-flight delegation tokens remain valid until natural
100
+ * expiry (up to ~15 minutes). Caller must be a team admin.
101
+ */
102
+ async revokeCredential(body) {
103
+ const fetchUri = this.createUrl(__privateGet(_IntegrationDefinitionClient, _credentialsUrl));
104
+ await this.apiClient(fetchUri, {
105
+ method: "DELETE",
106
+ body: JSON.stringify({ ...body, teamId: this.options.teamId }),
107
+ expectNoContent: true
108
+ });
109
+ }
79
110
  };
80
111
  _url = new WeakMap();
112
+ _credentialsUrl = new WeakMap();
81
113
  __privateAdd(_IntegrationDefinitionClient, _url, "/api/v1/integration-definitions");
114
+ __privateAdd(_IntegrationDefinitionClient, _credentialsUrl, "/api/v1/integration-credentials");
82
115
  var IntegrationDefinitionClient = _IntegrationDefinitionClient;
83
116
 
84
117
  // src/clients/IntegrationInstallationClient.ts
@@ -127,6 +160,14 @@ _url2 = new WeakMap();
127
160
  __privateAdd(_IntegrationInstallationClient, _url2, "/api/v1/integration-installations");
128
161
  var IntegrationInstallationClient = _IntegrationInstallationClient;
129
162
 
163
+ // src/delegation/csrfConstants.ts
164
+ var CSRF_HEADER_NAME = "x-mesh-csrf";
165
+ var CSRF_HEADER_VALUE = "1";
166
+
167
+ // src/delegation/delegationExpired.ts
168
+ var DELEGATION_EXPIRED_CODE = "delegation_expired";
169
+ var DELEGATION_SESSION_EXPIRED_MESSAGE = "Delegation session expired.";
170
+
130
171
  // src/locations/aiAgents.ts
131
172
  var functionCallSystemParameters = ["pageHtml"];
132
173
  function parseFunctionCall(request) {
@@ -172,7 +213,7 @@ var getLogger = (prefix, debug) => {
172
213
  };
173
214
 
174
215
  // src/temp/version.ts
175
- var UNIFORM_MESH_SDK_VERSION = "20.49.2";
216
+ var UNIFORM_MESH_SDK_VERSION = "20.74.3";
176
217
 
177
218
  // src/framepost/constants.ts
178
219
  var DEFAULT_REQUEST_TIMEOUT = 5e3;
@@ -529,54 +570,167 @@ async function connectToParent({
529
570
  });
530
571
  client.onRequest("metadata-value", onMetadataUpdated);
531
572
  client.onRequest("external-value-update", onValueExternallyUpdated);
573
+ const parent = {
574
+ resize: async ({ height }) => {
575
+ await client.request("resize", { height });
576
+ },
577
+ setValue: async (value) => {
578
+ await client.request("setValue", value);
579
+ },
580
+ openDialog: async (message) => {
581
+ const res = await client.request(
582
+ "openDialog",
583
+ message
584
+ );
585
+ const dialogId = res == null ? void 0 : res.dialogId;
586
+ if (!dialogId) {
587
+ return;
588
+ }
589
+ return new Promise((resolve, reject) => {
590
+ dialogResponseHandlers[dialogId] = { resolve, reject };
591
+ });
592
+ },
593
+ closeDialog: async (message) => {
594
+ await client.request("closeDialog", message);
595
+ },
596
+ getDataResource: async (message) => {
597
+ return await client.request("getDataResource", message, {
598
+ timeout: 3e4
599
+ });
600
+ },
601
+ navigate: async (message) => {
602
+ await client.request("navigate", message);
603
+ },
604
+ reloadLocation: async () => {
605
+ await client.request("reload");
606
+ },
607
+ editConnectedData: async (message) => {
608
+ return await client.request(
609
+ "editConnectedData",
610
+ message,
611
+ {
612
+ timeout: (
613
+ // 24 hours in ms
614
+ 864e5
615
+ )
616
+ }
617
+ );
618
+ },
619
+ getSessionToken: async () => {
620
+ return await client.request("getSessionToken", void 0, {
621
+ // Delegation may wait on consent UI + token API; default framepost timeout (5s) is too short.
622
+ timeout: 12e4
623
+ });
624
+ },
625
+ editorState: createEditorStateApi(client)
626
+ };
532
627
  return {
533
628
  initData,
534
- parent: {
535
- resize: async ({ height }) => {
536
- await client.request("resize", { height });
537
- },
538
- setValue: async (value) => {
539
- await client.request("setValue", value);
540
- },
541
- openDialog: async (message) => {
542
- const res = await client.request(
543
- "openDialog",
544
- message
545
- );
546
- const dialogId = res == null ? void 0 : res.dialogId;
547
- if (!dialogId) {
548
- return;
549
- }
550
- return new Promise((resolve, reject) => {
551
- dialogResponseHandlers[dialogId] = { resolve, reject };
552
- });
553
- },
554
- closeDialog: async (message) => {
555
- await client.request("closeDialog", message);
556
- },
557
- getDataResource: async (message) => {
558
- return await client.request("getDataResource", message, {
559
- timeout: 3e4
560
- });
561
- },
562
- navigate: async (message) => {
563
- await client.request("navigate", message);
564
- },
565
- reloadLocation: async () => {
566
- await client.request("reload");
567
- },
568
- editConnectedData: async (message) => {
569
- return await client.request(
570
- "editConnectedData",
571
- message,
572
- {
573
- timeout: (
574
- // 24 hours in ms
575
- 864e5
576
- )
577
- }
578
- );
629
+ parent
630
+ };
631
+ }
632
+ function createEditorStateApi(client) {
633
+ let cachedRootNodeId;
634
+ return {
635
+ async getRootNodeId() {
636
+ if (cachedRootNodeId) {
637
+ return cachedRootNodeId;
579
638
  }
639
+ const result = await client.request("editorState.getRootNodeId");
640
+ cachedRootNodeId = result;
641
+ return result;
642
+ },
643
+ // Read operations
644
+ async exportTree(params) {
645
+ const result = await client.request("editorState.exportTree", params);
646
+ cachedRootNodeId != null ? cachedRootNodeId : cachedRootNodeId = result == null ? void 0 : result._id;
647
+ return result;
648
+ },
649
+ async exportSubtree(params) {
650
+ return await client.request("editorState.exportSubtree", params);
651
+ },
652
+ async exportMetadata() {
653
+ return await client.request("editorState.exportMetadata");
654
+ },
655
+ async exportRootNodeMetadata() {
656
+ return await client.request("editorState.exportRootNodeMetadata");
657
+ },
658
+ async getNodeById(params) {
659
+ return await client.request("editorState.getNodeById", params);
660
+ },
661
+ async getNodeChildren(params) {
662
+ return await client.request("editorState.getNodeChildren", params);
663
+ },
664
+ async getNodeProperty(params) {
665
+ return await client.request("editorState.getNodeProperty", params);
666
+ },
667
+ async getNodeProperties(params) {
668
+ return await client.request("editorState.getNodeProperties", params);
669
+ },
670
+ async getParentInfo(params) {
671
+ return await client.request("editorState.getParentInfo", params);
672
+ },
673
+ // Selection
674
+ async getSelectedNodeId() {
675
+ return await client.request("editorState.getSelectedNodeId");
676
+ },
677
+ async setSelectedNodeId(params) {
678
+ await client.request("editorState.setSelectedNodeId", params);
679
+ },
680
+ async getSelectedParameterId() {
681
+ return await client.request("editorState.getSelectedParameterId");
682
+ },
683
+ async setSelectedParameterId(params) {
684
+ await client.request("editorState.setSelectedParameterId", params);
685
+ },
686
+ async getPristine() {
687
+ return await client.request("editorState.getPristine");
688
+ },
689
+ // Write operations
690
+ async insertNode(params) {
691
+ return await client.request("editorState.insertNode", params);
692
+ },
693
+ async deleteNode(params) {
694
+ await client.request("editorState.deleteNode", params);
695
+ },
696
+ async moveNode(params) {
697
+ await client.request("editorState.moveNode", params);
698
+ },
699
+ async updateNodeProperty(params) {
700
+ await client.request("editorState.updateNodeProperty", params);
701
+ },
702
+ async updateRootMetadata(params) {
703
+ await client.request("editorState.updateRootMetadata", params);
704
+ },
705
+ async updateRootNode(params) {
706
+ await client.request("editorState.updateRootNode", params);
707
+ },
708
+ // Pattern operations
709
+ async insertPattern(params) {
710
+ return await client.request("editorState.insertPattern", params);
711
+ },
712
+ async isPatternPropertyOverridden(params) {
713
+ return await client.request("editorState.isPatternPropertyOverridden", params);
714
+ },
715
+ async resetPatternPropertyOverride(params) {
716
+ await client.request("editorState.resetPatternPropertyOverride", params);
717
+ },
718
+ async setPropertyLocalizability(params) {
719
+ await client.request("editorState.setPropertyLocalizability", params);
720
+ },
721
+ // Locale operations
722
+ async enableLocale(params) {
723
+ await client.request("editorState.enableLocale", params);
724
+ },
725
+ async disableLocale(params) {
726
+ await client.request("editorState.disableLocale", params);
727
+ },
728
+ async setCurrentLocale(params) {
729
+ await client.request("editorState.setCurrentLocale", params);
730
+ },
731
+ // Dynamic input operations
732
+ async setDynamicInputPreviewValue(params) {
733
+ await client.request("editorState.setDynamicInputPreviewValue", params);
580
734
  }
581
735
  };
582
736
  }
@@ -774,7 +928,8 @@ async function initializeUniformMeshSDK({
774
928
  sdk.events.emit("onValueChanged", { newValue: value });
775
929
  await parent.setValue({ uniformMeshLocationValue: value, closeDialog: true });
776
930
  }
777
- } : void 0
931
+ } : void 0,
932
+ editorState: parent.editorState
778
933
  };
779
934
  return location;
780
935
  },
@@ -857,7 +1012,8 @@ async function initializeUniformMeshSDK({
857
1012
  },
858
1013
  closeCurrentLocationDialog: async () => {
859
1014
  await parent.closeDialog({ dialogId: void 0, dialogType: "currentLocation" });
860
- }
1015
+ },
1016
+ getSessionToken: () => parent.getSessionToken()
861
1017
  };
862
1018
  window.UniformMeshSDK = sdk;
863
1019
  initializing = false;
@@ -880,6 +1036,10 @@ var hasRole = (role, user) => {
880
1036
  };
881
1037
  // Annotate the CommonJS export names for ESM import in node:
882
1038
  0 && (module.exports = {
1039
+ CSRF_HEADER_NAME,
1040
+ CSRF_HEADER_VALUE,
1041
+ DELEGATION_EXPIRED_CODE,
1042
+ DELEGATION_SESSION_EXPIRED_MESSAGE,
883
1043
  IntegrationDefinitionClient,
884
1044
  IntegrationInstallationClient,
885
1045
  functionCallSystemParameters,