@salesforce/b2c-tooling-sdk / cli / JobCommand
Abstract Class: JobCommand<T> ​
Defined in: packages/b2c-tooling-sdk/src/cli/job-command.ts:31
Base command for job operations.
Extends InstanceCommand with job-specific functionality like displaying job logs on failure.
Example ​
export default class MyJobCommand extends JobCommand<typeof MyJobCommand> {
async run(): Promise<void> {
try {
await executeJob(this.instance, 'my-job');
} catch (error) {
if (error instanceof JobExecutionError) {
await this.showJobLog(error.execution);
}
throw error;
}
}
}Extends ​
Type Parameters ​
T ​
T extends typeof Command
Constructors ​
Constructor ​
new JobCommand<
T>(argv,config):JobCommand<T>
Defined in: packages/b2c-tooling-sdk/src/cli/oauth-command.ts:38
Parameters ​
argv ​
string[]
config ​
Config
Returns ​
JobCommand<T>
Inherited from ​
Properties ​
argv ​
argv:
string[]
Defined in: node_modules/@oclif/core/lib/command.d.ts:12
Inherited from ​
config ​
config:
Config
Defined in: node_modules/@oclif/core/lib/command.d.ts:13
Inherited from ​
id ​
id:
string|undefined
Defined in: node_modules/@oclif/core/lib/command.d.ts:75
Inherited from ​
parsed ​
parsed:
boolean
Defined in: node_modules/@oclif/core/lib/command.d.ts:76
Inherited from ​
aliases ​
staticaliases:string[]
Defined in: node_modules/@oclif/core/lib/command.d.ts:16
An array of aliases for this command.
Inherited from ​
args ​
staticargs:ArgInput
Defined in: node_modules/@oclif/core/lib/command.d.ts:18
An order-dependent object of arguments for the command
Inherited from ​
baseFlags ​
staticbaseFlags:object
Defined in: packages/b2c-tooling-sdk/src/cli/instance-command.ts:51
account-manager-host ​
account-manager-host:
OptionFlag<string,CustomOptions>
auth-methods ​
auth-methods:
OptionFlag<string[] |undefined,CustomOptions>
auth-scope ​
auth-scope:
OptionFlag<string[] |undefined,CustomOptions>
certificate ​
certificate:
OptionFlag<string|undefined,CustomOptions>
client-id ​
client-id:
OptionFlag<string,CustomOptions>
client-secret ​
client-secret:
OptionFlag<string,CustomOptions>
code-version ​
code-version:
OptionFlag<string|undefined,CustomOptions>
config ​
config:
OptionFlag<string|undefined,CustomOptions>
debug ​
debug:
BooleanFlag<boolean>
extra-body ​
extra-body:
OptionFlag<string|undefined,CustomOptions>
extra-headers ​
extra-headers:
OptionFlag<string|undefined,CustomOptions>
extra-query ​
extra-query:
OptionFlag<string|undefined,CustomOptions>
instance ​
instance:
OptionFlag<string|undefined,CustomOptions>
json ​
json:
BooleanFlag<boolean>
jsonl ​
jsonl:
BooleanFlag<boolean>
lang ​
lang:
OptionFlag<string|undefined,CustomOptions>
log-level ​
log-level:
OptionFlag<"trace"|"debug"|"info"|"warn"|"error"|"silent"|undefined,CustomOptions>
passphrase ​
passphrase:
OptionFlag<string|undefined,CustomOptions>
password ​
password:
OptionFlag<string|undefined,CustomOptions>
project-directory ​
project-directory:
OptionFlag<string,CustomOptions>
selfsigned ​
selfsigned:
BooleanFlag<boolean>
server ​
server:
OptionFlag<string|undefined,CustomOptions>
short-code ​
short-code:
OptionFlag<string|undefined,CustomOptions>
tenant-id ​
tenant-id:
OptionFlag<string|undefined,CustomOptions>
user-auth ​
user-auth:
BooleanFlag<boolean>
username ​
username:
OptionFlag<string|undefined,CustomOptions>
verify ​
verify:
BooleanFlag<boolean>
webdav-server ​
webdav-server:
OptionFlag<string|undefined,CustomOptions>
Inherited from ​
deprecateAliases? ​
staticoptionaldeprecateAliases:boolean
Defined in: node_modules/@oclif/core/lib/command.d.ts:23
Emit deprecation warning when a command alias is used
Inherited from ​
InstanceCommand.deprecateAliases
deprecationOptions? ​
staticoptionaldeprecationOptions:Deprecation
Defined in: node_modules/@oclif/core/lib/command.d.ts:24
Inherited from ​
InstanceCommand.deprecationOptions
description ​
staticdescription:string|undefined
Defined in: node_modules/@oclif/core/lib/command.d.ts:30
A full description of how to use the command.
If no summary, the first line of the description will be used as the summary.
Inherited from ​
enableJsonFlag ​
staticenableJsonFlag:boolean
Defined in: node_modules/@oclif/core/lib/command.d.ts:31
Inherited from ​
InstanceCommand.enableJsonFlag
examples ​
staticexamples:Example[]
Defined in: node_modules/@oclif/core/lib/command.d.ts:46
An array of examples to show at the end of the command's help.
IF only a string is provided, it will try to look for a line that starts with the cmd.bin as the example command and the rest as the description. If found, the command will be formatted appropriately.
EXAMPLES:
A description of a particular use case.
$ <%= config.bin => command flagsInherited from ​
flags ​
staticflags:FlagInput
Defined in: node_modules/@oclif/core/lib/command.d.ts:48
A hash of flags for the command
Inherited from ​
hasDynamicHelp ​
statichasDynamicHelp:boolean
Defined in: node_modules/@oclif/core/lib/command.d.ts:49
Inherited from ​
InstanceCommand.hasDynamicHelp
help ​
statichelp:string|undefined
Defined in: node_modules/@oclif/core/lib/command.d.ts:50
Inherited from ​
hidden ​
statichidden:boolean
Defined in: node_modules/@oclif/core/lib/command.d.ts:52
Hide the command from help
Inherited from ​
hiddenAliases ​
statichiddenAliases:string[]
Defined in: node_modules/@oclif/core/lib/command.d.ts:54
An array of aliases for this command that are hidden from help.
Inherited from ​
id ​
staticid:string
Defined in: node_modules/@oclif/core/lib/command.d.ts:56
A command ID, used mostly in error or verbose reporting.
Inherited from ​
plugin ​
staticplugin:Plugin|undefined
Defined in: node_modules/@oclif/core/lib/command.d.ts:57
Inherited from ​
pluginAlias? ​
readonlystaticoptionalpluginAlias:string
Defined in: node_modules/@oclif/core/lib/command.d.ts:58
Inherited from ​
pluginName? ​
readonlystaticoptionalpluginName:string
Defined in: node_modules/@oclif/core/lib/command.d.ts:59
Inherited from ​
pluginType? ​
readonlystaticoptionalpluginType:string
Defined in: node_modules/@oclif/core/lib/command.d.ts:60
Inherited from ​
state? ​
staticoptionalstate:string
Defined in: node_modules/@oclif/core/lib/command.d.ts:62
Mark the command as a given state (e.g. beta or deprecated) in help
Inherited from ​
strict ​
staticstrict:boolean
Defined in: node_modules/@oclif/core/lib/command.d.ts:64
When set to false, allows a variable amount of arguments
Inherited from ​
summary? ​
staticoptionalsummary:string
Defined in: node_modules/@oclif/core/lib/command.d.ts:69
The tweet-sized description for your class, used in a parent-commands sub-command listing and as the header for the command help.
Inherited from ​
usage ​
staticusage:string|string[] |undefined
Defined in: node_modules/@oclif/core/lib/command.d.ts:73
An override string (or strings) for the default usage documentation.
Inherited from ​
Methods ​
baseCommandTest() ​
baseCommandTest():
void
Defined in: packages/b2c-tooling-sdk/src/cli/base-command.ts:617
Returns ​
void
Inherited from ​
InstanceCommand.baseCommandTest
error() ​
Call Signature ​
error(
input,options):void
Defined in: node_modules/@oclif/core/lib/command.d.ts:90
Parameters ​
input ​
string | Error
options ​
object & PrettyPrintableError
Returns ​
void
Inherited from ​
Call Signature ​
error(
input,options?):never
Defined in: node_modules/@oclif/core/lib/command.d.ts:94
Parameters ​
input ​
string | Error
options? ​
object & PrettyPrintableError
Returns ​
never
Inherited from ​
exit() ​
exit(
code?):never
Defined in: node_modules/@oclif/core/lib/command.d.ts:98
Parameters ​
code? ​
number
Returns ​
never
Inherited from ​
init() ​
init():
Promise<void>
Defined in: packages/b2c-tooling-sdk/src/cli/instance-command.ts:114
Override init to collect lifecycle providers from plugins.
Returns ​
Promise<void>
Inherited from ​
jsonEnabled() ​
jsonEnabled():
boolean
Defined in: node_modules/@oclif/core/lib/command.d.ts:106
Determine if the command is being run with the --json flag in a command that supports it.
Returns ​
boolean
true if the command supports json and the --json flag is present
Inherited from ​
log() ​
log(
message?, ...args?):void
Defined in: packages/b2c-tooling-sdk/src/cli/base-command.ts:315
Override oclif's log() to use pino.
Parameters ​
message? ​
string
args? ​
...unknown[]
Returns ​
void
Inherited from ​
logToStderr() ​
logToStderr(
message?, ...args?):void
Defined in: node_modules/@oclif/core/lib/command.d.ts:109
Parameters ​
message? ​
string
args? ​
...any[]
Returns ​
void
Inherited from ​
run() ​
abstractrun():Promise<any>
Defined in: node_modules/@oclif/core/lib/command.d.ts:114
actual command run code goes here
Returns ​
Promise<any>
Inherited from ​
warn() ​
warn(
input):string|Error
Defined in: packages/b2c-tooling-sdk/src/cli/base-command.ts:324
Override oclif's warn() to use pino.
Parameters ​
input ​
string | Error
Returns ​
string | Error
Inherited from ​
run() ​
staticrun<T>(this,argv?,opts?):Promise<ReturnType<T["run"]>>
Defined in: node_modules/@oclif/core/lib/command.d.ts:86
instantiate and run the command
Type Parameters ​
T ​
T extends Command
Parameters ​
this ​
(argv, config) => T
the command class
argv? ​
string[]
argv
opts? ​
LoadOptions
options
Returns ​
Promise<ReturnType<T["run"]>>
result