Commands

Node

rmaker_cmd.node.claim_node(vars=None)

Claim the node connected to the given serial port (Get cloud credentials)

Parameters

vars (str | None) – port as key - Serial Port, defaults to None

Raises

Exception – If there is an HTTP issue while claiming

Returns

None on Success

Return type

None

rmaker_cmd.node.get_mqtt_host(vars=None)

Returns MQTT Host endpoint

Parameters

vars (dict | None) – No Parameters passed, defaults to None

Raises
  • NetworkError – If there is a network connection issue while getting MQTT Host endpoint

  • Exception – If there is an HTTP issue while getting MQTT Host endpoint or JSON format issue in HTTP response

Returns

MQTT Host endpoint

Return type

str

rmaker_cmd.node.get_node_config(vars=None)

Shows the configuration of the node.

Parameters

vars (dict | None) – nodeid as key - Node ID for the node, defaults to None

Raises

Exception – If there is an HTTP issue while getting node config

Returns

None on Success

Return type

None

rmaker_cmd.node.get_node_status(vars=None)

Shows the online/offline status of the node.

Parameters

vars (dict | None) – nodeid as key - Node ID for the node, defaults to None

Raises

Exception – If there is an HTTP issue while getting node status

Returns

None on Success

Return type

None

rmaker_cmd.node.get_nodes(vars=None)

List all nodes associated with the user.

Parameters

vars (dict | None) – No Parameters passed, defaults to None

Raises

Exception – If there is an HTTP issue while getting nodes

Returns

None on Success

Return type

None

rmaker_cmd.node.get_params(vars=None)

Get parameters of the node.

Parameters

vars (dict | None) – nodeid as key - Node ID for the node, defaults to None

Raises

Exception – If there is an HTTP issue while getting params or JSON format issue in HTTP response

Returns

None on Success

Return type

None

rmaker_cmd.node.ota_upgrade(vars=None)

Upload OTA Firmware Image and Set image url returned in response as node params

rmaker_cmd.node.remove_node(vars=None)

Removes the user node mapping.

Parameters

vars (dict | None) – nodeid as key - Node ID for the node, defaults to None

Raises
  • NetworkError – If there is a network connection issue during HTTP request for removing node

  • Exception – If there is an HTTP issue while removing node or JSON format issue in HTTP response

Returns

None on Success

Return type

None

rmaker_cmd.node.set_params(vars=None)

Set parameters of the node.

Parameters

vars (dict | None) –

nodeid as key - Node ID for the node,

data as key - JSON data containing parameters to be set or

filepath as key - Path of the JSON file containing parameters

to be set,

defaults to None

Raises

Exception – If there is an HTTP issue while setting params or JSON format issue in HTTP response

Returns

None on Success

Return type

None

User

rmaker_cmd.user.forgot_password(vars=None)

Forgot password request to reset the password.

Parameters

vars (dict) – email as key - Email address of the user, defaults to None

Raises

Exception – If there is an HTTP issue while changing password for user

Returns

None on Success and Failure

Return type

None

rmaker_cmd.user.get_password()

Get Password as input and perform basic password validation checks.

Raises

SystemExit – If there is an issue in getting password

Returns

Password for User on Success

Return type

str

rmaker_cmd.user.login(vars=None)

First time login of the user.

Parameters

vars (dict) – email as key - Email address of the user, defaults to None

Raises

Exception – If there is any issue in login for user

Returns

None on Success

Return type

None

rmaker_cmd.user.signup(vars=None)

User signup to the ESP Rainmaker.

Parameters

vars (dict) – email as key - Email address of the user, defaults to None

Raises

Exception – If there is any issue in signup for user

Returns

None on Success

Return type

None

Provision

rmaker_cmd.provision.provision(vars=None)

Provisioning of the node.

Raises
  • NetworkError – If there is a network connection issue during provisioning

  • Exception – If there is an HTTP issue during provisioning

Parameters

vars (dict) – pop - Proof of Possession of the node, defaults to None

Returns

None on Success and Failure

Return type

None

Browser Login

rmaker_cmd.browserlogin.browser_login()

Opens browser with login url using Httpd Server.

Raises

Exception – If there is an HTTP issue while logging in through browser

Returns

None on Success and Failure

Return type

None