[Bug / REST API Issue] Programmatically creating Automations via REST API / MCP fails to save sequences
Hi FluentCRM Team & Community,
I am attempting to programmatically create and configure FluentCRM Automation flows (Funnels) via REST API using an AI agent / MCP integration. However, Iβve encountered an issue where the Automation Sequences (Canvas Nodes) fail to save or be imported.
Here is a summary of the technical behavior observed:
1.Β POST /wp-json/fluent-crm/v2/funnels/import
When importing a full Automation JSON schema via the API endpoint, the API successfully creates the Funnel title and WooCommerce Trigger (e.g.Β woocommerce_order_status_processing), butΒ completely ignores and strips out theΒ sequencesΒ array. As a result, opening the imported Automation in the visual builder shows an empty canvas.
2.Β POST /wp-json/fluent-crm/v2/funnels/funnel/save-funnel-sequences
When sending a payload containing sequence nodes (e.g.Β action_name: "send_custom_email") to the sequence endpoint:
- Payload sent:Β JSON stringified array of sequence objects containingΒ
funnel_id,Βparent_id,Βaction_name, andΒsettings. - API Response:Β
{"sequences":[],"message":"Sequence successfully updated"} - Result:Β The API purges the sequence nodes and returns an emptyΒ
sequencesΒ array, leaving the canvas empty in the admin UI.
Questions / Request:
- Is there a specific REST API endpoint or required payload format to programmatically inject/save visual canvas sequence nodes (e.g.,Β
send_custom_email) into a Funnel? - Is theΒ
importΒ endpoint intended to support importing fullΒsequencesΒ via REST API, or is this a known API limitation?
Any insights or recommended code snippets/hooks to achieve this programmatically would be greatly appreciated!
Thanks in advance!
I'm interested in doing this so following along :)
Following.