{
  "openapi": "3.0.4",
  "info": {
    "title": "GateSync.API",
    "version": "1.0"
  },
  "paths": {
    "/api/v1/admin/units": {
      "get": {
        "tags": [
          "Admin"
        ],
        "parameters": [
          {
            "name": "includeInactive",
            "in": "query",
            "schema": {
              "type": "boolean",
              "default": false
            }
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "text/plain": {
                "schema": {
                  "type": "array",
                  "items": {
                    "$ref": "#/components/schemas/AdminUnitResponse"
                  }
                }
              },
              "application/json": {
                "schema": {
                  "type": "array",
                  "items": {
                    "$ref": "#/components/schemas/AdminUnitResponse"
                  }
                }
              },
              "text/json": {
                "schema": {
                  "type": "array",
                  "items": {
                    "$ref": "#/components/schemas/AdminUnitResponse"
                  }
                }
              }
            }
          }
        }
      },
      "post": {
        "tags": [
          "Admin"
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/CreateUnitRequest"
              }
            },
            "text/json": {
              "schema": {
                "$ref": "#/components/schemas/CreateUnitRequest"
              }
            },
            "application/*+json": {
              "schema": {
                "$ref": "#/components/schemas/CreateUnitRequest"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "text/plain": {
                "schema": {
                  "$ref": "#/components/schemas/AdminUnitResponse"
                }
              },
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/AdminUnitResponse"
                }
              },
              "text/json": {
                "schema": {
                  "$ref": "#/components/schemas/AdminUnitResponse"
                }
              }
            }
          }
        }
      }
    },
    "/api/v1/admin/units/{unitId}": {
      "put": {
        "tags": [
          "Admin"
        ],
        "parameters": [
          {
            "name": "unitId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "integer",
              "format": "int64"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/UpdateUnitRequest"
              }
            },
            "text/json": {
              "schema": {
                "$ref": "#/components/schemas/UpdateUnitRequest"
              }
            },
            "application/*+json": {
              "schema": {
                "$ref": "#/components/schemas/UpdateUnitRequest"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "OK"
          }
        }
      }
    },
    "/api/v1/admin/residents": {
      "get": {
        "tags": [
          "Admin"
        ],
        "parameters": [
          {
            "name": "search",
            "in": "query",
            "schema": {
              "type": "string"
            }
          },
          {
            "name": "includeInactive",
            "in": "query",
            "schema": {
              "type": "boolean",
              "default": false
            }
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "text/plain": {
                "schema": {
                  "type": "array",
                  "items": {
                    "$ref": "#/components/schemas/AdminResidentResponse"
                  }
                }
              },
              "application/json": {
                "schema": {
                  "type": "array",
                  "items": {
                    "$ref": "#/components/schemas/AdminResidentResponse"
                  }
                }
              },
              "text/json": {
                "schema": {
                  "type": "array",
                  "items": {
                    "$ref": "#/components/schemas/AdminResidentResponse"
                  }
                }
              }
            }
          }
        }
      },
      "post": {
        "tags": [
          "Admin"
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/CreateResidentRequest"
              }
            },
            "text/json": {
              "schema": {
                "$ref": "#/components/schemas/CreateResidentRequest"
              }
            },
            "application/*+json": {
              "schema": {
                "$ref": "#/components/schemas/CreateResidentRequest"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "text/plain": {
                "schema": {
                  "$ref": "#/components/schemas/AdminResidentResponse"
                }
              },
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/AdminResidentResponse"
                }
              },
              "text/json": {
                "schema": {
                  "$ref": "#/components/schemas/AdminResidentResponse"
                }
              }
            }
          }
        }
      }
    },
    "/api/v1/admin/residents/{profileId}": {
      "get": {
        "tags": [
          "Admin"
        ],
        "parameters": [
          {
            "name": "profileId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "integer",
              "format": "int64"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "text/plain": {
                "schema": {
                  "$ref": "#/components/schemas/AdminResidentResponse"
                }
              },
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/AdminResidentResponse"
                }
              },
              "text/json": {
                "schema": {
                  "$ref": "#/components/schemas/AdminResidentResponse"
                }
              }
            }
          }
        }
      },
      "put": {
        "tags": [
          "Admin"
        ],
        "parameters": [
          {
            "name": "profileId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "integer",
              "format": "int64"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/UpdateResidentRequest"
              }
            },
            "text/json": {
              "schema": {
                "$ref": "#/components/schemas/UpdateResidentRequest"
              }
            },
            "application/*+json": {
              "schema": {
                "$ref": "#/components/schemas/UpdateResidentRequest"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "OK"
          }
        }
      }
    },
    "/api/v1/admin/residents/{profileId}/units": {
      "get": {
        "tags": [
          "Admin"
        ],
        "parameters": [
          {
            "name": "profileId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "integer",
              "format": "int64"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "text/plain": {
                "schema": {
                  "type": "array",
                  "items": {
                    "$ref": "#/components/schemas/ResidentUnitResponse"
                  }
                }
              },
              "application/json": {
                "schema": {
                  "type": "array",
                  "items": {
                    "$ref": "#/components/schemas/ResidentUnitResponse"
                  }
                }
              },
              "text/json": {
                "schema": {
                  "type": "array",
                  "items": {
                    "$ref": "#/components/schemas/ResidentUnitResponse"
                  }
                }
              }
            }
          }
        }
      },
      "post": {
        "tags": [
          "Admin"
        ],
        "parameters": [
          {
            "name": "profileId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "integer",
              "format": "int64"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/AssignUnitRequest"
              }
            },
            "text/json": {
              "schema": {
                "$ref": "#/components/schemas/AssignUnitRequest"
              }
            },
            "application/*+json": {
              "schema": {
                "$ref": "#/components/schemas/AssignUnitRequest"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "OK"
          }
        }
      }
    },
    "/api/v1/admin/residents/{profileId}/units/{unit2ProfileId}": {
      "delete": {
        "tags": [
          "Admin"
        ],
        "parameters": [
          {
            "name": "profileId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "integer",
              "format": "int64"
            }
          },
          {
            "name": "unit2ProfileId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "integer",
              "format": "int64"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "OK"
          }
        }
      }
    },
    "/api/v1/admin/settings": {
      "get": {
        "tags": [
          "Admin"
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "text/plain": {
                "schema": {
                  "type": "array",
                  "items": {
                    "$ref": "#/components/schemas/AppConfigResponse"
                  }
                }
              },
              "application/json": {
                "schema": {
                  "type": "array",
                  "items": {
                    "$ref": "#/components/schemas/AppConfigResponse"
                  }
                }
              },
              "text/json": {
                "schema": {
                  "type": "array",
                  "items": {
                    "$ref": "#/components/schemas/AppConfigResponse"
                  }
                }
              }
            }
          }
        }
      }
    },
    "/api/v1/admin/settings/{configId}": {
      "put": {
        "tags": [
          "Admin"
        ],
        "parameters": [
          {
            "name": "configId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "integer",
              "format": "int32"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/UpdateSettingRequest"
              }
            },
            "text/json": {
              "schema": {
                "$ref": "#/components/schemas/UpdateSettingRequest"
              }
            },
            "application/*+json": {
              "schema": {
                "$ref": "#/components/schemas/UpdateSettingRequest"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "OK"
          }
        }
      }
    },
    "/api/v1/admin/demo-reset": {
      "post": {
        "tags": [
          "Admin"
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "text/plain": {
                "schema": {
                  "$ref": "#/components/schemas/DemoResetResult"
                }
              },
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/DemoResetResult"
                }
              },
              "text/json": {
                "schema": {
                  "$ref": "#/components/schemas/DemoResetResult"
                }
              }
            }
          }
        }
      }
    },
    "/api/v1/admin/feature-flags": {
      "get": {
        "tags": [
          "Admin"
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "text/plain": {
                "schema": {
                  "$ref": "#/components/schemas/FeatureFlagsResponse"
                }
              },
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/FeatureFlagsResponse"
                }
              },
              "text/json": {
                "schema": {
                  "$ref": "#/components/schemas/FeatureFlagsResponse"
                }
              }
            }
          }
        }
      }
    },
    "/api/v1/auth/login": {
      "post": {
        "tags": [
          "Auth"
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/LoginRequest"
              }
            },
            "text/json": {
              "schema": {
                "$ref": "#/components/schemas/LoginRequest"
              }
            },
            "application/*+json": {
              "schema": {
                "$ref": "#/components/schemas/LoginRequest"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "text/plain": {
                "schema": {
                  "$ref": "#/components/schemas/LoginResponse"
                }
              },
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/LoginResponse"
                }
              },
              "text/json": {
                "schema": {
                  "$ref": "#/components/schemas/LoginResponse"
                }
              }
            }
          }
        }
      }
    },
    "/api/v1/auth/demo": {
      "post": {
        "tags": [
          "Auth"
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "text/plain": {
                "schema": {
                  "$ref": "#/components/schemas/LoginResponse"
                }
              },
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/LoginResponse"
                }
              },
              "text/json": {
                "schema": {
                  "$ref": "#/components/schemas/LoginResponse"
                }
              }
            }
          }
        }
      }
    },
    "/api/v1/auth/otp/challenge": {
      "post": {
        "tags": [
          "Auth"
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/OtpChallengeRequest"
              }
            },
            "text/json": {
              "schema": {
                "$ref": "#/components/schemas/OtpChallengeRequest"
              }
            },
            "application/*+json": {
              "schema": {
                "$ref": "#/components/schemas/OtpChallengeRequest"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "OK"
          }
        }
      }
    },
    "/api/v1/auth/otp/verify": {
      "post": {
        "tags": [
          "Auth"
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/OtpVerifyRequest"
              }
            },
            "text/json": {
              "schema": {
                "$ref": "#/components/schemas/OtpVerifyRequest"
              }
            },
            "application/*+json": {
              "schema": {
                "$ref": "#/components/schemas/OtpVerifyRequest"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "text/plain": {
                "schema": {
                  "$ref": "#/components/schemas/LoginResponse"
                }
              },
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/LoginResponse"
                }
              },
              "text/json": {
                "schema": {
                  "$ref": "#/components/schemas/LoginResponse"
                }
              }
            }
          }
        }
      }
    },
    "/api/v1/auth/otp/resend": {
      "post": {
        "tags": [
          "Auth"
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/OtpResendRequest"
              }
            },
            "text/json": {
              "schema": {
                "$ref": "#/components/schemas/OtpResendRequest"
              }
            },
            "application/*+json": {
              "schema": {
                "$ref": "#/components/schemas/OtpResendRequest"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "OK"
          }
        }
      }
    },
    "/api/v1/auth/verify-receipt": {
      "post": {
        "tags": [
          "Auth"
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/VerifyReceiptRequest"
              }
            },
            "text/json": {
              "schema": {
                "$ref": "#/components/schemas/VerifyReceiptRequest"
              }
            },
            "application/*+json": {
              "schema": {
                "$ref": "#/components/schemas/VerifyReceiptRequest"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "text/plain": {
                "schema": {
                  "$ref": "#/components/schemas/LoginResponse"
                }
              },
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/LoginResponse"
                }
              },
              "text/json": {
                "schema": {
                  "$ref": "#/components/schemas/LoginResponse"
                }
              }
            }
          }
        }
      }
    },
    "/api/v1/billing/subscription": {
      "get": {
        "tags": [
          "Billing"
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "text/plain": {
                "schema": {
                  "$ref": "#/components/schemas/SubscriptionStatusResponse"
                }
              },
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/SubscriptionStatusResponse"
                }
              },
              "text/json": {
                "schema": {
                  "$ref": "#/components/schemas/SubscriptionStatusResponse"
                }
              }
            }
          }
        }
      }
    },
    "/api/v1/billing/checkout": {
      "post": {
        "tags": [
          "Billing"
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/CheckoutRequest"
              }
            },
            "text/json": {
              "schema": {
                "$ref": "#/components/schemas/CheckoutRequest"
              }
            },
            "application/*+json": {
              "schema": {
                "$ref": "#/components/schemas/CheckoutRequest"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "text/plain": {
                "schema": {
                  "$ref": "#/components/schemas/CheckoutResponse"
                }
              },
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CheckoutResponse"
                }
              },
              "text/json": {
                "schema": {
                  "$ref": "#/components/schemas/CheckoutResponse"
                }
              }
            }
          }
        }
      }
    },
    "/api/v1/billing/plans": {
      "get": {
        "tags": [
          "Billing"
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "text/plain": {
                "schema": {
                  "type": "array",
                  "items": {
                    "$ref": "#/components/schemas/PlanResponse"
                  }
                }
              },
              "application/json": {
                "schema": {
                  "type": "array",
                  "items": {
                    "$ref": "#/components/schemas/PlanResponse"
                  }
                }
              },
              "text/json": {
                "schema": {
                  "type": "array",
                  "items": {
                    "$ref": "#/components/schemas/PlanResponse"
                  }
                }
              }
            }
          }
        }
      }
    },
    "/api/v1/billing/publishable-key": {
      "get": {
        "tags": [
          "Billing"
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "text/plain": {
                "schema": {
                  "$ref": "#/components/schemas/PublishableKeyResponse"
                }
              },
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/PublishableKeyResponse"
                }
              },
              "text/json": {
                "schema": {
                  "$ref": "#/components/schemas/PublishableKeyResponse"
                }
              }
            }
          }
        }
      }
    },
    "/api/v1/demo/events": {
      "post": {
        "tags": [
          "DemoEvents"
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/DemoEventRequest"
              }
            },
            "text/json": {
              "schema": {
                "$ref": "#/components/schemas/DemoEventRequest"
              }
            },
            "application/*+json": {
              "schema": {
                "$ref": "#/components/schemas/DemoEventRequest"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "OK"
          }
        }
      }
    },
    "/api/v1/demo/sms/simulate": {
      "post": {
        "tags": [
          "DemoSms"
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/DemoSmsSimulateRequest"
              }
            },
            "text/json": {
              "schema": {
                "$ref": "#/components/schemas/DemoSmsSimulateRequest"
              }
            },
            "application/*+json": {
              "schema": {
                "$ref": "#/components/schemas/DemoSmsSimulateRequest"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "OK"
          }
        }
      }
    },
    "/api/v1/gate-items": {
      "get": {
        "tags": [
          "GateItems"
        ],
        "parameters": [
          {
            "name": "outstandingOnly",
            "in": "query",
            "schema": {
              "type": "boolean",
              "default": true
            }
          },
          {
            "name": "search",
            "in": "query",
            "schema": {
              "type": "string"
            }
          },
          {
            "name": "daysInPast",
            "in": "query",
            "schema": {
              "type": "integer",
              "format": "int32",
              "default": 30
            }
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "text/plain": {
                "schema": {
                  "type": "array",
                  "items": {
                    "$ref": "#/components/schemas/GateItemResponse"
                  }
                }
              },
              "application/json": {
                "schema": {
                  "type": "array",
                  "items": {
                    "$ref": "#/components/schemas/GateItemResponse"
                  }
                }
              },
              "text/json": {
                "schema": {
                  "type": "array",
                  "items": {
                    "$ref": "#/components/schemas/GateItemResponse"
                  }
                }
              }
            }
          }
        }
      }
    },
    "/api/v1/gate-items/{itemId}/return": {
      "patch": {
        "tags": [
          "GateItems"
        ],
        "parameters": [
          {
            "name": "itemId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "integer",
              "format": "int64"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "OK"
          }
        }
      }
    },
    "/api/v1/gate-items/types": {
      "get": {
        "tags": [
          "GateItems"
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "text/plain": {
                "schema": {
                  "type": "array",
                  "items": {
                    "$ref": "#/components/schemas/GateVisitItemTypeResponse"
                  }
                }
              },
              "application/json": {
                "schema": {
                  "type": "array",
                  "items": {
                    "$ref": "#/components/schemas/GateVisitItemTypeResponse"
                  }
                }
              },
              "text/json": {
                "schema": {
                  "type": "array",
                  "items": {
                    "$ref": "#/components/schemas/GateVisitItemTypeResponse"
                  }
                }
              }
            }
          }
        }
      }
    },
    "/api/v1/Gates": {
      "get": {
        "tags": [
          "Gates"
        ],
        "parameters": [
          {
            "name": "includeInactive",
            "in": "query",
            "schema": {
              "type": "boolean",
              "default": false
            }
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "text/plain": {
                "schema": {
                  "type": "array",
                  "items": {
                    "$ref": "#/components/schemas/GateResponse"
                  }
                }
              },
              "application/json": {
                "schema": {
                  "type": "array",
                  "items": {
                    "$ref": "#/components/schemas/GateResponse"
                  }
                }
              },
              "text/json": {
                "schema": {
                  "type": "array",
                  "items": {
                    "$ref": "#/components/schemas/GateResponse"
                  }
                }
              }
            }
          }
        }
      },
      "post": {
        "tags": [
          "Gates"
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/CreateGateRequest"
              }
            },
            "text/json": {
              "schema": {
                "$ref": "#/components/schemas/CreateGateRequest"
              }
            },
            "application/*+json": {
              "schema": {
                "$ref": "#/components/schemas/CreateGateRequest"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "text/plain": {
                "schema": {
                  "$ref": "#/components/schemas/GateResponse"
                }
              },
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/GateResponse"
                }
              },
              "text/json": {
                "schema": {
                  "$ref": "#/components/schemas/GateResponse"
                }
              }
            }
          }
        }
      }
    },
    "/api/v1/Gates/{gateId}": {
      "put": {
        "tags": [
          "Gates"
        ],
        "parameters": [
          {
            "name": "gateId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "integer",
              "format": "int32"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/UpdateGateRequest"
              }
            },
            "text/json": {
              "schema": {
                "$ref": "#/components/schemas/UpdateGateRequest"
              }
            },
            "application/*+json": {
              "schema": {
                "$ref": "#/components/schemas/UpdateGateRequest"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "OK"
          }
        }
      }
    },
    "/health": {
      "get": {
        "tags": [
          "GateSync.API"
        ],
        "operationId": "HealthCheck",
        "responses": {
          "200": {
            "description": "OK"
          }
        }
      }
    },
    "/api/v1/gate-visits": {
      "get": {
        "tags": [
          "GateVisits"
        ],
        "parameters": [
          {
            "name": "search",
            "in": "query",
            "schema": {
              "type": "string"
            }
          },
          {
            "name": "daysInPast",
            "in": "query",
            "schema": {
              "type": "integer",
              "format": "int32",
              "default": 1
            }
          },
          {
            "name": "type",
            "in": "query",
            "schema": {
              "type": "string"
            }
          },
          {
            "name": "visitId",
            "in": "query",
            "schema": {
              "type": "integer",
              "format": "int64"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "text/plain": {
                "schema": {
                  "type": "array",
                  "items": {
                    "$ref": "#/components/schemas/GateVisitResponse"
                  }
                }
              },
              "application/json": {
                "schema": {
                  "type": "array",
                  "items": {
                    "$ref": "#/components/schemas/GateVisitResponse"
                  }
                }
              },
              "text/json": {
                "schema": {
                  "type": "array",
                  "items": {
                    "$ref": "#/components/schemas/GateVisitResponse"
                  }
                }
              }
            }
          }
        }
      },
      "post": {
        "tags": [
          "GateVisits"
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/CheckInRequest"
              }
            },
            "text/json": {
              "schema": {
                "$ref": "#/components/schemas/CheckInRequest"
              }
            },
            "application/*+json": {
              "schema": {
                "$ref": "#/components/schemas/CheckInRequest"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "text/plain": {
                "schema": {
                  "$ref": "#/components/schemas/GateVisitResponse"
                }
              },
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/GateVisitResponse"
                }
              },
              "text/json": {
                "schema": {
                  "$ref": "#/components/schemas/GateVisitResponse"
                }
              }
            }
          }
        }
      }
    },
    "/api/v1/gate-visits/daily-count": {
      "get": {
        "tags": [
          "GateVisits"
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "text/plain": {
                "schema": {
                  "$ref": "#/components/schemas/DailyCountResponse"
                }
              },
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/DailyCountResponse"
                }
              },
              "text/json": {
                "schema": {
                  "$ref": "#/components/schemas/DailyCountResponse"
                }
              }
            }
          }
        }
      }
    },
    "/api/v1/gate-visits/export": {
      "get": {
        "tags": [
          "GateVisits"
        ],
        "parameters": [
          {
            "name": "startDate",
            "in": "query",
            "schema": {
              "type": "string",
              "format": "date-time"
            }
          },
          {
            "name": "endDate",
            "in": "query",
            "schema": {
              "type": "string",
              "format": "date-time"
            }
          },
          {
            "name": "gateId",
            "in": "query",
            "schema": {
              "type": "integer",
              "format": "int32"
            }
          },
          {
            "name": "unitId",
            "in": "query",
            "schema": {
              "type": "integer",
              "format": "int64"
            }
          },
          {
            "name": "search",
            "in": "query",
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "OK"
          }
        }
      }
    },
    "/api/v1/Profiles/search": {
      "get": {
        "tags": [
          "Profiles"
        ],
        "parameters": [
          {
            "name": "search",
            "in": "query",
            "schema": {
              "type": "string"
            }
          },
          {
            "name": "unitId",
            "in": "query",
            "schema": {
              "type": "integer",
              "format": "int64"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "text/plain": {
                "schema": {
                  "type": "array",
                  "items": {
                    "$ref": "#/components/schemas/ProfileSearchResult"
                  }
                }
              },
              "application/json": {
                "schema": {
                  "type": "array",
                  "items": {
                    "$ref": "#/components/schemas/ProfileSearchResult"
                  }
                }
              },
              "text/json": {
                "schema": {
                  "type": "array",
                  "items": {
                    "$ref": "#/components/schemas/ProfileSearchResult"
                  }
                }
              }
            }
          }
        }
      }
    },
    "/api/v1/Profiles/{profileId}/phone": {
      "get": {
        "tags": [
          "Profiles"
        ],
        "parameters": [
          {
            "name": "profileId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "integer",
              "format": "int64"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "OK"
          }
        }
      }
    },
    "/api/v1/reports/activity": {
      "get": {
        "tags": [
          "Reports"
        ],
        "parameters": [
          {
            "name": "period",
            "in": "query",
            "schema": {
              "type": "string",
              "default": "daily"
            }
          },
          {
            "name": "daysBack",
            "in": "query",
            "schema": {
              "type": "integer",
              "format": "int32",
              "default": 30
            }
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "text/plain": {
                "schema": {
                  "type": "array",
                  "items": {
                    "$ref": "#/components/schemas/ActivitySummary"
                  }
                }
              },
              "application/json": {
                "schema": {
                  "type": "array",
                  "items": {
                    "$ref": "#/components/schemas/ActivitySummary"
                  }
                }
              },
              "text/json": {
                "schema": {
                  "type": "array",
                  "items": {
                    "$ref": "#/components/schemas/ActivitySummary"
                  }
                }
              }
            }
          }
        }
      }
    },
    "/api/v1/reports/top-units": {
      "get": {
        "tags": [
          "Reports"
        ],
        "parameters": [
          {
            "name": "daysBack",
            "in": "query",
            "schema": {
              "type": "integer",
              "format": "int32",
              "default": 30
            }
          },
          {
            "name": "top",
            "in": "query",
            "schema": {
              "type": "integer",
              "format": "int32",
              "default": 10
            }
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "text/plain": {
                "schema": {
                  "type": "array",
                  "items": {
                    "$ref": "#/components/schemas/TopUnitResult"
                  }
                }
              },
              "application/json": {
                "schema": {
                  "type": "array",
                  "items": {
                    "$ref": "#/components/schemas/TopUnitResult"
                  }
                }
              },
              "text/json": {
                "schema": {
                  "type": "array",
                  "items": {
                    "$ref": "#/components/schemas/TopUnitResult"
                  }
                }
              }
            }
          }
        }
      }
    },
    "/api/v1/reports/by-hour": {
      "get": {
        "tags": [
          "Reports"
        ],
        "parameters": [
          {
            "name": "daysBack",
            "in": "query",
            "schema": {
              "type": "integer",
              "format": "int32",
              "default": 30
            }
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "text/plain": {
                "schema": {
                  "type": "array",
                  "items": {
                    "$ref": "#/components/schemas/ByHourResult"
                  }
                }
              },
              "application/json": {
                "schema": {
                  "type": "array",
                  "items": {
                    "$ref": "#/components/schemas/ByHourResult"
                  }
                }
              },
              "text/json": {
                "schema": {
                  "type": "array",
                  "items": {
                    "$ref": "#/components/schemas/ByHourResult"
                  }
                }
              }
            }
          }
        }
      }
    },
    "/api/v1/reports/response-times": {
      "get": {
        "tags": [
          "Reports"
        ],
        "parameters": [
          {
            "name": "daysBack",
            "in": "query",
            "schema": {
              "type": "integer",
              "format": "int32",
              "default": 30
            }
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "text/plain": {
                "schema": {
                  "$ref": "#/components/schemas/SmsResponseMetrics"
                }
              },
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/SmsResponseMetrics"
                }
              },
              "text/json": {
                "schema": {
                  "$ref": "#/components/schemas/SmsResponseMetrics"
                }
              }
            }
          }
        }
      }
    },
    "/api/v1/residents/template": {
      "get": {
        "tags": [
          "ResidentImport"
        ],
        "responses": {
          "200": {
            "description": "OK"
          }
        }
      }
    },
    "/api/v1/residents/import": {
      "post": {
        "tags": [
          "ResidentImport"
        ],
        "requestBody": {
          "content": {
            "multipart/form-data": {
              "schema": {
                "type": "object",
                "properties": {
                  "file": {
                    "type": "string",
                    "format": "binary"
                  }
                }
              },
              "encoding": {
                "file": {
                  "style": "form"
                }
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "text/plain": {
                "schema": {
                  "$ref": "#/components/schemas/ImportPreviewResponse"
                }
              },
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ImportPreviewResponse"
                }
              },
              "text/json": {
                "schema": {
                  "$ref": "#/components/schemas/ImportPreviewResponse"
                }
              }
            }
          }
        }
      }
    },
    "/api/v1/residents/import/confirm": {
      "post": {
        "tags": [
          "ResidentImport"
        ],
        "requestBody": {
          "content": {
            "multipart/form-data": {
              "schema": {
                "type": "object",
                "properties": {
                  "file": {
                    "type": "string",
                    "format": "binary"
                  }
                }
              },
              "encoding": {
                "file": {
                  "style": "form"
                }
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "text/plain": {
                "schema": {
                  "$ref": "#/components/schemas/ImportResultResponse"
                }
              },
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ImportResultResponse"
                }
              },
              "text/json": {
                "schema": {
                  "$ref": "#/components/schemas/ImportResultResponse"
                }
              }
            }
          }
        }
      }
    },
    "/api/v1/residents/export": {
      "get": {
        "tags": [
          "ResidentImport"
        ],
        "responses": {
          "200": {
            "description": "OK"
          }
        }
      }
    },
    "/api/v1/sms/webhook": {
      "post": {
        "tags": [
          "SmsWebhook"
        ],
        "requestBody": {
          "content": {
            "application/x-www-form-urlencoded": {
              "schema": {
                "type": "object",
                "properties": {
                  "From": {
                    "type": "string"
                  },
                  "To": {
                    "type": "string"
                  },
                  "Body": {
                    "type": "string"
                  },
                  "MessageSid": {
                    "type": "string"
                  },
                  "AccountSid": {
                    "type": "string"
                  },
                  "NumMedia": {
                    "type": "string"
                  }
                }
              },
              "encoding": {
                "From": {
                  "style": "form"
                },
                "To": {
                  "style": "form"
                },
                "Body": {
                  "style": "form"
                },
                "MessageSid": {
                  "style": "form"
                },
                "AccountSid": {
                  "style": "form"
                },
                "NumMedia": {
                  "style": "form"
                }
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "OK"
          }
        }
      }
    },
    "/api/v1/sms/status": {
      "post": {
        "tags": [
          "SmsWebhook"
        ],
        "requestBody": {
          "content": {
            "application/x-www-form-urlencoded": {
              "schema": {
                "type": "object",
                "properties": {
                  "MessageSid": {
                    "type": "string"
                  },
                  "MessageStatus": {
                    "type": "string"
                  },
                  "To": {
                    "type": "string"
                  },
                  "From": {
                    "type": "string"
                  }
                }
              },
              "encoding": {
                "MessageSid": {
                  "style": "form"
                },
                "MessageStatus": {
                  "style": "form"
                },
                "To": {
                  "style": "form"
                },
                "From": {
                  "style": "form"
                }
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "OK"
          }
        }
      }
    },
    "/api/v1/webhooks/twilio/tollfree": {
      "post": {
        "tags": [
          "TollFreeWebhook"
        ],
        "requestBody": {
          "content": {
            "application/x-www-form-urlencoded": {
              "schema": {
                "type": "object",
                "properties": {
                  "From": {
                    "type": "string"
                  },
                  "To": {
                    "type": "string"
                  },
                  "Body": {
                    "type": "string"
                  },
                  "MessageSid": {
                    "type": "string"
                  },
                  "AccountSid": {
                    "type": "string"
                  },
                  "NumMedia": {
                    "type": "string"
                  }
                }
              },
              "encoding": {
                "From": {
                  "style": "form"
                },
                "To": {
                  "style": "form"
                },
                "Body": {
                  "style": "form"
                },
                "MessageSid": {
                  "style": "form"
                },
                "AccountSid": {
                  "style": "form"
                },
                "NumMedia": {
                  "style": "form"
                }
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "OK"
          }
        }
      }
    },
    "/api/v1/trial/signup": {
      "post": {
        "tags": [
          "Trial"
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/TrialSignupRequest"
              }
            },
            "text/json": {
              "schema": {
                "$ref": "#/components/schemas/TrialSignupRequest"
              }
            },
            "application/*+json": {
              "schema": {
                "$ref": "#/components/schemas/TrialSignupRequest"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "text/plain": {
                "schema": {
                  "$ref": "#/components/schemas/TrialSignupResponse"
                }
              },
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/TrialSignupResponse"
                }
              },
              "text/json": {
                "schema": {
                  "$ref": "#/components/schemas/TrialSignupResponse"
                }
              }
            }
          }
        }
      }
    },
    "/api/v1/trial/status": {
      "get": {
        "tags": [
          "Trial"
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "text/plain": {
                "schema": {
                  "$ref": "#/components/schemas/TrialStatusResponse"
                }
              },
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/TrialStatusResponse"
                }
              },
              "text/json": {
                "schema": {
                  "$ref": "#/components/schemas/TrialStatusResponse"
                }
              }
            }
          }
        }
      }
    },
    "/api/v1/admin/twilio/number": {
      "get": {
        "tags": [
          "TwilioAdmin"
        ],
        "responses": {
          "200": {
            "description": "OK"
          }
        }
      }
    },
    "/api/v1/admin/twilio/provision": {
      "post": {
        "tags": [
          "TwilioAdmin"
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/ProvisionRequest"
              }
            },
            "text/json": {
              "schema": {
                "$ref": "#/components/schemas/ProvisionRequest"
              }
            },
            "application/*+json": {
              "schema": {
                "$ref": "#/components/schemas/ProvisionRequest"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "OK"
          }
        }
      }
    },
    "/api/v1/admin/twilio/number/{twilioNumberId}": {
      "delete": {
        "tags": [
          "TwilioAdmin"
        ],
        "parameters": [
          {
            "name": "twilioNumberId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "integer",
              "format": "int32"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "OK"
          }
        }
      }
    },
    "/api/v1/Units/search": {
      "get": {
        "tags": [
          "Units"
        ],
        "parameters": [
          {
            "name": "search",
            "in": "query",
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "text/plain": {
                "schema": {
                  "type": "array",
                  "items": {
                    "$ref": "#/components/schemas/UnitSearchResult"
                  }
                }
              },
              "application/json": {
                "schema": {
                  "type": "array",
                  "items": {
                    "$ref": "#/components/schemas/UnitSearchResult"
                  }
                }
              },
              "text/json": {
                "schema": {
                  "type": "array",
                  "items": {
                    "$ref": "#/components/schemas/UnitSearchResult"
                  }
                }
              }
            }
          }
        }
      }
    },
    "/api/v1/Visits": {
      "get": {
        "tags": [
          "Visits"
        ],
        "parameters": [
          {
            "name": "unitId",
            "in": "query",
            "schema": {
              "type": "integer",
              "format": "int64"
            }
          },
          {
            "name": "type",
            "in": "query",
            "schema": {
              "type": "string"
            }
          },
          {
            "name": "status",
            "in": "query",
            "schema": {
              "type": "string"
            }
          },
          {
            "name": "search",
            "in": "query",
            "schema": {
              "type": "string"
            }
          },
          {
            "name": "page",
            "in": "query",
            "schema": {
              "type": "integer",
              "format": "int32",
              "default": 1
            }
          },
          {
            "name": "pageSize",
            "in": "query",
            "schema": {
              "type": "integer",
              "format": "int32",
              "default": 20
            }
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "text/plain": {
                "schema": {
                  "$ref": "#/components/schemas/VisitResponsePaginatedResponse"
                }
              },
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/VisitResponsePaginatedResponse"
                }
              },
              "text/json": {
                "schema": {
                  "$ref": "#/components/schemas/VisitResponsePaginatedResponse"
                }
              }
            }
          }
        }
      },
      "post": {
        "tags": [
          "Visits"
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/CreateVisitRequest"
              }
            },
            "text/json": {
              "schema": {
                "$ref": "#/components/schemas/CreateVisitRequest"
              }
            },
            "application/*+json": {
              "schema": {
                "$ref": "#/components/schemas/CreateVisitRequest"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "text/plain": {
                "schema": {
                  "$ref": "#/components/schemas/VisitResponse"
                }
              },
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/VisitResponse"
                }
              },
              "text/json": {
                "schema": {
                  "$ref": "#/components/schemas/VisitResponse"
                }
              }
            }
          }
        }
      }
    },
    "/api/v1/Visits/{visitId}": {
      "get": {
        "tags": [
          "Visits"
        ],
        "parameters": [
          {
            "name": "visitId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "integer",
              "format": "int64"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "text/plain": {
                "schema": {
                  "$ref": "#/components/schemas/VisitResponse"
                }
              },
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/VisitResponse"
                }
              },
              "text/json": {
                "schema": {
                  "$ref": "#/components/schemas/VisitResponse"
                }
              }
            }
          }
        }
      },
      "delete": {
        "tags": [
          "Visits"
        ],
        "parameters": [
          {
            "name": "visitId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "integer",
              "format": "int64"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "OK"
          }
        }
      }
    },
    "/api/v1/Visits/{visitId}/approve": {
      "post": {
        "tags": [
          "Visits"
        ],
        "parameters": [
          {
            "name": "visitId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "integer",
              "format": "int64"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "OK"
          }
        }
      }
    },
    "/api/v1/Visits/{visitId}/deny": {
      "post": {
        "tags": [
          "Visits"
        ],
        "parameters": [
          {
            "name": "visitId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "integer",
              "format": "int64"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "OK"
          }
        }
      }
    },
    "/api/v1/Visits/{visitId}/sms-request": {
      "post": {
        "tags": [
          "Visits"
        ],
        "parameters": [
          {
            "name": "visitId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "integer",
              "format": "int64"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/SmsApprovalRequest"
              }
            },
            "text/json": {
              "schema": {
                "$ref": "#/components/schemas/SmsApprovalRequest"
              }
            },
            "application/*+json": {
              "schema": {
                "$ref": "#/components/schemas/SmsApprovalRequest"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "OK"
          }
        }
      }
    },
    "/api/v1/webhooks/stripe": {
      "post": {
        "tags": [
          "Webhook"
        ],
        "responses": {
          "200": {
            "description": "OK"
          }
        }
      }
    }
  },
  "components": {
    "schemas": {
      "ActivitySummary": {
        "type": "object",
        "properties": {
          "period": {
            "type": "string",
            "nullable": true
          },
          "count": {
            "type": "integer",
            "format": "int32"
          }
        },
        "additionalProperties": false
      },
      "AdminResidentResponse": {
        "type": "object",
        "properties": {
          "profileID": {
            "type": "integer",
            "format": "int64"
          },
          "firstName": {
            "type": "string",
            "nullable": true
          },
          "lastName": {
            "type": "string",
            "nullable": true
          },
          "phoneNumber": {
            "type": "string",
            "nullable": true
          },
          "email": {
            "type": "string",
            "nullable": true
          },
          "active": {
            "type": "boolean"
          }
        },
        "additionalProperties": false
      },
      "AdminUnitResponse": {
        "type": "object",
        "properties": {
          "unitID": {
            "type": "integer",
            "format": "int64"
          },
          "unitNumber": {
            "type": "string",
            "nullable": true
          },
          "active": {
            "type": "boolean"
          }
        },
        "additionalProperties": false
      },
      "AppConfigResponse": {
        "type": "object",
        "properties": {
          "appConfigID": {
            "type": "integer",
            "format": "int32"
          },
          "name": {
            "type": "string",
            "nullable": true
          },
          "value": {
            "type": "string",
            "nullable": true
          }
        },
        "additionalProperties": false
      },
      "AssignUnitRequest": {
        "type": "object",
        "properties": {
          "unitID": {
            "type": "integer",
            "format": "int64"
          },
          "startDate": {
            "type": "string",
            "format": "date-time",
            "nullable": true
          },
          "endDate": {
            "type": "string",
            "format": "date-time",
            "nullable": true
          }
        },
        "additionalProperties": false
      },
      "ByHourResult": {
        "type": "object",
        "properties": {
          "hour": {
            "type": "integer",
            "format": "int32"
          },
          "count": {
            "type": "integer",
            "format": "int32"
          }
        },
        "additionalProperties": false
      },
      "CheckInItemRequest": {
        "type": "object",
        "properties": {
          "gateVisitItemTypeID": {
            "type": "integer",
            "format": "int32"
          },
          "notes": {
            "type": "string",
            "nullable": true
          }
        },
        "additionalProperties": false
      },
      "CheckInRequest": {
        "type": "object",
        "properties": {
          "visitID": {
            "type": "integer",
            "format": "int64"
          },
          "gateId": {
            "type": "integer",
            "format": "int32",
            "nullable": true
          },
          "vehicleMake": {
            "type": "string",
            "nullable": true
          },
          "vehicleModel": {
            "type": "string",
            "nullable": true
          },
          "vehicleColor": {
            "type": "string",
            "nullable": true
          },
          "vehiclePlateNumber": {
            "type": "string",
            "nullable": true
          },
          "gateRemarks": {
            "type": "string",
            "nullable": true
          },
          "items": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/CheckInItemRequest"
            },
            "nullable": true
          }
        },
        "additionalProperties": false
      },
      "CheckoutRequest": {
        "type": "object",
        "properties": {
          "planTier": {
            "type": "string",
            "nullable": true
          },
          "successUrl": {
            "type": "string",
            "nullable": true
          },
          "cancelUrl": {
            "type": "string",
            "nullable": true
          }
        },
        "additionalProperties": false
      },
      "CheckoutResponse": {
        "type": "object",
        "properties": {
          "checkoutUrl": {
            "type": "string",
            "nullable": true
          }
        },
        "additionalProperties": false
      },
      "CreateGateRequest": {
        "type": "object",
        "properties": {
          "gateName": {
            "type": "string",
            "nullable": true
          },
          "gateCode": {
            "type": "string",
            "nullable": true
          },
          "gateType": {
            "type": "string",
            "nullable": true
          }
        },
        "additionalProperties": false
      },
      "CreateResidentRequest": {
        "type": "object",
        "properties": {
          "firstName": {
            "type": "string",
            "nullable": true
          },
          "lastName": {
            "type": "string",
            "nullable": true
          },
          "phoneNumber": {
            "type": "string",
            "nullable": true
          },
          "email": {
            "type": "string",
            "nullable": true
          },
          "unitID": {
            "type": "integer",
            "format": "int64",
            "nullable": true
          }
        },
        "additionalProperties": false
      },
      "CreateUnitRequest": {
        "type": "object",
        "properties": {
          "unitNumber": {
            "type": "string",
            "nullable": true
          }
        },
        "additionalProperties": false
      },
      "CreateVisitRequest": {
        "type": "object",
        "properties": {
          "unitID": {
            "type": "integer",
            "format": "int64"
          },
          "profileID": {
            "type": "integer",
            "format": "int64"
          },
          "description": {
            "type": "string",
            "nullable": true
          },
          "visitTypeID": {
            "type": "integer",
            "format": "int32",
            "nullable": true
          },
          "startDate": {
            "type": "string",
            "format": "date-time",
            "nullable": true
          },
          "endDate": {
            "type": "string",
            "format": "date-time",
            "nullable": true
          },
          "vehicleMake": {
            "type": "string",
            "nullable": true
          },
          "vehicleModel": {
            "type": "string",
            "nullable": true
          },
          "vehicleColor": {
            "type": "string",
            "nullable": true
          },
          "vehiclePlateNumber": {
            "type": "string",
            "nullable": true
          },
          "gateRemarks": {
            "type": "string",
            "nullable": true
          },
          "checkInNow": {
            "type": "boolean"
          }
        },
        "additionalProperties": false
      },
      "DailyCountResponse": {
        "type": "object",
        "properties": {
          "count": {
            "type": "integer",
            "format": "int32"
          },
          "date": {
            "type": "string",
            "format": "date-time"
          }
        },
        "additionalProperties": false
      },
      "DemoEventRequest": {
        "type": "object",
        "properties": {
          "event": {
            "type": "string",
            "nullable": true
          },
          "data": {
            "type": "string",
            "nullable": true
          }
        },
        "additionalProperties": false
      },
      "DemoResetResult": {
        "type": "object",
        "properties": {
          "visitsDeleted": {
            "type": "integer",
            "format": "int32"
          },
          "gateVisitsDeleted": {
            "type": "integer",
            "format": "int32"
          },
          "smsDeleted": {
            "type": "integer",
            "format": "int32"
          },
          "gateItemsDeleted": {
            "type": "integer",
            "format": "int32"
          }
        },
        "additionalProperties": false
      },
      "DemoSmsSimulateRequest": {
        "type": "object",
        "properties": {
          "phone": {
            "type": "string",
            "nullable": true
          },
          "visitorName": {
            "type": "string",
            "nullable": true
          }
        },
        "additionalProperties": false
      },
      "FeatureFlagsResponse": {
        "type": "object",
        "properties": {
          "useReactUI": {
            "type": "boolean"
          },
          "reactAppUrl": {
            "type": "string",
            "nullable": true
          }
        },
        "additionalProperties": false
      },
      "GateItemResponse": {
        "type": "object",
        "properties": {
          "gateVisitItemID": {
            "type": "integer",
            "format": "int64"
          },
          "itemTypeName": {
            "type": "string",
            "nullable": true
          },
          "visitorName": {
            "type": "string",
            "nullable": true
          },
          "unitNumber": {
            "type": "string",
            "nullable": true
          },
          "residentName": {
            "type": "string",
            "nullable": true
          },
          "dateIssued": {
            "type": "string",
            "format": "date-time",
            "nullable": true
          },
          "dateReturned": {
            "type": "string",
            "format": "date-time",
            "nullable": true
          },
          "notes": {
            "type": "string",
            "nullable": true
          }
        },
        "additionalProperties": false
      },
      "GateResponse": {
        "type": "object",
        "properties": {
          "gateId": {
            "type": "integer",
            "format": "int32"
          },
          "gateName": {
            "type": "string",
            "nullable": true
          },
          "gateCode": {
            "type": "string",
            "nullable": true
          },
          "gateType": {
            "type": "string",
            "nullable": true
          },
          "isActive": {
            "type": "boolean"
          }
        },
        "additionalProperties": false
      },
      "GateVisitItemTypeResponse": {
        "type": "object",
        "properties": {
          "gateVisitItemTypeID": {
            "type": "integer",
            "format": "int32"
          },
          "code": {
            "type": "string",
            "nullable": true
          },
          "name": {
            "type": "string",
            "nullable": true
          },
          "description": {
            "type": "string",
            "nullable": true
          }
        },
        "additionalProperties": false
      },
      "GateVisitResponse": {
        "type": "object",
        "properties": {
          "gateVisitID": {
            "type": "integer",
            "format": "int64"
          },
          "visitID": {
            "type": "integer",
            "format": "int64",
            "nullable": true
          },
          "visitorName": {
            "type": "string",
            "nullable": true
          },
          "residentName": {
            "type": "string",
            "nullable": true
          },
          "unitNumber": {
            "type": "string",
            "nullable": true
          },
          "phoneNumber": {
            "type": "string",
            "nullable": true
          },
          "visitTime": {
            "type": "string",
            "format": "date-time",
            "nullable": true
          },
          "vehicleMake": {
            "type": "string",
            "nullable": true
          },
          "vehicleModel": {
            "type": "string",
            "nullable": true
          },
          "vehicleColor": {
            "type": "string",
            "nullable": true
          },
          "vehiclePlateNumber": {
            "type": "string",
            "nullable": true
          },
          "gateRemarks": {
            "type": "string",
            "nullable": true
          },
          "gateName": {
            "type": "string",
            "nullable": true
          }
        },
        "additionalProperties": false
      },
      "ImportErrorRow": {
        "type": "object",
        "properties": {
          "rowNumber": {
            "type": "integer",
            "format": "int32"
          },
          "name": {
            "type": "string",
            "nullable": true
          },
          "errors": {
            "type": "array",
            "items": {
              "type": "string"
            },
            "nullable": true
          }
        },
        "additionalProperties": false
      },
      "ImportPreviewResponse": {
        "type": "object",
        "properties": {
          "rows": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/ImportPreviewRow"
            },
            "nullable": true
          },
          "validCount": {
            "type": "integer",
            "format": "int32"
          },
          "errorCount": {
            "type": "integer",
            "format": "int32"
          }
        },
        "additionalProperties": false
      },
      "ImportPreviewRow": {
        "type": "object",
        "properties": {
          "rowNumber": {
            "type": "integer",
            "format": "int32"
          },
          "firstName": {
            "type": "string",
            "nullable": true
          },
          "lastName": {
            "type": "string",
            "nullable": true
          },
          "email": {
            "type": "string",
            "nullable": true
          },
          "phone": {
            "type": "string",
            "nullable": true
          },
          "unitNumber": {
            "type": "string",
            "nullable": true
          },
          "role": {
            "type": "string",
            "nullable": true
          },
          "unitID": {
            "type": "integer",
            "format": "int64",
            "nullable": true
          },
          "isValid": {
            "type": "boolean"
          },
          "errors": {
            "type": "array",
            "items": {
              "type": "string"
            },
            "nullable": true
          }
        },
        "additionalProperties": false
      },
      "ImportResultResponse": {
        "type": "object",
        "properties": {
          "imported": {
            "type": "integer",
            "format": "int32"
          },
          "skipped": {
            "type": "integer",
            "format": "int32"
          },
          "errors": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/ImportErrorRow"
            },
            "nullable": true
          }
        },
        "additionalProperties": false
      },
      "LoginRequest": {
        "type": "object",
        "properties": {
          "username": {
            "type": "string",
            "nullable": true
          },
          "password": {
            "type": "string",
            "nullable": true
          }
        },
        "additionalProperties": false
      },
      "LoginResponse": {
        "type": "object",
        "properties": {
          "accessToken": {
            "type": "string",
            "nullable": true
          },
          "expiresAt": {
            "type": "string",
            "nullable": true
          },
          "role": {
            "type": "string",
            "nullable": true
          },
          "clientId": {
            "type": "integer",
            "format": "int64"
          },
          "communityName": {
            "type": "string",
            "nullable": true
          },
          "isDemoTenant": {
            "type": "boolean"
          },
          "isTrialTenant": {
            "type": "boolean"
          }
        },
        "additionalProperties": false
      },
      "OtpChallengeRequest": {
        "type": "object",
        "properties": {
          "channel": {
            "type": "string",
            "nullable": true
          },
          "recipient": {
            "type": "string",
            "nullable": true
          },
          "purpose": {
            "type": "string",
            "nullable": true
          }
        },
        "additionalProperties": false
      },
      "OtpResendRequest": {
        "type": "object",
        "properties": {
          "challengeId": {
            "type": "string",
            "nullable": true
          }
        },
        "additionalProperties": false
      },
      "OtpVerifyRequest": {
        "type": "object",
        "properties": {
          "challengeId": {
            "type": "string",
            "nullable": true
          },
          "code": {
            "type": "string",
            "nullable": true
          }
        },
        "additionalProperties": false
      },
      "PlanResponse": {
        "type": "object",
        "properties": {
          "tier": {
            "type": "string",
            "nullable": true
          },
          "name": {
            "type": "string",
            "nullable": true
          },
          "monthlyPrice": {
            "type": "integer",
            "format": "int32"
          },
          "setupFee": {
            "type": "integer",
            "format": "int32"
          },
          "maxUnits": {
            "type": "integer",
            "format": "int32"
          },
          "maxSmsPerDay": {
            "type": "integer",
            "format": "int32"
          },
          "maxGuards": {
            "type": "integer",
            "format": "int32"
          }
        },
        "additionalProperties": false
      },
      "ProfileSearchResult": {
        "type": "object",
        "properties": {
          "profileID": {
            "type": "integer",
            "format": "int64"
          },
          "name": {
            "type": "string",
            "nullable": true
          },
          "phoneNumber": {
            "type": "string",
            "nullable": true
          },
          "unitID": {
            "type": "integer",
            "format": "int64",
            "nullable": true
          },
          "unitNumber": {
            "type": "string",
            "nullable": true
          }
        },
        "additionalProperties": false
      },
      "ProvisionRequest": {
        "type": "object",
        "properties": {
          "areaCode": {
            "type": "string",
            "nullable": true
          }
        },
        "additionalProperties": false
      },
      "PublishableKeyResponse": {
        "type": "object",
        "properties": {
          "publishableKey": {
            "type": "string",
            "nullable": true
          }
        },
        "additionalProperties": false
      },
      "ResidentUnitResponse": {
        "type": "object",
        "properties": {
          "unit2ProfileID": {
            "type": "integer",
            "format": "int64"
          },
          "unitID": {
            "type": "integer",
            "format": "int64"
          },
          "unitNumber": {
            "type": "string",
            "nullable": true
          },
          "startDate": {
            "type": "string",
            "format": "date-time",
            "nullable": true
          },
          "endDate": {
            "type": "string",
            "format": "date-time",
            "nullable": true
          }
        },
        "additionalProperties": false
      },
      "SmsApprovalRequest": {
        "type": "object",
        "properties": {
          "visitorName": {
            "type": "string",
            "nullable": true
          },
          "gateName": {
            "type": "string",
            "nullable": true
          }
        },
        "additionalProperties": false
      },
      "SmsResponseMetrics": {
        "type": "object",
        "properties": {
          "totalSmsRequests": {
            "type": "integer",
            "format": "int32"
          },
          "approved": {
            "type": "integer",
            "format": "int32"
          },
          "denied": {
            "type": "integer",
            "format": "int32"
          },
          "noResponse": {
            "type": "integer",
            "format": "int32"
          },
          "pending": {
            "type": "integer",
            "format": "int32"
          },
          "avgResponseTimeSeconds": {
            "type": "number",
            "format": "double",
            "nullable": true
          },
          "maxResponseTimeSeconds": {
            "type": "number",
            "format": "double",
            "nullable": true
          },
          "medianResponseTimeSeconds": {
            "type": "number",
            "format": "double",
            "nullable": true
          }
        },
        "additionalProperties": false
      },
      "SubscriptionStatusResponse": {
        "type": "object",
        "properties": {
          "isTrialTenant": {
            "type": "boolean"
          },
          "isDemoTenant": {
            "type": "boolean"
          },
          "trialExpiresAt": {
            "type": "string",
            "nullable": true
          },
          "hasSubscription": {
            "type": "boolean"
          },
          "planTier": {
            "type": "string",
            "nullable": true
          },
          "planName": {
            "type": "string",
            "nullable": true
          },
          "maxUnits": {
            "type": "integer",
            "format": "int32",
            "nullable": true
          },
          "maxSmsPerDay": {
            "type": "integer",
            "format": "int32",
            "nullable": true
          },
          "maxGuards": {
            "type": "integer",
            "format": "int32",
            "nullable": true
          }
        },
        "additionalProperties": false
      },
      "TopUnitResult": {
        "type": "object",
        "properties": {
          "unitID": {
            "type": "integer",
            "format": "int64"
          },
          "unitNumber": {
            "type": "string",
            "nullable": true
          },
          "visitCount": {
            "type": "integer",
            "format": "int32"
          }
        },
        "additionalProperties": false
      },
      "TrialSignupRequest": {
        "type": "object",
        "properties": {
          "fullName": {
            "type": "string",
            "nullable": true
          },
          "email": {
            "type": "string",
            "nullable": true
          },
          "password": {
            "type": "string",
            "nullable": true
          },
          "communityName": {
            "type": "string",
            "nullable": true
          },
          "zipCode": {
            "type": "string",
            "nullable": true
          },
          "phone": {
            "type": "string",
            "nullable": true
          }
        },
        "additionalProperties": false
      },
      "TrialSignupResponse": {
        "type": "object",
        "properties": {
          "accessToken": {
            "type": "string",
            "nullable": true
          },
          "expiresAt": {
            "type": "string",
            "nullable": true
          },
          "role": {
            "type": "string",
            "nullable": true
          },
          "clientId": {
            "type": "integer",
            "format": "int64"
          },
          "communityName": {
            "type": "string",
            "nullable": true
          },
          "trialExpiresAt": {
            "type": "string",
            "nullable": true
          }
        },
        "additionalProperties": false
      },
      "TrialStatusResponse": {
        "type": "object",
        "properties": {
          "isTrialTenant": {
            "type": "boolean"
          },
          "trialExpiresAt": {
            "type": "string",
            "nullable": true
          },
          "isExpired": {
            "type": "boolean"
          }
        },
        "additionalProperties": false
      },
      "UnitSearchResult": {
        "type": "object",
        "properties": {
          "unitID": {
            "type": "integer",
            "format": "int64"
          },
          "unitNumber": {
            "type": "string",
            "nullable": true
          }
        },
        "additionalProperties": false
      },
      "UpdateGateRequest": {
        "type": "object",
        "properties": {
          "gateName": {
            "type": "string",
            "nullable": true
          },
          "gateCode": {
            "type": "string",
            "nullable": true
          },
          "gateType": {
            "type": "string",
            "nullable": true
          },
          "isActive": {
            "type": "boolean",
            "nullable": true
          }
        },
        "additionalProperties": false
      },
      "UpdateResidentRequest": {
        "type": "object",
        "properties": {
          "firstName": {
            "type": "string",
            "nullable": true
          },
          "lastName": {
            "type": "string",
            "nullable": true
          },
          "phoneNumber": {
            "type": "string",
            "nullable": true
          },
          "email": {
            "type": "string",
            "nullable": true
          },
          "active": {
            "type": "boolean",
            "nullable": true
          }
        },
        "additionalProperties": false
      },
      "UpdateSettingRequest": {
        "type": "object",
        "properties": {
          "value": {
            "type": "string",
            "nullable": true
          }
        },
        "additionalProperties": false
      },
      "UpdateUnitRequest": {
        "type": "object",
        "properties": {
          "unitNumber": {
            "type": "string",
            "nullable": true
          },
          "active": {
            "type": "boolean",
            "nullable": true
          }
        },
        "additionalProperties": false
      },
      "VerifyReceiptRequest": {
        "type": "object",
        "properties": {
          "receipt": {
            "type": "string",
            "nullable": true
          }
        },
        "additionalProperties": false
      },
      "VisitResponse": {
        "type": "object",
        "properties": {
          "visitID": {
            "type": "integer",
            "format": "int64"
          },
          "unitID": {
            "type": "integer",
            "format": "int64",
            "nullable": true
          },
          "unitNumber": {
            "type": "string",
            "nullable": true
          },
          "profileID": {
            "type": "integer",
            "format": "int64",
            "nullable": true
          },
          "residentName": {
            "type": "string",
            "nullable": true
          },
          "description": {
            "type": "string",
            "nullable": true
          },
          "visitStatus": {
            "type": "string",
            "nullable": true
          },
          "startDate": {
            "type": "string",
            "format": "date-time",
            "nullable": true
          },
          "endDate": {
            "type": "string",
            "format": "date-time",
            "nullable": true
          },
          "vehiclePlateNumber": {
            "type": "string",
            "nullable": true
          },
          "gateRemarks": {
            "type": "string",
            "nullable": true
          },
          "active": {
            "type": "boolean"
          },
          "gateVisitCount": {
            "type": "integer",
            "format": "int32"
          },
          "created": {
            "type": "string",
            "format": "date-time",
            "nullable": true
          }
        },
        "additionalProperties": false
      },
      "VisitResponsePaginatedResponse": {
        "type": "object",
        "properties": {
          "items": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/VisitResponse"
            },
            "nullable": true
          },
          "totalCount": {
            "type": "integer",
            "format": "int32"
          },
          "page": {
            "type": "integer",
            "format": "int32"
          },
          "pageSize": {
            "type": "integer",
            "format": "int32"
          },
          "totalPages": {
            "type": "integer",
            "format": "int32"
          }
        },
        "additionalProperties": false
      }
    }
  },
  "tags": [
    {
      "name": "Admin"
    },
    {
      "name": "Auth"
    },
    {
      "name": "Billing"
    },
    {
      "name": "DemoEvents"
    },
    {
      "name": "DemoSms"
    },
    {
      "name": "GateItems"
    },
    {
      "name": "Gates"
    },
    {
      "name": "GateSync.API"
    },
    {
      "name": "GateVisits"
    },
    {
      "name": "Profiles"
    },
    {
      "name": "Reports"
    },
    {
      "name": "ResidentImport"
    },
    {
      "name": "SmsWebhook"
    },
    {
      "name": "TollFreeWebhook"
    },
    {
      "name": "Trial"
    },
    {
      "name": "TwilioAdmin"
    },
    {
      "name": "Units"
    },
    {
      "name": "Visits"
    },
    {
      "name": "Webhook"
    }
  ]
}