{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://artifacts.apis.io/housingfax-com/json-schema/housingfax-com-search-address-output-schema.json",
  "title": "SearchAddressOutput",
  "x-generated": "2026-11-11",
  "x-method": "derived",
  "x-generator": "derive-json-schema.py",
  "x-source": "openapi/_original/housingfax-com-api-openapi.json#/components/schemas/SearchAddressOutput",
  "anyOf": [
    {
      "type": "object",
      "properties": {
        "contract": {
          "type": "string",
          "const": "agent-api-1.3.0"
        },
        "language": {
          "type": "string",
          "enum": [
            "es",
            "en",
            "de",
            "nl",
            "fr"
          ]
        },
        "kind": {
          "type": "string",
          "const": "municipality"
        },
        "options": {
          "maxItems": 20,
          "type": "array",
          "items": {
            "type": "object",
            "properties": {
              "provinceCode": {
                "type": "string",
                "pattern": "^\\d{2}$"
              },
              "municipalityDgcCode": {
                "type": "string",
                "pattern": "^\\d{1,3}$"
              },
              "municipalityIneCode": {
                "type": "string",
                "pattern": "^\\d{3}$"
              },
              "officialLabel": {
                "type": "string",
                "minLength": 1,
                "maxLength": 120
              }
            },
            "required": [
              "provinceCode",
              "municipalityDgcCode",
              "municipalityIneCode",
              "officialLabel"
            ],
            "additionalProperties": false
          }
        }
      },
      "required": [
        "contract",
        "language",
        "kind",
        "options"
      ],
      "additionalProperties": false
    },
    {
      "type": "object",
      "properties": {
        "contract": {
          "type": "string",
          "const": "agent-api-1.3.0"
        },
        "language": {
          "type": "string",
          "enum": [
            "es",
            "en",
            "de",
            "nl",
            "fr"
          ]
        },
        "kind": {
          "type": "string",
          "const": "street"
        },
        "numberHint": {
          "type": "string",
          "minLength": 1,
          "maxLength": 16
        },
        "options": {
          "maxItems": 20,
          "type": "array",
          "items": {
            "type": "object",
            "properties": {
              "provinceCode": {
                "type": "string",
                "pattern": "^\\d{2}$"
              },
              "municipalityDgcCode": {
                "type": "string",
                "pattern": "^\\d{1,3}$"
              },
              "municipalityIneCode": {
                "type": "string",
                "pattern": "^\\d{3}$"
              },
              "officialLabel": {
                "type": "string",
                "minLength": 1,
                "maxLength": 120
              },
              "streetTypeCode": {
                "type": "string",
                "pattern": "^[A-Z0-9]{1,4}$"
              },
              "streetCode": {
                "type": "string",
                "pattern": "^[A-Z0-9]{1,15}$"
              },
              "streetTypeLabel": {
                "type": "string",
                "minLength": 1,
                "maxLength": 120
              },
              "localityId": {
                "type": "string",
                "pattern": "^[0-9]{14}$"
              },
              "localityLabel": {
                "type": "string",
                "minLength": 1,
                "maxLength": 120
              }
            },
            "required": [
              "provinceCode",
              "municipalityDgcCode",
              "municipalityIneCode",
              "officialLabel",
              "streetTypeCode",
              "streetCode"
            ],
            "additionalProperties": false
          }
        }
      },
      "required": [
        "contract",
        "language",
        "kind",
        "options"
      ],
      "additionalProperties": false
    }
  ]
}