{
  "openapi": "3.1.0",
  "info": {
    "title": "Voyant Quotes Booking Extension API",
    "version": "1.0.0"
  },
  "paths": {
    "/v1/admin/bookings/{bookingId}/quote-details": {
      "get": {
        "summary": "Get Quote details for a booking",
        "parameters": [
          {
            "name": "bookingId",
            "in": "path",
            "required": true,
            "schema": { "type": "string" }
          }
        ],
        "responses": {
          "200": { "description": "The booking's Quote details, or null when none exist." }
        },
        "x-voyant-api-id": "@voyant-travel/quotes#booking-extension.api"
      },
      "put": {
        "summary": "Create or update Quote details for a booking",
        "parameters": [
          {
            "name": "bookingId",
            "in": "path",
            "required": true,
            "schema": { "type": "string" }
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "quoteId": { "type": ["string", "null"] },
                  "quoteVersionId": { "type": ["string", "null"] }
                }
              }
            }
          }
        },
        "responses": {
          "200": { "description": "The saved booking Quote details." }
        },
        "x-voyant-api-id": "@voyant-travel/quotes#booking-extension.api"
      },
      "delete": {
        "summary": "Remove Quote details from a booking",
        "parameters": [
          {
            "name": "bookingId",
            "in": "path",
            "required": true,
            "schema": { "type": "string" }
          }
        ],
        "responses": {
          "200": { "description": "The Quote details were removed." },
          "404": { "description": "No Quote details exist for the booking." }
        },
        "x-voyant-api-id": "@voyant-travel/quotes#booking-extension.api"
      }
    }
  }
}
