mailmoo_campaign_remove_step
Remove a step from a campaign's sequence
Removes one step from a paused campaign's sequence and joins the steps around it. The last step on a condition's path cannot be removed until another takes its place. Removing a condition needs keepBranch: yes or no keeps that path in the condition's place, its steps and their settings unchanged, and deletes the other path; none deletes both and leaves an End. When the user has not said which path to keep, ask. Without confirm it changes nothing: for a condition it returns what each path holds, how many leads have reached it, and which keepBranch values would work (steps leads have reached cannot be deleted); for any other step, the campaign's current readiness so you can name the step to the user. Then call again with confirm: true.
Effect: Write. See Effects.
Permissions: Read campaigns, Write campaigns.
Parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
campaign | string | Yes | The campaign, by name or id. |
stepId | string | Yes | The step, from campaign_get_context. |
keepBranch | yes, no, none | No | Conditions only, and required for them on confirm: the path that takes the condition's place. none deletes both paths. |
confirm | boolean | No | Leave out first: the call then changes nothing and returns what would happen. Show that to the user, and call again with confirm: true once they agree. |

