{
  "config": {
    "schemaVersion": 1,
    "name": "Demo Home Services — Flawed",
    "evaluationMode": "first-match",
    "destinations": [
      {
        "id": "plumbing-team",
        "label": "Plumbing Team",
        "available": true
      },
      {
        "id": "hvac-team",
        "label": "HVAC Team",
        "available": true
      },
      {
        "id": "electrical-team",
        "label": "Electrical Team",
        "available": false
      },
      {
        "id": "after-hours-desk",
        "label": "After-hours Desk",
        "available": true
      },
      {
        "id": "manual-review",
        "label": "Manual Review",
        "available": true
      }
    ],
    "rules": [
      {
        "id": "R1",
        "priority": 10,
        "conditions": [
          {
            "field": "service",
            "operator": "eq",
            "value": "plumbing"
          },
          {
            "field": "area",
            "operator": "in",
            "value": [
              "north",
              "south"
            ]
          }
        ],
        "destination": "plumbing-team"
      },
      {
        "id": "R2",
        "priority": 20,
        "conditions": [
          {
            "field": "urgent",
            "operator": "eq",
            "value": true
          },
          {
            "field": "businessHours",
            "operator": "eq",
            "value": false
          },
          {
            "field": "area",
            "operator": "in",
            "value": [
              "north",
              "south"
            ]
          }
        ],
        "destination": "after-hours-desk"
      },
      {
        "id": "R3",
        "priority": 30,
        "conditions": [
          {
            "field": "service",
            "operator": "eq",
            "value": "hvac"
          },
          {
            "field": "area",
            "operator": "eq",
            "value": "north"
          }
        ],
        "destination": "hvac-team"
      },
      {
        "id": "R4",
        "priority": 40,
        "conditions": [
          {
            "field": "service",
            "operator": "eq",
            "value": "electrical"
          },
          {
            "field": "area",
            "operator": "eq",
            "value": "north"
          }
        ],
        "destination": "electrical-team"
      }
    ],
    "fallback": null
  },
  "testCases": [
    {
      "id": "T01",
      "description": "Normal plumbing request",
      "input": {
        "service": "plumbing",
        "area": "north",
        "urgent": false,
        "businessHours": true
      },
      "expectedDestination": "plumbing-team"
    },
    {
      "id": "T02",
      "description": "Urgent after-hours plumbing request",
      "input": {
        "service": "plumbing",
        "area": "north",
        "urgent": true,
        "businessHours": false
      },
      "expectedDestination": "after-hours-desk"
    },
    {
      "id": "T03",
      "description": "North HVAC request",
      "input": {
        "service": "hvac",
        "area": "north",
        "urgent": false,
        "businessHours": true
      },
      "expectedDestination": "hvac-team"
    },
    {
      "id": "T04",
      "description": "South HVAC request",
      "input": {
        "service": "hvac",
        "area": "south",
        "urgent": false,
        "businessHours": true
      },
      "expectedDestination": "hvac-team"
    },
    {
      "id": "T05",
      "description": "Electrical team unavailable",
      "input": {
        "service": "electrical",
        "area": "north",
        "urgent": false,
        "businessHours": true
      },
      "expectedDestination": "manual-review"
    },
    {
      "id": "T06",
      "description": "Missing area",
      "input": {
        "service": "plumbing",
        "urgent": false,
        "businessHours": true
      },
      "expectedDestination": "manual-review"
    },
    {
      "id": "T07",
      "description": "Unsupported area",
      "input": {
        "service": "plumbing",
        "area": "east",
        "urgent": false,
        "businessHours": true
      },
      "expectedDestination": "manual-review"
    },
    {
      "id": "T08",
      "description": "Urgent after-hours HVAC request",
      "input": {
        "service": "hvac",
        "area": "north",
        "urgent": true,
        "businessHours": false
      },
      "expectedDestination": "after-hours-desk"
    }
  ]
}
