{
  "openapi": "3.1.0",
  "info": {
    "title": "The Syd public booking API",
    "version": "1.0.0",
    "description": "Public, unauthenticated API for AI agents and integrators: blocked-date calendars, live quotes, and request-to-book for six poolside villas at 1730 Clio St, New Orleans (14-24 guests per villa, 106 across the property). No API key. Human checkout at /checkout is instant card payment through Guesty's secure checkout. The agent path is request-to-book: POST /api/request-booking files a real inquiry, takes no payment, and the team confirms by email with a secure payment link. Only submit a booking with the traveler's explicit consent and real contact details; never submit test requests. Human-readable guide: https://thesyd.com/agents",
    "contact": {
      "email": "hello@thesyd.com",
      "url": "https://thesyd.com/agents"
    },
    "termsOfService": "https://thesyd.com/terms"
  },
  "servers": [
    {
      "url": "https://thesyd.com"
    }
  ],
  "paths": {
    "/api/calendar": {
      "get": {
        "operationId": "getBlockedDates",
        "summary": "Blocked dates for one villa (dates not listed are open)",
        "parameters": [
          {
            "name": "listingId",
            "in": "query",
            "required": true,
            "schema": {
              "type": "string",
              "enum": [
                "6077269ef25260002f94b7e7",
                "607b6ae0aed119002ff5c202",
                "607b677162c7fc002fbcbef8",
                "607753f964fe4200312283c0",
                "6782b6ec6e9c10000fe0f3ea",
                "678403487beb6100115bc0b1"
              ]
            },
            "description": "street-parades 6077269ef25260002f94b7e7, swamp-to-city 607b6ae0aed119002ff5c202, rhythm-of-new-orleans 607b677162c7fc002fbcbef8, mardi-gras-magic 607753f964fe4200312283c0, louisiana-wildlife 6782b6ec6e9c10000fe0f3ea, louisiana-living 678403487beb6100115bc0b1"
          },
          {
            "name": "from",
            "in": "query",
            "required": true,
            "schema": {
              "type": "string",
              "format": "date"
            }
          },
          {
            "name": "to",
            "in": "query",
            "required": true,
            "schema": {
              "type": "string",
              "format": "date"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Blocked dates in the window.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "ok": {
                      "type": "boolean"
                    },
                    "blocked": {
                      "type": "array",
                      "items": {
                        "type": "string",
                        "format": "date"
                      }
                    }
                  }
                }
              }
            }
          }
        }
      }
    },
    "/api/quote": {
      "get": {
        "operationId": "getQuote",
        "summary": "Live quote for one villa or the full six-villa buyout (JSON)",
        "description": "Same numbers as checkout: nightly rate, cleaning, occupancy taxes, no per-guest fees. Stays of 4+ nights include an automatic 5% discount (losDiscount). A plain-HTML version of the same quote is GET /quote?villa=...&checkin=...&checkout=...&guests=... Minimum stay is typically 3 nights.",
        "parameters": [
          {
            "name": "villa",
            "in": "query",
            "required": true,
            "schema": {
              "type": "string",
              "enum": [
                "street-parades",
                "swamp-to-city",
                "rhythm-of-new-orleans",
                "mardi-gras-magic",
                "louisiana-wildlife",
                "louisiana-living",
                "buyout"
              ]
            }
          },
          {
            "name": "checkin",
            "in": "query",
            "required": true,
            "schema": {
              "type": "string",
              "format": "date"
            }
          },
          {
            "name": "checkout",
            "in": "query",
            "required": true,
            "schema": {
              "type": "string",
              "format": "date"
            }
          },
          {
            "name": "guests",
            "in": "query",
            "required": false,
            "schema": {
              "type": "integer",
              "minimum": 1,
              "maximum": 106
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Quote in USD.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "ok": {
                      "type": "boolean"
                    },
                    "quote": {
                      "type": "object",
                      "properties": {
                        "nights": {
                          "type": "integer"
                        },
                        "currency": {
                          "type": "string"
                        },
                        "accommodation": {
                          "type": "number"
                        },
                        "losDiscount": {
                          "type": "number"
                        },
                        "cleaningFee": {
                          "type": "number"
                        },
                        "fees": {
                          "type": "number"
                        },
                        "taxes": {
                          "type": "number"
                        },
                        "total": {
                          "type": "number"
                        }
                      }
                    }
                  }
                }
              }
            }
          }
        }
      }
    },
    "/api/request-booking": {
      "post": {
        "operationId": "requestBooking",
        "summary": "File a real booking request (request-to-book, no payment taken)",
        "description": "Creates a real inquiry the team acts on: they reply to the guest's email with one secure payment link (the 50% deposit paid through it confirms the dates; the balance auto-charges 60 days before check-in). Cancellation: full refund 60+ days before arrival, non-refundable inside 60 days. Requirements for agents: get the traveler's explicit consent after showing them the quoted total and the terms (https://thesyd.com/terms), use their real name and email, state in notes that an agent is submitting and for whom, and never send test or placeholder requests.",
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "required": [
                  "listingId",
                  "checkIn",
                  "checkOut",
                  "guest"
                ],
                "properties": {
                  "listingId": {
                    "type": "string",
                    "enum": [
                      "6077269ef25260002f94b7e7",
                      "607b6ae0aed119002ff5c202",
                      "607b677162c7fc002fbcbef8",
                      "607753f964fe4200312283c0",
                      "6782b6ec6e9c10000fe0f3ea",
                      "678403487beb6100115bc0b1"
                    ]
                  },
                  "checkIn": {
                    "type": "string",
                    "format": "date"
                  },
                  "checkOut": {
                    "type": "string",
                    "format": "date"
                  },
                  "guestsCount": {
                    "type": "integer",
                    "minimum": 1,
                    "maximum": 106
                  },
                  "guest": {
                    "type": "object",
                    "required": [
                      "name",
                      "email"
                    ],
                    "properties": {
                      "name": {
                        "type": "string",
                        "description": "Traveler's full name"
                      },
                      "email": {
                        "type": "string",
                        "format": "email",
                        "description": "Traveler's real email; confirmation and the payment link go here"
                      },
                      "phone": {
                        "type": "string"
                      }
                    }
                  },
                  "villas": {
                    "type": "string",
                    "description": "Villa name(s) the group wants, e.g. \"Street Parades\" or \"all six\""
                  },
                  "occasion": {
                    "type": "string"
                  },
                  "notes": {
                    "type": "string",
                    "description": "Include your agent name and that you are booking on the guest's behalf"
                  },
                  "quoted": {
                    "type": "string",
                    "description": "The total you quoted the guest, e.g. \"$9,200\""
                  }
                }
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Request filed; the team follows up by email.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "ok": {
                      "type": "boolean"
                    },
                    "reservationId": {
                      "type": [
                        "string",
                        "null"
                      ]
                    },
                    "held": {
                      "type": "boolean"
                    }
                  }
                }
              }
            }
          },
          "400": {
            "description": "Validation failure ({ ok: false, reason })"
          },
          "429": {
            "description": "Rate limited; slow down"
          }
        }
      }
    }
  }
}