MCPcopy Create free account
hub / github.com/SmartThingsCommunity/smartthings-cli / builder

Function builder

src/commands/edge/channels/enroll.ts:20–32  ·  view source on GitHub ↗
(yargs: Argv)

Source from the content-addressed store, hash-verified

18const describe = 'enroll a hub in a channel'
19
20const builder = (yargs: Argv): Argv<CommandArgs> =>
21 apiCommandBuilder(yargs)
22 .positional('id', { describe: 'hub id', type: 'string' })
23 .option('channel', { alias: 'C', describe: 'channel id', type: 'string' })
24 .example([
25 ['$0 edge:channels:enroll', 'prompt for channel and hub'],
26 [
27 '$0 edge:channels:enroll 8bbc88c2-8e59-4cad-ade2-b57021a2dbfd' +
28 ' --channel b1a462c1-f63b-442c-8db9-4af7da31f187',
29 'enroll the specified hub in the specified channel',
30 ],
31 ])
32 .epilog(buildEpilog({ command }))
33
34
35const handler = async (argv: ArgumentsCamelCase<CommandArgs>): Promise<void> => {

Callers

nothing calls this directly

Calls 2

apiCommandBuilderFunction · 0.85
buildEpilogFunction · 0.85

Tested by

no test coverage detected