Command line tool to interact with the dojot plataform
This module is supposed to be used directly through command line, hence its recommended to install it globally
npm install -g @znti/dojot-cli
After installation is complete, you can use this module's features
CLI-tool configuration defaults to http://localhost:8000
as the dojot host, using credentials admin/admin
.
To change the host this tool connects to, simply export the new value into the DOJOT_HOST
environment variable.
export DOJOT_HOST="myServerAddress.com"
Export the environment variables DOJOT_USER
and DOJOT_PWD
to alter the used credentials for username/password access.
export DOJOT_USER="myCustomUsername" export DOJOT_HOST="myCustomPassword"
In case you already generated a JWT and wants to avoid getting yet another token, simply set the DOJOT_JWT
environment variable into your system before executing the CLI tool.
export DOJOT_JWT="eyJ0eXAiOiJKV1QiLCJh.."
Authenticates with dojot platform and list its templates and devices.
dojot hello-world
Removes every template and device on your dojot installation
dojot powerwash