How do I actually invoke a shared Common Module from different inbound call flows using the Architect API? I’m trying to consolidate some IVR logic into a single reusable flow, but the documentation on linking flows dynamically is sparse.
I’ve created the Common Module flow with the appropriate entry points. Now I need the main inbound flows to jump to this module. I’m looking at the PUT /api/v2/architect/flows endpoint to update the flow JSON. I see there’s a subFlow action type, but I’m unclear on how to reference the Common Module ID correctly when the entry point isn’t the default start node.
Here’s the snippet I’m trying to patch into the flow JSON:
{
"name": "Route to Shared Logic",
"type": "subFlow",
"flowId": "<common-module-id>",
"entryPointId": "shared-entry-node",
"return": {
"entryPointId": "return-node"
},
"onError": {
"entryPointId": "error-handler"
}
}
When I push this, the flow validates without errors, but when a call hits this node, it just drops. No error in the logs, just silence. I’ve verified the flowId is correct and the entryPointId matches the node ID in the Common Module. Is there a specific permission or routing setting I’m missing? Or is the subFlow action not the right way to handle this? I’ve tried using the transfer action with the flowId parameter, but that seems to disconnect the call entirely rather than branching within the same session.
I’m using the Python SDK to handle the API calls, so the structure might be slightly different if I’m serializing the JSON manually. Any pointers on the correct action type or JSON structure for reusing a Common Module across multiple flows would be appreciated.