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

Function toURL

src/lib/help.ts:6–8  ·  view source on GitHub ↗
(nameOrURL: string)

Source from the content-addressed store, hash-verified

4
5
6const toURL = (nameOrURL: string): string => nameOrURL.startsWith('http')
7 ? nameOrURL
8 : `https://developer.smartthings.com/docs/api/public/#operation/${nameOrURL}`
9
10export const apiDocsURL = (names: string | string[]): string => 'For API information, see:\n ' +
11 (typeof names === 'string' ? [names] : names).map(name => toURL(name)).join('\n ')

Callers 2

apiDocsURLFunction · 0.85
itemInputHelpTextFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected