The default CLI configuration can be overridden by creating a YAML file called
config.yaml in the
$HOME/.config/@smartthings/clion MacOS or Linux
You can define multiple profiles with different configurations. Top-level keys other than the special
logging key define these profiles.
The default profile is named "default" and will be used unless otherwise specified. Most users can put their configuration options here.
To choose a different profile, you can either set the
environment variable, or use the
-p) command line
argument (when both are used, the command line argument overrides the
The following per-profile config options are supported:
|indent||2||Indent level for JSON or YAML output.|
|groupTableOutputRows||true||Separate groups of four rows by a line to make long rows easier to follow across the screen.|
|organization||none||UUID of the organization to use in applicable CLI commands.|
|token||none||Use a bearer token (such as a PAT) for authentication instead of the default login flow.|
Logging is useful when you are developing the CLI itself (rather than using it).
The CLI uses log4js for logging.
Logging is configured using a YAML file called
logging.yaml in the same
location as the config file mentioned above. The contents of this file are
passed directly to log4js, so any valid log4js configuration can be included
here. The following categories are used in the CLI:
- cli - Generic logger used by the CLI. Log entries will have the command name appended. (ex. cli.DriversCommand)
- rest-client - Used for the SDK that interfaces with the SmartThings API.
- login-authenticator - Used in the default OAuth login flow.