{
  "openapi": "3.1.0",
  "info": {
    "title": "Rosedell Estate public discovery API",
    "version": "1.0.0",
    "description": "Read-only property discovery and provisional availability. No quote, hold, booking, payment, cancellation, guest identity or access endpoints. All stays require host approval; Unit C remains inquiry-only. A calendar response does not guarantee availability or approval. No query parameters are accepted except the exact start/end pair on availability; duplicates are rejected. No authentication required. No CORS grant. Responses are no-store."
  },
  "servers": [
    {
      "url": "https://rosedellestate.com/api/guest/v1"
    }
  ],
  "paths": {
    "/properties": {
      "get": {
        "operationId": "listProperties",
        "summary": "Read public property facts and current approved rules.",
        "parameters": [],
        "responses": {
          "200": {
            "description": "Read public property facts and current approved rules.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Catalog"
                }
              }
            }
          },
          "400": {
            "description": "Malformed or unsupported query parameters.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "429": {
            "description": "60 requests per minute per client IP shared across these endpoints; no queue.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            },
            "headers": {
              "Retry-After": {
                "description": "Wait this many seconds before retrying.",
                "schema": {
                  "type": "integer",
                  "example": 60
                }
              }
            }
          }
        }
      }
    },
    "/properties/{unit}": {
      "get": {
        "operationId": "getProperty",
        "summary": "Read one public property.",
        "parameters": [
          {
            "name": "unit",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "enum": [
                "a",
                "b",
                "c"
              ]
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Read one public property.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/PropertyResponse"
                }
              }
            }
          },
          "400": {
            "description": "Malformed or unsupported query parameters.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "429": {
            "description": "60 requests per minute per client IP shared across these endpoints; no queue.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            },
            "headers": {
              "Retry-After": {
                "description": "Wait this many seconds before retrying.",
                "schema": {
                  "type": "integer",
                  "example": 60
                }
              }
            }
          },
          "404": {
            "description": "Unknown property ID.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          }
        }
      }
    },
    "/properties/{unit}/availability": {
      "get": {
        "operationId": "getAvailability",
        "summary": "Read provisional availability, never a reservation.",
        "parameters": [
          {
            "name": "unit",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "enum": [
                "a",
                "b",
                "c"
              ]
            }
          },
          {
            "name": "start",
            "in": "query",
            "required": true,
            "description": "Inclusive first night, no earlier than today in America/Los_Angeles.",
            "schema": {
              "type": "string",
              "format": "date"
            }
          },
          {
            "name": "end",
            "in": "query",
            "required": true,
            "description": "Exclusive final date. Window is 1\u201362 nights and within the next two years. This is a calendar window, not a permissible stay length.",
            "schema": {
              "type": "string",
              "format": "date"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Read provisional availability, never a reservation.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/AvailabilityResponse"
                }
              }
            }
          },
          "400": {
            "description": "Malformed or unsupported query parameters.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "429": {
            "description": "60 requests per minute per client IP shared across these endpoints; no queue.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            },
            "headers": {
              "Retry-After": {
                "description": "Wait this many seconds before retrying.",
                "schema": {
                  "type": "integer",
                  "example": 60
                }
              }
            }
          },
          "404": {
            "description": "Unknown property ID.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "503": {
            "description": "Availability unavailable. Never interpret a failure as open dates.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            },
            "headers": {
              "Retry-After": {
                "description": "Wait this many seconds before retrying.",
                "schema": {
                  "type": "integer",
                  "example": 60
                }
              }
            }
          }
        }
      }
    },
    "/openapi.json": {
      "get": {
        "operationId": "getContract",
        "summary": "Read this versioned contract.",
        "responses": {
          "200": {
            "description": "OpenAPI 3.1 contract.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object"
                }
              }
            }
          },
          "400": {
            "description": "Query parameters are not supported.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "429": {
            "description": "Rate limited.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            },
            "headers": {
              "Retry-After": {
                "description": "Wait this many seconds before retrying.",
                "schema": {
                  "type": "integer",
                  "example": 60
                }
              }
            }
          }
        }
      }
    }
  },
  "components": {
    "schemas": {
      "Error": {
        "type": "object",
        "additionalProperties": false,
        "properties": {
          "apiVersion": {
            "type": "string",
            "const": "1"
          },
          "code": {
            "type": "string",
            "enum": [
              "invalid_query",
              "invalid_window",
              "unknown_property",
              "rate_limited",
              "availability_unavailable"
            ]
          },
          "message": {
            "type": "string"
          }
        },
        "required": [
          "apiVersion",
          "code",
          "message"
        ]
      },
      "Rules": {
        "type": "object",
        "additionalProperties": false,
        "properties": {
          "version": {
            "type": "string"
          },
          "maxGuests": {
            "type": "integer"
          },
          "minNights": {
            "type": "integer"
          },
          "maxNights": {
            "type": "integer"
          },
          "bufferNights": {
            "type": "integer"
          }
        },
        "required": [
          "version",
          "maxGuests",
          "minNights",
          "maxNights",
          "bufferNights"
        ]
      },
      "Policies": {
        "type": "object",
        "additionalProperties": false,
        "properties": {
          "timeZone": {
            "type": "string",
            "const": "America/Los_Angeles"
          },
          "checkInLocalTime": {
            "type": "string"
          },
          "checkOutLocalTime": {
            "type": "string"
          },
          "petsAllowed": {
            "type": "boolean"
          },
          "smokingAllowed": {
            "type": "boolean"
          },
          "version": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ]
          },
          "bookingTerms": {
            "anyOf": [
              {
                "type": "string",
                "description": "Informational current policy, not a quote or acceptance. Null when not configured consistently; contact the host."
              },
              {
                "type": "null"
              }
            ]
          }
        },
        "required": [
          "timeZone",
          "checkInLocalTime",
          "checkOutLocalTime",
          "petsAllowed",
          "smokingAllowed",
          "version",
          "bookingTerms"
        ]
      },
      "Photo": {
        "type": "object",
        "additionalProperties": false,
        "properties": {
          "url": {
            "type": "string",
            "format": "uri"
          },
          "description": {
            "type": "string"
          }
        },
        "required": [
          "url",
          "description"
        ]
      },
      "Property": {
        "type": "object",
        "additionalProperties": false,
        "properties": {
          "id": {
            "type": "string",
            "enum": [
              "a",
              "b",
              "c"
            ]
          },
          "name": {
            "type": "string"
          },
          "headline": {
            "type": "string"
          },
          "description": {
            "type": "string"
          },
          "location": {
            "type": "string"
          },
          "maxGuests": {
            "type": "integer"
          },
          "sleeping": {
            "type": "string"
          },
          "accessNote": {
            "type": "string"
          },
          "amenities": {
            "type": "array",
            "items": {
              "type": "string"
            }
          },
          "photos": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/Photo"
            }
          },
          "publicUrl": {
            "type": "string",
            "format": "uri"
          },
          "inquiryUrl": {
            "type": "string",
            "format": "uri"
          },
          "availabilityUrl": {
            "type": "string",
            "format": "uri"
          },
          "inquiryOnly": {
            "type": "boolean"
          },
          "requiresHostReview": {
            "type": "boolean",
            "const": true
          },
          "approvedRules": {
            "anyOf": [
              {
                "$ref": "#/components/schemas/Rules"
              },
              {
                "type": "null"
              }
            ]
          },
          "policies": {
            "$ref": "#/components/schemas/Policies"
          }
        },
        "required": [
          "id",
          "name",
          "headline",
          "description",
          "location",
          "maxGuests",
          "sleeping",
          "accessNote",
          "amenities",
          "photos",
          "publicUrl",
          "inquiryUrl",
          "availabilityUrl",
          "inquiryOnly",
          "requiresHostReview",
          "approvedRules",
          "policies"
        ]
      },
      "Catalog": {
        "type": "object",
        "additionalProperties": false,
        "properties": {
          "apiVersion": {
            "type": "string",
            "const": "1"
          },
          "readOnly": {
            "type": "boolean",
            "const": true
          },
          "bookingSupported": {
            "type": "boolean",
            "const": false
          },
          "contractUrl": {
            "type": "string",
            "format": "uri"
          },
          "contactEmail": {
            "type": "string",
            "format": "email"
          },
          "properties": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/Property"
            }
          }
        },
        "required": [
          "apiVersion",
          "readOnly",
          "bookingSupported",
          "contractUrl",
          "contactEmail",
          "properties"
        ]
      },
      "PropertyResponse": {
        "type": "object",
        "additionalProperties": false,
        "properties": {
          "apiVersion": {
            "type": "string",
            "const": "1"
          },
          "readOnly": {
            "type": "boolean",
            "const": true
          },
          "bookingSupported": {
            "type": "boolean",
            "const": false
          },
          "property": {
            "$ref": "#/components/schemas/Property"
          }
        },
        "required": [
          "apiVersion",
          "readOnly",
          "bookingSupported",
          "property"
        ]
      },
      "Day": {
        "type": "object",
        "additionalProperties": false,
        "properties": {
          "date": {
            "type": "string",
            "format": "date"
          },
          "state": {
            "type": "string",
            "enum": [
              "unavailable",
              "available_to_request",
              "unknown"
            ],
            "description": "available_to_request is provisional and requires host approval; unknown must never be treated as open."
          }
        },
        "required": [
          "date",
          "state"
        ]
      },
      "Calendar": {
        "type": "object",
        "additionalProperties": false,
        "properties": {
          "unit": {
            "type": "string",
            "enum": [
              "a",
              "b",
              "c"
            ]
          },
          "start": {
            "type": "string",
            "format": "date"
          },
          "end": {
            "type": "string",
            "format": "date"
          },
          "days": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/Day"
            }
          },
          "dataStatus": {
            "type": "string",
            "enum": [
              "current",
              "partial"
            ]
          },
          "lastUpdatedAt": {
            "anyOf": [
              {
                "type": "string",
                "format": "date-time"
              },
              {
                "type": "null"
              }
            ]
          },
          "coverageStart": {
            "anyOf": [
              {
                "type": "string",
                "format": "date"
              },
              {
                "type": "null"
              }
            ]
          },
          "coverageEnd": {
            "anyOf": [
              {
                "type": "string",
                "format": "date"
              },
              {
                "type": "null"
              }
            ]
          },
          "requiresHostReview": {
            "type": "boolean",
            "const": true
          },
          "inquiryOnly": {
            "type": "boolean"
          }
        },
        "required": [
          "unit",
          "start",
          "end",
          "days",
          "dataStatus",
          "lastUpdatedAt",
          "coverageStart",
          "coverageEnd",
          "requiresHostReview",
          "inquiryOnly"
        ]
      },
      "AvailabilityResponse": {
        "type": "object",
        "additionalProperties": false,
        "properties": {
          "apiVersion": {
            "type": "string",
            "const": "1"
          },
          "readOnly": {
            "type": "boolean",
            "const": true
          },
          "bookingSupported": {
            "type": "boolean",
            "const": false
          },
          "provisional": {
            "type": "boolean",
            "const": true
          },
          "timeZone": {
            "type": "string",
            "const": "America/Los_Angeles"
          },
          "calendar": {
            "$ref": "#/components/schemas/Calendar"
          }
        },
        "required": [
          "apiVersion",
          "readOnly",
          "bookingSupported",
          "provisional",
          "timeZone",
          "calendar"
        ]
      }
    }
  }
}