curl --request POST \
--url https://{api-address}.org.machina.gg/workflow \
--header 'Content-Type: application/json' \
--header 'x-api-token: <api-key>' \
--data '{
"name": "<string>",
"title": "<string>",
"description": "<string>",
"context-variables": {},
"inputs": {},
"outputs": {
"workflow-status": "$.get('\''event_exists'\'') is not True and '\''skipped'\'' or '\''executed'\''"
},
"tasks": [
{
"type": "connector",
"name": "<string>",
"description": "<string>",
"condition": "<string>",
"inputs": {},
"outputs": {}
}
],
"status": "active"
}'
{
"data": {
"_id": "<string>"
},
"status": true
}
Create a new workflow and configure its parameters.
curl --request POST \
--url https://{api-address}.org.machina.gg/workflow \
--header 'Content-Type: application/json' \
--header 'x-api-token: <api-key>' \
--data '{
"name": "<string>",
"title": "<string>",
"description": "<string>",
"context-variables": {},
"inputs": {},
"outputs": {
"workflow-status": "$.get('\''event_exists'\'') is not True and '\''skipped'\'' or '\''executed'\''"
},
"tasks": [
{
"type": "connector",
"name": "<string>",
"description": "<string>",
"condition": "<string>",
"inputs": {},
"outputs": {}
}
],
"status": "active"
}'
{
"data": {
"_id": "<string>"
},
"status": true
}
API key authentication
Workflow created successfully
The response is of type object
.