@salesforce/plugin-agent 1.24.14-demo.2 → 1.24.14-demo.6
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 +30 -29
- package/lib/commands/agent/generate/authoring-bundle.d.ts +2 -2
- package/lib/commands/agent/generate/authoring-bundle.js +60 -21
- package/lib/commands/agent/generate/authoring-bundle.js.map +1 -1
- package/lib/commands/agent/preview.d.ts +1 -2
- package/lib/commands/agent/preview.js +4 -3
- package/lib/commands/agent/preview.js.map +1 -1
- package/lib/commands/agent/publish/authoring-bundle.d.ts +2 -2
- package/lib/commands/agent/publish/authoring-bundle.js +25 -7
- package/lib/commands/agent/publish/authoring-bundle.js.map +1 -1
- package/lib/commands/agent/validate/authoring-bundle.d.ts +2 -2
- package/lib/commands/agent/validate/authoring-bundle.js +61 -11
- package/lib/commands/agent/validate/authoring-bundle.js.map +1 -1
- package/lib/flags.d.ts +2 -0
- package/lib/flags.js +23 -5
- package/lib/flags.js.map +1 -1
- package/messages/agent.generate.authoring-bundle.md +12 -4
- package/messages/agent.preview.md +1 -1
- package/messages/agent.publish.authoring-bundle.md +8 -4
- package/messages/agent.validate.authoring-bundle.md +8 -4
- package/oclif.manifest.json +105 -89
- package/package.json +7 -7
- package/schemas/agent-generate-authoring__bundle.json +2 -2
|
@@ -17,7 +17,11 @@ import { readFileSync } from 'node:fs';
|
|
|
17
17
|
import { join } from 'node:path';
|
|
18
18
|
import { SfCommand, Flags } from '@salesforce/sf-plugins-core';
|
|
19
19
|
import { Messages, SfError } from '@salesforce/core';
|
|
20
|
+
import { MultiStageOutput } from '@oclif/multi-stage-output';
|
|
20
21
|
import { Agent, findAuthoringBundle } from '@salesforce/agents';
|
|
22
|
+
import { Duration, sleep } from '@salesforce/kit';
|
|
23
|
+
import { colorize } from '@oclif/core/ux';
|
|
24
|
+
import { promptForFileByExtensions } from '../../../flags.js';
|
|
21
25
|
Messages.importMessagesDirectoryFromMetaUrl(import.meta.url);
|
|
22
26
|
const messages = Messages.loadMessages('@salesforce/plugin-agent', 'agent.validate.authoring-bundle');
|
|
23
27
|
export default class AgentValidateAuthoringBundle extends SfCommand {
|
|
@@ -25,32 +29,70 @@ export default class AgentValidateAuthoringBundle extends SfCommand {
|
|
|
25
29
|
static description = messages.getMessage('description');
|
|
26
30
|
static examples = messages.getMessages('examples');
|
|
27
31
|
static requiresProject = true;
|
|
28
|
-
static state = 'beta';
|
|
29
32
|
static flags = {
|
|
30
33
|
'target-org': Flags.requiredOrg(),
|
|
31
34
|
'api-version': Flags.orgApiVersion(),
|
|
32
35
|
'api-name': Flags.string({
|
|
33
36
|
char: 'n',
|
|
34
37
|
summary: messages.getMessage('flags.api-name.summary'),
|
|
35
|
-
required: true,
|
|
36
38
|
}),
|
|
37
39
|
};
|
|
40
|
+
static FLAGGABLE_PROMPTS = {
|
|
41
|
+
'api-name': {
|
|
42
|
+
message: messages.getMessage('flags.api-name.summary'),
|
|
43
|
+
promptMessage: messages.getMessage('flags.api-name.prompt'),
|
|
44
|
+
validate: (d) => {
|
|
45
|
+
if (d.length > 80) {
|
|
46
|
+
return 'API name cannot be over 80 characters.';
|
|
47
|
+
}
|
|
48
|
+
const regex = /^[A-Za-z][A-Za-z0-9_]*[A-Za-z0-9]+$/;
|
|
49
|
+
if (d.length === 0 || !regex.test(d)) {
|
|
50
|
+
return 'Invalid API name.';
|
|
51
|
+
}
|
|
52
|
+
return true;
|
|
53
|
+
},
|
|
54
|
+
},
|
|
55
|
+
};
|
|
38
56
|
async run() {
|
|
39
57
|
const { flags } = await this.parse(AgentValidateAuthoringBundle);
|
|
40
|
-
//
|
|
41
|
-
|
|
42
|
-
|
|
58
|
+
// If api-name is not provided, prompt user to select an .agent file from the project and extract the API name from it
|
|
59
|
+
const apiName = flags['api-name'] ??
|
|
60
|
+
(await promptForFileByExtensions(AgentValidateAuthoringBundle.FLAGGABLE_PROMPTS['api-name'], ['.agent'], true));
|
|
61
|
+
const authoringBundleDir = findAuthoringBundle(this.project.getPath(), apiName);
|
|
43
62
|
if (!authoringBundleDir) {
|
|
44
|
-
throw new SfError(messages.getMessage('error.
|
|
45
|
-
messages.getMessage('error.
|
|
63
|
+
throw new SfError(messages.getMessage('error.agentNotFound', [apiName]), 'AgentNotFoundError', [
|
|
64
|
+
messages.getMessage('error.agentNotFoundAction'),
|
|
46
65
|
]);
|
|
47
66
|
}
|
|
67
|
+
const mso = new MultiStageOutput({
|
|
68
|
+
jsonEnabled: this.jsonEnabled(),
|
|
69
|
+
title: `Validating ${apiName} Authoring Bundle`,
|
|
70
|
+
showTitle: true,
|
|
71
|
+
stages: ['Validating Authoring Bundle'],
|
|
72
|
+
stageSpecificBlock: [
|
|
73
|
+
{
|
|
74
|
+
stage: 'Validating Authoring Bundle',
|
|
75
|
+
label: 'Status',
|
|
76
|
+
type: 'dynamic-key-value',
|
|
77
|
+
get: (data) => data?.status ?? 'IN PROGRESS',
|
|
78
|
+
},
|
|
79
|
+
{
|
|
80
|
+
stage: 'Validating Authoring Bundle',
|
|
81
|
+
label: 'Errors',
|
|
82
|
+
type: 'dynamic-key-value',
|
|
83
|
+
get: (data) => data?.errors ?? '0',
|
|
84
|
+
},
|
|
85
|
+
],
|
|
86
|
+
});
|
|
48
87
|
try {
|
|
88
|
+
mso.skipTo('Validating Authoring Bundle');
|
|
49
89
|
const targetOrg = flags['target-org'];
|
|
50
90
|
const conn = targetOrg.getConnection(flags['api-version']);
|
|
51
91
|
// Call Agent.compileAfScript() API
|
|
52
|
-
await
|
|
53
|
-
|
|
92
|
+
await sleep(Duration.seconds(2));
|
|
93
|
+
await Agent.compileAfScript(conn, readFileSync(join(authoringBundleDir, `${apiName}.agent`), 'utf8'));
|
|
94
|
+
mso.updateData({ status: 'COMPLETED' });
|
|
95
|
+
mso.stop('completed');
|
|
54
96
|
return {
|
|
55
97
|
success: true,
|
|
56
98
|
};
|
|
@@ -58,11 +100,19 @@ export default class AgentValidateAuthoringBundle extends SfCommand {
|
|
|
58
100
|
catch (error) {
|
|
59
101
|
// Handle validation errors
|
|
60
102
|
const err = SfError.wrap(error);
|
|
103
|
+
let count = 0;
|
|
61
104
|
const formattedError = err.message
|
|
62
105
|
.split('\n')
|
|
63
|
-
.map((line) =>
|
|
106
|
+
.map((line) => {
|
|
107
|
+
count += 1;
|
|
108
|
+
const type = line.split(':')[0];
|
|
109
|
+
const rest = line.substring(line.indexOf(':')).trim();
|
|
110
|
+
return `- ${colorize('red', type)} ${rest}`;
|
|
111
|
+
})
|
|
64
112
|
.join('\n');
|
|
65
|
-
|
|
113
|
+
mso.updateData({ errors: count.toString(), status: 'ERROR' });
|
|
114
|
+
mso.error();
|
|
115
|
+
this.log(messages.getMessage('error.compilationFailed', [formattedError]));
|
|
66
116
|
return {
|
|
67
117
|
success: false,
|
|
68
118
|
errors: err.message.split('\n'),
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"authoring-bundle.js","sourceRoot":"","sources":["../../../../src/commands/agent/validate/authoring-bundle.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;GAcG;AACH,OAAO,EAAE,YAAY,EAAE,MAAM,SAAS,CAAC;AACvC,OAAO,EAAE,IAAI,EAAE,MAAM,WAAW,CAAC;AACjC,OAAO,EAAE,SAAS,EAAE,KAAK,EAAE,MAAM,6BAA6B,CAAC;AAC/D,OAAO,EAAE,QAAQ,EAAE,OAAO,EAAE,MAAM,kBAAkB,CAAC;AACrD,OAAO,EAAE,KAAK,EAAE,mBAAmB,EAAE,MAAM,oBAAoB,CAAC;
|
|
1
|
+
{"version":3,"file":"authoring-bundle.js","sourceRoot":"","sources":["../../../../src/commands/agent/validate/authoring-bundle.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;GAcG;AACH,OAAO,EAAE,YAAY,EAAE,MAAM,SAAS,CAAC;AACvC,OAAO,EAAE,IAAI,EAAE,MAAM,WAAW,CAAC;AACjC,OAAO,EAAE,SAAS,EAAE,KAAK,EAAE,MAAM,6BAA6B,CAAC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X,GAAG,CAAC,CAAC,IAAI,EAAE,EAAE;gBACZ,KAAK,IAAI,CAAC,CAAC;gBACX,MAAM,IAAI,GAAG,IAAI,CAAC,KAAK,CAAC,GAAG,CAAC,CAAC,CAAC,CAAC,CAAC;gBAChC,MAAM,IAAI,GAAG,IAAI,CAAC,SAAS,CAAC,IAAI,CAAC,OAAO,CAAC,GAAG,CAAC,CAAC,CAAC,IAAI,EAAE,CAAC;gBACtD,OAAO,KAAK,QAAQ,CAAC,KAAK,EAAE,IAAI,CAAC,IAAI,IAAI,EAAE,CAAC;YAC9C,CAAC,CAAC;iBACD,IAAI,CAAC,IAAI,CAAC,CAAC;YAEd,GAAG,CAAC,UAAU,CAAC,EAAE,MAAM,EAAE,KAAK,CAAC,QAAQ,EAAE,EAAE,MAAM,EAAE,OAAO,EAAE,CAAC,CAAC;YAC9D,GAAG,CAAC,KAAK,EAAE,CAAC;YAEZ,IAAI,CAAC,GAAG,CAAC,QAAQ,CAAC,UAAU,CAAC,yBAAyB,EAAE,CAAC,cAAc,CAAC,CAAC,CAAC,CAAC;YAC3E,OAAO;gBACL,OAAO,EAAE,KAAK;gBACd,MAAM,EAAE,GAAG,CAAC,OAAO,CAAC,KAAK,CAAC,IAAI,CAAC;aAChC,CAAC;QACJ,CAAC;IACH,CAAC"}
|
package/lib/flags.d.ts
CHANGED
|
@@ -30,8 +30,10 @@ export declare const testOutputDirFlag: Interfaces.FlagDefinition<string, Interf
|
|
|
30
30
|
}>;
|
|
31
31
|
export declare const verboseFlag: Interfaces.BooleanFlag<boolean>;
|
|
32
32
|
export declare function makeFlags<T extends Record<string, FlaggablePrompt>>(flaggablePrompts: T): FlagsOfPrompts<T>;
|
|
33
|
+
export declare function getHiddenDirs(projectRoot?: string): Promise<string[]>;
|
|
33
34
|
export declare function traverseForFiles(dir: string, suffixes: string[], excludeDirs?: string[]): Promise<string[]>;
|
|
34
35
|
export declare const promptForAiEvaluationDefinitionApiName: (flagDef: FlaggablePrompt, connection: Connection) => Promise<string>;
|
|
36
|
+
export declare const promptForFileByExtensions: (flagDef: FlaggablePrompt, extensions: string[], fileNameOnly?: boolean) => Promise<string>;
|
|
35
37
|
export declare const promptForYamlFile: (flagDef: FlaggablePrompt) => Promise<string>;
|
|
36
38
|
export declare const promptForFlag: (flagDef: FlaggablePrompt) => Promise<string>;
|
|
37
39
|
export declare const validateAgentType: (agentType?: string, required?: boolean) => string | undefined;
|
package/lib/flags.js
CHANGED
|
@@ -14,7 +14,7 @@
|
|
|
14
14
|
* limitations under the License.
|
|
15
15
|
*/
|
|
16
16
|
import { readdir } from 'node:fs/promises';
|
|
17
|
-
import { join, relative } from 'node:path';
|
|
17
|
+
import { basename, join, relative } from 'node:path';
|
|
18
18
|
import { Flags } from '@salesforce/sf-plugins-core';
|
|
19
19
|
import { Messages, SfError } from '@salesforce/core';
|
|
20
20
|
import { camelCaseToTitleCase } from '@salesforce/kit';
|
|
@@ -59,6 +59,16 @@ export function makeFlags(flaggablePrompts) {
|
|
|
59
59
|
}),
|
|
60
60
|
]));
|
|
61
61
|
}
|
|
62
|
+
export async function getHiddenDirs(projectRoot) {
|
|
63
|
+
const rootDir = projectRoot ?? process.cwd();
|
|
64
|
+
try {
|
|
65
|
+
const files = await readdir(rootDir, { withFileTypes: true });
|
|
66
|
+
return files.filter((file) => file.isDirectory() && file.name.startsWith('.')).map((file) => file.name);
|
|
67
|
+
}
|
|
68
|
+
catch (error) {
|
|
69
|
+
return [];
|
|
70
|
+
}
|
|
71
|
+
}
|
|
62
72
|
export async function traverseForFiles(dir, suffixes, excludeDirs) {
|
|
63
73
|
const files = await readdir(dir, { withFileTypes: true });
|
|
64
74
|
const results = [];
|
|
@@ -99,19 +109,27 @@ export const promptForAiEvaluationDefinitionApiName = async (flagDef, connection
|
|
|
99
109
|
return result;
|
|
100
110
|
});
|
|
101
111
|
};
|
|
102
|
-
export const
|
|
103
|
-
const
|
|
112
|
+
export const promptForFileByExtensions = async (flagDef, extensions, fileNameOnly = false) => {
|
|
113
|
+
const hiddenDirs = await getHiddenDirs();
|
|
114
|
+
const files = await traverseForFiles(process.cwd(), extensions, ['node_modules', ...hiddenDirs]);
|
|
104
115
|
return autocomplete({
|
|
105
|
-
message: flagDef.message,
|
|
116
|
+
message: flagDef.promptMessage ?? flagDef.message.replace(/\.$/, ''),
|
|
106
117
|
// eslint-disable-next-line @typescript-eslint/require-await
|
|
107
118
|
source: async (input) => {
|
|
108
|
-
|
|
119
|
+
let arr;
|
|
120
|
+
if (fileNameOnly) {
|
|
121
|
+
arr = files.map((o) => ({ name: basename(o).split('.')[0], value: basename(o).split('.')[0] }));
|
|
122
|
+
}
|
|
123
|
+
else {
|
|
124
|
+
arr = files.map((o) => ({ name: relative(process.cwd(), o), value: o }));
|
|
125
|
+
}
|
|
109
126
|
if (!input)
|
|
110
127
|
return arr;
|
|
111
128
|
return arr.filter((o) => o.name.includes(input));
|
|
112
129
|
},
|
|
113
130
|
});
|
|
114
131
|
};
|
|
132
|
+
export const promptForYamlFile = async (flagDef) => promptForFileByExtensions(flagDef, ['.yml', '.yaml']);
|
|
115
133
|
export const promptForFlag = async (flagDef) => {
|
|
116
134
|
const message = flagDef.promptMessage ?? flagDef.message.replace(/\.$/, '');
|
|
117
135
|
if (flagDef.options) {
|
package/lib/flags.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"flags.js","sourceRoot":"","sources":["../src/flags.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;GAcG;AAEH,OAAO,EAAE,OAAO,EAAE,MAAM,kBAAkB,CAAC;AAC3C,OAAO,EAAE,IAAI,EAAE,QAAQ,EAAE,MAAM,WAAW,CAAC;
|
|
1
|
+
{"version":3,"file":"flags.js","sourceRoot":"","sources":["../src/flags.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;GAcG;AAEH,OAAO,EAAE,OAAO,EAAE,MAAM,kBAAkB,CAAC;AAC3C,OAAO,EAAE,QAAQ,EAAE,IAAI,EAAE,QAAQ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ACpE,CAAC,CAAC"}
|
|
@@ -4,7 +4,7 @@ Generate an authoring bundle from an agent specification.
|
|
|
4
4
|
|
|
5
5
|
# description
|
|
6
6
|
|
|
7
|
-
Generates an authoring bundle containing
|
|
7
|
+
Generates an authoring bundle containing Agent and its meta.xml file from an agent specification file.
|
|
8
8
|
|
|
9
9
|
# flags.spec.summary
|
|
10
10
|
|
|
@@ -16,7 +16,15 @@ Directory where the authoring bundle files will be generated.
|
|
|
16
16
|
|
|
17
17
|
# flags.name.summary
|
|
18
18
|
|
|
19
|
-
Name (label) of the authoring bundle.
|
|
19
|
+
Name (label) of the authoring bundle.
|
|
20
|
+
|
|
21
|
+
# flags.api-name.summary
|
|
22
|
+
|
|
23
|
+
API name of the new authoring bundle; if not specified, the API name is derived from the authoring bundle name (label); the API name must not exist in the org.
|
|
24
|
+
|
|
25
|
+
# flags.api-name.prompt
|
|
26
|
+
|
|
27
|
+
API name of the new authoring bundle
|
|
20
28
|
|
|
21
29
|
# examples
|
|
22
30
|
|
|
@@ -34,6 +42,6 @@ No agent specification file found at the specified path.
|
|
|
34
42
|
|
|
35
43
|
The specified file is not a valid agent specification file.
|
|
36
44
|
|
|
37
|
-
# error.failed-to-create-
|
|
45
|
+
# error.failed-to-create-agent
|
|
38
46
|
|
|
39
|
-
Failed to create
|
|
47
|
+
Failed to create Agent from the agent specification.
|
|
@@ -20,7 +20,7 @@ API name of the agent you want to interact with.
|
|
|
20
20
|
|
|
21
21
|
# flags.authoring-bundle.summary
|
|
22
22
|
|
|
23
|
-
Preview an ephemeral
|
|
23
|
+
Preview an ephemeral agent by specifying the API name of the Authoring Bundle metadata
|
|
24
24
|
|
|
25
25
|
# flags.client-app.summary
|
|
26
26
|
|
|
@@ -15,6 +15,10 @@ Publishes an Agent Authoring Bundle by compiling the AF script and creating a ne
|
|
|
15
15
|
|
|
16
16
|
API name of the Agent Authoring Bundle to publish
|
|
17
17
|
|
|
18
|
+
# flags.api-name.prompt
|
|
19
|
+
|
|
20
|
+
API name of the authoring bundle to publish
|
|
21
|
+
|
|
18
22
|
# flags.agent-name.summary
|
|
19
23
|
|
|
20
24
|
Name for the new agent to be created
|
|
@@ -32,10 +36,10 @@ Invalid bundle path. Please provide a valid path to an Agent Authoring Bundle.
|
|
|
32
36
|
Failed to publish agent with the following errors:
|
|
33
37
|
%s
|
|
34
38
|
|
|
35
|
-
# error.
|
|
39
|
+
# error.agentNotFound
|
|
36
40
|
|
|
37
|
-
Could not find an .
|
|
41
|
+
Could not find an .agent file with API name '%s' in the project.
|
|
38
42
|
|
|
39
|
-
# error.
|
|
43
|
+
# error.agentNotFoundAction
|
|
40
44
|
|
|
41
|
-
Please check that the API name is correct and that the .
|
|
45
|
+
Please check that the API name is correct and that the .agent file exists in your project directory.
|
|
@@ -15,6 +15,10 @@ Validates an Agent Authoring Bundle by compiling the AF script and checking for
|
|
|
15
15
|
|
|
16
16
|
Path to the Agent Authoring Bundle to validate
|
|
17
17
|
|
|
18
|
+
# flags.api-name.prompt
|
|
19
|
+
|
|
20
|
+
API name of the authoring bundle to validate
|
|
21
|
+
|
|
18
22
|
# error.missingRequiredFlags
|
|
19
23
|
|
|
20
24
|
Required flag(s) missing: %s
|
|
@@ -28,10 +32,10 @@ Invalid bundle path. Please provide a valid path to an Agent Authoring Bundle.
|
|
|
28
32
|
AF Script compilation failed with the following errors:
|
|
29
33
|
%s
|
|
30
34
|
|
|
31
|
-
# error.
|
|
35
|
+
# error.agentNotFound
|
|
32
36
|
|
|
33
|
-
Could not find an .
|
|
37
|
+
Could not find an .agent file with API name '%s' in the project.
|
|
34
38
|
|
|
35
|
-
# error.
|
|
39
|
+
# error.agentNotFoundAction
|
|
36
40
|
|
|
37
|
-
Please check that the API name is correct and that the .
|
|
41
|
+
Please check that the API name is correct and that the .agent file exists in your project directory.
|
package/oclif.manifest.json
CHANGED
|
@@ -285,7 +285,6 @@
|
|
|
285
285
|
"target-org"
|
|
286
286
|
],
|
|
287
287
|
"name": "client-app",
|
|
288
|
-
"required": true,
|
|
289
288
|
"summary": "Name of the linked client app to use for the agent connection. You must have previously created this link with \"org login web --client-app\". Run \"org display\" to see the available linked client apps.",
|
|
290
289
|
"hasDynamicHelp": false,
|
|
291
290
|
"multiple": false,
|
|
@@ -301,7 +300,7 @@
|
|
|
301
300
|
},
|
|
302
301
|
"authoring-bundle": {
|
|
303
302
|
"name": "authoring-bundle",
|
|
304
|
-
"summary": "Preview an ephemeral
|
|
303
|
+
"summary": "Preview an ephemeral agent by specifying the API name of the Authoring Bundle metadata",
|
|
305
304
|
"hasDynamicHelp": false,
|
|
306
305
|
"multiple": false,
|
|
307
306
|
"type": "option"
|
|
@@ -328,7 +327,6 @@
|
|
|
328
327
|
"pluginAlias": "@salesforce/plugin-agent",
|
|
329
328
|
"pluginName": "@salesforce/plugin-agent",
|
|
330
329
|
"pluginType": "core",
|
|
331
|
-
"state": "beta",
|
|
332
330
|
"strict": true,
|
|
333
331
|
"summary": "Interact with an active agent to preview how the agent responds to your statements, questions, and commands (utterances).",
|
|
334
332
|
"enableJsonFlag": false,
|
|
@@ -346,6 +344,89 @@
|
|
|
346
344
|
"preview:agent"
|
|
347
345
|
]
|
|
348
346
|
},
|
|
347
|
+
"agent:publish:authoring-bundle": {
|
|
348
|
+
"aliases": [],
|
|
349
|
+
"args": {},
|
|
350
|
+
"description": "Publishes an Agent Authoring Bundle by compiling the AF script and creating a new agent in your org.",
|
|
351
|
+
"examples": [
|
|
352
|
+
"Publish an Agent Authoring Bundle:\n<%= config.bin %> <%= command.id %> --api-name path/to/bundle --agent-name \"My New Agent\" --target-org myorg@example.com"
|
|
353
|
+
],
|
|
354
|
+
"flags": {
|
|
355
|
+
"json": {
|
|
356
|
+
"description": "Format output as json.",
|
|
357
|
+
"helpGroup": "GLOBAL",
|
|
358
|
+
"name": "json",
|
|
359
|
+
"allowNo": false,
|
|
360
|
+
"type": "boolean"
|
|
361
|
+
},
|
|
362
|
+
"flags-dir": {
|
|
363
|
+
"helpGroup": "GLOBAL",
|
|
364
|
+
"name": "flags-dir",
|
|
365
|
+
"summary": "Import flag values from a directory.",
|
|
366
|
+
"hasDynamicHelp": false,
|
|
367
|
+
"multiple": false,
|
|
368
|
+
"type": "option"
|
|
369
|
+
},
|
|
370
|
+
"target-org": {
|
|
371
|
+
"char": "o",
|
|
372
|
+
"name": "target-org",
|
|
373
|
+
"noCacheDefault": true,
|
|
374
|
+
"required": true,
|
|
375
|
+
"summary": "Username or alias of the target org. Not required if the `target-org` configuration variable is already set.",
|
|
376
|
+
"hasDynamicHelp": true,
|
|
377
|
+
"multiple": false,
|
|
378
|
+
"type": "option"
|
|
379
|
+
},
|
|
380
|
+
"api-version": {
|
|
381
|
+
"description": "Override the api version used for api requests made by this command",
|
|
382
|
+
"name": "api-version",
|
|
383
|
+
"hasDynamicHelp": false,
|
|
384
|
+
"multiple": false,
|
|
385
|
+
"type": "option"
|
|
386
|
+
},
|
|
387
|
+
"api-name": {
|
|
388
|
+
"char": "n",
|
|
389
|
+
"name": "api-name",
|
|
390
|
+
"summary": "API name of the Agent Authoring Bundle to publish",
|
|
391
|
+
"hasDynamicHelp": false,
|
|
392
|
+
"multiple": false,
|
|
393
|
+
"type": "option"
|
|
394
|
+
}
|
|
395
|
+
},
|
|
396
|
+
"hasDynamicHelp": true,
|
|
397
|
+
"hiddenAliases": [],
|
|
398
|
+
"id": "agent:publish:authoring-bundle",
|
|
399
|
+
"pluginAlias": "@salesforce/plugin-agent",
|
|
400
|
+
"pluginName": "@salesforce/plugin-agent",
|
|
401
|
+
"pluginType": "core",
|
|
402
|
+
"strict": true,
|
|
403
|
+
"summary": "Publish an Agent Authoring Bundle as a new agent",
|
|
404
|
+
"enableJsonFlag": true,
|
|
405
|
+
"requiresProject": true,
|
|
406
|
+
"FLAGGABLE_PROMPTS": {
|
|
407
|
+
"api-name": {
|
|
408
|
+
"message": "API name of the Agent Authoring Bundle to publish",
|
|
409
|
+
"promptMessage": "API name of the authoring bundle to publish"
|
|
410
|
+
}
|
|
411
|
+
},
|
|
412
|
+
"isESM": true,
|
|
413
|
+
"relativePath": [
|
|
414
|
+
"lib",
|
|
415
|
+
"commands",
|
|
416
|
+
"agent",
|
|
417
|
+
"publish",
|
|
418
|
+
"authoring-bundle.js"
|
|
419
|
+
],
|
|
420
|
+
"aliasPermutations": [],
|
|
421
|
+
"permutations": [
|
|
422
|
+
"agent:publish:authoring-bundle",
|
|
423
|
+
"publish:agent:authoring-bundle",
|
|
424
|
+
"publish:authoring-bundle:agent",
|
|
425
|
+
"agent:authoring-bundle:publish",
|
|
426
|
+
"authoring-bundle:agent:publish",
|
|
427
|
+
"authoring-bundle:publish:agent"
|
|
428
|
+
]
|
|
429
|
+
},
|
|
349
430
|
"agent:generate:agent-spec": {
|
|
350
431
|
"aliases": [],
|
|
351
432
|
"args": {},
|
|
@@ -542,7 +623,7 @@
|
|
|
542
623
|
"agent:generate:authoring-bundle": {
|
|
543
624
|
"aliases": [],
|
|
544
625
|
"args": {},
|
|
545
|
-
"description": "Generates an authoring bundle containing
|
|
626
|
+
"description": "Generates an authoring bundle containing Agent and its meta.xml file from an agent specification file.",
|
|
546
627
|
"examples": [
|
|
547
628
|
"Generate an authoring bundle from a specification file:\n<%= config.bin %> <%= command.id %> --spec-file path/to/spec.yaml --name \"My Authoring Bundle\"",
|
|
548
629
|
"Generate an authoring bundle with a custom output directory:\n<%= config.bin %> <%= command.id %> --spec-file path/to/spec.yaml --name \"My Authoring Bundle\" --output-dir path/to/output"
|
|
@@ -573,6 +654,13 @@
|
|
|
573
654
|
"multiple": false,
|
|
574
655
|
"type": "option"
|
|
575
656
|
},
|
|
657
|
+
"api-name": {
|
|
658
|
+
"name": "api-name",
|
|
659
|
+
"summary": "API name of the new authoring bundle; if not specified, the API name is derived from the authoring bundle name (label); the API name must not exist in the org.",
|
|
660
|
+
"hasDynamicHelp": false,
|
|
661
|
+
"multiple": false,
|
|
662
|
+
"type": "option"
|
|
663
|
+
},
|
|
576
664
|
"api-version": {
|
|
577
665
|
"description": "Override the api version used for api requests made by this command",
|
|
578
666
|
"name": "api-version",
|
|
@@ -599,7 +687,7 @@
|
|
|
599
687
|
"name": {
|
|
600
688
|
"char": "n",
|
|
601
689
|
"name": "name",
|
|
602
|
-
"summary": "Name (label) of the authoring bundle.
|
|
690
|
+
"summary": "Name (label) of the authoring bundle.",
|
|
603
691
|
"hasDynamicHelp": false,
|
|
604
692
|
"multiple": false,
|
|
605
693
|
"type": "option"
|
|
@@ -611,16 +699,19 @@
|
|
|
611
699
|
"pluginAlias": "@salesforce/plugin-agent",
|
|
612
700
|
"pluginName": "@salesforce/plugin-agent",
|
|
613
701
|
"pluginType": "core",
|
|
614
|
-
"state": "beta",
|
|
615
702
|
"strict": true,
|
|
616
703
|
"summary": "Generate an authoring bundle from an agent specification.",
|
|
617
704
|
"enableJsonFlag": true,
|
|
618
705
|
"requiresProject": true,
|
|
619
706
|
"FLAGGABLE_PROMPTS": {
|
|
620
707
|
"name": {
|
|
621
|
-
"message": "Name (label) of the authoring bundle.
|
|
708
|
+
"message": "Name (label) of the authoring bundle.",
|
|
622
709
|
"required": true
|
|
623
710
|
},
|
|
711
|
+
"api-name": {
|
|
712
|
+
"message": "API name of the new authoring bundle; if not specified, the API name is derived from the authoring bundle name (label); the API name must not exist in the org.",
|
|
713
|
+
"promptMessage": "API name of the new authoring bundle"
|
|
714
|
+
},
|
|
624
715
|
"spec": {
|
|
625
716
|
"message": "Path to the agent specification file.",
|
|
626
717
|
"required": true
|
|
@@ -788,85 +879,6 @@
|
|
|
788
879
|
"test-spec:generate:agent"
|
|
789
880
|
]
|
|
790
881
|
},
|
|
791
|
-
"agent:publish:authoring-bundle": {
|
|
792
|
-
"aliases": [],
|
|
793
|
-
"args": {},
|
|
794
|
-
"description": "Publishes an Agent Authoring Bundle by compiling the AF script and creating a new agent in your org.",
|
|
795
|
-
"examples": [
|
|
796
|
-
"Publish an Agent Authoring Bundle:\n<%= config.bin %> <%= command.id %> --api-name path/to/bundle --agent-name \"My New Agent\" --target-org myorg@example.com"
|
|
797
|
-
],
|
|
798
|
-
"flags": {
|
|
799
|
-
"json": {
|
|
800
|
-
"description": "Format output as json.",
|
|
801
|
-
"helpGroup": "GLOBAL",
|
|
802
|
-
"name": "json",
|
|
803
|
-
"allowNo": false,
|
|
804
|
-
"type": "boolean"
|
|
805
|
-
},
|
|
806
|
-
"flags-dir": {
|
|
807
|
-
"helpGroup": "GLOBAL",
|
|
808
|
-
"name": "flags-dir",
|
|
809
|
-
"summary": "Import flag values from a directory.",
|
|
810
|
-
"hasDynamicHelp": false,
|
|
811
|
-
"multiple": false,
|
|
812
|
-
"type": "option"
|
|
813
|
-
},
|
|
814
|
-
"target-org": {
|
|
815
|
-
"char": "o",
|
|
816
|
-
"name": "target-org",
|
|
817
|
-
"noCacheDefault": true,
|
|
818
|
-
"required": true,
|
|
819
|
-
"summary": "Username or alias of the target org. Not required if the `target-org` configuration variable is already set.",
|
|
820
|
-
"hasDynamicHelp": true,
|
|
821
|
-
"multiple": false,
|
|
822
|
-
"type": "option"
|
|
823
|
-
},
|
|
824
|
-
"api-version": {
|
|
825
|
-
"description": "Override the api version used for api requests made by this command",
|
|
826
|
-
"name": "api-version",
|
|
827
|
-
"hasDynamicHelp": false,
|
|
828
|
-
"multiple": false,
|
|
829
|
-
"type": "option"
|
|
830
|
-
},
|
|
831
|
-
"api-name": {
|
|
832
|
-
"char": "n",
|
|
833
|
-
"name": "api-name",
|
|
834
|
-
"required": true,
|
|
835
|
-
"summary": "API name of the Agent Authoring Bundle to publish",
|
|
836
|
-
"hasDynamicHelp": false,
|
|
837
|
-
"multiple": false,
|
|
838
|
-
"type": "option"
|
|
839
|
-
}
|
|
840
|
-
},
|
|
841
|
-
"hasDynamicHelp": true,
|
|
842
|
-
"hiddenAliases": [],
|
|
843
|
-
"id": "agent:publish:authoring-bundle",
|
|
844
|
-
"pluginAlias": "@salesforce/plugin-agent",
|
|
845
|
-
"pluginName": "@salesforce/plugin-agent",
|
|
846
|
-
"pluginType": "core",
|
|
847
|
-
"state": "beta",
|
|
848
|
-
"strict": true,
|
|
849
|
-
"summary": "Publish an Agent Authoring Bundle as a new agent",
|
|
850
|
-
"enableJsonFlag": true,
|
|
851
|
-
"requiresProject": true,
|
|
852
|
-
"isESM": true,
|
|
853
|
-
"relativePath": [
|
|
854
|
-
"lib",
|
|
855
|
-
"commands",
|
|
856
|
-
"agent",
|
|
857
|
-
"publish",
|
|
858
|
-
"authoring-bundle.js"
|
|
859
|
-
],
|
|
860
|
-
"aliasPermutations": [],
|
|
861
|
-
"permutations": [
|
|
862
|
-
"agent:publish:authoring-bundle",
|
|
863
|
-
"publish:agent:authoring-bundle",
|
|
864
|
-
"publish:authoring-bundle:agent",
|
|
865
|
-
"agent:authoring-bundle:publish",
|
|
866
|
-
"authoring-bundle:agent:publish",
|
|
867
|
-
"authoring-bundle:publish:agent"
|
|
868
|
-
]
|
|
869
|
-
},
|
|
870
882
|
"agent:test:create": {
|
|
871
883
|
"aliases": [],
|
|
872
884
|
"args": {},
|
|
@@ -1424,7 +1436,6 @@
|
|
|
1424
1436
|
"api-name": {
|
|
1425
1437
|
"char": "n",
|
|
1426
1438
|
"name": "api-name",
|
|
1427
|
-
"required": true,
|
|
1428
1439
|
"summary": "Path to the Agent Authoring Bundle to validate",
|
|
1429
1440
|
"hasDynamicHelp": false,
|
|
1430
1441
|
"multiple": false,
|
|
@@ -1437,11 +1448,16 @@
|
|
|
1437
1448
|
"pluginAlias": "@salesforce/plugin-agent",
|
|
1438
1449
|
"pluginName": "@salesforce/plugin-agent",
|
|
1439
1450
|
"pluginType": "core",
|
|
1440
|
-
"state": "beta",
|
|
1441
1451
|
"strict": true,
|
|
1442
1452
|
"summary": "Validate an Agent Authoring Bundle",
|
|
1443
1453
|
"enableJsonFlag": true,
|
|
1444
1454
|
"requiresProject": true,
|
|
1455
|
+
"FLAGGABLE_PROMPTS": {
|
|
1456
|
+
"api-name": {
|
|
1457
|
+
"message": "Path to the Agent Authoring Bundle to validate",
|
|
1458
|
+
"promptMessage": "API name of the authoring bundle to validate"
|
|
1459
|
+
}
|
|
1460
|
+
},
|
|
1445
1461
|
"isESM": true,
|
|
1446
1462
|
"relativePath": [
|
|
1447
1463
|
"lib",
|
|
@@ -1461,5 +1477,5 @@
|
|
|
1461
1477
|
]
|
|
1462
1478
|
}
|
|
1463
1479
|
},
|
|
1464
|
-
"version": "1.24.14-demo.
|
|
1480
|
+
"version": "1.24.14-demo.6"
|
|
1465
1481
|
}
|