{
  "slug": "maintenance-request",
  "name": "Maintenance request",
  "description": "Let anyone raise a repair with a photo, a location, and enough detail to dispatch on.",
  "page": "https://lazerforms.com/use-cases/maintenance-request",
  "create_url": "https://lazerforms.com/signup?template=maintenance-request",
  "fields": [
    {
      "id": "mr_category",
      "type": "select",
      "label": "What kind of problem",
      "required": true,
      "description": "",
      "options": [
        {
          "label": "Plumbing or water",
          "value": "plumbing_or_water"
        },
        {
          "label": "Electrical or lighting",
          "value": "electrical_or_lighting"
        },
        {
          "label": "Heating or cooling",
          "value": "heating_or_cooling"
        },
        {
          "label": "Door, lock, or window",
          "value": "door_lock_or_window"
        },
        {
          "label": "Lift or escalator",
          "value": "lift_or_escalator"
        },
        {
          "label": "Something else",
          "value": "something_else"
        }
      ]
    },
    {
      "id": "mr_description",
      "type": "textarea",
      "label": "Describe the problem",
      "required": true,
      "description": ""
    },
    {
      "id": "mr_photo",
      "type": "fileupload",
      "label": "Photograph of the problem",
      "required": true,
      "description": "One photo close in, one showing where it is in the room.",
      "max_files": 4
    },
    {
      "id": "mr_building",
      "type": "text",
      "label": "Building or property",
      "required": true,
      "description": ""
    },
    {
      "id": "mr_room",
      "type": "text",
      "label": "Floor and room",
      "required": true,
      "description": ""
    },
    {
      "id": "mr_access",
      "type": "select",
      "label": "Access for the technician",
      "required": true,
      "description": "",
      "options": [
        {
          "label": "Open during business hours",
          "value": "open_during_business_hours"
        },
        {
          "label": "Key needed from reception",
          "value": "key_needed_from_reception"
        },
        {
          "label": "Occupant must be present",
          "value": "occupant_must_be_present"
        },
        {
          "label": "Restricted area, escort required",
          "value": "restricted_area_escort_required"
        }
      ]
    },
    {
      "id": "mr_urgency",
      "type": "select",
      "label": "Urgency",
      "required": true,
      "description": "",
      "options": [
        {
          "label": "Emergency, unsafe right now",
          "value": "emergency_unsafe_right_now"
        },
        {
          "label": "Same day",
          "value": "same_day"
        },
        {
          "label": "Within the week",
          "value": "within_the_week"
        },
        {
          "label": "Whenever convenient",
          "value": "whenever_convenient"
        }
      ]
    },
    {
      "id": "mr_workaround",
      "type": "checkbox-simple",
      "label": "There is a usable workaround in the meantime",
      "required": true,
      "description": ""
    },
    {
      "id": "mr_reporter",
      "type": "text",
      "label": "Your name",
      "required": true,
      "description": ""
    },
    {
      "id": "mr_reporter_email",
      "type": "email",
      "label": "Your email",
      "required": true,
      "description": ""
    }
  ],
  "structure": [
    {
      "id": "mr_h1",
      "type": "heading",
      "label": "",
      "config": {
        "required": false,
        "placeholder": "",
        "description": ""
      },
      "meta": {
        "text": "What needs fixing",
        "level": 2,
        "alignment": "left",
        "color": "#000",
        "font_size": 0,
        "font_weight": "700",
        "margin_top": 24,
        "margin_bottom": 8
      }
    },
    {
      "id": "mr_category",
      "type": "select",
      "label": "What kind of problem",
      "config": {
        "required": true,
        "placeholder": "",
        "description": ""
      },
      "meta": {
        "options": [
          {
            "label": "Plumbing or water",
            "value": "plumbing_or_water"
          },
          {
            "label": "Electrical or lighting",
            "value": "electrical_or_lighting"
          },
          {
            "label": "Heating or cooling",
            "value": "heating_or_cooling"
          },
          {
            "label": "Door, lock, or window",
            "value": "door_lock_or_window"
          },
          {
            "label": "Lift or escalator",
            "value": "lift_or_escalator"
          },
          {
            "label": "Something else",
            "value": "something_else"
          }
        ]
      }
    },
    {
      "id": "mr_description",
      "type": "textarea",
      "label": "Describe the problem",
      "config": {
        "required": true,
        "placeholder": "What is wrong, and when you first noticed it.",
        "description": ""
      },
      "meta": {
        "minlength": 15,
        "maxlength": 0,
        "rows": 4
      }
    },
    {
      "id": "mr_photo",
      "type": "fileupload",
      "label": "Photograph of the problem",
      "config": {
        "required": true,
        "placeholder": "",
        "description": "One photo close in, one showing where it is in the room."
      },
      "meta": {
        "allowed_types": "jpg, png",
        "camera": true,
        "max_files": 4,
        "min_files": 1
      }
    },
    {
      "id": "mr_h2",
      "type": "heading",
      "label": "",
      "config": {
        "required": false,
        "placeholder": "",
        "description": ""
      },
      "meta": {
        "text": "Where it is",
        "level": 2,
        "alignment": "left",
        "color": "#000",
        "font_size": 0,
        "font_weight": "700",
        "margin_top": 24,
        "margin_bottom": 8
      }
    },
    {
      "id": "mr_building",
      "type": "text",
      "label": "Building or property",
      "config": {
        "required": true,
        "placeholder": "",
        "description": ""
      },
      "meta": {
        "minlength": 0,
        "maxlength": 0
      }
    },
    {
      "id": "mr_room",
      "type": "text",
      "label": "Floor and room",
      "config": {
        "required": true,
        "placeholder": "e.g. Level 3, meeting room 3.04",
        "description": ""
      },
      "meta": {
        "minlength": 0,
        "maxlength": 0
      }
    },
    {
      "id": "mr_access",
      "type": "select",
      "label": "Access for the technician",
      "config": {
        "required": true,
        "placeholder": "",
        "description": ""
      },
      "meta": {
        "options": [
          {
            "label": "Open during business hours",
            "value": "open_during_business_hours"
          },
          {
            "label": "Key needed from reception",
            "value": "key_needed_from_reception"
          },
          {
            "label": "Occupant must be present",
            "value": "occupant_must_be_present"
          },
          {
            "label": "Restricted area, escort required",
            "value": "restricted_area_escort_required"
          }
        ]
      }
    },
    {
      "id": "mr_h3",
      "type": "heading",
      "label": "",
      "config": {
        "required": false,
        "placeholder": "",
        "description": ""
      },
      "meta": {
        "text": "How urgent",
        "level": 2,
        "alignment": "left",
        "color": "#000",
        "font_size": 0,
        "font_weight": "700",
        "margin_top": 24,
        "margin_bottom": 8
      }
    },
    {
      "id": "mr_urgency",
      "type": "select",
      "label": "Urgency",
      "config": {
        "required": true,
        "placeholder": "",
        "description": ""
      },
      "meta": {
        "options": [
          {
            "label": "Emergency, unsafe right now",
            "value": "emergency_unsafe_right_now"
          },
          {
            "label": "Same day",
            "value": "same_day"
          },
          {
            "label": "Within the week",
            "value": "within_the_week"
          },
          {
            "label": "Whenever convenient",
            "value": "whenever_convenient"
          }
        ]
      }
    },
    {
      "id": "mr_workaround",
      "type": "checkbox-simple",
      "label": "There is a usable workaround in the meantime",
      "config": {
        "required": true,
        "placeholder": "",
        "description": ""
      },
      "meta": {
        "defaultValue": ""
      }
    },
    {
      "id": "mr_h4",
      "type": "heading",
      "label": "",
      "config": {
        "required": false,
        "placeholder": "",
        "description": ""
      },
      "meta": {
        "text": "Who reported it",
        "level": 2,
        "alignment": "left",
        "color": "#000",
        "font_size": 0,
        "font_weight": "700",
        "margin_top": 24,
        "margin_bottom": 8
      }
    },
    {
      "id": "mr_reporter",
      "type": "text",
      "label": "Your name",
      "config": {
        "required": true,
        "placeholder": "",
        "description": ""
      },
      "meta": {
        "minlength": 0,
        "maxlength": 0
      }
    },
    {
      "id": "mr_reporter_email",
      "type": "email",
      "label": "Your email",
      "config": {
        "required": true,
        "placeholder": "e.g., name@example.com",
        "description": ""
      },
      "meta": {}
    }
  ],
  "example_submission": {
    "values": {
      "mr_category": "plumbing_or_water",
      "mr_description": "A short factual answer.",
      "mr_building": "A short factual answer.",
      "mr_room": "A short factual answer.",
      "mr_access": "open_during_business_hours"
    },
    "idempotency_key": "maintenance-request-2026-09-09-001",
    "agent": {
      "name": "your-agent"
    }
  },
  "notes": [
    "Key every value by the field id, never by the label. A label may be renamed.",
    "A fileupload value is {\"base64\", \"filename\", \"content_type\"} or {\"url\"}, capped at 3 MB.",
    "A select value must match one of the option values exactly.",
    "A checkbox-simple value is one of yes, no, or na.",
    "A datepicker value is YYYY-MM-DD.",
    "Send an idempotency_key so a retry cannot store the same submission twice."
  ]
}