Actions
Actions are things you can do when one of your triggers hit. You can select multiple actions, all of them will be executed parallely. Chronological execution coming soon. Current support actions:
- Send notifications via email, Discord, Slack, Telegram, SMS, WhatsApp or webhook.
- Run snippets of javascript, python or go code in a secure environment.
- Send transactions on-chain like calling contracts or moving assets.
Actions set on an app are called everytime any trigger fires; you can set an action
by calling .addAction
on the execute app by passing an action from below.
const x = await app.addAction(
actions.eth.callContract("contractAddress", "methodName", ["parameters"]),
);
Lets discuss the different types of actions available in execute ( we're constantly adding more )
sendWebhook
We'll ping your webhook whenever a trigger is fired in your app.
const x = await app.addAction(actions.sendWebhook("webhook url"));
callApi
We'll call your endpoint whenever a trigger is fired in your app.
const x = await app.addAction(
actions.callApi("URL", "POST", { body }, { headers }, { query }),
);
sendNotification
{" "}
Execute can send notifications to your team via email, Discord, Slack, Telegram, SMS, WhatsApp or webhook.
const x = await app.addAction(
actions.sendNotification("message body", "discord | slack | telegram"),
);
callContract
Call your contract right from execute's app by adding this action to your app.
const x = await app.addAction(
actions.eth.callContract("contractAddress", "methodName", ["parameters"]),
);