Configure Flow Steps Tool
Configures handler settings or AI user messages on flow steps. Supports both single-step and bulk pipeline-scoped operations.
Overview
The configure_flow_steps tool enables configuration of flow steps after creation:
- Single Mode: Configure one specific flow step by ID
- Bulk Mode: Configure all matching steps across all flows in a pipeline
Parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
flow_step_id |
string | No* | Flow step ID for single-step mode |
pipeline_id |
integer | No* | Pipeline ID for bulk mode |
step_type |
string | No** | Filter by step type (fetch, publish, update, ai) |
handler_slug |
string | No | Handler slug to set (single) or filter by (bulk) |
target_handler_slug |
string | No | Handler to switch TO. When provided, handler_slug filters existing handlers (bulk) and target_handler_slug sets the new handler. |
field_map |
object | No | Field mappings when switching handlers, e.g. {"endpoint_url": "source_url"}. |
handler_config |
object | No*** | Handler config to merge into existing config |
flow_configs |
array | No | Per-flow configurations for bulk mode. Array of {flow_id: int, handler_config: object}. |
user_message |
string | No*** | User message/prompt for AI steps |
Validation Rules:
- *One of
flow_step_idORpipeline_idrequired - **When
pipeline_idprovided, at least one ofstep_typeorhandler_slugrequired - ***At least one of
handler_config,user_message, ortarget_handler_slugrequired
Operational Modes
Single Mode
Provide flow_step_id to configure a specific step. If target_handler_slug is provided, the step will switch handlers.
Bulk Mode
Provide pipeline_id and filters (step_type and/or handler_slug) to update multiple flows at once. This is highly efficient for updating credentials, endpoints, or prompts across an entire pipeline.
Handler Switching & Field Mapping
When switching handlers (using target_handler_slug), the tool attempts to preserve existing configuration:
- Explicit Mapping: Uses
field_mapto map old field names to new ones. - Auto-Mapping: Fields with identical names in both handlers are automatically preserved.
- Cleanup: Fields that do not exist in the target handler and aren’t mapped are dropped.
Configuration Merge Logic
The tool uses a multi-layered merge approach for handler_config:
- Mapped Base: Starts with existing config (mapped to new handler if switching).
- Shared Config:
handler_configis merged on top (applies to all targeted steps). - Per-Flow Config: In bulk mode,
flow_configsallows overriding shared settings for specific flows (merges on top of Shared Config).
Bulk Mode: Shared vs. Per-Flow Config
{
"pipeline_id": 42,
"handler_slug": "rss",
"handler_config": {
"timeframe_limit": "24_hours"
},
"flow_configs": [
{
"flow_id": 101,
"handler_config": { "feed_url": "https://site-a.com/rss" }
},
{
"flow_id": 102,
"handler_config": { "feed_url": "https://site-b.com/rss" }
}
]
}
In this example, all matching steps get timeframe_limit: "24_hours", but each flow receives its specific feed_url.
Usage Examples
Single Mode: Switch Handler with Mapping
{
"flow_step_id": "pipeline_step_123_456",
"handler_slug": "old_handler",
"target_handler_slug": "new_handler",
"field_map": {
"old_url_field": "new_source_field"
},
"handler_config": {
"additional_new_setting": true
}
}
Single Mode: Update Existing Handler Config
{
"flow_step_id": "pipeline_step_123_456",
"handler_config": {
"taxonomy_category_selection": "skip"
}
}
Bulk Mode: Update All WordPress Publish Steps in Pipeline
{
"pipeline_id": 42,
"handler_slug": "wordpress",
"handler_config": {
"taxonomy_category_selection": "skip"
}
}
Bulk Mode: Update All Publish Steps by Type
{
"pipeline_id": 42,
"step_type": "publish",
"handler_config": {
"post_status": "draft"
}
}
Bulk Mode: Update AI Prompts Across Pipeline
{
"pipeline_id": 42,
"step_type": "ai",
"user_message": "Summarize the content in 2-3 sentences"
}
Response Format
Single Mode Response
{
"success": true,
"data": {
"flow_step_id": "pipeline_step_123_456",
"handler_updated": true,
"handler_slug": "rss",
"message": "Flow step configured successfully."
}
}
Bulk Mode Response
{
"success": true,
"data": {
"pipeline_id": 42,
"flows_updated": 5,
"steps_modified": 5,
"details": [
{"flow_id": 101, "flow_name": "Music Festival Feed", "flow_step_id": "ps_15_101"},
{"flow_id": 102, "flow_name": "Food Festival Feed", "flow_step_id": "ps_15_102"}
],
"message": "Updated 5 step(s) across 5 flow(s)."
}
}
Handler Config Merge Behavior
The handler_config parameter merges into existing configuration rather than replacing it entirely. This allows targeted updates:
Existing config:
{
"post_type": "post",
"post_status": "publish",
"taxonomy_category_selection": "15"
}
Update with:
{
"handler_config": {
"taxonomy_category_selection": "skip"
}
}
Result:
{
"post_type": "post",
"post_status": "publish",
"taxonomy_category_selection": "skip"
}
Integration Workflow
- Query pipelines with
api_queryto find pipeline ID - Use
configure_flow_stepswithpipeline_idfor bulk updates - Or use
flow_step_idfor targeted single-step configuration
Error Handling
Returns structured error responses for:
- Missing required parameters
- Invalid pipeline_id or flow_step_id
- No matching steps found for bulk criteria
- Handler configuration validation failures