Workflows
Create a workflow
Persist a new workflow definition. Each chain-aware trigger and node carries its own required chainId (there is no workflow-level chain); the server validates those chains and ensures the smart wallet belongs to the authenticated user. Returns the persisted Workflow with its server-assigned id and createdAt.
post/workflows
Request body
Example request
{
"smartWalletAddress": "0x82F2Dd9a552a69f2ceD7Ff2D05c43aB8430158FB",
"trigger": {
"config": {
"chainId": 11155111
}
},
"nodes": [
{
"config": {
"destination": "0x82F2Dd9a552a69f2ceD7Ff2D05c43aB8430158FB",
"chainId": 11155111
}
}
]
}Response
Workflow created.
Example response
{
"id": "01JG2FE5MDVKBPHEG0PEYSDKAC",
"owner": "0x82F2Dd9a552a69f2ceD7Ff2D05c43aB8430158FB",
"smartWalletAddress": "0x82F2Dd9a552a69f2ceD7Ff2D05c43aB8430158FB",
"trigger": {
"config": {
"chainId": 11155111
}
},
"nodes": [
{
"config": {
"destination": "0x82F2Dd9a552a69f2ceD7Ff2D05c43aB8430158FB",
"chainId": 11155111
}
}
]
}