Comment on page
Code
In Mechanic, actions are performed after their originating task run concludes. Actions are not performed inline during the task's Liquid rendering.
To inspect and respond to the results of an HTTP action, add a task subscription to mechanic/actions/perform, allowing the action to re-invoke the task with the action result data.
Task code always has access to a set of environment variables, which can be used to make decisions about what JSON objects to render.
A task must purposefully consider its preview, so as to accurately communicate its intent to users and to the Mechanic platform.
Last modified 15d ago