You have no disk or network access, and the VM will be killed after 1 second, which is plenty of time for most loops and workloads. Network access must be through separate Webhook steps.
This VM provides an ECMAScript v5 compatible JS. This means
other ECMAScript 6 additions are not available.
console.log can be used in the VM to log output, and this output will be
visible in the action event in the ticket itself. This can be extremely helpful
when debugging. The output from
console.log will be visible like this:
Thankful by default does not pass in or out any memories from the VM. You can
specifically pass a variable to the VM using the
In Memories and
Out Memories sections above and below the JS textarea, respectively.
will be available as variables in the JS VM. The same memory can be both passed
in and passed out, indicating that the Execute JS step is modifying the memory.
Parse JSON checkbox, you can have all memories passed into the VM
converted to JSON for you. Without this checkbox, you’ll need to run the
following before trying access any JS object fields or arrays:
myMemory = JSON.parse(myMemory)
Note that Webhook response bodies can not be parsed as JSON, so you cannot use
Parse JSON checkbox when passing in webhook data. Manually parse the
responses in the VM when appropriate.