remot3 package¶
Submodules¶
remot3.remot3 module¶
Main Module
-
class
remot3.remot3.
Remot3
(developerkey, user, password, apiurl='https://api.remot3.it/apv/v27/')[source]¶ Bases:
object
Implements the remot3.it API calls
- Args:
- user (str): account user.
- password (str): account secret password.
- developerkey (str): account secret developer key.
- apiurl (str): API url and version.
- Params:
- token (str): session token
-
get_device_address
(deviceName, serviceType=None)[source]¶ Maps a device name to a device address
- Args:
- deviceName (str):
- serviceType (str): the service type, e.g. SSH
- Returns:
- deviceAddress(list): a list of matching device addresses
-
get_server_name
(deviceAddr, resource='/device/connect', token=None)[source]¶ Implemented the connect to a device API call
- Args:
- deviceAddres (str): the device address of the selected installation
- token (str): Optional token to be used instead of self.token
- Returns:
- status (bool): whether the call returned successfully and the response is valid
- proxyserver (str): the connection sever name if any, otherwise None
- proxyserver (str): the connection port number if any, otherwise None
- response_body (dict): the full response JSON object
-
list_devices
(resource='/device/list/all', token=None)[source]¶ Implements the device/list API call
- Args:
- resource (str): API resource
- token (str): Optional token to be used instead of self.token
- headers (dict): Optional JSON object overriding the request header
- Returns:
- status (bool): whether the call returned successfully and the response is valid
- devices (list): a list of devices
- response_body (dict): the full response JSON object
Module contents¶
Top-level package for remot3.