update_automation
Update an automation. Send only the fields to change — absent fields are left untouched. Supplying a trigger rewrites it and recomputes the schedule's next fire time; supplying an action rewrites it as a whole. Set enabled: false to pause an automation without deleting it.
Request
PATCH /api/v1/ops/projects/{project}/automations/{automationId}
| Parameter | In | Type | Required | Description |
|---|---|---|---|---|
project | path | string | yes | The project's public id. |
automationId | path | string | yes | The automation's public id. |
name | body | string | no | A new name. |
enabled | body | boolean | no | Enable (true) or pause (false). |
trigger | body | object | no | Replace the trigger ({ type, cron?, tz? } / { type, kind?, filter? }); recomputes nextDueUtc. |
action | body | object | no | Replace the action ({ type, … }). |
condition | body | object | null | no | Set a gate ({ "status": "failed" }) or pass null to clear it. |
warning
The trigger and action are replaced wholesale, not merged — include their full shape when you change them. Switching a schedule trigger to an event trigger clears nextDueUtc.
- cURL
- CLI
- MCP
curl -X PATCH -H "Authorization: Bearer $TESTVIBE_API_KEY" \
-H "Content-Type: application/json" \
-d '{ "enabled": false }' \
"$TESTVIBE_SERVER/api/v1/ops/projects/$PROJECT/automations/$AUTOMATION"
testvibe automations update $AUTOMATION --enabled false # pause
testvibe automations update $AUTOMATION --cron "0 6 * * *" --trigger schedule
Tool update_automation — { "automationId": "a1b2c3d4-…", "enabled": false }, or pass the trigger/action args to rewrite them.
Response
200 OK — the updated automation object.
Errors
| HTTP | When |
|---|---|
400 invalid_request | An empty name, an unknown trigger.type/action.type, or an invalid cron. |
404 not_found | No such project, or no such automation in this workspace. |