Skip to main content
Every computer procedure takes a botId. See Computers.

Lifecycle

If the computer provider is slow or down, these return SERVICE_UNAVAILABLE; retry with backoff.

Files

computer/files

Lists a folder.
string
required
The bot.
string
default:"/"
The folder.
Returns entries with path, kind (file or dir) and size.

computer/readFile and computer/downloadFile

readFile returns a text file’s content. downloadFile returns any file as contentBase64. Both take botId and path.

computer/uploadFile

string
required
The bot.
string
required
Where to write the file.
string
required
The file, base64-encoded.

Taking control

computer/takeover gives you control of the screen and returns a leaseId and when it expires. computer/release hands control back to the bot. You cannot take over while the bot is running; stop it first. computer/commands returns the commands the bot ran, for an activity log.