# Add a "switch" node for workflows

**URL:** <https://meta.discourse.org/t/add-a-switch-node-for-workflows/417938>\
**Category:** Feature\
**Tags:** workflows\
**Created:** [November 20, 2026, 2:54pm UTC](https://meta.discourse.org/t/add-a-switch-node-for-workflows/417938 "2026-11-20T14:54:37Z")\
**Posts on this page:** 1\
**Page:** 1

## AI-generated summary

[mcwumbly](/t/-/417938/1) proposes adding a "switch" node to workflows to simplify branching logic for different input types. Currently, to handle various inputs with the same processing logic, the user employs a code node to normalize a configuration object, allowing downstream steps to reference variables consistently. Initially, this involved connecting separate scheduled triggers for each input type, but managing the schedules for longer-running jobs became cumbersome. Consequently, the user migrated to using a data table for schedule management, which resulted in a workflow filled with chained "If" nodes to route execution based on the input type. The proposed "switch" node would allow defining multiple "case" statements, each directing the flow to a distinct branch, thereby improving readability and maintainability compared to nested conditional checks.

<div class="post-metadata">

**Author:** ![mcwumbly](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/mcwumbly/32/103861_2.png) [@mcwumbly](https://meta.discourse.org/u/mcwumbly)\
**Post date:** [November 20, 2026, 2:54pm UTC](https://meta.discourse.org/t/add-a-switch-node-for-workflows/417938/1 "2026-11-20T14:54:38Z")

</div>

I have a workflow where I want to do the same thing, but for different kinds of inputs.

My approach has been to use a code node that has a simple configuration object, which is then normalized through another code node, so that downstream references can use the same name, like `var vars = $('run vars').first().json`

Initially, I had been wiring them each up to a scheduled trigger, kind of like this:

 ![Screenshot 2026-11-20 at 9.46.11 AM](https://global.discourse-cdn.com/meta/original/4X/0/2/0/0201f1c7d84eec5db3760338acefdbcac359db9f.png)

But then it got a bit tiresome to think about what each of the schedules should be, especially when there are some longer running jobs for each. So I moved to a data table to manage that part. But in the process, I have had to make this small compromise, with a bunch of chained “Ifs”:

 ![Screenshot 2026-11-20 at 9.53.26 AM](https://global.discourse-cdn.com/meta/original/4X/c/a/d/cad2e0c28fd204c2b20eeb3eb4af2cf6ec2578fa.png)

I’d love to have something like a “switch” node, where I could have multiple “case” statements that each output to a different branch.
