@curless/hotel-storefront 0.85.0 → 0.86.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (207) hide show
  1. package/dist/server.d.ts +1 -1
  2. package/dist/server.js +1 -1
  3. package/dist/tools/accept-terms.d.ts +4 -0
  4. package/dist/tools/accept-terms.d.ts.map +1 -0
  5. package/dist/tools/accept-terms.js +26 -0
  6. package/dist/tools/accept-terms.js.map +1 -0
  7. package/dist/tools/add-booking-addon.d.ts +4 -0
  8. package/dist/tools/add-booking-addon.d.ts.map +1 -0
  9. package/dist/tools/add-booking-addon.js +44 -0
  10. package/dist/tools/add-booking-addon.js.map +1 -0
  11. package/dist/tools/add-to-trip.d.ts +4 -0
  12. package/dist/tools/add-to-trip.d.ts.map +1 -0
  13. package/dist/tools/add-to-trip.js +49 -0
  14. package/dist/tools/add-to-trip.js.map +1 -0
  15. package/dist/tools/all-tools.d.ts +1342 -0
  16. package/dist/tools/all-tools.d.ts.map +1 -0
  17. package/dist/tools/all-tools.js +954 -0
  18. package/dist/tools/all-tools.js.map +1 -0
  19. package/dist/tools/answer.d.ts +3 -0
  20. package/dist/tools/answer.d.ts.map +1 -0
  21. package/dist/tools/answer.js +104 -0
  22. package/dist/tools/answer.js.map +1 -0
  23. package/dist/tools/args.d.ts +149 -0
  24. package/dist/tools/args.d.ts.map +1 -0
  25. package/dist/tools/args.js +176 -0
  26. package/dist/tools/args.js.map +1 -0
  27. package/dist/tools/base-output-schemas.d.ts +3 -0
  28. package/dist/tools/base-output-schemas.d.ts.map +1 -0
  29. package/dist/tools/base-output-schemas.js +380 -0
  30. package/dist/tools/base-output-schemas.js.map +1 -0
  31. package/dist/tools/book-picked.d.ts +4 -0
  32. package/dist/tools/book-picked.d.ts.map +1 -0
  33. package/dist/tools/book-picked.js +14 -0
  34. package/dist/tools/book-picked.js.map +1 -0
  35. package/dist/tools/booking-answer.d.ts +24 -0
  36. package/dist/tools/booking-answer.d.ts.map +1 -0
  37. package/dist/tools/booking-answer.js +485 -0
  38. package/dist/tools/booking-answer.js.map +1 -0
  39. package/dist/tools/buy-shop-item.d.ts +4 -0
  40. package/dist/tools/buy-shop-item.d.ts.map +1 -0
  41. package/dist/tools/buy-shop-item.js +45 -0
  42. package/dist/tools/buy-shop-item.js.map +1 -0
  43. package/dist/tools/call.d.ts +11 -0
  44. package/dist/tools/call.d.ts.map +1 -0
  45. package/dist/tools/call.js +2 -0
  46. package/dist/tools/call.js.map +1 -0
  47. package/dist/tools/cancel-facts.d.ts +281 -0
  48. package/dist/tools/cancel-facts.d.ts.map +1 -0
  49. package/dist/tools/cancel-facts.js +309 -0
  50. package/dist/tools/cancel-facts.js.map +1 -0
  51. package/dist/tools/cancel.d.ts +4 -0
  52. package/dist/tools/cancel.d.ts.map +1 -0
  53. package/dist/tools/cancel.js +364 -0
  54. package/dist/tools/cancel.js.map +1 -0
  55. package/dist/tools/card-addons.d.ts +4 -0
  56. package/dist/tools/card-addons.d.ts.map +1 -0
  57. package/dist/tools/card-addons.js +76 -0
  58. package/dist/tools/card-addons.js.map +1 -0
  59. package/dist/tools/change-booking.d.ts +4 -0
  60. package/dist/tools/change-booking.d.ts.map +1 -0
  61. package/dist/tools/change-booking.js +145 -0
  62. package/dist/tools/change-booking.js.map +1 -0
  63. package/dist/tools/clear-trip.d.ts +4 -0
  64. package/dist/tools/clear-trip.d.ts.map +1 -0
  65. package/dist/tools/clear-trip.js +10 -0
  66. package/dist/tools/clear-trip.js.map +1 -0
  67. package/dist/tools/compare.d.ts +4 -0
  68. package/dist/tools/compare.d.ts.map +1 -0
  69. package/dist/tools/compare.js +114 -0
  70. package/dist/tools/compare.js.map +1 -0
  71. package/dist/tools/current-trip.d.ts +70 -0
  72. package/dist/tools/current-trip.d.ts.map +1 -0
  73. package/dist/tools/current-trip.js +261 -0
  74. package/dist/tools/current-trip.js.map +1 -0
  75. package/dist/tools/deps.d.ts +229 -0
  76. package/dist/tools/deps.d.ts.map +1 -0
  77. package/dist/tools/deps.js +2 -0
  78. package/dist/tools/deps.js.map +1 -0
  79. package/dist/tools/follow-ups.d.ts +120 -0
  80. package/dist/tools/follow-ups.d.ts.map +1 -0
  81. package/dist/tools/follow-ups.js +369 -0
  82. package/dist/tools/follow-ups.js.map +1 -0
  83. package/dist/tools/forget-preferences.d.ts +4 -0
  84. package/dist/tools/forget-preferences.d.ts.map +1 -0
  85. package/dist/tools/forget-preferences.js +24 -0
  86. package/dist/tools/forget-preferences.js.map +1 -0
  87. package/dist/tools/get-hotel.d.ts +4 -0
  88. package/dist/tools/get-hotel.d.ts.map +1 -0
  89. package/dist/tools/get-hotel.js +324 -0
  90. package/dist/tools/get-hotel.js.map +1 -0
  91. package/dist/tools/hotel-choices.d.ts +132 -0
  92. package/dist/tools/hotel-choices.d.ts.map +1 -0
  93. package/dist/tools/hotel-choices.js +558 -0
  94. package/dist/tools/hotel-choices.js.map +1 -0
  95. package/dist/tools/itinerary.d.ts +4 -0
  96. package/dist/tools/itinerary.d.ts.map +1 -0
  97. package/dist/tools/itinerary.js +148 -0
  98. package/dist/tools/itinerary.js.map +1 -0
  99. package/dist/tools/list-booking-addons.d.ts +4 -0
  100. package/dist/tools/list-booking-addons.d.ts.map +1 -0
  101. package/dist/tools/list-booking-addons.js +21 -0
  102. package/dist/tools/list-booking-addons.js.map +1 -0
  103. package/dist/tools/list-bookings.d.ts +4 -0
  104. package/dist/tools/list-bookings.d.ts.map +1 -0
  105. package/dist/tools/list-bookings.js +119 -0
  106. package/dist/tools/list-bookings.js.map +1 -0
  107. package/dist/tools/list-extras.d.ts +4 -0
  108. package/dist/tools/list-extras.d.ts.map +1 -0
  109. package/dist/tools/list-extras.js +90 -0
  110. package/dist/tools/list-extras.js.map +1 -0
  111. package/dist/tools/list-hotels.d.ts +4 -0
  112. package/dist/tools/list-hotels.d.ts.map +1 -0
  113. package/dist/tools/list-hotels.js +891 -0
  114. package/dist/tools/list-hotels.js.map +1 -0
  115. package/dist/tools/list-shop-items.d.ts +4 -0
  116. package/dist/tools/list-shop-items.d.ts.map +1 -0
  117. package/dist/tools/list-shop-items.js +34 -0
  118. package/dist/tools/list-shop-items.js.map +1 -0
  119. package/dist/tools/list-shop-orders.d.ts +4 -0
  120. package/dist/tools/list-shop-orders.d.ts.map +1 -0
  121. package/dist/tools/list-shop-orders.js +22 -0
  122. package/dist/tools/list-shop-orders.js.map +1 -0
  123. package/dist/tools/look-up.d.ts +4 -0
  124. package/dist/tools/look-up.d.ts.map +1 -0
  125. package/dist/tools/look-up.js +170 -0
  126. package/dist/tools/look-up.js.map +1 -0
  127. package/dist/tools/output-schemas.d.ts +645 -0
  128. package/dist/tools/output-schemas.d.ts.map +1 -0
  129. package/dist/tools/output-schemas.js +503 -0
  130. package/dist/tools/output-schemas.js.map +1 -0
  131. package/dist/tools/paid-lines.d.ts +718 -0
  132. package/dist/tools/paid-lines.d.ts.map +1 -0
  133. package/dist/tools/paid-lines.js +359 -0
  134. package/dist/tools/paid-lines.js.map +1 -0
  135. package/dist/tools/pay-with-union-pay.d.ts +4 -0
  136. package/dist/tools/pay-with-union-pay.d.ts.map +1 -0
  137. package/dist/tools/pay-with-union-pay.js +112 -0
  138. package/dist/tools/pay-with-union-pay.js.map +1 -0
  139. package/dist/tools/payment-words.d.ts +269 -0
  140. package/dist/tools/payment-words.d.ts.map +1 -0
  141. package/dist/tools/payment-words.js +365 -0
  142. package/dist/tools/payment-words.js.map +1 -0
  143. package/dist/tools/pick-room.d.ts +4 -0
  144. package/dist/tools/pick-room.d.ts.map +1 -0
  145. package/dist/tools/pick-room.js +23 -0
  146. package/dist/tools/pick-room.js.map +1 -0
  147. package/dist/tools/policies.d.ts +4 -0
  148. package/dist/tools/policies.d.ts.map +1 -0
  149. package/dist/tools/policies.js +74 -0
  150. package/dist/tools/policies.js.map +1 -0
  151. package/dist/tools/pricing.d.ts +55 -0
  152. package/dist/tools/pricing.d.ts.map +1 -0
  153. package/dist/tools/pricing.js +260 -0
  154. package/dist/tools/pricing.js.map +1 -0
  155. package/dist/tools/put-room-line.d.ts +12 -0
  156. package/dist/tools/put-room-line.d.ts.map +1 -0
  157. package/dist/tools/put-room-line.js +314 -0
  158. package/dist/tools/put-room-line.js.map +1 -0
  159. package/dist/tools/quote-card.d.ts +234 -0
  160. package/dist/tools/quote-card.d.ts.map +1 -0
  161. package/dist/tools/quote-card.js +375 -0
  162. package/dist/tools/quote-card.js.map +1 -0
  163. package/dist/tools/refund-booking.d.ts +4 -0
  164. package/dist/tools/refund-booking.d.ts.map +1 -0
  165. package/dist/tools/refund-booking.js +112 -0
  166. package/dist/tools/refund-booking.js.map +1 -0
  167. package/dist/tools/request-booking.d.ts +4 -0
  168. package/dist/tools/request-booking.d.ts.map +1 -0
  169. package/dist/tools/request-booking.js +5 -0
  170. package/dist/tools/request-booking.js.map +1 -0
  171. package/dist/tools/request-words.d.ts +238 -0
  172. package/dist/tools/request-words.d.ts.map +1 -0
  173. package/dist/tools/request-words.js +487 -0
  174. package/dist/tools/request-words.js.map +1 -0
  175. package/dist/tools/room-choices.d.ts +64 -0
  176. package/dist/tools/room-choices.d.ts.map +1 -0
  177. package/dist/tools/room-choices.js +348 -0
  178. package/dist/tools/room-choices.js.map +1 -0
  179. package/dist/tools/session-notes.d.ts +164 -0
  180. package/dist/tools/session-notes.d.ts.map +1 -0
  181. package/dist/tools/session-notes.js +412 -0
  182. package/dist/tools/session-notes.js.map +1 -0
  183. package/dist/tools/sign-in.d.ts +4 -0
  184. package/dist/tools/sign-in.d.ts.map +1 -0
  185. package/dist/tools/sign-in.js +72 -0
  186. package/dist/tools/sign-in.js.map +1 -0
  187. package/dist/tools/sign-out.d.ts +4 -0
  188. package/dist/tools/sign-out.d.ts.map +1 -0
  189. package/dist/tools/sign-out.js +13 -0
  190. package/dist/tools/sign-out.js.map +1 -0
  191. package/dist/tools/terms-answer.d.ts +114 -0
  192. package/dist/tools/terms-answer.d.ts.map +1 -0
  193. package/dist/tools/terms-answer.js +475 -0
  194. package/dist/tools/terms-answer.js.map +1 -0
  195. package/dist/tools/tool-set.d.ts +1474 -0
  196. package/dist/tools/tool-set.d.ts.map +1 -0
  197. package/dist/tools/tool-set.js +497 -0
  198. package/dist/tools/tool-set.js.map +1 -0
  199. package/dist/tools/view-trip.d.ts +4 -0
  200. package/dist/tools/view-trip.d.ts.map +1 -0
  201. package/dist/tools/view-trip.js +7 -0
  202. package/dist/tools/view-trip.js.map +1 -0
  203. package/dist/tools.d.ts +13 -2089
  204. package/dist/tools.d.ts.map +1 -1
  205. package/dist/tools.js +11 -10685
  206. package/dist/tools.js.map +1 -1
  207. package/package.json +1 -1
@@ -0,0 +1,503 @@
1
+ import { baseOutputSchemas } from './base-output-schemas.js';
2
+ /**
3
+ * The value-added service orders tool (0.84.1). ⚠️ Says what it reads, in the words a guest uses for it
4
+ * (增值服务订单, 商城订单, shop orders, add-on orders - one thing), and that they are not hotel bookings;
5
+ * names no other tool and tells the model nothing to do (listing.ts).
6
+ */
7
+ export const SHOP_ORDERS_DESCRIPTION = 'The value-added service orders (增值服务订单) of the Otaless account signed in here: goods bought from the Otaless shop to go with a stay - not hotel bookings. 增值服务订单, 商城订单, shop orders and add-on orders are all the same thing. Each order comes with its item, total and currency, status, order id, the hotel booking it was bought with where that is known, and when it was ordered and paid where that is known (in UTC); cancelled ones are listed as the shop has them. It only reads: nothing is ordered, paid or cancelled. Nothing is listed when no account is signed in.';
8
+ /** Said by the bookings list where the shop is on (0.84.1). */
9
+ export const SHOP_ORDERS_IN_BOOKINGS = "Value-added service orders (增值服务订单 - the same as shop orders or add-on orders) are not hotel bookings: here each one shows under the hotel booking it was bought with, and one that matches none under other value-added service orders; the account's value-added service orders tool lists them all on their own, with their times.";
10
+ /** A guest's reason for a refund, as the group's staff are sent it (`otaless/booking.ts`). */
11
+ export const REFUND_REASON_MAX = 200;
12
+ // The shape of each tool's `structuredContent`, so a reader knows what it is
13
+ // holding without inferring it from one example.
14
+ //
15
+ // `view` is the discriminator and is always present - that is the part a reader
16
+ // must be able to rely on, so it is the part declared exactly. Item internals
17
+ // are left open on purpose: a schema that promises fields the payload sometimes
18
+ // omits is a claim that is sometimes false, and the reader trusting it is the
19
+ // model deciding what to tell a guest.
20
+ /**
21
+ * ⚠️ EACH STAY IS BOOKED ON ITS OWN (0.79.9, the OpenAI scan of 11-20 on H World: "this tool's
22
+ * description appears to claim capabilities that do not match its behavior"). The pay-at-hotel
23
+ * descriptions said "All of the trip is booked or none of it", while `request_*_booking` has
24
+ * booked what it could and named the rest since 2026-10-14 (robin: `failed`, each still in the
25
+ * trip, with why) - the words now say what the code does.
26
+ */
27
+ export const STAYS_ON_THEIR_OWN = 'Each stay is booked on its own: one that cannot be is named in the answer, with why, and stays in the trip while the others are booked.';
28
+ export const OBJ = { type: 'object' };
29
+ export const ARR = { type: 'array', items: { type: 'object' } };
30
+ /**
31
+ * A list of names - cities, currencies, a comparison's row labels. ⚠️ Declared
32
+ * as ARR (objects) since the first build while the answers carried strings: a
33
+ * host validating `structuredContent` against `outputSchema`, as the MCP spec
34
+ * has a client do, would refuse every city list (2026-10-08).
35
+ */
36
+ export const STRS = { type: 'array', items: { type: 'string' } };
37
+ export const STR = { type: 'string' };
38
+ export const BOOL = { type: 'boolean' };
39
+ /** A group's own type, as `common` hands it to the card (`BrandFonts`). */
40
+ const FONTS_SCHEMA = {
41
+ type: 'object',
42
+ properties: {
43
+ css: { type: 'array', items: { type: 'string' } },
44
+ display: STR,
45
+ body: STR,
46
+ numeric: STR,
47
+ },
48
+ required: ['css'],
49
+ additionalProperties: false,
50
+ };
51
+ /** A hotel, with the fields a card decides on declared. */
52
+ const HOTEL = { type: 'object', properties: { sellsHourly: BOOL } };
53
+ export const HOTELS = { type: 'array', items: HOTEL };
54
+ export const TRIP_SCHEMA = {
55
+ type: 'object',
56
+ properties: {
57
+ view: { enum: ['trip', 'needs-dates', 'error'] },
58
+ brand: STR,
59
+ toolNames: OBJ,
60
+ bookingMode: STR,
61
+ vocab: OBJ,
62
+ demo: BOOL,
63
+ demoNote: STR,
64
+ lines: ARR,
65
+ stay: OBJ,
66
+ /** Why the room could not go in, as words (`why`) and as a code (`NoRoomsCode`). */
67
+ why: STR,
68
+ whyCode: STR,
69
+ whyArgs: OBJ,
70
+ subtotal: STR,
71
+ taxesAndFees: STR,
72
+ total: STR,
73
+ /** Which of a room type's rates a room named by its type was put in as - the text's first line. */
74
+ took: STR,
75
+ /** Who is signed in, on every payload. */
76
+ member: OBJ,
77
+ /** What the tier took off THIS trip, and what it earns. */
78
+ memberSaving: OBJ,
79
+ /** The coupon taken off, the one asked for and refused, and every one the member holds. */
80
+ coupon: OBJ,
81
+ couponRefused: OBJ,
82
+ coupons: ARR,
83
+ days: ARR,
84
+ dropped: ARR,
85
+ /** A name that fits more than one hotel: the ones it fits (`namesLike`). */
86
+ candidates: ARR,
87
+ /** The trip as this answer drew it - the card sends it back with its booking form (`stampOf`). */
88
+ stamp: STR,
89
+ },
90
+ required: ['view'],
91
+ };
92
+ export const CANCEL_SCHEMA = {
93
+ type: 'object',
94
+ properties: {
95
+ view: { enum: ['cancellation-preview', 'cancelled', 'booking-not-found', 'error'] },
96
+ /** The fee is not known before the group cancels: `rule` is its terms and no fee is said. */
97
+ feeUnknown: BOOL,
98
+ /** The group answered with terms the guest has not agreed to: `rule` is ours, not the group's (0.74.5). */
99
+ termsNew: BOOL,
100
+ error: STR,
101
+ detail: STR,
102
+ groups: ARR,
103
+ /** The coupon the booking used and whether cancelling gives it back. */
104
+ coupon: OBJ,
105
+ brand: STR,
106
+ toolNames: OBJ,
107
+ bookingMode: STR,
108
+ demo: BOOL,
109
+ demoNote: STR,
110
+ booking: OBJ,
111
+ hotelName: STR,
112
+ hotelNames: OBJ,
113
+ stay: OBJ,
114
+ terms: ARR,
115
+ demoHold: BOOL,
116
+ addOnsFree: BOOL,
117
+ fee: STR,
118
+ /** What the booking being cancelled came to, taxes in - the fee is read against it. */
119
+ bookingTotal: STR,
120
+ refund: STR,
121
+ rule: STR,
122
+ freeUntil: STR,
123
+ cancellable: BOOL,
124
+ /**
125
+ * What was paid here in advance and what cancelling now gives back of it -
126
+ * only on a booking paid by card or UnionPay that can be cancelled (`PaidFacts`).
127
+ */
128
+ payment: {
129
+ type: 'object',
130
+ properties: {
131
+ method: { enum: ['card', 'unionpay'] },
132
+ amount: STR,
133
+ refund: { enum: ['all', 'part', 'none'] },
134
+ refundAmount: STR,
135
+ },
136
+ required: ['method', 'amount', 'refund'],
137
+ },
138
+ /** The terms as facts, for the card to say in the guest's language (`CancellationPreview`). */
139
+ feeIsCap: BOOL,
140
+ reason: STR,
141
+ steps: ARR,
142
+ /** Paid, at a group that refunds: confirming also asks all of `amount` back (0.74.2). */
143
+ refundWithCancel: {
144
+ type: 'object',
145
+ properties: { amount: STR, supplier: STR },
146
+ required: ['amount'],
147
+ },
148
+ },
149
+ required: ['view'],
150
+ };
151
+ /** Both halves of a change answer with the same payload, like the cancellation pair. */
152
+ export const CHANGE_SCHEMA = {
153
+ type: 'object',
154
+ properties: {
155
+ view: { enum: ['change-preview', 'changed', 'booking-not-found'] },
156
+ brand: STR,
157
+ toolNames: OBJ,
158
+ bookingMode: STR,
159
+ demo: BOOL,
160
+ demoNote: STR,
161
+ booking: OBJ,
162
+ /** What it holds now, and what it would hold. Both priced by the server. */
163
+ from: OBJ,
164
+ to: OBJ,
165
+ difference: STR,
166
+ /** True when the difference is money back rather than money owed. */
167
+ refundDue: BOOL,
168
+ changeable: BOOL,
169
+ roomsLeft: { type: 'number' },
170
+ rule: STR,
171
+ },
172
+ required: ['view'],
173
+ };
174
+ /**
175
+ * The output schemas with what this backend never fills taken out.
176
+ *
177
+ * ⚠️ A SCHEMA PROMISES. A Huazhu hotel's still promised its add-ons and
178
+ * policies, and every trip a member badge and saving (2026-10-05 audit) -
179
+ * fields no answer there ever carries.
180
+ */
181
+ export const outputSchemasFor = (schemas, caps, lang, also = {}) => {
182
+ const gone = [
183
+ ...(caps.members ? [] : ['member', 'memberSaving']),
184
+ ...(caps.extras ? [] : ['extras']),
185
+ ...(caps.policies === false ? ['policies'] : []),
186
+ ];
187
+ if (!gone.length &&
188
+ !caps.hourly &&
189
+ !lang &&
190
+ !also.logoDark &&
191
+ !also.logoByLang &&
192
+ !also.accent &&
193
+ !also.primary &&
194
+ !also.fonts &&
195
+ !also.homeImage &&
196
+ !also.brandNames)
197
+ return schemas;
198
+ return Object.fromEntries(Object.entries(schemas).map(([name, schema]) => {
199
+ const s = schema;
200
+ if (!s?.properties)
201
+ return [name, schema];
202
+ const properties = { ...s.properties };
203
+ for (const k of gone)
204
+ delete properties[k];
205
+ // On every answer, as `common` puts it: rooms by the hour are sold here.
206
+ if (caps.hourly)
207
+ properties.hourly = BOOL;
208
+ // On every answer too: the language the card draws its own words in.
209
+ if (lang)
210
+ properties.lang = { enum: ['zh', 'en'] };
211
+ // And the dark page's logo, where the group gave one.
212
+ if (also.logoDark)
213
+ properties.logoDarkUrl = STR;
214
+ // And its logo by the card's language, where it has more than one (`server.logoByLang`).
215
+ if (also.logoByLang)
216
+ properties.logoByLang = OBJ;
217
+ // And the group's own name in other languages, where its deployment gives them.
218
+ if (also.brandNames)
219
+ properties.brandNames = OBJ;
220
+ // And the group's own colour, where its deployment gives one.
221
+ if (also.accent)
222
+ properties.accent = { type: 'string', pattern: '^#[0-9a-fA-F]{6}$' };
223
+ // And its primary colour, with the shades its own site uses.
224
+ if (also.primary) {
225
+ const hex = { type: 'string', pattern: '^#[0-9a-fA-F]{6}$' };
226
+ properties.primary = {
227
+ type: 'object',
228
+ properties: {
229
+ color: hex,
230
+ hover: hex,
231
+ press: hex,
232
+ ...(also.primaryDark ? { dark: hex } : {}),
233
+ },
234
+ required: ['color'],
235
+ additionalProperties: false,
236
+ };
237
+ }
238
+ // And its own type, where its deployment names it.
239
+ if (also.fonts)
240
+ properties.fonts = FONTS_SCHEMA;
241
+ // And the one picture on its home, where its deployment gives one.
242
+ if (also.homeImage)
243
+ properties.homeImage = STR;
244
+ return [name, { ...s, properties }];
245
+ }));
246
+ };
247
+ /** A hotel's page - what get_hotel answers, and the list too where a deployment has one hotel. */
248
+ export const HOTEL_PAGE = {
249
+ hotel: HOTEL,
250
+ stay: OBJ,
251
+ rooms: ARR,
252
+ /** True when no dates were given: the card asks for them instead of showing rooms. */
253
+ needsDates: BOOL,
254
+ /** How many rooms of one type the list was filtered to. */
255
+ rooms_wanted: { type: 'number' },
256
+ /** Signed in: whose rate the prices are, said as the text says it (`said`). */
257
+ memberRates: OBJ,
258
+ noRooms: STR,
259
+ /** `noRooms` as a code (`NoRoomsCode`) and what it holds, for a card to say in the guest's language. */
260
+ noRoomsCode: STR,
261
+ noRoomsArgs: OBJ,
262
+ extras: ARR,
263
+ policies: ARR,
264
+ /** Arrivals a few days either side, each re-quoted for the same nights - what the date picker prices its days from. */
265
+ dates: ARR,
266
+ /**
267
+ * The room filters this hotel's rooms offer, each with how many rooms (rates)
268
+ * it keeps - `{ key, count }`, `key` one of `breakfast`, `king`, `twin`,
269
+ * `freeCancellation` (always here, `count` 0 where no room has it) and
270
+ * `window`, `payAtHotel`, `payOnline`, `family` (here only where some rooms
271
+ * have it and some do not).
272
+ */
273
+ roomFilters: ARR,
274
+ /** The filters the call asked for, as the same keys - the card opens with these selected. */
275
+ activeFilters: STRS,
276
+ /** Only where the client draws cards: the hotels, or the rooms, are on the card - `ON_CARD`. */
277
+ cardShows: STR,
278
+ /**
279
+ * Room types with no room to book for these nights (none left, or fewer
280
+ * than the rooms asked for): `{ id, name, names?, sleeps, ..., left? }`, no
281
+ * price. The card draws them muted at the end of the list, so a type the
282
+ * guest saw is said to be sold out and not left out. Absent where there are
283
+ * none - and never in what the assistant is told.
284
+ */
285
+ soldOut: ARR,
286
+ /**
287
+ * Where some rates are listed but not booked here (`Room.notSoldHere`, paid
288
+ * in advance on a deployment that takes no payment): what that means and
289
+ * what to offer - the same sentence as the text.
290
+ */
291
+ notSoldHere: STR,
292
+ };
293
+ /**
294
+ * What request_booking answers - and book_picked_room, which books the same way
295
+ * from the picked room (`direct`, below).
296
+ */
297
+ export const BOOKING_SCHEMA = {
298
+ type: 'object',
299
+ properties: {
300
+ // `trip`: nothing was booked and the trip is shown again - its price
301
+ // moved, or (in a market) it holds two groups' stays.
302
+ // `terms`: a group sent its booking terms back for the GUEST to agree to - the
303
+ // stay is neither booked nor failed yet (`terms`, `termsSaid`).
304
+ view: { enum: ['booking', 'needs-guest', 'empty-trip', 'error', 'trip', 'terms'] },
305
+ /** `coupon`: nothing was booked because the coupon asked for cannot be used (`couponRefused`). */
306
+ notBooked: STR,
307
+ /** `terms`: the terms waiting for the guest, word for word (`termsOf`). */
308
+ terms: ARR,
309
+ /** `terms`: the sentence that says the guest agrees to them themselves, as the text says it. */
310
+ termsSaid: STR,
311
+ /** `error`: why, as a code (`BOOKING_REFUSALS` or 'card-only') and in the guest's words. */
312
+ error: STR,
313
+ detail: STR,
314
+ /** `needs-guest`: what the booking still needs, in words ('a name', 'a complete email', …). */
315
+ missing: STRS,
316
+ /** `needs-guest`: the email given was hidden (「•」) or not a whole address - turned away (`wholeEmail`). */
317
+ emailRefused: BOOL,
318
+ /** A sign-in refusal: the groups the guest must sign in to, `{ code, name, names? }`. */
319
+ groups: ARR,
320
+ coupon: OBJ,
321
+ couponRefused: OBJ,
322
+ coupons: ARR,
323
+ brand: STR,
324
+ toolNames: OBJ,
325
+ bookingMode: STR,
326
+ demo: BOOL,
327
+ demoNote: STR,
328
+ booking: OBJ,
329
+ /** Always false here: this connector holds rooms and takes no money. */
330
+ paid: BOOL,
331
+ holdUntil: STR,
332
+ total: STR,
333
+ /** Each preference written out as what it is - something asked for, not held. */
334
+ requested: ARR,
335
+ /** An accessible room was asked for, which this booking does not reserve. */
336
+ accessibility: BOOL,
337
+ /** One per stay, when the trip held several. */
338
+ bookings: ARR,
339
+ /** What all of `bookings` come to, where they are in one currency (the card's first screen). */
340
+ totalAll: STR,
341
+ /**
342
+ * The stays that could not be booked when the others were - each with
343
+ * why, still in the trip, and what could be booked instead (robin,
344
+ * 2026-10-14).
345
+ */
346
+ failed: ARR,
347
+ /**
348
+ * The same stays for the same guest asked for again within minutes: the
349
+ * booking made then is the answer, and nothing new was booked.
350
+ */
351
+ repeat: BOOL,
352
+ /** A form whose room is no longer the one picked: the pick that would put it back (`pickChanged`). */
353
+ again: OBJ,
354
+ /** Of `bookings`, the ids asked for minutes before, when the others are new (`BookingResult.reused`). */
355
+ repeated: STRS,
356
+ /** The coupon asked for was not used: the booking returned was made before, without it (`couponNotUsedOf`). */
357
+ couponNotUsed: OBJ,
358
+ /** `trip`, drawn again: see `stampOf`. */
359
+ stamp: STR,
360
+ /** The trip changed after the card that sent the form was drawn, so nothing was booked (`stampOf`). */
361
+ tripChanged: BOOL,
362
+ /** Two stays at two hotels on the same nights, each with what the text says of it (`overlapsOf`). */
363
+ overlaps: ARR,
364
+ },
365
+ required: ['view'],
366
+ };
367
+ /**
368
+ * ⚠️ ONLY WHERE THE SHOP'S NAMES EXIST (`data.otaless.shop`): its two tools' schemas, and the
369
+ * shop views a bookings list and a cancellation may also answer with. Everywhere else the schemas
370
+ * are the ones above, untouched.
371
+ */
372
+ export const buildOutputSchemas = (n) => {
373
+ const base = baseOutputSchemas(n);
374
+ if (!n.listShopItems && !n.cardAddons)
375
+ return base;
376
+ // Only the add-ons card tool (no shop): its own schema, and nothing else touched.
377
+ if (!n.listShopItems)
378
+ return { ...base, ...shopSchemas(n) };
379
+ const widen = (name, views, more) => {
380
+ const s = base[name];
381
+ if (!s)
382
+ return;
383
+ base[name] = {
384
+ ...s,
385
+ properties: {
386
+ ...s.properties,
387
+ view: { enum: [...(s.properties.view?.enum ?? []), ...views] },
388
+ ...more,
389
+ },
390
+ };
391
+ };
392
+ widen(n.listBookings, [], {
393
+ shopOrders: ARR,
394
+ shopOrdersUnavailable: BOOL,
395
+ shopOrdersNeedShopSignIn: BOOL,
396
+ });
397
+ const cancelMore = {
398
+ shopOrder: OBJ,
399
+ kind: STR,
400
+ charged: STR,
401
+ refund: STR,
402
+ refundMinor: { type: 'number' },
403
+ shopSaidMinor: { type: 'number' },
404
+ pointsTakenBack: BOOL,
405
+ until: STR,
406
+ toolToConfirm: STR,
407
+ done: STR,
408
+ };
409
+ const cancelViews = ['shop-order-preview', 'shop-order-done', 'shop-order-unknown'];
410
+ widen(n.previewCancellation, cancelViews, cancelMore);
411
+ widen(n.cancelBooking, cancelViews, cancelMore);
412
+ return { ...base, ...shopSchemas(n) };
413
+ };
414
+ /** The shop tools' answers. */
415
+ const shopSchemas = (n) => ({
416
+ ...(n.cardAddons
417
+ ? {
418
+ [n.cardAddons]: {
419
+ type: 'object',
420
+ properties: {
421
+ view: { enum: ['addons', 'error'] },
422
+ brand: STR,
423
+ toolNames: OBJ,
424
+ bookingMode: STR,
425
+ addonsView: OBJ,
426
+ addonResult: OBJ,
427
+ error: STR,
428
+ detail: STR,
429
+ },
430
+ required: ['view'],
431
+ },
432
+ }
433
+ : {}),
434
+ ...(n.listShopItems
435
+ ? {
436
+ [n.listShopItems]: {
437
+ type: 'object',
438
+ properties: {
439
+ view: { enum: ['shop-items', 'shop-item', 'shop-item-not-found', 'error'] },
440
+ brand: STR,
441
+ toolNames: OBJ,
442
+ bookingMode: STR,
443
+ items: ARR,
444
+ item: OBJ,
445
+ count: { type: 'number' },
446
+ buyOpen: BOOL,
447
+ query: STR,
448
+ error: STR,
449
+ detail: STR,
450
+ },
451
+ required: ['view'],
452
+ },
453
+ }
454
+ : {}),
455
+ ...(n.listShopOrders
456
+ ? {
457
+ [n.listShopOrders]: {
458
+ type: 'object',
459
+ properties: {
460
+ view: { enum: ['shop-orders', 'error'] },
461
+ brand: STR,
462
+ toolNames: OBJ,
463
+ bookingMode: STR,
464
+ shopOrders: ARR,
465
+ count: { type: 'number' },
466
+ counts: OBJ,
467
+ timesNote: STR,
468
+ error: STR,
469
+ detail: STR,
470
+ },
471
+ required: ['view'],
472
+ },
473
+ }
474
+ : {}),
475
+ ...(n.buyShopItem
476
+ ? {
477
+ [n.buyShopItem]: {
478
+ type: 'object',
479
+ properties: {
480
+ view: { enum: ['shop-buy', 'addon-confirm', 'error'] },
481
+ brand: STR,
482
+ toolNames: OBJ,
483
+ bookingMode: STR,
484
+ confirm: OBJ,
485
+ outcome: STR,
486
+ order: OBJ,
487
+ checkoutUrl: STR,
488
+ checkoutHost: STR,
489
+ now: OBJ,
490
+ cancelled: BOOL,
491
+ needsPerson: BOOL,
492
+ overShown: BOOL,
493
+ charged: STR,
494
+ orderId: STR,
495
+ error: STR,
496
+ detail: STR,
497
+ },
498
+ required: ['view'],
499
+ },
500
+ }
501
+ : {}),
502
+ });
503
+ //# sourceMappingURL=output-schemas.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"output-schemas.js","sourceRoot":"","sources":["../../src/tools/output-schemas.ts"],"names":[],"mappings":"AAEA,OAAO,EAAE,iBAAiB,EAAE,MAAM,0BAA0B,CAAC;AAG7D;;;;GAIG;AACH,MAAM,CAAC,MAAM,uBAAuB,GAClC,ojBAAojB,CAAC;AACvjB,+DAA+D;AAC/D,MAAM,CAAC,MAAM,uBAAuB,GAClC,uUAAuU,CAAC;AAE1U,8FAA8F;AAC9F,MAAM,CAAC,MAAM,iBAAiB,GAAG,GAAG,CAAC;AAErC,6EAA6E;AAC7E,iDAAiD;AACjD,EAAE;AACF,gFAAgF;AAChF,8EAA8E;AAC9E,gFAAgF;AAChF,8EAA8E;AAC9E,uCAAuC;AACvC;;;;;;GAMG;AACH,MAAM,CAAC,MAAM,kBAAkB,GAC7B,yIAAyI,CAAC;AAC5I,MAAM,CAAC,MAAM,GAAG,GAAG,EAAE,IAAI,EAAE,QAAQ,EAAW,CAAC;AAC/C,MAAM,CAAC,MAAM,GAAG,GAAG,EAAE,IAAI,EAAE,OAAO,EAAE,KAAK,EAAE,EAAE,IAAI,EAAE,QAAQ,EAAE,EAAW,CAAC;AACzE;;;;;GAKG;AACH,MAAM,CAAC,MAAM,IAAI,GAAG,EAAE,IAAI,EAAE,OAAO,EAAE,KAAK,EAAE,EAAE,IAAI,EAA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