Cart Items
Listing items on a cart — add (incl. from an encoded search selection), update dates/guests/quantity, remove, and pick a cancellation plan.
📄️ Per-unit price and availability calendar for a stay
The same night-by-night strip as `GET /api/v1/search/listings/{listingId}/calendar`, for the stay's listing on the cart's channel, with each unit the stay holds carrying its `selectedQuantity` and, per night, whether that quantity still fits. Units this cart is itself holding are not counted against it. The window defaults to 7 nights from the stay's check-in, at most 31. 400 for `to` not after `from` or a window over 31 nights; 404 for an unknown cart or item.
📄️ Add a listing item to the cart
Idempotent on (listingId, checkIn, checkOut) — re-adding sums the unit quantities.
📄️ Select a cancellation plan for an item
Picks a cancellation plan (e.g. a discounted non-refundable rate) from those available for the item's listing+channel. The plan's discount reduces the item's stay subtotal, before any cart-level coupon / bank offer. Each item's available plans are returned on the cart response.
📄️ Clear an item's cancellation plan (back to standard refundable)
Clear an item's cancellation plan (back to standard refundable)
📄️ Add an item from an encoded search selection
Decodes the `encodedId` returned on each listing search result (listing, stay dates, guest mix, selected properties, unit quantity and cancellation plan) and adds it as a cart item — no need to repeat those fields. Any of them present on the request body wins over the token. Same idempotent (listingId, checkIn, checkOut) semantics as the regular add.
📄️ Set which units a stay has
Replaces the stay's units with exactly the ones sent — swap, add and drop in one call; a unit left out (or sent with quantity 0) is removed. Every unit is checked against the listing and for availability on every night at its full new quantity. Returns the re-priced cart. 400 when no unit would remain, a unit is not on the stay's listing, a unit is not available for the stay's nights, or the cart is shared, booked, paid, on hold or under a price-change request; 404 for an unknown cart or item.
📄️ Remove an item from the cart
Remove an item from the cart
📄️ Update an item's dates / guests / quantity / position
Update an item's dates / guests / quantity / position