Device Scripting
Overview
Scripting is a feature that allows you to run a script unattended (written in any interpreted language you have installed on your Operating System) on any number of devices with a Linux or Windows based operating system.
This is useful when you have a repetitive action that you would like to perform on one or more devices.
These examples are for graphQL API scripting and do not apply to legacy.app.remote.it UI scripting. legacy.app.remote.it is deprecated and you should use this method.
Creating Scripts
Remote.It allows you to write scripts in any language your host operating system supports because the script is run just like any other executable script on your machine. This means you can write in bash, Python, Ruby, Node, etc., assuming you have the interpreter installed on your system. Scripts are executed as root.
Hello world script returning a value to Remote.It:
More example shell scripts can be found at our github repository:
Files must be able to be uploaded in 30 seconds. If you need to have larger files, consider hosting at another location such as S3 and having your script fetch them.
Scripts can also have arguments which you can pass. Arguments can be created by placing commented lines like this in your code:
These arguments can then be used as environment variables in you code. See script examples for usage.
API
Uploading a Script
Files must be able to be uploaded in 30 seconds. If you need to have larger files, consider hosting at another location such as S3 and having your script fetch them.
Running a Script
View files
Run Script without arguments
Run Script with arguments
Get Script/Job Status
Last updated
Was this helpful?