{
  "title": "SupaMoto Existing Customer Claim",
  "pages": [
    {
      "name": "screening",
      "elements": [
        {
          "type": "text",
          "name": "ecs:customerId",
          "title": "Customer ID",
          "isRequired": true,
          "readOnly": true
        },
        {
          "type": "dropdown",
          "name": "ecs:clientType",
          "title": "Client Group Type",
          "isRequired": true,
          "choices": [
            "Utility",
            "Utility-Staff",
            "Non-Utility",
            "Non-Utility Staff",
            "Organisation",
            "Retired",
            "Unregistered",
            "Reseller"
          ],
          "showOtherItem": true
        },
        {
          "type": "text",
          "name": "schema:givenName",
          "title": "First Name",
          "isRequired": true,
          "validators": [
            {
              "type": "regex",
              "regex": "^[A-Za-z ]+$"
            }
          ]
        },
        {
          "type": "text",
          "name": "schema:familyName",
          "title": "Last Name",
          "isRequired": true,
          "validators": [
            {
              "type": "regex",
              "regex": "^[A-Za-z ]+$"
            }
          ]
        },
        {
          "type": "radiogroup",
          "name": "person:gender",
          "title": "Gender",
          "isRequired": true,
          "choices": [
            {
              "value": "male",
              "text": "Male"
            },
            {
              "value": "female",
              "text": "Female"
            }
          ]
        },
        {
          "type": "text",
          "name": "schema:birthDate",
          "title": "Date of Birth",
          "inputType": "date"
        },
        {
          "type": "text",
          "name": "person:nationalId",
          "title": "National Registration Number",
          "isRequired": true,
          "validators": [
            {
              "type": "regex",
              "text": "Use the format xxxxxx/xx/x",
              "regex": "^\\d{6}/\\d{2}/\\d{1}$"
            }
          ],
          "placeholder": "xxxxxx/xx/x"
        },
        {
          "type": "file",
          "name": "person:nationalIdCard",
          "title": "NRC photos (front and back)",
          "isRequired": true,
          "allowMultiple": true,
          "acceptedTypes": "image/*,.pdf",
          "waitForUpload": true,
          "maxSize": 10000000,
          "sourceType": "file-camera"
        },
        {
          "type": "text",
          "name": "schema:telephone",
          "title": "Contact number",
          "isRequired": true,
          "validators": [
            {
              "type": "regex",
              "text": "Please enter the phone number in international format, including the country code (e.g. +260977123456).",
              "regex": "^\\+[1-9]\\d{6,14}$"
            }
          ],
          "inputType": "tel"
        },
        {
          "type": "text",
          "name": "schema:telephone_2",
          "title": "Alternative Contact number",
          "validators": [
            {
              "type": "regex",
              "text": "Please enter the phone number in international format, including the country code (e.g. +260977123456).",
              "regex": "^\\+[1-9]\\d{6,14}$"
            }
          ],
          "inputType": "tel"
        },
        {
          "type": "radiogroup",
          "name": "schema:DeliveryMethod",
          "title": "How would you prefer to get your pellet bag?",
          "isRequired": true,
          "choices": [
            {
              "value": "Collect from neighbor",
              "text": "Lead Generator (Neighbor) pickup"
            },
            {
              "value": "Shop Pickup",
              "text": "SupaMoto Shop pickup"
            },
            "Home Delivery"
          ]
        },
        {
          "type": "file",
          "name": "schema:profileImage",
          "title": "Profile Image ",
          "description": "Provide the reference the customer can use for real‑time payment assignment.",
          "isRequired": true,
          "acceptedTypes": "image/*,.pdf",
          "waitForUpload": true,
          "maxSize": 10000000,
          "sourceType": "file-camera",
          "allowMultiple": true
        },
        {
          "type": "text",
          "name": "schema:addressCountry",
          "title": "Country",
          "isRequired": true
        },
        {
          "type": "text",
          "name": "geo:coordinates:latitude",
          "title": "Coordinates: Latitude ",
          "isRequired": true
        },
        {
          "type": "text",
          "name": "geo:coordinates:longitude",
          "title": "Coordinates: Longitude",
          "isRequired": true
        },
        {
          "type": "file",
          "name": "schema:dataWaiver",
          "title": "Signed Carbon/Data Waiver (all pages)",
          "description": "Provide the reference the customer can use for real‑time payment assignment.",
          "isRequired": true,
          "acceptedTypes": "image/*,.pdf",
          "waitForUpload": true,
          "maxSize": 10000000,
          "sourceType": "file-camera",
          "allowMultiple": true
        },
        {
          "type": "text",
          "name": "schema:dataWaiverDate",
          "title": "Date of signature (Carbon Waiver)",
          "isRequired": true
        },
        {
          "type": "file",
          "name": "schema:signedContract",
          "title": "Upload photo of the signed contract (all pages)",
          "description": "Provide the reference the customer can use for real‑time payment assignment.",
          "isRequired": true,
          "acceptedTypes": "image/*,.pdf",
          "waitForUpload": true,
          "maxSize": 10000000,
          "sourceType": "file-camera",
          "allowMultiple": true
        },
        {
          "type": "text",
          "name": "schema:signedContractDate",
          "title": "Date of signature (Contract)",
          "isRequired": true
        }
      ],
      "title": "Questions"
    },
    {
      "name": "household",
      "title": "Household Survey",
      "elements": [
        {
          "type": "radiogroup",
          "name": "ecs:marital_status",
          "title": "Marital status",
          "choices": [
            {
              "value": "single",
              "text": "Single"
            },
            {
              "value": "married",
              "text": "Married"
            },
            {
              "value": "divorced",
              "text": "Divorced"
            },
            {
              "value": "widowed",
              "text": "Widowed"
            }
          ]
        },
        {
          "type": "dropdown",
          "name": "schema:occupancy",
          "title": "Household size (number of people)",
          "choices": [
            "1",
            "2",
            "3",
            "4",
            "5",
            "6",
            "7",
            "8",
            "9",
            "10",
            "11-15",
            "15+"
          ]
        },
        {
          "type": "text",
          "name": "ecs:occupation",
          "title": "Occupation"
        },
        {
          "type": "text",
          "name": "ecs:quantityBreakfast",
          "title": "How many people do you cook breakfast for?",
          "inputType": "number"
        },
        {
          "type": "text",
          "name": "ecs:quantityLunch",
          "title": "How many people do you cook lunch for?",
          "inputType": "number"
        },
        {
          "type": "text",
          "name": "ecs:quantityDinner",
          "title": "How many people do you cook dinner for?",
          "inputType": "number"
        },
        {
          "type": "radiogroup",
          "name": "ecs:charcoalBusiness",
          "title": "Do you run a charcoal business?",
          "choices": [
            "Yes",
            "No"
          ]
        },
        {
          "type": "dropdown",
          "name": "ecs:charcoalExpenditure",
          "title": "Monthly charcoal expenditure (ZMW)",
          "choices": [
            "0",
            "1-50",
            "50-100",
            "100-200",
            "200-300",
            "300-400",
            "400-500",
            "500-600",
            "600+"
          ]
        },
        {
          "type": "dropdown",
          "name": "ecs:charcoalPurchaseFrequency",
          "title": "How often do you buy charcoal?",
          "choices": [
            "Daily",
            "Weekly",
            "Bi-weekly",
            "Monthly",
            "Never"
          ]
        },
        {
          "type": "dropdown",
          "name": "ecs:charcoalBagSizeKg",
          "title": "Usual charcoal bag size (kg)",
          "choices": [
            "1-20",
            "21-50",
            "51-90",
            "91+"
          ],
          "showOtherItem": true
        },
        {
          "type": "dropdown",
          "name": "ecs:stoveUse",
          "title": "How will the stove be used?",
          "choices": [
            "Home use",
            "Commercial use (a defined and registered business with minimum 2 employees)"
          ]
        },
        {
          "type": "radiogroup",
          "name": "ecs:ownsStove",
          "title": "Do you already own a SupaMoto stove?",
          "choices": [
            "Yes",
            "No"
          ]
        },
        {
          "type": "dropdown",
          "name": "ecs:ignitionMethod",
          "title": "How do you light your charcoal stove?",
          "choices": [
            "Sticks",
            "Plastics",
            "Paper",
            "Paraffin",
            "Methylated Spirit"
          ],
          "showOtherItem": true
        },
        {
          "type": "radiogroup",
          "name": "schema:electricitySupply",
          "title": "Do you have access to electricity?",
          "choices": [
            "Yes",
            "No"
          ]
        },
        {
          "type": "dropdown",
          "name": "ecs:quantityElectricityCooking",
          "title": "Days per month cooking with electricity",
          "choices": [
            "0",
            "1-7",
            "8-14",
            "15-21",
            "22-31"
          ],
          "visibleIf": "{schema:electricitySupply} = 'Yes'"
        },
        {
          "type": "dropdown",
          "name": "ecs:quantityLPGCooking",
          "title": "Days per month cooking with LPG",
          "choices": [
            "0",
            "1-7",
            "8-14",
            "15-21",
            "22-31"
          ]
        },
        {
          "type": "radiogroup",
          "name": "ecs:fuelBudgetAbility",
          "title": "Can you spend K130 per month on pellets?",
          "choices": [
            "Yes",
            "No"
          ]
        },
        {
          "type": "radiogroup",
          "name": "ecs:membershipFeeWilling",
          "title": "Willing to pay the once-off membership fee?",
          "choices": [
            "Yes",
            "No"
          ]
        },
        {
          "type": "radiogroup",
          "name": "ecs:signingContract",
          "title": "Willing to self-sign the contract?",
          "choices": [
            "Yes",
            "No"
          ]
        }
      ]
    },
    {
      "name": "legacyRecord",
      "title": "Legacy Record",
      "elements": [
        {
          "type": "text",
          "name": "ecs:operatorId",
          "title": "Supa Operator",
          "isRequired": true,
          "description": "Supa Operator ID for the sales operation this customer belongs to."
        },
        {
          "type": "text",
          "name": "ecs:legacyLgId",
          "title": "Legacy Collection Partner ID",
          "readOnly": true,
          "description": "collection_partners.id from the legacy system (customers.lg_id)"
        },
        {
          "type": "text",
          "name": "ecs:timeRegistered",
          "title": "Registered at (legacy)",
          "readOnly": true,
          "isRequired": false
        },
        {
          "type": "text",
          "name": "ecs:timeLeadRegistered",
          "title": "Lead registered at (legacy)",
          "readOnly": true,
          "isRequired": false
        },
        {
          "type": "text",
          "name": "ecs:freshdeskId",
          "title": "Freshdesk ID",
          "readOnly": true,
          "isRequired": false
        }
      ]
    }
  ],
  "checkErrorsMode": "onValueChanged",
  "validateVisitedEmptyFields": true,
  "textUpdateMode": "onTyping",
  "showPreviewBeforeComplete": true
}