@salesforce/plugin-orchestrator 1.0.21 → 1.0.23

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.
@@ -52,7 +52,7 @@ export default class TemplateEval extends SfCommand<TemplatePreviewResult> {
52
52
  static readonly flags: {
53
53
  'target-org': import("@oclif/core/interfaces").OptionFlag<import("@salesforce/core").Org, import("@oclif/core/interfaces").CustomOptions>;
54
54
  'api-version': import("@oclif/core/interfaces").OptionFlag<string | undefined, import("@oclif/core/interfaces").CustomOptions>;
55
- 'template-info': import("@oclif/core/interfaces").OptionFlag<string, import("@oclif/core/interfaces").CustomOptions>;
55
+ document: import("@oclif/core/interfaces").OptionFlag<string, import("@oclif/core/interfaces").CustomOptions>;
56
56
  variables: import("@oclif/core/interfaces").OptionFlag<string, import("@oclif/core/interfaces").CustomOptions>;
57
57
  rules: import("@oclif/core/interfaces").OptionFlag<string, import("@oclif/core/interfaces").CustomOptions>;
58
58
  };
@@ -32,10 +32,10 @@ export default class TemplateEval extends SfCommand {
32
32
  summary: messages.getMessage('flags.api-version.summary'),
33
33
  description: messages.getMessage('flags.api-version.description'),
34
34
  }),
35
- 'template-info': Flags.file({
36
- char: 't',
37
- summary: messages.getMessage('flags.template-info.summary'),
38
- description: messages.getMessage('flags.template-info.description'),
35
+ document: Flags.file({
36
+ char: 'd',
37
+ summary: messages.getMessage('flags.document.summary'),
38
+ description: messages.getMessage('flags.document.description'),
39
39
  required: true,
40
40
  }),
41
41
  variables: Flags.file({
@@ -94,17 +94,18 @@ export default class TemplateEval extends SfCommand {
94
94
  }
95
95
  }
96
96
  async getTemplatePayload(flags) {
97
- return this.getDirectFilePayload(flags['template-info'], flags['variables'], flags['rules']);
97
+ return this.getDirectFilePayload(flags.document, flags.variables, flags.rules);
98
98
  }
99
- async getDirectFilePayload(templateInfoFile, variablesFile, rulesFile) {
100
- this.log(`Loading template info: ${templateInfoFile}`);
101
- // Read and parse the template-info file
102
- const templateInfoContent = await fs.readFile(templateInfoFile, 'utf8');
103
- const document = JSON.parse(templateInfoContent);
99
+ async getDirectFilePayload(documentFile, variablesFile, rulesFile) {
100
+ this.log(`Loading document: ${documentFile}`);
101
+ // Read and parse the document file
102
+ const documentContent = await fs.readFile(documentFile, 'utf8');
103
+ const document = JSON.parse(documentContent);
104
104
  // Read variables file
105
105
  this.log(`Loading variables: ${variablesFile}`);
106
106
  const variablesContent = await fs.readFile(variablesFile, 'utf8');
107
- const values = JSON.parse(variablesContent);
107
+ const variablesData = JSON.parse(variablesContent);
108
+ const values = { Variables: variablesData };
108
109
  // Read rules file
109
110
  this.log(`Loading rules: ${rulesFile}`);
110
111
  const rulesContent = await fs.readFile(rulesFile, 'utf8');
@@ -112,7 +113,7 @@ export default class TemplateEval extends SfCommand {
112
113
  return {
113
114
  template: {
114
115
  name: 'Direct Files',
115
- path: templateInfoFile,
116
+ path: documentFile,
116
117
  source: 'local',
117
118
  },
118
119
  payload: {
@@ -1 +1 @@
1
- {"version":3,"file":"eval.js","sourceRoot":"","sources":["../../../../src/commands/orchestrator/rules/eval.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;GAcG;AAEH,OAAO,KAAK,EAAE,MAAM,kBAAkB,CAAC;AACvC,OAAO,EAAE,SAAS,EAAE,KAAK,EAAE,MAAM,6BAA6B,CAAC;AAC/D,OAAO,EAAE,QAAQ,EAAc,MAAM,kBAAkB,CAAC;AAExD,QAAQ,CAAC,kCAAkC,CAAC,MAAM,CAAC,IAAI,CAAC,GAAG,CAAC,CAAC;AAC7D,MAAM,QAAQ,GAAG,QAAQ,CAAC,YAAY,CAAC,iCAAiC,EAAE,yBAAyB,CAAC,CAAC;AAmDrG,MAAM,CAAC,OAAO,OAAO,YAAa,SAAQ,SAAgC;IACjE,MAAM,CAAU,OAAO,GAAG,QAAQ,CAAC,UAAU,CAAC,SAAS,CAAC,CAAC;IACzD,MAAM,CAAU,WAAW,GAAG,QAAQ,CAAC,UAAU,CAAC,aAAa,CAAC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,EAAE,OAAgB;aACzB;YACD,OAAO,EAAE;gBACP,QAAQ,EAAE,QAA6C;gBACvD,MAAM,EAAE,MAAyC;gBACjD,UAAU,EAAE,UAAiD;aAC9D;SACF,CAAC;IACJ,CAAC"}
@@ -22,13 +22,13 @@ Override the api version used for api requests made by this command.
22
22
 
23
23
  API version to use for the transformation request. Defaults to the org's configured API version.
24
24
 
25
- # flags.template-info.summary
25
+ # flags.document.summary
26
26
 
27
- Path to Analytics template-info.json file.
27
+ Path to JSON document file to transform.
28
28
 
29
- # flags.template-info.description
29
+ # flags.document.description
30
30
 
31
- Path to the template-info.json file containing the base JSON document structure that will be transformed.
31
+ Path to the JSON document file (dashboard, lens, etc.) that will be transformed by the rules.
32
32
 
33
33
  # flags.variables.summary
34
34
 
@@ -36,7 +36,7 @@ Path to Analytics variables.json file.
36
36
 
37
37
  # flags.variables.description
38
38
 
39
- Path to the variables.json file containing variable definitions used in transformations.
39
+ Path to the variables.json file containing variable definitions used in transformations. The file should contain a flat JSON object with key-value pairs. The CLI will automatically wrap these in the required Variables structure.
40
40
 
41
41
  # flags.rules.summary
42
42
 
@@ -48,8 +48,8 @@ Path to the rules.json file containing transformation rules and macro definition
48
48
 
49
49
  # examples
50
50
 
51
- - Test JSON transformation with Analytics template files:
52
- <%= config.bin %> <%= command.id %> --template-info ./template-info.json --variables ./variables.json --rules ./rules.json --target-org myorg
51
+ - Test JSON transformation with Analytics files:
52
+ <%= config.bin %> <%= command.id %> --document ./dashboard.json --variables ./variables.json --rules ./rules.json --target-org myorg
53
53
 
54
54
  - Test with specific API version:
55
- <%= config.bin %> <%= command.id %> --template-info ./template-info.json --variables ./variables.json --rules ./rules.json --target-org myorg --api-version 60.0
55
+ <%= config.bin %> <%= command.id %> --document ./dashboard.json --variables ./variables.json --rules ./rules.json --target-org myorg --api-version 60.0
@@ -1,12 +1,12 @@
1
1
  {
2
2
  "name": "@salesforce/plugin-orchestrator",
3
- "version": "1.0.21",
3
+ "version": "1.0.23",
4
4
  "lockfileVersion": 3,
5
5
  "requires": true,
6
6
  "packages": {
7
7
  "": {
8
8
  "name": "@salesforce/plugin-orchestrator",
9
- "version": "1.0.21",
9
+ "version": "1.0.23",
10
10
  "license": "Apache-2.0",
11
11
  "dependencies": {
12
12
  "@inquirer/select": "^5.0.1",
@@ -705,6 +705,107 @@
705
705
  "upgrade:app:orchestrator"
706
706
  ]
707
707
  },
708
+ "orchestrator:rules:eval": {
709
+ "aliases": [],
710
+ "args": {},
711
+ "description": "Preview how transformation rules will modify JSON documents before deploying templates. This command uses a sample transformation to test the jsonxform/transformation endpoint with built-in User and Org context variables.",
712
+ "examples": [
713
+ "Test JSON transformation with Analytics files:\n<%= config.bin %> <%= command.id %> --document ./dashboard.json --variables ./variables.json --rules ./rules.json --target-org myorg",
714
+ "Test with specific API version:\n<%= config.bin %> <%= command.id %> --document ./dashboard.json --variables ./variables.json --rules ./rules.json --target-org myorg --api-version 60.0"
715
+ ],
716
+ "flags": {
717
+ "json": {
718
+ "description": "Format output as json.",
719
+ "helpGroup": "GLOBAL",
720
+ "name": "json",
721
+ "allowNo": false,
722
+ "type": "boolean"
723
+ },
724
+ "flags-dir": {
725
+ "helpGroup": "GLOBAL",
726
+ "name": "flags-dir",
727
+ "summary": "Import flag values from a directory.",
728
+ "hasDynamicHelp": false,
729
+ "multiple": false,
730
+ "type": "option"
731
+ },
732
+ "target-org": {
733
+ "char": "o",
734
+ "description": "The username or alias of the target org where the jsonxform/transformation endpoint will be called. This org provides the User and Org context variables used in the transformation.",
735
+ "name": "target-org",
736
+ "noCacheDefault": true,
737
+ "required": true,
738
+ "summary": "Username or alias for the target org; overrides default target org.",
739
+ "hasDynamicHelp": true,
740
+ "multiple": false,
741
+ "type": "option"
742
+ },
743
+ "api-version": {
744
+ "description": "API version to use for the transformation request. Defaults to the org's configured API version.",
745
+ "name": "api-version",
746
+ "summary": "Override the api version used for api requests made by this command.",
747
+ "hasDynamicHelp": false,
748
+ "multiple": false,
749
+ "type": "option"
750
+ },
751
+ "document": {
752
+ "char": "d",
753
+ "description": "Path to the JSON document file (dashboard, lens, etc.) that will be transformed by the rules.",
754
+ "name": "document",
755
+ "required": true,
756
+ "summary": "Path to JSON document file to transform.",
757
+ "hasDynamicHelp": false,
758
+ "multiple": false,
759
+ "type": "option"
760
+ },
761
+ "variables": {
762
+ "char": "v",
763
+ "description": "Path to the variables.json file containing variable definitions used in transformations. The file should contain a flat JSON object with key-value pairs. The CLI will automatically wrap these in the required Variables structure.",
764
+ "name": "variables",
765
+ "required": true,
766
+ "summary": "Path to Analytics variables.json file.",
767
+ "hasDynamicHelp": false,
768
+ "multiple": false,
769
+ "type": "option"
770
+ },
771
+ "rules": {
772
+ "char": "r",
773
+ "description": "Path to the rules.json file containing transformation rules and macro definitions.",
774
+ "name": "rules",
775
+ "required": true,
776
+ "summary": "Path to Analytics rules.json file.",
777
+ "hasDynamicHelp": false,
778
+ "multiple": false,
779
+ "type": "option"
780
+ }
781
+ },
782
+ "hasDynamicHelp": true,
783
+ "hiddenAliases": [],
784
+ "id": "orchestrator:rules:eval",
785
+ "pluginAlias": "@salesforce/plugin-orchestrator",
786
+ "pluginName": "@salesforce/plugin-orchestrator",
787
+ "pluginType": "core",
788
+ "strict": true,
789
+ "summary": "Test JSON transformation rules using the jsonxform/transformation endpoint.",
790
+ "enableJsonFlag": true,
791
+ "isESM": true,
792
+ "relativePath": [
793
+ "lib",
794
+ "commands",
795
+ "orchestrator",
796
+ "rules",
797
+ "eval.js"
798
+ ],
799
+ "aliasPermutations": [],
800
+ "permutations": [
801
+ "orchestrator:rules:eval",
802
+ "rules:orchestrator:eval",
803
+ "rules:eval:orchestrator",
804
+ "orchestrator:eval:rules",
805
+ "eval:orchestrator:rules",
806
+ "eval:rules:orchestrator"
807
+ ]
808
+ },
708
809
  "orchestrator:template:create": {
709
810
  "aliases": [],
710
811
  "args": {},
@@ -1239,108 +1340,7 @@
1239
1340
  "update:orchestrator:template",
1240
1341
  "update:template:orchestrator"
1241
1342
  ]
1242
- },
1243
- "orchestrator:rules:eval": {
1244
- "aliases": [],
1245
- "args": {},
1246
- "description": "Preview how transformation rules will modify JSON documents before deploying templates. This command uses a sample transformation to test the jsonxform/transformation endpoint with built-in User and Org context variables.",
1247
- "examples": [
1248
- "Test JSON transformation with Analytics template files:\n<%= config.bin %> <%= command.id %> --template-info ./template-info.json --variables ./variables.json --rules ./rules.json --target-org myorg",
1249
- "Test with specific API version:\n<%= config.bin %> <%= command.id %> --template-info ./template-info.json --variables ./variables.json --rules ./rules.json --target-org myorg --api-version 60.0"
1250
- ],
1251
- "flags": {
1252
- "json": {
1253
- "description": "Format output as json.",
1254
- "helpGroup": "GLOBAL",
1255
- "name": "json",
1256
- "allowNo": false,
1257
- "type": "boolean"
1258
- },
1259
- "flags-dir": {
1260
- "helpGroup": "GLOBAL",
1261
- "name": "flags-dir",
1262
- "summary": "Import flag values from a directory.",
1263
- "hasDynamicHelp": false,
1264
- "multiple": false,
1265
- "type": "option"
1266
- },
1267
- "target-org": {
1268
- "char": "o",
1269
- "description": "The username or alias of the target org where the jsonxform/transformation endpoint will be called. This org provides the User and Org context variables used in the transformation.",
1270
- "name": "target-org",
1271
- "noCacheDefault": true,
1272
- "required": true,
1273
- "summary": "Username or alias for the target org; overrides default target org.",
1274
- "hasDynamicHelp": true,
1275
- "multiple": false,
1276
- "type": "option"
1277
- },
1278
- "api-version": {
1279
- "description": "API version to use for the transformation request. Defaults to the org's configured API version.",
1280
- "name": "api-version",
1281
- "summary": "Override the api version used for api requests made by this command.",
1282
- "hasDynamicHelp": false,
1283
- "multiple": false,
1284
- "type": "option"
1285
- },
1286
- "template-info": {
1287
- "char": "t",
1288
- "description": "Path to the template-info.json file containing the base JSON document structure that will be transformed.",
1289
- "name": "template-info",
1290
- "required": true,
1291
- "summary": "Path to Analytics template-info.json file.",
1292
- "hasDynamicHelp": false,
1293
- "multiple": false,
1294
- "type": "option"
1295
- },
1296
- "variables": {
1297
- "char": "v",
1298
- "description": "Path to the variables.json file containing variable definitions used in transformations.",
1299
- "name": "variables",
1300
- "required": true,
1301
- "summary": "Path to Analytics variables.json file.",
1302
- "hasDynamicHelp": false,
1303
- "multiple": false,
1304
- "type": "option"
1305
- },
1306
- "rules": {
1307
- "char": "r",
1308
- "description": "Path to the rules.json file containing transformation rules and macro definitions.",
1309
- "name": "rules",
1310
- "required": true,
1311
- "summary": "Path to Analytics rules.json file.",
1312
- "hasDynamicHelp": false,
1313
- "multiple": false,
1314
- "type": "option"
1315
- }
1316
- },
1317
- "hasDynamicHelp": true,
1318
- "hiddenAliases": [],
1319
- "id": "orchestrator:rules:eval",
1320
- "pluginAlias": "@salesforce/plugin-orchestrator",
1321
- "pluginName": "@salesforce/plugin-orchestrator",
1322
- "pluginType": "core",
1323
- "strict": true,
1324
- "summary": "Test JSON transformation rules using the jsonxform/transformation endpoint.",
1325
- "enableJsonFlag": true,
1326
- "isESM": true,
1327
- "relativePath": [
1328
- "lib",
1329
- "commands",
1330
- "orchestrator",
1331
- "rules",
1332
- "eval.js"
1333
- ],
1334
- "aliasPermutations": [],
1335
- "permutations": [
1336
- "orchestrator:rules:eval",
1337
- "rules:orchestrator:eval",
1338
- "rules:eval:orchestrator",
1339
- "orchestrator:eval:rules",
1340
- "eval:orchestrator:rules",
1341
- "eval:rules:orchestrator"
1342
- ]
1343
1343
  }
1344
1344
  },
1345
- "version": "1.0.21"
1345
+ "version": "1.0.23"
1346
1346
  }
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@salesforce/plugin-orchestrator",
3
3
  "description": "Plugin for working with SalesForce analytic apps, templates, assets and services.",
4
- "version": "1.0.21",
4
+ "version": "1.0.23",
5
5
  "author": "Salesforce",
6
6
  "bugs": "https://github.com/forcedotcom/cli/issues",
7
7
  "dependencies": {
@@ -229,7 +229,7 @@
229
229
  "exports": "./lib/index.js",
230
230
  "type": "module",
231
231
  "sfdx": {
232
- "publicKeyUrl": "https://developer.salesforce.com/media/salesforce-cli/security/@salesforce/plugin-orchestrator/1.0.21.crt",
233
- "signatureUrl": "https://developer.salesforce.com/media/salesforce-cli/security/@salesforce/plugin-orchestrator/1.0.21.sig"
232
+ "publicKeyUrl": "https://developer.salesforce.com/media/salesforce-cli/security/@salesforce/plugin-orchestrator/1.0.23.crt",
233
+ "signatureUrl": "https://developer.salesforce.com/media/salesforce-cli/security/@salesforce/plugin-orchestrator/1.0.23.sig"
234
234
  }
235
235
  }