@@ -85,13 +85,17 @@ Activate an agent in an org.
8585
8686```
8787USAGE
88- $ sf agent activate -o <value> [--json] [--flags-dir <value>] [--api-version <value>] [-n <value>]
88+ $ sf agent activate -o <value> [--json] [--flags-dir <value>] [--api-version <value>] [-n <value>] [--version
89+ <value>]
8990
9091FLAGS
91- -n, --api-name=<value> API name of the agent to activate.
92+ -n, --api-name=<value> API name of the agent to activate; if not specified, the command provides a list that you
93+ choose from.
9294 -o, --target-org=<value> (required) Username or alias of the target org. Not required if the `target-org`
9395 configuration variable is already set.
9496 --api-version=<value> Override the api version used for api requests made by this command
97+ --version=<value> Version number of the agent to activate; if not specified, the command provides a list that
98+ you choose from.
9599
96100GLOBAL FLAGS
97101 --flags-dir=<value> Import flag values from a directory.
@@ -100,23 +104,29 @@ GLOBAL FLAGS
100104DESCRIPTION
101105 Activate an agent in an org.
102106
103- Activating an agent makes it immediately available to your users. An agent must be active before you can preview it
104- with the "agent preview" CLI command or VS Code.
107+ Activating an agent makes it immediately available to your users. A published agent must be active before you can
108+ preview it with the "agent preview" CLI command or VS Code. Agents can have multiple versions; only one version can be
109+ active at a time.
105110
106- You must know the agent's API name to activate it; you can either be prompted for it or you can specify it with the
107- --api-name flag. Find the agent's API name in its Agent Details page of your org's Agentforce Studio UI in Setup.
111+ If you run the command without the --api-name or --version flags, the command provides a list of agent API names and
112+ versions for you to choose from. Use the flags to specify the exact agent and version without being prompted. If you
113+ use the --json flag and not --version, then the latest agent version is automatically activated.
114+
115+ The value of the --version flag is always a number, corresponding to the "vX" part of the "BotVersion" metadata in
116+ your project. For example, if you have a force-app/main/default/bots/My_Agent/v4.botVersion-meta.xml file in your
117+ project, then you activate this version with the "--version 4" flag.
108118
109119EXAMPLES
110- Activate an agent in your default target org by being prompted:
120+ Activate an agent in your default target org by being prompted for both its API name and version :
111121
112122 $ sf agent activate
113123
114- Activate an agent with API name Resort_Manager in the org with alias "my-org":
124+ Activate version 2 of an agent with API name Resort_Manager in the org with alias "my-org":
115125
116- $ sf agent activate --api-name Resort_Manager --target-org my-org
126+ $ sf agent activate --api-name Resort_Manager --version 2 -- target-org my-org
117127```
118128
119- _ See code: [ src/commands/agent/activate.ts] ( https://github.com/salesforcecli/plugin-agent/blob/1.32.0 /src/commands/agent/activate.ts ) _
129+ _ See code: [ src/commands/agent/activate.ts] ( https://github.com/salesforcecli/plugin-agent/blob/1.32.1 /src/commands/agent/activate.ts ) _
120130
121131## ` sf agent create `
122132
@@ -183,7 +193,7 @@ EXAMPLES
183193 $ sf agent create --name "Resort Manager" --spec specs/resortManagerAgent.yaml --preview
184194```
185195
186- _ See code: [ src/commands/agent/create.ts] ( https://github.com/salesforcecli/plugin-agent/blob/1.32.0 /src/commands/agent/create.ts ) _
196+ _ See code: [ src/commands/agent/create.ts] ( https://github.com/salesforcecli/plugin-agent/blob/1.32.1 /src/commands/agent/create.ts ) _
187197
188198## ` sf agent deactivate `
189199
@@ -194,7 +204,8 @@ USAGE
194204 $ sf agent deactivate -o <value> [--json] [--flags-dir <value>] [--api-version <value>] [-n <value>]
195205
196206FLAGS
197- -n, --api-name=<value> API name of the agent to deactivate.
207+ -n, --api-name=<value> API name of the agent to deactivate; if not specified, the command provides a list that you
208+ choose from.
198209 -o, --target-org=<value> (required) Username or alias of the target org. Not required if the `target-org`
199210 configuration variable is already set.
200211 --api-version=<value> Override the api version used for api requests made by this command
@@ -210,8 +221,8 @@ DESCRIPTION
210221 topics or actions, you must deactivate it. You can't preview an agent with the "agent preview" CLI command or VS Code
211222 if it's deactivated.
212223
213- You must know the agent's API name to deactivate it; you can either be prompted for it or you can specify it with the
214- --api-name flag. Find the agent's API name in its Agent Details page of your org's Agentforce Studio UI in Setup .
224+ If you run the command without the --api- name flag, the command provides a list of agent API names for you to choose
225+ from. Use the flag to specify the exact agent without being prompted .
215226
216227EXAMPLES
217228 Deactivate an agent in your default target org by being prompted:
@@ -223,7 +234,7 @@ EXAMPLES
223234 $ sf agent deactivate --api-name Resort_Manager --target-org my-org
224235```
225236
226- _ See code: [ src/commands/agent/deactivate.ts] ( https://github.com/salesforcecli/plugin-agent/blob/1.32.0 /src/commands/agent/deactivate.ts ) _
237+ _ See code: [ src/commands/agent/deactivate.ts] ( https://github.com/salesforcecli/plugin-agent/blob/1.32.1 /src/commands/agent/deactivate.ts ) _
227238
228239## ` sf agent generate agent-spec `
229240
@@ -330,7 +341,7 @@ EXAMPLES
330341 $ sf agent generate agent-spec --tone formal --agent-user resortmanager@myorg.com
331342```
332343
333- _ See code: [ src/commands/agent/generate/agent-spec.ts] ( https://github.com/salesforcecli/plugin-agent/blob/1.32.0 /src/commands/agent/generate/agent-spec.ts ) _
344+ _ See code: [ src/commands/agent/generate/agent-spec.ts] ( https://github.com/salesforcecli/plugin-agent/blob/1.32.1 /src/commands/agent/generate/agent-spec.ts ) _
334345
335346## ` sf agent generate authoring-bundle `
336347
@@ -407,7 +418,7 @@ EXAMPLES
407418 other-package-dir/main/default --target-org my-dev-org
408419```
409420
410- _ See code: [ src/commands/agent/generate/authoring-bundle.ts] ( https://github.com/salesforcecli/plugin-agent/blob/1.32.0 /src/commands/agent/generate/authoring-bundle.ts ) _
421+ _ See code: [ src/commands/agent/generate/authoring-bundle.ts] ( https://github.com/salesforcecli/plugin-agent/blob/1.32.1 /src/commands/agent/generate/authoring-bundle.ts ) _
411422
412423## ` sf agent generate template `
413424
@@ -455,7 +466,7 @@ EXAMPLES
455466 force-app/main/default/bots/My_Awesome_Agent/My_Awesome_Agent.bot-meta.xml --agent-version 1
456467```
457468
458- _ See code: [ src/commands/agent/generate/template.ts] ( https://github.com/salesforcecli/plugin-agent/blob/1.32.0 /src/commands/agent/generate/template.ts ) _
469+ _ See code: [ src/commands/agent/generate/template.ts] ( https://github.com/salesforcecli/plugin-agent/blob/1.32.1 /src/commands/agent/generate/template.ts ) _
459470
460471## ` sf agent generate test-spec `
461472
@@ -520,7 +531,7 @@ EXAMPLES
520531 force-app//main/default/aiEvaluationDefinitions/Resort_Manager_Tests.aiEvaluationDefinition-meta.xml
521532```
522533
523- _ See code: [ src/commands/agent/generate/test-spec.ts] ( https://github.com/salesforcecli/plugin-agent/blob/1.32.0 /src/commands/agent/generate/test-spec.ts ) _
534+ _ See code: [ src/commands/agent/generate/test-spec.ts] ( https://github.com/salesforcecli/plugin-agent/blob/1.32.1 /src/commands/agent/generate/test-spec.ts ) _
524535
525536## ` sf agent preview `
526537
@@ -593,7 +604,7 @@ EXAMPLES
593604 $ sf agent preview --use-live-actions --apex-debug --output-dir transcripts/my-preview
594605```
595606
596- _ See code: [ src/commands/agent/preview.ts] ( https://github.com/salesforcecli/plugin-agent/blob/1.32.0 /src/commands/agent/preview.ts ) _
607+ _ See code: [ src/commands/agent/preview.ts] ( https://github.com/salesforcecli/plugin-agent/blob/1.32.1 /src/commands/agent/preview.ts ) _
597608
598609## ` sf agent preview end `
599610
@@ -648,7 +659,7 @@ EXAMPLES
648659 $ sf agent preview end --authoring-bundle My_Local_Agent
649660```
650661
651- _ See code: [ src/commands/agent/preview/end.ts] ( https://github.com/salesforcecli/plugin-agent/blob/1.32.0 /src/commands/agent/preview/end.ts ) _
662+ _ See code: [ src/commands/agent/preview/end.ts] ( https://github.com/salesforcecli/plugin-agent/blob/1.32.1 /src/commands/agent/preview/end.ts ) _
652663
653664## ` sf agent preview send `
654665
@@ -706,7 +717,7 @@ EXAMPLES
706717 $ sf agent preview send --utterance "what can you help me with?" --authoring-bundle My_Local_Agent
707718```
708719
709- _ See code: [ src/commands/agent/preview/send.ts] ( https://github.com/salesforcecli/plugin-agent/blob/1.32.0 /src/commands/agent/preview/send.ts ) _
720+ _ See code: [ src/commands/agent/preview/send.ts] ( https://github.com/salesforcecli/plugin-agent/blob/1.32.1 /src/commands/agent/preview/send.ts ) _
710721
711722## ` sf agent preview sessions `
712723
@@ -739,7 +750,7 @@ EXAMPLES
739750 $ sf agent preview sessions
740751```
741752
742- _ See code: [ src/commands/agent/preview/sessions.ts] ( https://github.com/salesforcecli/plugin-agent/blob/1.32.0 /src/commands/agent/preview/sessions.ts ) _
753+ _ See code: [ src/commands/agent/preview/sessions.ts] ( https://github.com/salesforcecli/plugin-agent/blob/1.32.1 /src/commands/agent/preview/sessions.ts ) _
743754
744755## ` sf agent preview start `
745756
@@ -796,7 +807,7 @@ EXAMPLES
796807 $ sf agent preview start --api-name My_Published_Agent
797808```
798809
799- _ See code: [ src/commands/agent/preview/start.ts] ( https://github.com/salesforcecli/plugin-agent/blob/1.32.0 /src/commands/agent/preview/start.ts ) _
810+ _ See code: [ src/commands/agent/preview/start.ts] ( https://github.com/salesforcecli/plugin-agent/blob/1.32.1 /src/commands/agent/preview/start.ts ) _
800811
801812## ` sf agent publish authoring-bundle `
802813
@@ -845,7 +856,7 @@ EXAMPLES
845856 $ sf agent publish authoring-bundle --api-name MyAuthoringbundle --target-org my-dev-org
846857```
847858
848- _ See code: [ src/commands/agent/publish/authoring-bundle.ts] ( https://github.com/salesforcecli/plugin-agent/blob/1.32.0 /src/commands/agent/publish/authoring-bundle.ts ) _
859+ _ See code: [ src/commands/agent/publish/authoring-bundle.ts] ( https://github.com/salesforcecli/plugin-agent/blob/1.32.1 /src/commands/agent/publish/authoring-bundle.ts ) _
849860
850861## ` sf agent test create `
851862
@@ -900,7 +911,7 @@ EXAMPLES
900911 $ sf agent test create --spec specs/Resort_Manager-testSpec.yaml --api-name Resort_Manager_Test --preview
901912```
902913
903- _ See code: [ src/commands/agent/test/create.ts] ( https://github.com/salesforcecli/plugin-agent/blob/1.32.0 /src/commands/agent/test/create.ts ) _
914+ _ See code: [ src/commands/agent/test/create.ts] ( https://github.com/salesforcecli/plugin-agent/blob/1.32.1 /src/commands/agent/test/create.ts ) _
904915
905916## ` sf agent test list `
906917
@@ -935,7 +946,7 @@ EXAMPLES
935946 $ sf agent test list --target-org my-org
936947```
937948
938- _ See code: [ src/commands/agent/test/list.ts] ( https://github.com/salesforcecli/plugin-agent/blob/1.32.0 /src/commands/agent/test/list.ts ) _
949+ _ See code: [ src/commands/agent/test/list.ts] ( https://github.com/salesforcecli/plugin-agent/blob/1.32.1 /src/commands/agent/test/list.ts ) _
939950
940951## ` sf agent test results `
941952
@@ -1001,7 +1012,7 @@ FLAG DESCRIPTIONS
10011012 expression when using custom evaluations.
10021013```
10031014
1004- _ See code: [ src/commands/agent/test/results.ts] ( https://github.com/salesforcecli/plugin-agent/blob/1.32.0 /src/commands/agent/test/results.ts ) _
1015+ _ See code: [ src/commands/agent/test/results.ts] ( https://github.com/salesforcecli/plugin-agent/blob/1.32.1 /src/commands/agent/test/results.ts ) _
10051016
10061017## ` sf agent test resume `
10071018
@@ -1074,7 +1085,7 @@ FLAG DESCRIPTIONS
10741085 expression when using custom evaluations.
10751086```
10761087
1077- _ See code: [ src/commands/agent/test/resume.ts] ( https://github.com/salesforcecli/plugin-agent/blob/1.32.0 /src/commands/agent/test/resume.ts ) _
1088+ _ See code: [ src/commands/agent/test/resume.ts] ( https://github.com/salesforcecli/plugin-agent/blob/1.32.1 /src/commands/agent/test/resume.ts ) _
10781089
10791090## ` sf agent test run `
10801091
@@ -1148,7 +1159,7 @@ FLAG DESCRIPTIONS
11481159 expression when using custom evaluations.
11491160```
11501161
1151- _ See code: [ src/commands/agent/test/run.ts] ( https://github.com/salesforcecli/plugin-agent/blob/1.32.0 /src/commands/agent/test/run.ts ) _
1162+ _ See code: [ src/commands/agent/test/run.ts] ( https://github.com/salesforcecli/plugin-agent/blob/1.32.1 /src/commands/agent/test/run.ts ) _
11521163
11531164## ` sf agent validate authoring-bundle `
11541165
@@ -1195,6 +1206,6 @@ EXAMPLES
11951206 $ sf agent validate authoring-bundle --api-name MyAuthoringBundle --target-org my-dev-org
11961207```
11971208
1198- _ See code: [ src/commands/agent/validate/authoring-bundle.ts] ( https://github.com/salesforcecli/plugin-agent/blob/1.32.0 /src/commands/agent/validate/authoring-bundle.ts ) _
1209+ _ See code: [ src/commands/agent/validate/authoring-bundle.ts] ( https://github.com/salesforcecli/plugin-agent/blob/1.32.1 /src/commands/agent/validate/authoring-bundle.ts ) _
11991210
12001211<!-- commandsstop -->
0 commit comments