{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://caribescout.com/standard/rees/v0.2/schema.json",
  "title": "REES feed",
  "description": "Real Estate Exchange Standard v0.2: one publisher, its listings and developments.",
  "type": "object",
  "required": [
    "rees",
    "publisher",
    "generated_at",
    "listings"
  ],
  "additionalProperties": false,
  "properties": {
    "rees": {
      "const": "0.2",
      "description": "Spec version this feed follows: \"0.2\"."
    },
    "publisher": {
      "$ref": "#/$defs/Publisher",
      "description": "Who sends this feed."
    },
    "generated_at": {
      "type": "string",
      "format": "date-time",
      "description": "When this feed was produced (ISO 8601, with timezone)."
    },
    "license": {
      "$ref": "#/$defs/License",
      "description": "Default licence for every listing in the feed; a listing may override it."
    },
    "listings": {
      "type": "array",
      "items": {
        "$ref": "#/$defs/Listing"
      },
      "description": "All current listings, or only changes when `since` is set."
    },
    "developments": {
      "type": "array",
      "items": {
        "$ref": "#/$defs/Development"
      },
      "description": "Developments (projects) whose units appear in `listings`."
    },
    "since": {
      "type": "string",
      "format": "date-time",
      "description": "Set when this is a delta feed: only records updated after this instant."
    },
    "next": {
      "type": "string",
      "format": "uri",
      "description": "URL of the next page, for large feeds."
    }
  },
  "$defs": {
    "LocalizedText": {
      "type": "object",
      "description": "Text by language, keyed by ISO 639-1 code: {\"en\": \"...\", \"es\": \"...\"}. At least one language.",
      "minProperties": 1,
      "additionalProperties": {
        "type": "string",
        "description": "The text in that language."
      },
      "propertyNames": {
        "pattern": "^[a-z]{2}(-[A-Z]{2})?$",
        "x-hint": "a language code such as en, es or pt-BR"
      }
    },
    "Money": {
      "type": "object",
      "description": "An amount, its currency and what it is a price OF. Never a bare number.",
      "required": [
        "currency",
        "basis"
      ],
      "additionalProperties": false,
      "properties": {
        "amount": {
          "type": "number",
          "minimum": 0,
          "description": "Required unless basis is on_request. For a range, the low end."
        },
        "max": {
          "type": "number",
          "minimum": 0,
          "description": "High end of a range (basis \"range\")."
        },
        "currency": {
          "type": "string",
          "pattern": "^[A-Z]{3}$",
          "x-hint": "a 3-letter ISO currency code such as USD or DOP, not a symbol",
          "description": "ISO 4217 code: USD, DOP, EUR, JMD… Never a symbol."
        },
        "basis": {
          "enum": [
            "total",
            "per_m2",
            "from",
            "range",
            "per_month",
            "per_week",
            "per_night",
            "per_year",
            "on_request"
          ],
          "description": "total = the whole property; per_m2 = rate × area; from = lowest unit in a development; range = amount…max."
        },
        "includes": {
          "type": "array",
          "items": {
            "enum": [
              "furniture",
              "hoa",
              "utilities",
              "vat",
              "transfer_tax",
              "cleaning",
              "parking"
            ],
            "description": "One inclusion."
          },
          "description": "What the amount includes, when it is not bare."
        },
        "provenance": {
          "$ref": "#/$defs/Provenance",
          "description": "Where this value came from."
        }
      }
    },
    "Measure": {
      "type": "object",
      "description": "An area with its unit.",
      "required": [
        "value",
        "unit"
      ],
      "additionalProperties": false,
      "properties": {
        "value": {
          "type": "number",
          "exclusiveMinimum": 0,
          "description": "The area, in `unit`."
        },
        "unit": {
          "enum": [
            "m2",
            "ft2",
            "ha",
            "acre"
          ],
          "description": "Always stated. No default unit exists."
        },
        "provenance": {
          "$ref": "#/$defs/Provenance",
          "description": "Where this value came from."
        }
      }
    },
    "Length": {
      "type": "object",
      "description": "A length with its unit (ceiling heights, frontages).",
      "required": [
        "value",
        "unit"
      ],
      "additionalProperties": false,
      "properties": {
        "value": {
          "type": "number",
          "exclusiveMinimum": 0,
          "description": "The length, in `unit`."
        },
        "unit": {
          "enum": [
            "m",
            "ft"
          ],
          "description": "Always stated."
        }
      }
    },
    "Geo": {
      "type": "object",
      "description": "A point on the map and how close it is to the property.",
      "required": [
        "lat",
        "lng",
        "precision"
      ],
      "additionalProperties": false,
      "properties": {
        "lat": {
          "type": "number",
          "minimum": -90,
          "maximum": 90,
          "description": "Latitude, WGS 84 decimal degrees."
        },
        "lng": {
          "type": "number",
          "minimum": -180,
          "maximum": 180,
          "description": "Longitude, WGS 84 decimal degrees (negative west of Greenwich)."
        },
        "precision": {
          "enum": [
            "exact",
            "street",
            "neighbourhood",
            "approximate"
          ],
          "description": "How close the point is to the property. Use \"approximate\" for a deliberately blurred pin."
        },
        "provenance": {
          "$ref": "#/$defs/Provenance",
          "description": "Where this value came from."
        }
      }
    },
    "Provenance": {
      "type": "object",
      "description": "Where a value came from. Optional everywhere; required on price and area for the Verified level.",
      "required": [
        "source"
      ],
      "additionalProperties": false,
      "properties": {
        "source": {
          "enum": [
            "owner",
            "agent",
            "developer",
            "survey",
            "registry",
            "appraisal",
            "certificate",
            "estimate"
          ],
          "description": "Who or what stated the value."
        },
        "date": {
          "type": "string",
          "format": "date",
          "description": "When it was stated or checked."
        },
        "confidence": {
          "enum": [
            "verified",
            "stated",
            "estimated"
          ],
          "description": "verified = checked against a document; stated = as told; estimated = derived."
        },
        "note": {
          "type": "string",
          "description": "Anything a reader needs to interpret the value."
        }
      }
    },
    "Contact": {
      "type": "object",
      "description": "A person or office to contact.",
      "additionalProperties": false,
      "properties": {
        "name": {
          "type": "string",
          "minLength": 1,
          "description": "Full name or office name."
        },
        "email": {
          "type": "string",
          "format": "email",
          "description": "Email address."
        },
        "phone": {
          "type": "string",
          "pattern": "^\\+[0-9 ()-]{7,20}$",
          "x-hint": "an international number starting with +, e.g. +1 809 555 0100",
          "description": "Phone with country code: +1 809 555 0100."
        },
        "whatsapp": {
          "type": "string",
          "pattern": "^\\+[0-9 ()-]{7,20}$",
          "x-hint": "an international number starting with +",
          "description": "WhatsApp number with country code."
        },
        "languages": {
          "type": "array",
          "items": {
            "type": "string",
            "pattern": "^[a-z]{2}$",
            "x-hint": "a 2-letter language code such as en",
            "description": "One language code."
          },
          "description": "Languages this contact speaks (ISO 639-1)."
        }
      }
    },
    "License": {
      "type": "object",
      "description": "What a receiver may do with the data. Set once on the feed; override per listing.",
      "required": [
        "use"
      ],
      "additionalProperties": false,
      "properties": {
        "use": {
          "enum": [
            "republish-with-credit",
            "display-only",
            "idx-personal-use",
            "no-republish"
          ],
          "description": "idx-personal-use = MLS/IDX data a portal may NOT republish; no-republish = analysis only."
        },
        "credit_required": {
          "type": "boolean",
          "description": "The publisher (or listing office) must be named wherever the listing is shown."
        },
        "backlink_required": {
          "type": "boolean",
          "description": "The listing must link to its `url`."
        },
        "url": {
          "type": "string",
          "format": "uri",
          "description": "The publisher's terms, if any."
        }
      }
    },
    "Publisher": {
      "type": "object",
      "description": "The organisation that sends the feed.",
      "required": [
        "id",
        "name",
        "website"
      ],
      "additionalProperties": false,
      "properties": {
        "id": {
          "type": "string",
          "pattern": "^[a-z0-9][a-z0-9-]{1,62}$",
          "x-hint": "lowercase letters, digits and hyphens, e.g. \"example-realty\"",
          "description": "Stable slug for the publisher, chosen once: \"cabarete-real-estate\"."
        },
        "name": {
          "type": "string",
          "minLength": 1,
          "description": "Trading name."
        },
        "kind": {
          "enum": [
            "agency",
            "developer",
            "owner",
            "mls",
            "portal"
          ],
          "description": "What kind of organisation this is."
        },
        "website": {
          "type": "string",
          "format": "uri",
          "description": "Home page."
        },
        "country": {
          "type": "string",
          "pattern": "^[A-Z]{2}$",
          "x-hint": "a 2-letter ISO country code such as DO",
          "description": "Country of registration (ISO 3166-1 alpha-2)."
        },
        "contact": {
          "$ref": "#/$defs/Contact",
          "description": "Main contact for the feed."
        },
        "license_number": {
          "type": "string",
          "description": "Local broker licence or registry number, where one exists."
        }
      }
    },
    "Energy": {
      "type": "object",
      "description": "Energy performance certificate. Required by law in listings across the EU and the UK; optional elsewhere.",
      "additionalProperties": false,
      "properties": {
        "scheme": {
          "enum": [
            "eu_epc",
            "uk_epc",
            "leed",
            "edge",
            "other"
          ],
          "description": "Which certificate system the rating belongs to."
        },
        "rating": {
          "enum": [
            "A+++",
            "A++",
            "A+",
            "A",
            "B",
            "C",
            "D",
            "E",
            "F",
            "G"
          ],
          "description": "Energy class on the certificate."
        },
        "primary_kwh_m2_year": {
          "type": "number",
          "minimum": 0,
          "description": "Primary energy demand, kWh per m² per year."
        },
        "co2_kg_m2_year": {
          "type": "number",
          "minimum": 0,
          "description": "CO₂ emissions, kg per m² per year."
        },
        "valid_until": {
          "type": "string",
          "format": "date",
          "description": "Certificate expiry."
        },
        "status": {
          "enum": [
            "issued",
            "in_process",
            "exempt"
          ],
          "description": "exempt = the property is legally exempt (e.g. listed buildings, land)."
        },
        "provenance": {
          "$ref": "#/$defs/Provenance",
          "description": "Where this value came from."
        }
      }
    },
    "RentalTerms": {
      "type": "object",
      "description": "Terms of a long or mid-term let. Use with operation rent_long or rent_mid.",
      "additionalProperties": false,
      "properties": {
        "deposit": {
          "$ref": "#/$defs/Money",
          "description": "Security deposit as an amount (basis \"total\")."
        },
        "deposit_months": {
          "type": "number",
          "minimum": 0,
          "maximum": 24,
          "description": "Deposit as months of rent, when stated that way."
        },
        "min_term_months": {
          "type": "integer",
          "minimum": 1,
          "description": "Shortest lease accepted."
        },
        "max_term_months": {
          "type": "integer",
          "minimum": 1,
          "description": "Longest lease offered, when limited."
        },
        "available_from": {
          "type": "string",
          "format": "date",
          "description": "Move-in date. Omit when available now."
        },
        "furnished": {
          "enum": [
            "unfurnished",
            "part",
            "fully"
          ],
          "description": "How it is let."
        },
        "utilities_included": {
          "type": "array",
          "items": {
            "enum": [
              "electricity",
              "water",
              "gas",
              "internet",
              "tv",
              "hoa",
              "cleaning"
            ],
            "description": "One utility."
          },
          "description": "Utilities included in the rent."
        },
        "pets": {
          "enum": [
            "allowed",
            "on_request",
            "not_allowed"
          ],
          "description": "Pet policy."
        },
        "smoking_allowed": {
          "type": "boolean",
          "description": "Smoking allowed inside."
        }
      }
    },
    "ShortTerm": {
      "type": "object",
      "description": "Holiday / short-term letting. Use with operation rent_short, or on a sale to describe its rental use.",
      "additionalProperties": false,
      "properties": {
        "license_number": {
          "type": "string",
          "description": "Tourist-rental registration number where the law requires one."
        },
        "license_authority": {
          "type": "string",
          "description": "Who issued it."
        },
        "max_guests": {
          "type": "integer",
          "minimum": 1,
          "description": "Maximum occupancy."
        },
        "min_nights": {
          "type": "integer",
          "minimum": 1,
          "description": "Minimum stay."
        },
        "check_in": {
          "type": "string",
          "pattern": "^[0-2][0-9]:[0-5][0-9]$",
          "x-hint": "a 24-hour time such as 15:00",
          "description": "Check-in from (local time, HH:MM)."
        },
        "check_out": {
          "type": "string",
          "pattern": "^[0-2][0-9]:[0-5][0-9]$",
          "x-hint": "a 24-hour time such as 11:00",
          "description": "Check-out by (local time, HH:MM)."
        },
        "calendar_url": {
          "type": "string",
          "format": "uri",
          "description": "iCal (.ics) availability feed."
        },
        "rates": {
          "type": "array",
          "description": "Seasonal nightly or weekly rates.",
          "items": {
            "type": "object",
            "description": "One season.",
            "required": [
              "from",
              "to",
              "price"
            ],
            "additionalProperties": false,
            "properties": {
              "name": {
                "type": "string",
                "description": "Season name: \"High season\", \"Christmas\"."
              },
              "from": {
                "type": "string",
                "format": "date",
                "description": "First night."
              },
              "to": {
                "type": "string",
                "format": "date",
                "description": "Last night."
              },
              "price": {
                "$ref": "#/$defs/Money",
                "description": "Rate, basis per_night or per_week."
              }
            }
          }
        },
        "cleaning_fee": {
          "$ref": "#/$defs/Money",
          "description": "One-off cleaning fee per stay (basis \"total\")."
        },
        "managed_by": {
          "type": "string",
          "minLength": 1,
          "description": "Rental manager, when not the publisher."
        }
      }
    },
    "Commercial": {
      "type": "object",
      "description": "Commercial property details. Use with property_type commercial, hotel or building.",
      "additionalProperties": false,
      "properties": {
        "use": {
          "enum": [
            "office",
            "retail",
            "restaurant",
            "industrial",
            "warehouse",
            "hospitality",
            "mixed_use",
            "healthcare",
            "land_commercial"
          ],
          "description": "Main permitted use."
        },
        "zoning": {
          "type": "string",
          "description": "Local zoning designation, as written by the authority."
        },
        "ceiling_height": {
          "$ref": "#/$defs/Length",
          "description": "Clear internal height."
        },
        "frontage": {
          "$ref": "#/$defs/Length",
          "description": "Street frontage."
        },
        "loading_docks": {
          "type": "integer",
          "minimum": 0,
          "description": "Number of loading docks."
        },
        "power_kva": {
          "type": "number",
          "minimum": 0,
          "description": "Electrical supply capacity in kVA."
        },
        "rooms_keys": {
          "type": "integer",
          "minimum": 0,
          "description": "Hotel rooms / keys."
        },
        "tenanted": {
          "type": "boolean",
          "description": "Sold with a sitting tenant."
        },
        "income": {
          "$ref": "#/$defs/Money",
          "description": "Current rental income (basis per_month or per_year)."
        }
      }
    },
    "Building": {
      "type": "object",
      "description": "The building the unit is in, or the house itself.",
      "additionalProperties": false,
      "properties": {
        "floor": {
          "type": "integer",
          "minimum": -10,
          "maximum": 200,
          "description": "Floor of the unit: 0 = ground, negative = below ground."
        },
        "floors_total": {
          "type": "integer",
          "minimum": 1,
          "maximum": 200,
          "description": "Floors in the building."
        },
        "units_total": {
          "type": "integer",
          "minimum": 1,
          "description": "Units in the building."
        },
        "orientation": {
          "enum": [
            "n",
            "ne",
            "e",
            "se",
            "s",
            "sw",
            "w",
            "nw"
          ],
          "description": "Main façade or terrace direction."
        },
        "condition": {
          "enum": [
            "new",
            "excellent",
            "good",
            "needs_renovation",
            "to_restore"
          ],
          "description": "Condition as described by the publisher."
        },
        "year_renovated": {
          "type": "integer",
          "minimum": 1800,
          "maximum": 2100,
          "description": "Last major renovation."
        },
        "construction": {
          "enum": [
            "concrete",
            "concrete_block",
            "steel",
            "wood",
            "masonry",
            "mixed"
          ],
          "description": "Main structure."
        },
        "roof": {
          "enum": [
            "concrete",
            "metal",
            "tile",
            "wood",
            "thatch",
            "other"
          ],
          "description": "Roof type: matters for hurricane exposure and insurance."
        },
        "design_wind_speed_kmh": {
          "type": "number",
          "minimum": 0,
          "maximum": 500,
          "description": "Wind speed the structure is engineered for, km/h."
        },
        "ground_elevation_m": {
          "type": "number",
          "minimum": -50,
          "maximum": 6000,
          "description": "Ground elevation above sea level, metres."
        }
      }
    },
    "Listing": {
      "type": "object",
      "description": "One property offered for sale or rent.",
      "required": [
        "id",
        "url",
        "status",
        "updated_at",
        "operation",
        "property_type",
        "title",
        "price",
        "location"
      ],
      "additionalProperties": false,
      "properties": {
        "id": {
          "type": "string",
          "minLength": 1,
          "maxLength": 128,
          "description": "Stable within the publisher. Never reuse; never change when the listing is edited."
        },
        "url": {
          "type": "string",
          "format": "uri",
          "description": "The listing's canonical page on the publisher's site. Receivers link back here."
        },
        "status": {
          "enum": [
            "active",
            "reserved",
            "sold",
            "rented",
            "withdrawn"
          ],
          "description": "Market status. Keep sold/withdrawn listings in the feed for 30 days."
        },
        "updated_at": {
          "type": "string",
          "format": "date-time",
          "description": "Last change to any field."
        },
        "listed_at": {
          "type": "string",
          "format": "date",
          "description": "First day on the market."
        },
        "operation": {
          "enum": [
            "sale",
            "rent_long",
            "rent_mid",
            "rent_short"
          ],
          "description": "rent_mid = monthly, 1–11 months; rent_short = nightly/weekly."
        },
        "property_type": {
          "enum": [
            "apartment",
            "penthouse",
            "villa",
            "house",
            "townhouse",
            "land",
            "commercial",
            "hotel",
            "building",
            "other"
          ],
          "description": "What the property is."
        },
        "development_id": {
          "type": "string",
          "description": "The development this unit belongs to, when there is one in `developments`."
        },
        "unit": {
          "type": "string",
          "description": "Unit label inside a building or development: \"A-402\"."
        },
        "title": {
          "$ref": "#/$defs/LocalizedText",
          "description": "Headline, in one or more languages."
        },
        "description": {
          "$ref": "#/$defs/LocalizedText",
          "description": "Full description, in one or more languages."
        },
        "price": {
          "$ref": "#/$defs/Money",
          "description": "Asking price or rent."
        },
        "area": {
          "type": "object",
          "description": "Areas, each with its own unit.",
          "additionalProperties": false,
          "properties": {
            "built": {
              "$ref": "#/$defs/Measure",
              "description": "Interior living area."
            },
            "usable": {
              "$ref": "#/$defs/Measure",
              "description": "Net usable floor area, where the market distinguishes it."
            },
            "gross": {
              "$ref": "#/$defs/Measure",
              "description": "Gross built area including walls and common shares."
            },
            "terrace": {
              "$ref": "#/$defs/Measure",
              "description": "Terraces and balconies."
            },
            "plot": {
              "$ref": "#/$defs/Measure",
              "description": "Land. For property_type \"land\", this is the size."
            },
            "standard": {
              "enum": [
                "ipms",
                "local",
                "unknown"
              ],
              "description": "How areas were measured: IPMS, or the local convention."
            }
          }
        },
        "rooms": {
          "type": "object",
          "description": "Room counts.",
          "additionalProperties": false,
          "properties": {
            "bedrooms": {
              "type": "integer",
              "minimum": 0,
              "description": "0 = studio."
            },
            "bathrooms": {
              "type": "number",
              "minimum": 0,
              "description": "Half baths as .5."
            },
            "parking": {
              "type": "integer",
              "minimum": 0,
              "description": "Parking spaces included."
            },
            "total": {
              "type": "integer",
              "minimum": 0,
              "description": "All habitable rooms, where the market counts them (Europe)."
            }
          }
        },
        "location": {
          "type": "object",
          "description": "Where the property is.",
          "required": [
            "country",
            "city"
          ],
          "additionalProperties": false,
          "properties": {
            "country": {
              "type": "string",
              "pattern": "^[A-Z]{2}$",
              "x-hint": "a 2-letter ISO country code such as DO",
              "description": "ISO 3166-1 alpha-2."
            },
            "region": {
              "type": "string",
              "description": "Province / parish / state."
            },
            "city": {
              "type": "string",
              "minLength": 1,
              "description": "City or municipality."
            },
            "area": {
              "type": "string",
              "description": "Neighbourhood, sector or resort: \"Cap Cana\", \"Los Corales\"."
            },
            "address": {
              "type": "string",
              "description": "Street address. Omit when the publisher does not disclose it."
            },
            "address_visibility": {
              "enum": [
                "full",
                "street",
                "area_only"
              ],
              "description": "What a receiver may show: the full address, the street only, or only the area."
            },
            "postal_code": {
              "type": "string",
              "description": "Postal code."
            },
            "geo": {
              "$ref": "#/$defs/Geo",
              "description": "Coordinates and their precision."
            }
          }
        },
        "delivery": {
          "type": "object",
          "description": "Construction status.",
          "required": [
            "status"
          ],
          "additionalProperties": false,
          "properties": {
            "status": {
              "enum": [
                "built",
                "under_construction",
                "off_plan"
              ],
              "description": "Whether it exists yet."
            },
            "year_built": {
              "type": "integer",
              "minimum": 1800,
              "maximum": 2100,
              "description": "Year completed."
            },
            "expected": {
              "type": "string",
              "pattern": "^[0-9]{4}(-Q[1-4]|-[01][0-9])?$",
              "x-hint": "a year, quarter or month: 2027, 2027-Q2 or 2027-06",
              "description": "Handover: \"2027\", \"2027-Q2\" or \"2027-06\"."
            }
          }
        },
        "features": {
          "type": "array",
          "items": {
            "type": "string",
            "pattern": "^[a-z0-9_]+$",
            "x-hint": "lowercase with underscores, e.g. ocean_view",
            "description": "One amenity code."
          },
          "description": "Amenity codes from the REES vocabulary (150 terms, 12 categories, labelled in 7 languages). Other codes are kept with a warning."
        },
        "media": {
          "type": "array",
          "description": "Photos, plans, videos and documents.",
          "items": {
            "type": "object",
            "description": "One media item.",
            "required": [
              "url",
              "type"
            ],
            "additionalProperties": false,
            "properties": {
              "url": {
                "type": "string",
                "format": "uri",
                "description": "Original file, largest size available."
              },
              "type": {
                "enum": [
                  "photo",
                  "floorplan",
                  "video",
                  "tour",
                  "document"
                ],
                "description": "What the file is."
              },
              "caption": {
                "$ref": "#/$defs/LocalizedText",
                "description": "Caption, in one or more languages."
              },
              "order": {
                "type": "integer",
                "minimum": 0,
                "description": "Display order; lowest first."
              }
            }
          }
        },
        "costs": {
          "type": "object",
          "description": "Running and purchase costs.",
          "additionalProperties": false,
          "properties": {
            "hoa": {
              "$ref": "#/$defs/Money",
              "description": "Condominium / maintenance fee, basis per_month or per_year."
            },
            "property_tax": {
              "$ref": "#/$defs/Money",
              "description": "Annual property tax."
            },
            "transfer_tax_pct": {
              "type": "number",
              "minimum": 0,
              "maximum": 30,
              "description": "Transfer tax payable by the buyer, % of price."
            }
          }
        },
        "legal": {
          "type": "object",
          "description": "Legal status.",
          "additionalProperties": false,
          "properties": {
            "title_status": {
              "enum": [
                "titled",
                "titled_individual",
                "in_process",
                "untitled",
                "unknown"
              ],
              "description": "titled_individual = its own certificate (in the DR, after deslinde)."
            },
            "survey_done": {
              "type": "boolean",
              "description": "Boundary survey registered (deslinde in the DR)."
            },
            "tax_exemption": {
              "type": "object",
              "description": "A tax incentive attached to the property.",
              "required": [
                "scheme"
              ],
              "additionalProperties": false,
              "properties": {
                "scheme": {
                  "type": "string",
                  "description": "e.g. \"CONFOTUR\"."
                },
                "until_year": {
                  "type": "integer",
                  "minimum": 2000,
                  "maximum": 2100,
                  "description": "Last year it applies."
                },
                "provenance": {
                  "$ref": "#/$defs/Provenance",
                  "description": "Where this value came from."
                }
              }
            },
            "foreign_buyers": {
              "enum": [
                "allowed",
                "restricted",
                "not_allowed",
                "unknown"
              ],
              "description": "Whether non-residents may buy."
            }
          }
        },
        "energy": {
          "$ref": "#/$defs/Energy",
          "description": "Energy certificate (v0.2)."
        },
        "rental_terms": {
          "$ref": "#/$defs/RentalTerms",
          "description": "Lease terms for long and mid-term lets (v0.2)."
        },
        "short_term": {
          "$ref": "#/$defs/ShortTerm",
          "description": "Holiday-letting details (v0.2)."
        },
        "commercial": {
          "$ref": "#/$defs/Commercial",
          "description": "Commercial details (v0.2)."
        },
        "building": {
          "$ref": "#/$defs/Building",
          "description": "Building and construction (v0.2)."
        },
        "agent": {
          "$ref": "#/$defs/Contact",
          "description": "The person to contact about this listing."
        },
        "listing_office": {
          "type": "object",
          "required": [
            "name"
          ],
          "additionalProperties": false,
          "description": "The office that holds the listing, when it is not the publisher (co-brokerage, MLS).",
          "properties": {
            "name": {
              "type": "string",
              "minLength": 1,
              "description": "Office name."
            },
            "id": {
              "type": "string",
              "description": "Office id in the source system."
            },
            "website": {
              "type": "string",
              "format": "uri",
              "description": "Office website."
            }
          }
        },
        "license": {
          "$ref": "#/$defs/License",
          "description": "Licence for this listing, overriding the feed default."
        }
      }
    },
    "Development": {
      "type": "object",
      "description": "A project with several units, each listed separately with `development_id`.",
      "required": [
        "id",
        "name",
        "url",
        "location",
        "delivery"
      ],
      "additionalProperties": false,
      "properties": {
        "id": {
          "type": "string",
          "minLength": 1,
          "maxLength": 128,
          "description": "Stable within the publisher."
        },
        "name": {
          "type": "string",
          "minLength": 1,
          "description": "Project name."
        },
        "url": {
          "type": "string",
          "format": "uri",
          "description": "Project page."
        },
        "developer": {
          "type": "string",
          "description": "Developer company."
        },
        "location": {
          "$ref": "#/$defs/Listing/properties/location",
          "description": "Where the project is."
        },
        "delivery": {
          "$ref": "#/$defs/Listing/properties/delivery",
          "description": "Construction status and handover."
        },
        "units_total": {
          "type": "integer",
          "minimum": 1,
          "description": "Units in the project."
        },
        "units_available": {
          "type": "integer",
          "minimum": 0,
          "description": "Units still for sale."
        },
        "price_from": {
          "$ref": "#/$defs/Money",
          "description": "Lowest price, basis \"from\"."
        },
        "description": {
          "$ref": "#/$defs/LocalizedText",
          "description": "Project description."
        },
        "media": {
          "$ref": "#/$defs/Listing/properties/media",
          "description": "Project media."
        },
        "features": {
          "$ref": "#/$defs/Listing/properties/features",
          "description": "Project amenities."
        },
        "building": {
          "$ref": "#/$defs/Building",
          "description": "Construction details shared by all units."
        },
        "energy": {
          "$ref": "#/$defs/Energy",
          "description": "Project-level certificate (e.g. EDGE, LEED)."
        }
      }
    }
  }
}