{
  "name": "M10 - IF Validation & Switch with Fallback",
  "nodes": [
    {
      "id": "b4a3e7b3-9aec-4761-af50-af70de4998d4",
      "parameters": {},
      "name": "Manual Trigger",
      "type": "n8n-nodes-base.manualTrigger",
      "typeVersion": 1,
      "position": [
        220,
        300
      ]
    },
    {
      "id": "235835be-4596-4c90-aa77-ad20439090fd",
      "parameters": {
        "conditions": {
          "conditions": [
            {
              "leftValue": "={{ Boolean($json.record_id?.trim()) && Boolean($json.email?.trim()) }}",
              "rightValue": true,
              "operator": {
                "type": "boolean",
                "operation": "equals"
              }
            }
          ]
        }
      },
      "name": "Validate Required Fields",
      "type": "n8n-nodes-base.if",
      "typeVersion": 2.2,
      "position": [
        460,
        300
      ]
    },
    {
      "id": "daabbc1c-c0c3-4096-a642-714352b24b23",
      "parameters": {
        "rules": {
          "values": [
            {
              "conditions": {
                "conditions": [
                  {
                    "leftValue": "={{ $json.priority }}",
                    "rightValue": "High",
                    "operator": {
                      "type": "string",
                      "operation": "equals"
                    }
                  }
                ]
              },
              "renameOutput": true,
              "outputKey": "High"
            },
            {
              "conditions": {
                "conditions": [
                  {
                    "leftValue": "={{ $json.priority }}",
                    "rightValue": "Medium",
                    "operator": {
                      "type": "string",
                      "operation": "equals"
                    }
                  }
                ]
              },
              "renameOutput": true,
              "outputKey": "Medium"
            },
            {
              "conditions": {
                "conditions": [
                  {
                    "leftValue": "={{ $json.priority }}",
                    "rightValue": "Low",
                    "operator": {
                      "type": "string",
                      "operation": "equals"
                    }
                  }
                ]
              },
              "renameOutput": true,
              "outputKey": "Low"
            }
          ]
        },
        "options": {
          "fallbackOutput": "extra"
        }
      },
      "name": "Route Priority",
      "type": "n8n-nodes-base.switch",
      "typeVersion": 3.2,
      "position": [
        720,
        260
      ]
    }
  ],
  "connections": {
    "Manual Trigger": {
      "main": [
        [
          {
            "node": "Validate Required Fields",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Validate Required Fields": {
      "main": [
        [
          {
            "node": "Route Priority",
            "type": "main",
            "index": 0
          }
        ],
        []
      ]
    }
  },
  "pinData": {},
  "settings": {
    "executionOrder": "v1"
  },
  "meta": {
    "templateCredsSetupCompleted": false,
    "source": "n8n-learning-hub"
  }
}