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

Function builder

src/commands/edge/channels/drivers.ts:30–43  ·  view source on GitHub ↗
(yargs: Argv)

Source from the content-addressed store, hash-verified

28
29
30const builder = (yargs: Argv): Argv<CommandArgs> =>
31 outputListBuilder(apiCommandBuilder(yargs))
32 .positional('id-or-index', { describe: 'channel id or number in list', type: 'string' })
33 .example([
34 [
35 '$0 edge:channels:drivers',
36 'prompt for a channel and display drivers assigned to it',
37 ],
38 [
39 '$0 edge:channels:drivers 5491f7e6-8140-415c-9158-a3eec1cb583d',
40 'display drivers assigned to the specified channel',
41 ],
42 ])
43 .epilog(buildEpilog({ command, apiDocs: ['getChannelDrivers', 'getDriverChannel'] }))
44
45const handler = async (argv: ArgumentsCamelCase<CommandArgs>): Promise<void> => {
46 const command = await apiCommand(argv)

Callers

nothing calls this directly

Calls 2

apiCommandBuilderFunction · 0.85
buildEpilogFunction · 0.85

Tested by

no test coverage detected