Changes

First full draft, might be okay
Line 78: Line 78:     
==Getting the device ID in RMS==
 
==Getting the device ID in RMS==
To get the ID of the device, for which we will want to generate RMS connect remote accesses and generate link for them, we first need to execute
+
To get the ID of the device, for which we will want to generate RMS connect remote accesses and generate link for them, we first need to execute '''GET /devices''' API call called '''Get all device''' in the collection list.
 +
 
 +
To get the RMS device ID we need to make this call with API call keys: '''fields''' and '''q'''. Fields will make it so that the response will only contain fields which we entered and q will make it so that only the serial number we entered is outputted.
 +
 
 +
The parameters and the response can be seen in the following image:
 +
 
 +
[[File:Networking rut configuration example RMS API get device id v1.png|border|frameless|687x687px]]
 +
 
 +
 
 +
Field "id" in the response string is the device ID in RMS.
 +
 
 +
== Adding a new remote device ==
 +
This section will tell you how to a new remote device to RMS Connect.
 +
 
 +
To add a new remote device we will need:
 +
 
 +
* Device ID of Teltonika Networks device in RMS;
 +
* LAN IP address of the device we will be creating the remote to;
 +
* Port that is used to reach that service;
 +
* Name of the protocol. The currently supported protocols are:
 +
** HTTPS
 +
** HTTP
 +
** SFTP
 +
** RDP
 +
** SSH
 +
** Telnet
 +
 
 +
The call needed to add a remote remote access device/service is '''Post /devices/remote/access''' and can be find by name '''Create a remote access configuration''' in the collection list. This API call only needs to have a quest body and no keys. An example request body to add a remote access to the routers WebUI and the response after sending the call:
 +
 
 +
 
 +
[[File:Networking rut configuration example RMS API create remote access v1.png|frameless|685x685px]]
 +
 
 +
 
 +
This will create a remote access configuration for which we will be able to generate RMS Connect links to access the devices and/or services remotely.
 +
 
 +
'''NOTE:''' It is recommended to use unique names for each remote access configuration within each router to allow for better management of remote access configurations.
 +
 
 +
== Getting the remote access ID ==
 +
After the creation of remote access configuration, it was assigned a unique id, which we need to know, to be able to generate links to that specific remote access.
 +
 
 +
For this process API call '''GET /devices/remote-access'''  and in the API call collection it is called '''Get all device's remote access configurations'''. To get the remote access ID for the newly created remote access configuration, the best way would be to filter by the device ID and the name of your new remote access configuration.
 +
 
 +
An example of the API call can be seen bellow, the remote access id will be shown in the field called "id".
 +
 
 +
[[File:Networking rut configuration example RMS API get remote access id v1.png|border|frameless|687x687px]]
 +
 
 +
== Generation of RMS Connect link ==
 +
When the remote access ID is known, we can generate the remote access link with the RMS API call '''POST /devices/connect''' that in the API collection is called '''Start a RMS Connect session'''. This call will require both the variable keys and the request body.
 +
 
 +
The only key required is '''access_id''' which will be used to identify for which remote access configuration the link will be created.
 +
 
 +
 
 +
[[File:Networking rut configuration example RMS API generate rms link keys v1.png|border|frameless|696x696px]]
 +
 
 +
 
 +
The request body need to contain the '''duration''' that will be entered in seconds. There is no limit to the maximum value but note, that our time standard has some limits.
 +
 
 +
 
 +
[[File:Networking rut configuration example RMS API generate rms link body response v1.png|border|frameless|698x698px]]
 +
 
 +
 
 +
After this call is completed the RMS connect link is now generated.
 +
 
 +
== Getting the remote access link ==
 +
After the link has been created, we can use the RMS API call '''GET /devices/connect/:access_id/sessions''' which in the API collection is called '''Get RMS Connect sessions'''. This call will display all of the links that are generated the specified remote access ID.
 +
 
 +
 
 +
[[File:Networking rut configuration example RMS API get rms connect link v1.png|border|frameless|773x773px]]
 +
 
 +
 
 +
 
 +
Congratulations, you can how access your remote device using the link you generated using RMS API.
 +
 
 +
[[File:Networking rut configuration example RMS API successful connection v1.png|border|frameless|840x840px]]

Navigation menu