@hyperscale0/udl 1.0.0-alpha.1
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.
- package/AUTHORS +8 -0
- package/CHANGELOG.md +36 -0
- package/LICENSE +661 -0
- package/LICENSING.md +51 -0
- package/README.md +163 -0
- package/SECURITY.md +42 -0
- package/TRADEMARKS.md +35 -0
- package/conformance/README.md +79 -0
- package/conformance/invalid/blank-title.expected.json +10 -0
- package/conformance/invalid/blank-title.udl +50 -0
- package/conformance/invalid/depth-budget.expected.json +10 -0
- package/conformance/invalid/depth-budget.udl +49 -0
- package/conformance/invalid/format-version.expected.json +10 -0
- package/conformance/invalid/format-version.udl +50 -0
- package/conformance/invalid/invalid-utf8.expected.json +10 -0
- package/conformance/invalid/invalid-utf8.udl +1 -0
- package/conformance/invalid/malformed-json.expected.json +10 -0
- package/conformance/invalid/malformed-json.udl +1 -0
- package/conformance/invalid/missing-create-verb.expected.json +10 -0
- package/conformance/invalid/missing-create-verb.udl +45 -0
- package/conformance/invalid/not-an-object.expected.json +10 -0
- package/conformance/invalid/not-an-object.udl +1 -0
- package/conformance/invalid/noun-id-not-snake-case.expected.json +10 -0
- package/conformance/invalid/noun-id-not-snake-case.udl +50 -0
- package/conformance/invalid/unknown-key.expected.json +10 -0
- package/conformance/invalid/unknown-key.udl +51 -0
- package/conformance/invalid/unreachable-state.expected.json +10 -0
- package/conformance/invalid/unreachable-state.udl +51 -0
- package/conformance/invalid/verb-without-transition.expected.json +10 -0
- package/conformance/invalid/verb-without-transition.udl +55 -0
- package/conformance/valid/cards.expected.json +5 -0
- package/conformance/valid/cards.udl +1092 -0
- package/conformance/valid/commerce-escrow.expected.json +5 -0
- package/conformance/valid/commerce-escrow.udl +1011 -0
- package/conformance/valid/hand-edited.expected.json +5 -0
- package/conformance/valid/hand-edited.udl +1 -0
- package/conformance/valid/insured-car-marketplace.expected.json +5 -0
- package/conformance/valid/insured-car-marketplace.udl +831 -0
- package/conformance/valid/insured-travel.expected.json +5 -0
- package/conformance/valid/insured-travel.udl +2621 -0
- package/conformance/valid/minimal.expected.json +5 -0
- package/conformance/valid/minimal.udl +50 -0
- package/conformance/valid/protection.expected.json +5 -0
- package/conformance/valid/protection.udl +1136 -0
- package/dist/canonical.d.ts +2 -0
- package/dist/canonical.d.ts.map +1 -0
- package/dist/canonical.js +35 -0
- package/dist/canonical.js.map +1 -0
- package/dist/cli.d.ts +3 -0
- package/dist/cli.d.ts.map +1 -0
- package/dist/cli.js +138 -0
- package/dist/cli.js.map +1 -0
- package/dist/duration.d.ts +3 -0
- package/dist/duration.d.ts.map +1 -0
- package/dist/duration.js +23 -0
- package/dist/duration.js.map +1 -0
- package/dist/evolution.d.ts +63 -0
- package/dist/evolution.d.ts.map +1 -0
- package/dist/evolution.js +345 -0
- package/dist/evolution.js.map +1 -0
- package/dist/finance.d.ts +53 -0
- package/dist/finance.d.ts.map +1 -0
- package/dist/finance.js +511 -0
- package/dist/finance.js.map +1 -0
- package/dist/index.d.ts +11 -0
- package/dist/index.d.ts.map +1 -0
- package/dist/index.js +8 -0
- package/dist/index.js.map +1 -0
- package/dist/limits.d.ts +33 -0
- package/dist/limits.d.ts.map +1 -0
- package/dist/limits.js +33 -0
- package/dist/limits.js.map +1 -0
- package/dist/parser.d.ts +4 -0
- package/dist/parser.d.ts.map +1 -0
- package/dist/parser.js +54 -0
- package/dist/parser.js.map +1 -0
- package/dist/schema.d.ts +757 -0
- package/dist/schema.d.ts.map +1 -0
- package/dist/schema.js +281 -0
- package/dist/schema.js.map +1 -0
- package/dist/validation.d.ts +64 -0
- package/dist/validation.d.ts.map +1 -0
- package/dist/validation.js +1323 -0
- package/dist/validation.js.map +1 -0
- package/package.json +84 -0
- package/spec/README.md +137 -0
- package/spec/udl.schema.json +1019 -0
- package/src/canonical.ts +41 -0
- package/src/cli.ts +148 -0
- package/src/duration.ts +26 -0
- package/src/evolution.ts +587 -0
- package/src/finance.ts +775 -0
- package/src/index.ts +59 -0
- package/src/limits.ts +32 -0
- package/src/parser.ts +61 -0
- package/src/schema.ts +339 -0
- package/src/validation.ts +2053 -0
|
@@ -0,0 +1,2621 @@
|
|
|
1
|
+
{
|
|
2
|
+
"nouns": [
|
|
3
|
+
{
|
|
4
|
+
"description": "A flight booking opens as a hold against a flight itinerary subject with no money moved. Confirming it runs a just-in-time air carrier decision under a deadline, then settles the fare from the traveler into a dedicated fare reserve. An unconfirmed hold expires on its deadline, cancellation unwinds through a quote then a confirm under the void-window penalty schedule, and completion at departure pays the reserved fare to the operator.",
|
|
5
|
+
"fields": {
|
|
6
|
+
"bookingNote": {
|
|
7
|
+
"maxLength": 180,
|
|
8
|
+
"minLength": 1,
|
|
9
|
+
"type": "string"
|
|
10
|
+
},
|
|
11
|
+
"currency": {
|
|
12
|
+
"description": "ISO 4217 currency code",
|
|
13
|
+
"maxLength": 3,
|
|
14
|
+
"minLength": 3,
|
|
15
|
+
"pattern": "^[A-Z]{3}$",
|
|
16
|
+
"type": "string"
|
|
17
|
+
},
|
|
18
|
+
"departsAt": {
|
|
19
|
+
"format": "hyperscale-date-time",
|
|
20
|
+
"type": "string"
|
|
21
|
+
},
|
|
22
|
+
"fareAmount": {
|
|
23
|
+
"description": "Positive minor-unit integer amount serialized as a string (at most 18 digits)",
|
|
24
|
+
"pattern": "^[1-9][0-9]{0,17}$",
|
|
25
|
+
"type": "string"
|
|
26
|
+
},
|
|
27
|
+
"holdExpiresAt": {
|
|
28
|
+
"format": "hyperscale-date-time",
|
|
29
|
+
"type": "string"
|
|
30
|
+
},
|
|
31
|
+
"operatorAccountId": {
|
|
32
|
+
"description": "Hyperscale account ID",
|
|
33
|
+
"pattern": "^acct_(sandbox|live)_[a-z0-9]{8,64}$",
|
|
34
|
+
"type": "string",
|
|
35
|
+
"x-hyperscale-reference-filter": {
|
|
36
|
+
"column": "role",
|
|
37
|
+
"values": [
|
|
38
|
+
"customer_balance"
|
|
39
|
+
]
|
|
40
|
+
}
|
|
41
|
+
},
|
|
42
|
+
"travelPackageId": {
|
|
43
|
+
"description": "Travel package this booking is a leg of",
|
|
44
|
+
"pattern": "^tpkg_(sandbox|live)_[a-z0-9]{8,64}$",
|
|
45
|
+
"type": "string"
|
|
46
|
+
},
|
|
47
|
+
"travelerAccountId": {
|
|
48
|
+
"description": "Hyperscale account ID",
|
|
49
|
+
"pattern": "^acct_(sandbox|live)_[a-z0-9]{8,64}$",
|
|
50
|
+
"type": "string",
|
|
51
|
+
"x-hyperscale-reference-filter": {
|
|
52
|
+
"column": "role",
|
|
53
|
+
"values": [
|
|
54
|
+
"customer_balance"
|
|
55
|
+
]
|
|
56
|
+
}
|
|
57
|
+
}
|
|
58
|
+
},
|
|
59
|
+
"id": "flight_booking",
|
|
60
|
+
"idPrefix": "fbkg",
|
|
61
|
+
"lifecycle": {
|
|
62
|
+
"initial": "held",
|
|
63
|
+
"states": [
|
|
64
|
+
"held",
|
|
65
|
+
"released",
|
|
66
|
+
"confirmed",
|
|
67
|
+
"cancel_quoted",
|
|
68
|
+
"completed",
|
|
69
|
+
"canceled",
|
|
70
|
+
"penalty_collected",
|
|
71
|
+
"package_canceled",
|
|
72
|
+
"expired"
|
|
73
|
+
],
|
|
74
|
+
"transitions": {
|
|
75
|
+
"amend_collect": {
|
|
76
|
+
"from": [
|
|
77
|
+
"confirmed"
|
|
78
|
+
],
|
|
79
|
+
"to": "confirmed"
|
|
80
|
+
},
|
|
81
|
+
"amend_fee": {
|
|
82
|
+
"from": [
|
|
83
|
+
"confirmed"
|
|
84
|
+
],
|
|
85
|
+
"to": "confirmed"
|
|
86
|
+
},
|
|
87
|
+
"amend_refund": {
|
|
88
|
+
"from": [
|
|
89
|
+
"confirmed"
|
|
90
|
+
],
|
|
91
|
+
"to": "confirmed"
|
|
92
|
+
},
|
|
93
|
+
"cancel_confirm": {
|
|
94
|
+
"from": [
|
|
95
|
+
"cancel_quoted"
|
|
96
|
+
],
|
|
97
|
+
"to": "canceled"
|
|
98
|
+
},
|
|
99
|
+
"cancel_quote": {
|
|
100
|
+
"from": [
|
|
101
|
+
"confirmed"
|
|
102
|
+
],
|
|
103
|
+
"to": "cancel_quoted"
|
|
104
|
+
},
|
|
105
|
+
"collect_penalty": {
|
|
106
|
+
"from": [
|
|
107
|
+
"canceled"
|
|
108
|
+
],
|
|
109
|
+
"to": "penalty_collected"
|
|
110
|
+
},
|
|
111
|
+
"complete": {
|
|
112
|
+
"from": [
|
|
113
|
+
"confirmed",
|
|
114
|
+
"cancel_quoted"
|
|
115
|
+
],
|
|
116
|
+
"to": "completed"
|
|
117
|
+
},
|
|
118
|
+
"confirm": {
|
|
119
|
+
"from": [
|
|
120
|
+
"held"
|
|
121
|
+
],
|
|
122
|
+
"to": "confirmed"
|
|
123
|
+
},
|
|
124
|
+
"expire": {
|
|
125
|
+
"from": [
|
|
126
|
+
"held"
|
|
127
|
+
],
|
|
128
|
+
"to": "expired"
|
|
129
|
+
},
|
|
130
|
+
"package_cancel": {
|
|
131
|
+
"from": [
|
|
132
|
+
"confirmed",
|
|
133
|
+
"cancel_quoted"
|
|
134
|
+
],
|
|
135
|
+
"to": "package_canceled"
|
|
136
|
+
},
|
|
137
|
+
"release": {
|
|
138
|
+
"from": [
|
|
139
|
+
"held"
|
|
140
|
+
],
|
|
141
|
+
"to": "released"
|
|
142
|
+
}
|
|
143
|
+
}
|
|
144
|
+
},
|
|
145
|
+
"parties": {
|
|
146
|
+
"beneficiary": "operatorAccountId",
|
|
147
|
+
"payer": "travelerAccountId"
|
|
148
|
+
},
|
|
149
|
+
"required": [
|
|
150
|
+
"travelerAccountId",
|
|
151
|
+
"operatorAccountId",
|
|
152
|
+
"fareAmount",
|
|
153
|
+
"currency",
|
|
154
|
+
"holdExpiresAt",
|
|
155
|
+
"departsAt"
|
|
156
|
+
],
|
|
157
|
+
"subject": {
|
|
158
|
+
"kinds": [
|
|
159
|
+
"flight_itinerary"
|
|
160
|
+
]
|
|
161
|
+
},
|
|
162
|
+
"summary": "Held-then-confirmed flight purchase settled on a carrier decision.",
|
|
163
|
+
"title": "Flight booking",
|
|
164
|
+
"unwind": {
|
|
165
|
+
"confirm": "cancel_confirm",
|
|
166
|
+
"penalty": [
|
|
167
|
+
{
|
|
168
|
+
"bps": 0,
|
|
169
|
+
"withinOffset": "P1D"
|
|
170
|
+
},
|
|
171
|
+
{
|
|
172
|
+
"bps": 2500
|
|
173
|
+
}
|
|
174
|
+
],
|
|
175
|
+
"quote": "cancel_quote",
|
|
176
|
+
"refundDestinationField": "travelerAccountId",
|
|
177
|
+
"refundableField": "fareAmount"
|
|
178
|
+
},
|
|
179
|
+
"update": {
|
|
180
|
+
"fields": [
|
|
181
|
+
"departsAt",
|
|
182
|
+
"bookingNote"
|
|
183
|
+
],
|
|
184
|
+
"states": [
|
|
185
|
+
"held",
|
|
186
|
+
"confirmed"
|
|
187
|
+
]
|
|
188
|
+
},
|
|
189
|
+
"verbs": {
|
|
190
|
+
"amend_collect": {
|
|
191
|
+
"description": "Reprices a confirmed booking whose amended itinerary costs more: the traveler pays the fare difference to the operator directly and the booking stays confirmed. The fare reserve is untouched; it still pays out in full at departure. Pair with flight_booking.update for the itinerary fields and amend_fee for the reissue fee.",
|
|
192
|
+
"eventName": "flight_booking.amendment_collected",
|
|
193
|
+
"examples": [
|
|
194
|
+
{
|
|
195
|
+
"input": {
|
|
196
|
+
"amendmentNote": "Rebooked SV1024 to the evening departure",
|
|
197
|
+
"fareDifference": "24000"
|
|
198
|
+
},
|
|
199
|
+
"name": "collect_reissued_fare_increase"
|
|
200
|
+
}
|
|
201
|
+
],
|
|
202
|
+
"input": {
|
|
203
|
+
"additionalProperties": false,
|
|
204
|
+
"properties": {
|
|
205
|
+
"amendmentNote": {
|
|
206
|
+
"maxLength": 180,
|
|
207
|
+
"minLength": 1,
|
|
208
|
+
"type": "string"
|
|
209
|
+
},
|
|
210
|
+
"fareDifference": {
|
|
211
|
+
"description": "Positive minor-unit integer amount serialized as a string (at most 18 digits)",
|
|
212
|
+
"pattern": "^[1-9][0-9]{0,17}$",
|
|
213
|
+
"type": "string"
|
|
214
|
+
}
|
|
215
|
+
},
|
|
216
|
+
"required": [
|
|
217
|
+
"fareDifference",
|
|
218
|
+
"amendmentNote"
|
|
219
|
+
],
|
|
220
|
+
"type": "object"
|
|
221
|
+
},
|
|
222
|
+
"moves": [
|
|
223
|
+
{
|
|
224
|
+
"bind": {
|
|
225
|
+
"amount": {
|
|
226
|
+
"from": "input",
|
|
227
|
+
"path": "fareDifference"
|
|
228
|
+
},
|
|
229
|
+
"currency": {
|
|
230
|
+
"from": "instance",
|
|
231
|
+
"path": "fields.currency"
|
|
232
|
+
},
|
|
233
|
+
"destinationAccountId": {
|
|
234
|
+
"from": "instance",
|
|
235
|
+
"path": "fields.operatorAccountId"
|
|
236
|
+
},
|
|
237
|
+
"memo": {
|
|
238
|
+
"from": "input",
|
|
239
|
+
"path": "amendmentNote"
|
|
240
|
+
},
|
|
241
|
+
"sourceAccountId": {
|
|
242
|
+
"from": "instance",
|
|
243
|
+
"path": "fields.travelerAccountId"
|
|
244
|
+
},
|
|
245
|
+
"workspaceId": {
|
|
246
|
+
"from": "instance",
|
|
247
|
+
"path": "workspaceId"
|
|
248
|
+
}
|
|
249
|
+
},
|
|
250
|
+
"capture": {
|
|
251
|
+
"amendCollectTransferId": "transferId"
|
|
252
|
+
},
|
|
253
|
+
"key": "transfer",
|
|
254
|
+
"operation": "internal_transfer.create"
|
|
255
|
+
}
|
|
256
|
+
],
|
|
257
|
+
"steps": [],
|
|
258
|
+
"summary": "Collect an amended fare increase"
|
|
259
|
+
},
|
|
260
|
+
"amend_fee": {
|
|
261
|
+
"description": "Collects the operator's reissue fee for one amendment from the traveler, in either repricing direction. Declared as its own verb so a fee-free amendment simply never invokes it and an equal-fare reissue is a fee with no difference leg.",
|
|
262
|
+
"eventName": "flight_booking.amendment_fee_collected",
|
|
263
|
+
"examples": [
|
|
264
|
+
{
|
|
265
|
+
"input": {
|
|
266
|
+
"amendmentFee": "5000",
|
|
267
|
+
"amendmentNote": "Carrier reissue fee for the date change"
|
|
268
|
+
},
|
|
269
|
+
"name": "collect_reissue_fee"
|
|
270
|
+
}
|
|
271
|
+
],
|
|
272
|
+
"input": {
|
|
273
|
+
"additionalProperties": false,
|
|
274
|
+
"properties": {
|
|
275
|
+
"amendmentFee": {
|
|
276
|
+
"description": "Positive minor-unit integer amount serialized as a string (at most 18 digits)",
|
|
277
|
+
"pattern": "^[1-9][0-9]{0,17}$",
|
|
278
|
+
"type": "string"
|
|
279
|
+
},
|
|
280
|
+
"amendmentNote": {
|
|
281
|
+
"maxLength": 180,
|
|
282
|
+
"minLength": 1,
|
|
283
|
+
"type": "string"
|
|
284
|
+
}
|
|
285
|
+
},
|
|
286
|
+
"required": [
|
|
287
|
+
"amendmentFee",
|
|
288
|
+
"amendmentNote"
|
|
289
|
+
],
|
|
290
|
+
"type": "object"
|
|
291
|
+
},
|
|
292
|
+
"moves": [
|
|
293
|
+
{
|
|
294
|
+
"bind": {
|
|
295
|
+
"amount": {
|
|
296
|
+
"from": "input",
|
|
297
|
+
"path": "amendmentFee"
|
|
298
|
+
},
|
|
299
|
+
"currency": {
|
|
300
|
+
"from": "instance",
|
|
301
|
+
"path": "fields.currency"
|
|
302
|
+
},
|
|
303
|
+
"destinationAccountId": {
|
|
304
|
+
"from": "instance",
|
|
305
|
+
"path": "fields.operatorAccountId"
|
|
306
|
+
},
|
|
307
|
+
"memo": {
|
|
308
|
+
"from": "input",
|
|
309
|
+
"path": "amendmentNote"
|
|
310
|
+
},
|
|
311
|
+
"sourceAccountId": {
|
|
312
|
+
"from": "instance",
|
|
313
|
+
"path": "fields.travelerAccountId"
|
|
314
|
+
},
|
|
315
|
+
"workspaceId": {
|
|
316
|
+
"from": "instance",
|
|
317
|
+
"path": "workspaceId"
|
|
318
|
+
}
|
|
319
|
+
},
|
|
320
|
+
"capture": {
|
|
321
|
+
"amendFeeTransferId": "transferId"
|
|
322
|
+
},
|
|
323
|
+
"key": "transfer",
|
|
324
|
+
"operation": "internal_transfer.create"
|
|
325
|
+
}
|
|
326
|
+
],
|
|
327
|
+
"steps": [],
|
|
328
|
+
"summary": "Collect a flight amendment fee"
|
|
329
|
+
},
|
|
330
|
+
"amend_refund": {
|
|
331
|
+
"description": "Reprices a confirmed booking whose amended itinerary costs less: the operator refunds the fare difference to the traveler directly and the booking stays confirmed. The fare reserve is untouched, so the operator's departure payout still nets to the amended fare. Any reissue fee is collected separately by amend_fee.",
|
|
332
|
+
"eventName": "flight_booking.amendment_refunded",
|
|
333
|
+
"examples": [
|
|
334
|
+
{
|
|
335
|
+
"input": {
|
|
336
|
+
"amendmentNote": "Moved to the lower morning fare",
|
|
337
|
+
"fareDifference": "18500"
|
|
338
|
+
},
|
|
339
|
+
"name": "refund_reissued_fare_decrease"
|
|
340
|
+
}
|
|
341
|
+
],
|
|
342
|
+
"input": {
|
|
343
|
+
"additionalProperties": false,
|
|
344
|
+
"properties": {
|
|
345
|
+
"amendmentNote": {
|
|
346
|
+
"maxLength": 180,
|
|
347
|
+
"minLength": 1,
|
|
348
|
+
"type": "string"
|
|
349
|
+
},
|
|
350
|
+
"fareDifference": {
|
|
351
|
+
"description": "Positive minor-unit integer amount serialized as a string (at most 18 digits)",
|
|
352
|
+
"pattern": "^[1-9][0-9]{0,17}$",
|
|
353
|
+
"type": "string"
|
|
354
|
+
}
|
|
355
|
+
},
|
|
356
|
+
"required": [
|
|
357
|
+
"fareDifference",
|
|
358
|
+
"amendmentNote"
|
|
359
|
+
],
|
|
360
|
+
"type": "object"
|
|
361
|
+
},
|
|
362
|
+
"moves": [
|
|
363
|
+
{
|
|
364
|
+
"bind": {
|
|
365
|
+
"amount": {
|
|
366
|
+
"from": "input",
|
|
367
|
+
"path": "fareDifference"
|
|
368
|
+
},
|
|
369
|
+
"currency": {
|
|
370
|
+
"from": "instance",
|
|
371
|
+
"path": "fields.currency"
|
|
372
|
+
},
|
|
373
|
+
"destinationAccountId": {
|
|
374
|
+
"from": "instance",
|
|
375
|
+
"path": "fields.travelerAccountId"
|
|
376
|
+
},
|
|
377
|
+
"memo": {
|
|
378
|
+
"from": "input",
|
|
379
|
+
"path": "amendmentNote"
|
|
380
|
+
},
|
|
381
|
+
"sourceAccountId": {
|
|
382
|
+
"from": "instance",
|
|
383
|
+
"path": "fields.operatorAccountId"
|
|
384
|
+
},
|
|
385
|
+
"workspaceId": {
|
|
386
|
+
"from": "instance",
|
|
387
|
+
"path": "workspaceId"
|
|
388
|
+
}
|
|
389
|
+
},
|
|
390
|
+
"capture": {
|
|
391
|
+
"amendRefundTransferId": "transferId"
|
|
392
|
+
},
|
|
393
|
+
"key": "transfer",
|
|
394
|
+
"operation": "internal_transfer.create"
|
|
395
|
+
}
|
|
396
|
+
],
|
|
397
|
+
"steps": [],
|
|
398
|
+
"summary": "Refund an amended fare decrease"
|
|
399
|
+
},
|
|
400
|
+
"cancel_confirm": {
|
|
401
|
+
"description": "Unwinds the booking, refunding the fare minus the scheduled penalty from the fare reserve back to the traveler. The refund is repriced at confirm time into refs.unwindRefund; collect_penalty pays the retained remainder separately.",
|
|
402
|
+
"moves": [
|
|
403
|
+
{
|
|
404
|
+
"bind": {
|
|
405
|
+
"amount": {
|
|
406
|
+
"from": "instance",
|
|
407
|
+
"path": "refs.unwindRefund"
|
|
408
|
+
},
|
|
409
|
+
"currency": {
|
|
410
|
+
"from": "instance",
|
|
411
|
+
"path": "fields.currency"
|
|
412
|
+
},
|
|
413
|
+
"destinationAccountId": {
|
|
414
|
+
"from": "instance",
|
|
415
|
+
"path": "fields.travelerAccountId"
|
|
416
|
+
},
|
|
417
|
+
"sourceAccountId": {
|
|
418
|
+
"from": "instance",
|
|
419
|
+
"path": "refs.fareReserveAccountId"
|
|
420
|
+
},
|
|
421
|
+
"workspaceId": {
|
|
422
|
+
"from": "instance",
|
|
423
|
+
"path": "workspaceId"
|
|
424
|
+
}
|
|
425
|
+
},
|
|
426
|
+
"capture": {
|
|
427
|
+
"refundTransferId": "transferId"
|
|
428
|
+
},
|
|
429
|
+
"key": "transfer",
|
|
430
|
+
"operation": "internal_transfer.create"
|
|
431
|
+
}
|
|
432
|
+
],
|
|
433
|
+
"steps": [],
|
|
434
|
+
"summary": "Confirm a flight booking cancellation"
|
|
435
|
+
},
|
|
436
|
+
"cancel_quote": {
|
|
437
|
+
"description": "Parks the confirmed booking for cancellation and quotes the refund under the void-window penalty schedule. No money moves and the quote is advisory: the cancellation confirm reprices at its own clock.",
|
|
438
|
+
"moves": [],
|
|
439
|
+
"steps": [],
|
|
440
|
+
"summary": "Quote a flight booking cancellation"
|
|
441
|
+
},
|
|
442
|
+
"collect_penalty": {
|
|
443
|
+
"description": "Pays the computed retained cancellation penalty to the operator. Invoke only when cancel_confirm returns a positive refs.unwindPenalty.",
|
|
444
|
+
"eventName": "flight_booking.penalty_collected",
|
|
445
|
+
"moves": [
|
|
446
|
+
{
|
|
447
|
+
"bind": {
|
|
448
|
+
"amount": {
|
|
449
|
+
"from": "instance",
|
|
450
|
+
"path": "refs.unwindPenalty"
|
|
451
|
+
},
|
|
452
|
+
"currency": {
|
|
453
|
+
"from": "instance",
|
|
454
|
+
"path": "fields.currency"
|
|
455
|
+
},
|
|
456
|
+
"destinationAccountId": {
|
|
457
|
+
"from": "instance",
|
|
458
|
+
"path": "fields.operatorAccountId"
|
|
459
|
+
},
|
|
460
|
+
"sourceAccountId": {
|
|
461
|
+
"from": "instance",
|
|
462
|
+
"path": "refs.fareReserveAccountId"
|
|
463
|
+
},
|
|
464
|
+
"workspaceId": {
|
|
465
|
+
"from": "instance",
|
|
466
|
+
"path": "workspaceId"
|
|
467
|
+
}
|
|
468
|
+
},
|
|
469
|
+
"capture": {
|
|
470
|
+
"penaltyTransferId": "transferId"
|
|
471
|
+
},
|
|
472
|
+
"key": "transfer",
|
|
473
|
+
"operation": "internal_transfer.create"
|
|
474
|
+
}
|
|
475
|
+
],
|
|
476
|
+
"steps": [],
|
|
477
|
+
"summary": "Collect a flight cancellation penalty"
|
|
478
|
+
},
|
|
479
|
+
"complete": {
|
|
480
|
+
"description": "Closes a confirmed booking at departure and pays the reserved fare to the operator under the machine principal, even if a cancellation quote is parked un-acted. This is the operator's revenue event, fired by the maintenance loop under the departure due-condition.",
|
|
481
|
+
"due": {
|
|
482
|
+
"field": "departsAt"
|
|
483
|
+
},
|
|
484
|
+
"earnable": true,
|
|
485
|
+
"moves": [
|
|
486
|
+
{
|
|
487
|
+
"bind": {
|
|
488
|
+
"amount": {
|
|
489
|
+
"from": "instance",
|
|
490
|
+
"path": "fields.fareAmount"
|
|
491
|
+
},
|
|
492
|
+
"currency": {
|
|
493
|
+
"from": "instance",
|
|
494
|
+
"path": "fields.currency"
|
|
495
|
+
},
|
|
496
|
+
"destinationAccountId": {
|
|
497
|
+
"from": "instance",
|
|
498
|
+
"path": "fields.operatorAccountId"
|
|
499
|
+
},
|
|
500
|
+
"sourceAccountId": {
|
|
501
|
+
"from": "instance",
|
|
502
|
+
"path": "refs.fareReserveAccountId"
|
|
503
|
+
},
|
|
504
|
+
"workspaceId": {
|
|
505
|
+
"from": "instance",
|
|
506
|
+
"path": "workspaceId"
|
|
507
|
+
}
|
|
508
|
+
},
|
|
509
|
+
"capture": {
|
|
510
|
+
"farePayoutTransferId": "transferId"
|
|
511
|
+
},
|
|
512
|
+
"key": "transfer",
|
|
513
|
+
"operation": "internal_transfer.create"
|
|
514
|
+
}
|
|
515
|
+
],
|
|
516
|
+
"steps": [],
|
|
517
|
+
"summary": "Complete a flight booking"
|
|
518
|
+
},
|
|
519
|
+
"confirm": {
|
|
520
|
+
"deadline": {
|
|
521
|
+
"field": "holdExpiresAt"
|
|
522
|
+
},
|
|
523
|
+
"decision": {
|
|
524
|
+
"capability": "air_carrier",
|
|
525
|
+
"deadlineMs": 15000,
|
|
526
|
+
"onTimeout": "decline"
|
|
527
|
+
},
|
|
528
|
+
"description": "Runs a just-in-time air carrier decision under a deadline, then settles the fare from the traveler into the dedicated fare reserve and puts the booking in force. Refused once the hold expiry has passed, even if the expiry sweep has not fired yet.",
|
|
529
|
+
"moves": [
|
|
530
|
+
{
|
|
531
|
+
"bind": {
|
|
532
|
+
"amount": {
|
|
533
|
+
"from": "instance",
|
|
534
|
+
"path": "fields.fareAmount"
|
|
535
|
+
},
|
|
536
|
+
"currency": {
|
|
537
|
+
"from": "instance",
|
|
538
|
+
"path": "fields.currency"
|
|
539
|
+
},
|
|
540
|
+
"destinationAccountId": {
|
|
541
|
+
"from": "instance",
|
|
542
|
+
"path": "refs.fareReserveAccountId"
|
|
543
|
+
},
|
|
544
|
+
"sourceAccountId": {
|
|
545
|
+
"from": "instance",
|
|
546
|
+
"path": "fields.travelerAccountId"
|
|
547
|
+
},
|
|
548
|
+
"workspaceId": {
|
|
549
|
+
"from": "instance",
|
|
550
|
+
"path": "workspaceId"
|
|
551
|
+
}
|
|
552
|
+
},
|
|
553
|
+
"capture": {
|
|
554
|
+
"fareTransferId": "transferId"
|
|
555
|
+
},
|
|
556
|
+
"key": "transfer",
|
|
557
|
+
"operation": "internal_transfer.create"
|
|
558
|
+
}
|
|
559
|
+
],
|
|
560
|
+
"steps": [],
|
|
561
|
+
"summary": "Confirm a flight booking"
|
|
562
|
+
},
|
|
563
|
+
"create": {
|
|
564
|
+
"description": "Opens the booking as a hold against a flight itinerary subject at the quoted fare and provisions the dedicated fare reserve. No money moves until the booking confirms; the hold carries its own expiry deadline. A booking holding a leg of a packaged trip names its travel package, admitted only while that package is still draft or booked.",
|
|
565
|
+
"moves": [],
|
|
566
|
+
"requiresRefs": [
|
|
567
|
+
{
|
|
568
|
+
"field": "travelPackageId",
|
|
569
|
+
"optional": true,
|
|
570
|
+
"statuses": [
|
|
571
|
+
"draft",
|
|
572
|
+
"booked"
|
|
573
|
+
]
|
|
574
|
+
}
|
|
575
|
+
],
|
|
576
|
+
"steps": [
|
|
577
|
+
{
|
|
578
|
+
"bind": {
|
|
579
|
+
"currency": {
|
|
580
|
+
"from": "instance",
|
|
581
|
+
"path": "fields.currency"
|
|
582
|
+
},
|
|
583
|
+
"owner.id": {
|
|
584
|
+
"from": "instance",
|
|
585
|
+
"path": "workspaceId"
|
|
586
|
+
},
|
|
587
|
+
"owner.type": {
|
|
588
|
+
"from": "const",
|
|
589
|
+
"value": "workspace"
|
|
590
|
+
},
|
|
591
|
+
"role": {
|
|
592
|
+
"from": "const",
|
|
593
|
+
"value": "workspace_escrow"
|
|
594
|
+
},
|
|
595
|
+
"workspaceId": {
|
|
596
|
+
"from": "instance",
|
|
597
|
+
"path": "workspaceId"
|
|
598
|
+
}
|
|
599
|
+
},
|
|
600
|
+
"capture": {
|
|
601
|
+
"fareReserveAccountId": "accountId"
|
|
602
|
+
},
|
|
603
|
+
"operation": "account.escrow.provision"
|
|
604
|
+
}
|
|
605
|
+
],
|
|
606
|
+
"summary": "Hold a flight booking"
|
|
607
|
+
},
|
|
608
|
+
"expire": {
|
|
609
|
+
"description": "Ends an unconfirmed hold at its deadline. No money has moved, so this is a pure lifecycle transition fired by the maintenance loop under the hold-expiry due-condition.",
|
|
610
|
+
"due": {
|
|
611
|
+
"field": "holdExpiresAt"
|
|
612
|
+
},
|
|
613
|
+
"moves": [],
|
|
614
|
+
"requiresDrainedAccount": {
|
|
615
|
+
"path": "refs.fareReserveAccountId"
|
|
616
|
+
},
|
|
617
|
+
"steps": [],
|
|
618
|
+
"summary": "Expire a held flight booking"
|
|
619
|
+
},
|
|
620
|
+
"package_cancel": {
|
|
621
|
+
"description": "Fires under the machine principal for a leg of a cancelled travel package: refunds the full reserved fare to the traveler, penalty-free, because the cancellation is the package's, not the traveler's. Selectable once the hold window has passed (a confirmed leg is past it in practice); a held leg simply expires on its own deadline, and an already-flown (completed) booking is never cascade-cancelled.",
|
|
622
|
+
"due": {
|
|
623
|
+
"field": "holdExpiresAt",
|
|
624
|
+
"whenParentStatus": {
|
|
625
|
+
"nounId": "travel_package",
|
|
626
|
+
"refField": "travelPackageId",
|
|
627
|
+
"statuses": [
|
|
628
|
+
"cancelled"
|
|
629
|
+
]
|
|
630
|
+
}
|
|
631
|
+
},
|
|
632
|
+
"moves": [
|
|
633
|
+
{
|
|
634
|
+
"bind": {
|
|
635
|
+
"amount": {
|
|
636
|
+
"from": "instance",
|
|
637
|
+
"path": "fields.fareAmount"
|
|
638
|
+
},
|
|
639
|
+
"currency": {
|
|
640
|
+
"from": "instance",
|
|
641
|
+
"path": "fields.currency"
|
|
642
|
+
},
|
|
643
|
+
"destinationAccountId": {
|
|
644
|
+
"from": "instance",
|
|
645
|
+
"path": "fields.travelerAccountId"
|
|
646
|
+
},
|
|
647
|
+
"sourceAccountId": {
|
|
648
|
+
"from": "instance",
|
|
649
|
+
"path": "refs.fareReserveAccountId"
|
|
650
|
+
},
|
|
651
|
+
"workspaceId": {
|
|
652
|
+
"from": "instance",
|
|
653
|
+
"path": "workspaceId"
|
|
654
|
+
}
|
|
655
|
+
},
|
|
656
|
+
"capture": {
|
|
657
|
+
"packageRefundTransferId": "transferId"
|
|
658
|
+
},
|
|
659
|
+
"key": "transfer",
|
|
660
|
+
"operation": "internal_transfer.create"
|
|
661
|
+
}
|
|
662
|
+
],
|
|
663
|
+
"steps": [],
|
|
664
|
+
"summary": "Cancel a flight booking with its cancelled package"
|
|
665
|
+
},
|
|
666
|
+
"release": {
|
|
667
|
+
"description": "Closes a hold the traveler abandoned before confirmation. No money has moved, so this is a pure lifecycle transition.",
|
|
668
|
+
"moves": [],
|
|
669
|
+
"requiresDrainedAccount": {
|
|
670
|
+
"path": "refs.fareReserveAccountId"
|
|
671
|
+
},
|
|
672
|
+
"steps": [],
|
|
673
|
+
"summary": "Release a held flight booking"
|
|
674
|
+
}
|
|
675
|
+
}
|
|
676
|
+
},
|
|
677
|
+
{
|
|
678
|
+
"description": "A hotel stay opens as a hold against a lodging stay subject with no money moved. Confirming it runs a just-in-time lodging supplier decision under a deadline, then settles the rate from the guest into a dedicated rate reserve. An unconfirmed hold expires on its deadline, cancellation unwinds through a quote then a confirm under the free-cancel penalty schedule, and completion at checkout pays the reserved rate to the property.",
|
|
679
|
+
"fields": {
|
|
680
|
+
"checkInAt": {
|
|
681
|
+
"format": "hyperscale-date-time",
|
|
682
|
+
"type": "string"
|
|
683
|
+
},
|
|
684
|
+
"checkOutAt": {
|
|
685
|
+
"format": "hyperscale-date-time",
|
|
686
|
+
"type": "string"
|
|
687
|
+
},
|
|
688
|
+
"currency": {
|
|
689
|
+
"description": "ISO 4217 currency code",
|
|
690
|
+
"maxLength": 3,
|
|
691
|
+
"minLength": 3,
|
|
692
|
+
"pattern": "^[A-Z]{3}$",
|
|
693
|
+
"type": "string"
|
|
694
|
+
},
|
|
695
|
+
"guestAccountId": {
|
|
696
|
+
"description": "Hyperscale account ID",
|
|
697
|
+
"pattern": "^acct_(sandbox|live)_[a-z0-9]{8,64}$",
|
|
698
|
+
"type": "string",
|
|
699
|
+
"x-hyperscale-reference-filter": {
|
|
700
|
+
"column": "role",
|
|
701
|
+
"values": [
|
|
702
|
+
"customer_balance"
|
|
703
|
+
]
|
|
704
|
+
}
|
|
705
|
+
},
|
|
706
|
+
"holdExpiresAt": {
|
|
707
|
+
"format": "hyperscale-date-time",
|
|
708
|
+
"type": "string"
|
|
709
|
+
},
|
|
710
|
+
"propertyAccountId": {
|
|
711
|
+
"description": "Hyperscale account ID",
|
|
712
|
+
"pattern": "^acct_(sandbox|live)_[a-z0-9]{8,64}$",
|
|
713
|
+
"type": "string",
|
|
714
|
+
"x-hyperscale-reference-filter": {
|
|
715
|
+
"column": "role",
|
|
716
|
+
"values": [
|
|
717
|
+
"customer_balance"
|
|
718
|
+
]
|
|
719
|
+
}
|
|
720
|
+
},
|
|
721
|
+
"rateAmount": {
|
|
722
|
+
"description": "Positive minor-unit integer amount serialized as a string (at most 18 digits)",
|
|
723
|
+
"pattern": "^[1-9][0-9]{0,17}$",
|
|
724
|
+
"type": "string"
|
|
725
|
+
},
|
|
726
|
+
"stayNote": {
|
|
727
|
+
"maxLength": 180,
|
|
728
|
+
"minLength": 1,
|
|
729
|
+
"type": "string"
|
|
730
|
+
},
|
|
731
|
+
"travelPackageId": {
|
|
732
|
+
"description": "Travel package this stay is a leg of",
|
|
733
|
+
"pattern": "^tpkg_(sandbox|live)_[a-z0-9]{8,64}$",
|
|
734
|
+
"type": "string"
|
|
735
|
+
}
|
|
736
|
+
},
|
|
737
|
+
"id": "hotel_stay",
|
|
738
|
+
"idPrefix": "hstay",
|
|
739
|
+
"lifecycle": {
|
|
740
|
+
"initial": "held",
|
|
741
|
+
"states": [
|
|
742
|
+
"held",
|
|
743
|
+
"released",
|
|
744
|
+
"confirmed",
|
|
745
|
+
"cancel_quoted",
|
|
746
|
+
"completed",
|
|
747
|
+
"canceled",
|
|
748
|
+
"penalty_collected",
|
|
749
|
+
"package_canceled",
|
|
750
|
+
"expired"
|
|
751
|
+
],
|
|
752
|
+
"transitions": {
|
|
753
|
+
"amend_collect": {
|
|
754
|
+
"from": [
|
|
755
|
+
"confirmed"
|
|
756
|
+
],
|
|
757
|
+
"to": "confirmed"
|
|
758
|
+
},
|
|
759
|
+
"amend_fee": {
|
|
760
|
+
"from": [
|
|
761
|
+
"confirmed"
|
|
762
|
+
],
|
|
763
|
+
"to": "confirmed"
|
|
764
|
+
},
|
|
765
|
+
"amend_refund": {
|
|
766
|
+
"from": [
|
|
767
|
+
"confirmed"
|
|
768
|
+
],
|
|
769
|
+
"to": "confirmed"
|
|
770
|
+
},
|
|
771
|
+
"cancel_confirm": {
|
|
772
|
+
"from": [
|
|
773
|
+
"cancel_quoted"
|
|
774
|
+
],
|
|
775
|
+
"to": "canceled"
|
|
776
|
+
},
|
|
777
|
+
"cancel_quote": {
|
|
778
|
+
"from": [
|
|
779
|
+
"confirmed"
|
|
780
|
+
],
|
|
781
|
+
"to": "cancel_quoted"
|
|
782
|
+
},
|
|
783
|
+
"collect_penalty": {
|
|
784
|
+
"from": [
|
|
785
|
+
"canceled"
|
|
786
|
+
],
|
|
787
|
+
"to": "penalty_collected"
|
|
788
|
+
},
|
|
789
|
+
"complete": {
|
|
790
|
+
"from": [
|
|
791
|
+
"confirmed",
|
|
792
|
+
"cancel_quoted"
|
|
793
|
+
],
|
|
794
|
+
"to": "completed"
|
|
795
|
+
},
|
|
796
|
+
"confirm": {
|
|
797
|
+
"from": [
|
|
798
|
+
"held"
|
|
799
|
+
],
|
|
800
|
+
"to": "confirmed"
|
|
801
|
+
},
|
|
802
|
+
"expire": {
|
|
803
|
+
"from": [
|
|
804
|
+
"held"
|
|
805
|
+
],
|
|
806
|
+
"to": "expired"
|
|
807
|
+
},
|
|
808
|
+
"package_cancel": {
|
|
809
|
+
"from": [
|
|
810
|
+
"confirmed",
|
|
811
|
+
"cancel_quoted"
|
|
812
|
+
],
|
|
813
|
+
"to": "package_canceled"
|
|
814
|
+
},
|
|
815
|
+
"release": {
|
|
816
|
+
"from": [
|
|
817
|
+
"held"
|
|
818
|
+
],
|
|
819
|
+
"to": "released"
|
|
820
|
+
}
|
|
821
|
+
}
|
|
822
|
+
},
|
|
823
|
+
"parties": {
|
|
824
|
+
"beneficiary": "propertyAccountId",
|
|
825
|
+
"payer": "guestAccountId"
|
|
826
|
+
},
|
|
827
|
+
"required": [
|
|
828
|
+
"guestAccountId",
|
|
829
|
+
"propertyAccountId",
|
|
830
|
+
"rateAmount",
|
|
831
|
+
"currency",
|
|
832
|
+
"holdExpiresAt",
|
|
833
|
+
"checkInAt",
|
|
834
|
+
"checkOutAt"
|
|
835
|
+
],
|
|
836
|
+
"subject": {
|
|
837
|
+
"kinds": [
|
|
838
|
+
"lodging_stay"
|
|
839
|
+
]
|
|
840
|
+
},
|
|
841
|
+
"summary": "Held-then-confirmed hotel stay settled on a supplier decision.",
|
|
842
|
+
"title": "Hotel stay",
|
|
843
|
+
"unwind": {
|
|
844
|
+
"confirm": "cancel_confirm",
|
|
845
|
+
"penalty": [
|
|
846
|
+
{
|
|
847
|
+
"bps": 0,
|
|
848
|
+
"withinOffset": "P2D"
|
|
849
|
+
},
|
|
850
|
+
{
|
|
851
|
+
"bps": 5000
|
|
852
|
+
}
|
|
853
|
+
],
|
|
854
|
+
"quote": "cancel_quote",
|
|
855
|
+
"refundDestinationField": "guestAccountId",
|
|
856
|
+
"refundableField": "rateAmount"
|
|
857
|
+
},
|
|
858
|
+
"update": {
|
|
859
|
+
"fields": [
|
|
860
|
+
"checkInAt",
|
|
861
|
+
"checkOutAt",
|
|
862
|
+
"stayNote"
|
|
863
|
+
],
|
|
864
|
+
"states": [
|
|
865
|
+
"held",
|
|
866
|
+
"confirmed"
|
|
867
|
+
]
|
|
868
|
+
},
|
|
869
|
+
"verbs": {
|
|
870
|
+
"amend_collect": {
|
|
871
|
+
"description": "Reprices a confirmed stay whose amended dates or room cost more: the guest pays the rate difference to the property directly and the stay remains confirmed. The rate reserve is untouched; it still pays out in full at checkout. Pair with hotel_stay.update for the stay fields and amend_fee for the amendment fee.",
|
|
872
|
+
"eventName": "hotel_stay.amendment_collected",
|
|
873
|
+
"examples": [
|
|
874
|
+
{
|
|
875
|
+
"input": {
|
|
876
|
+
"amendmentNote": "Extended the stay by two nights",
|
|
877
|
+
"rateDifference": "32000"
|
|
878
|
+
},
|
|
879
|
+
"name": "collect_extended_stay_increase"
|
|
880
|
+
}
|
|
881
|
+
],
|
|
882
|
+
"input": {
|
|
883
|
+
"additionalProperties": false,
|
|
884
|
+
"properties": {
|
|
885
|
+
"amendmentNote": {
|
|
886
|
+
"maxLength": 180,
|
|
887
|
+
"minLength": 1,
|
|
888
|
+
"type": "string"
|
|
889
|
+
},
|
|
890
|
+
"rateDifference": {
|
|
891
|
+
"description": "Positive minor-unit integer amount serialized as a string (at most 18 digits)",
|
|
892
|
+
"pattern": "^[1-9][0-9]{0,17}$",
|
|
893
|
+
"type": "string"
|
|
894
|
+
}
|
|
895
|
+
},
|
|
896
|
+
"required": [
|
|
897
|
+
"rateDifference",
|
|
898
|
+
"amendmentNote"
|
|
899
|
+
],
|
|
900
|
+
"type": "object"
|
|
901
|
+
},
|
|
902
|
+
"moves": [
|
|
903
|
+
{
|
|
904
|
+
"bind": {
|
|
905
|
+
"amount": {
|
|
906
|
+
"from": "input",
|
|
907
|
+
"path": "rateDifference"
|
|
908
|
+
},
|
|
909
|
+
"currency": {
|
|
910
|
+
"from": "instance",
|
|
911
|
+
"path": "fields.currency"
|
|
912
|
+
},
|
|
913
|
+
"destinationAccountId": {
|
|
914
|
+
"from": "instance",
|
|
915
|
+
"path": "fields.propertyAccountId"
|
|
916
|
+
},
|
|
917
|
+
"memo": {
|
|
918
|
+
"from": "input",
|
|
919
|
+
"path": "amendmentNote"
|
|
920
|
+
},
|
|
921
|
+
"sourceAccountId": {
|
|
922
|
+
"from": "instance",
|
|
923
|
+
"path": "fields.guestAccountId"
|
|
924
|
+
},
|
|
925
|
+
"workspaceId": {
|
|
926
|
+
"from": "instance",
|
|
927
|
+
"path": "workspaceId"
|
|
928
|
+
}
|
|
929
|
+
},
|
|
930
|
+
"capture": {
|
|
931
|
+
"amendCollectTransferId": "transferId"
|
|
932
|
+
},
|
|
933
|
+
"key": "transfer",
|
|
934
|
+
"operation": "internal_transfer.create"
|
|
935
|
+
}
|
|
936
|
+
],
|
|
937
|
+
"steps": [],
|
|
938
|
+
"summary": "Collect an amended rate increase"
|
|
939
|
+
},
|
|
940
|
+
"amend_fee": {
|
|
941
|
+
"description": "Collects the property's amendment fee for one stay change from the guest, in either repricing direction. Declared as its own verb so a fee-free amendment simply never invokes it and an equal-rate change is a fee with no difference leg.",
|
|
942
|
+
"eventName": "hotel_stay.amendment_fee_collected",
|
|
943
|
+
"examples": [
|
|
944
|
+
{
|
|
945
|
+
"input": {
|
|
946
|
+
"amendmentFee": "7500",
|
|
947
|
+
"amendmentNote": "Property fee for the date change"
|
|
948
|
+
},
|
|
949
|
+
"name": "collect_date_change_fee"
|
|
950
|
+
}
|
|
951
|
+
],
|
|
952
|
+
"input": {
|
|
953
|
+
"additionalProperties": false,
|
|
954
|
+
"properties": {
|
|
955
|
+
"amendmentFee": {
|
|
956
|
+
"description": "Positive minor-unit integer amount serialized as a string (at most 18 digits)",
|
|
957
|
+
"pattern": "^[1-9][0-9]{0,17}$",
|
|
958
|
+
"type": "string"
|
|
959
|
+
},
|
|
960
|
+
"amendmentNote": {
|
|
961
|
+
"maxLength": 180,
|
|
962
|
+
"minLength": 1,
|
|
963
|
+
"type": "string"
|
|
964
|
+
}
|
|
965
|
+
},
|
|
966
|
+
"required": [
|
|
967
|
+
"amendmentFee",
|
|
968
|
+
"amendmentNote"
|
|
969
|
+
],
|
|
970
|
+
"type": "object"
|
|
971
|
+
},
|
|
972
|
+
"moves": [
|
|
973
|
+
{
|
|
974
|
+
"bind": {
|
|
975
|
+
"amount": {
|
|
976
|
+
"from": "input",
|
|
977
|
+
"path": "amendmentFee"
|
|
978
|
+
},
|
|
979
|
+
"currency": {
|
|
980
|
+
"from": "instance",
|
|
981
|
+
"path": "fields.currency"
|
|
982
|
+
},
|
|
983
|
+
"destinationAccountId": {
|
|
984
|
+
"from": "instance",
|
|
985
|
+
"path": "fields.propertyAccountId"
|
|
986
|
+
},
|
|
987
|
+
"memo": {
|
|
988
|
+
"from": "input",
|
|
989
|
+
"path": "amendmentNote"
|
|
990
|
+
},
|
|
991
|
+
"sourceAccountId": {
|
|
992
|
+
"from": "instance",
|
|
993
|
+
"path": "fields.guestAccountId"
|
|
994
|
+
},
|
|
995
|
+
"workspaceId": {
|
|
996
|
+
"from": "instance",
|
|
997
|
+
"path": "workspaceId"
|
|
998
|
+
}
|
|
999
|
+
},
|
|
1000
|
+
"capture": {
|
|
1001
|
+
"amendFeeTransferId": "transferId"
|
|
1002
|
+
},
|
|
1003
|
+
"key": "transfer",
|
|
1004
|
+
"operation": "internal_transfer.create"
|
|
1005
|
+
}
|
|
1006
|
+
],
|
|
1007
|
+
"steps": [],
|
|
1008
|
+
"summary": "Collect a stay amendment fee"
|
|
1009
|
+
},
|
|
1010
|
+
"amend_refund": {
|
|
1011
|
+
"description": "Reprices a confirmed stay whose amended dates or room cost less: the property refunds the rate difference to the guest directly and the stay remains confirmed. The rate reserve is untouched, so the property's checkout payout still nets to the amended rate. Any amendment fee is collected separately by amend_fee.",
|
|
1012
|
+
"eventName": "hotel_stay.amendment_refunded",
|
|
1013
|
+
"examples": [
|
|
1014
|
+
{
|
|
1015
|
+
"input": {
|
|
1016
|
+
"amendmentNote": "Shortened the stay by one night",
|
|
1017
|
+
"rateDifference": "16000"
|
|
1018
|
+
},
|
|
1019
|
+
"name": "refund_shortened_stay_decrease"
|
|
1020
|
+
}
|
|
1021
|
+
],
|
|
1022
|
+
"input": {
|
|
1023
|
+
"additionalProperties": false,
|
|
1024
|
+
"properties": {
|
|
1025
|
+
"amendmentNote": {
|
|
1026
|
+
"maxLength": 180,
|
|
1027
|
+
"minLength": 1,
|
|
1028
|
+
"type": "string"
|
|
1029
|
+
},
|
|
1030
|
+
"rateDifference": {
|
|
1031
|
+
"description": "Positive minor-unit integer amount serialized as a string (at most 18 digits)",
|
|
1032
|
+
"pattern": "^[1-9][0-9]{0,17}$",
|
|
1033
|
+
"type": "string"
|
|
1034
|
+
}
|
|
1035
|
+
},
|
|
1036
|
+
"required": [
|
|
1037
|
+
"rateDifference",
|
|
1038
|
+
"amendmentNote"
|
|
1039
|
+
],
|
|
1040
|
+
"type": "object"
|
|
1041
|
+
},
|
|
1042
|
+
"moves": [
|
|
1043
|
+
{
|
|
1044
|
+
"bind": {
|
|
1045
|
+
"amount": {
|
|
1046
|
+
"from": "input",
|
|
1047
|
+
"path": "rateDifference"
|
|
1048
|
+
},
|
|
1049
|
+
"currency": {
|
|
1050
|
+
"from": "instance",
|
|
1051
|
+
"path": "fields.currency"
|
|
1052
|
+
},
|
|
1053
|
+
"destinationAccountId": {
|
|
1054
|
+
"from": "instance",
|
|
1055
|
+
"path": "fields.guestAccountId"
|
|
1056
|
+
},
|
|
1057
|
+
"memo": {
|
|
1058
|
+
"from": "input",
|
|
1059
|
+
"path": "amendmentNote"
|
|
1060
|
+
},
|
|
1061
|
+
"sourceAccountId": {
|
|
1062
|
+
"from": "instance",
|
|
1063
|
+
"path": "fields.propertyAccountId"
|
|
1064
|
+
},
|
|
1065
|
+
"workspaceId": {
|
|
1066
|
+
"from": "instance",
|
|
1067
|
+
"path": "workspaceId"
|
|
1068
|
+
}
|
|
1069
|
+
},
|
|
1070
|
+
"capture": {
|
|
1071
|
+
"amendRefundTransferId": "transferId"
|
|
1072
|
+
},
|
|
1073
|
+
"key": "transfer",
|
|
1074
|
+
"operation": "internal_transfer.create"
|
|
1075
|
+
}
|
|
1076
|
+
],
|
|
1077
|
+
"steps": [],
|
|
1078
|
+
"summary": "Refund an amended rate decrease"
|
|
1079
|
+
},
|
|
1080
|
+
"cancel_confirm": {
|
|
1081
|
+
"description": "Unwinds the stay, refunding the rate minus the scheduled penalty from the rate reserve back to the guest. The refund is repriced at confirm time into refs.unwindRefund; collect_penalty pays the retained remainder separately.",
|
|
1082
|
+
"moves": [
|
|
1083
|
+
{
|
|
1084
|
+
"bind": {
|
|
1085
|
+
"amount": {
|
|
1086
|
+
"from": "instance",
|
|
1087
|
+
"path": "refs.unwindRefund"
|
|
1088
|
+
},
|
|
1089
|
+
"currency": {
|
|
1090
|
+
"from": "instance",
|
|
1091
|
+
"path": "fields.currency"
|
|
1092
|
+
},
|
|
1093
|
+
"destinationAccountId": {
|
|
1094
|
+
"from": "instance",
|
|
1095
|
+
"path": "fields.guestAccountId"
|
|
1096
|
+
},
|
|
1097
|
+
"sourceAccountId": {
|
|
1098
|
+
"from": "instance",
|
|
1099
|
+
"path": "refs.rateReserveAccountId"
|
|
1100
|
+
},
|
|
1101
|
+
"workspaceId": {
|
|
1102
|
+
"from": "instance",
|
|
1103
|
+
"path": "workspaceId"
|
|
1104
|
+
}
|
|
1105
|
+
},
|
|
1106
|
+
"capture": {
|
|
1107
|
+
"refundTransferId": "transferId"
|
|
1108
|
+
},
|
|
1109
|
+
"key": "transfer",
|
|
1110
|
+
"operation": "internal_transfer.create"
|
|
1111
|
+
}
|
|
1112
|
+
],
|
|
1113
|
+
"steps": [],
|
|
1114
|
+
"summary": "Confirm a hotel stay cancellation"
|
|
1115
|
+
},
|
|
1116
|
+
"cancel_quote": {
|
|
1117
|
+
"description": "Parks the confirmed stay for cancellation and quotes the refund under the free-cancel penalty schedule. No money moves and the quote is advisory: the cancellation confirm reprices at its own clock.",
|
|
1118
|
+
"moves": [],
|
|
1119
|
+
"steps": [],
|
|
1120
|
+
"summary": "Quote a hotel stay cancellation"
|
|
1121
|
+
},
|
|
1122
|
+
"collect_penalty": {
|
|
1123
|
+
"description": "Pays the computed retained cancellation penalty to the property. Invoke only when cancel_confirm returns a positive refs.unwindPenalty.",
|
|
1124
|
+
"eventName": "hotel_stay.penalty_collected",
|
|
1125
|
+
"moves": [
|
|
1126
|
+
{
|
|
1127
|
+
"bind": {
|
|
1128
|
+
"amount": {
|
|
1129
|
+
"from": "instance",
|
|
1130
|
+
"path": "refs.unwindPenalty"
|
|
1131
|
+
},
|
|
1132
|
+
"currency": {
|
|
1133
|
+
"from": "instance",
|
|
1134
|
+
"path": "fields.currency"
|
|
1135
|
+
},
|
|
1136
|
+
"destinationAccountId": {
|
|
1137
|
+
"from": "instance",
|
|
1138
|
+
"path": "fields.propertyAccountId"
|
|
1139
|
+
},
|
|
1140
|
+
"sourceAccountId": {
|
|
1141
|
+
"from": "instance",
|
|
1142
|
+
"path": "refs.rateReserveAccountId"
|
|
1143
|
+
},
|
|
1144
|
+
"workspaceId": {
|
|
1145
|
+
"from": "instance",
|
|
1146
|
+
"path": "workspaceId"
|
|
1147
|
+
}
|
|
1148
|
+
},
|
|
1149
|
+
"capture": {
|
|
1150
|
+
"penaltyTransferId": "transferId"
|
|
1151
|
+
},
|
|
1152
|
+
"key": "transfer",
|
|
1153
|
+
"operation": "internal_transfer.create"
|
|
1154
|
+
}
|
|
1155
|
+
],
|
|
1156
|
+
"steps": [],
|
|
1157
|
+
"summary": "Collect a hotel cancellation penalty"
|
|
1158
|
+
},
|
|
1159
|
+
"complete": {
|
|
1160
|
+
"description": "Closes a confirmed stay at checkout and pays the reserved rate to the property under the machine principal, even if a cancellation quote is parked un-acted. This is the property's revenue event, fired by the maintenance loop under the checkout due-condition.",
|
|
1161
|
+
"due": {
|
|
1162
|
+
"field": "checkOutAt"
|
|
1163
|
+
},
|
|
1164
|
+
"earnable": true,
|
|
1165
|
+
"moves": [
|
|
1166
|
+
{
|
|
1167
|
+
"bind": {
|
|
1168
|
+
"amount": {
|
|
1169
|
+
"from": "instance",
|
|
1170
|
+
"path": "fields.rateAmount"
|
|
1171
|
+
},
|
|
1172
|
+
"currency": {
|
|
1173
|
+
"from": "instance",
|
|
1174
|
+
"path": "fields.currency"
|
|
1175
|
+
},
|
|
1176
|
+
"destinationAccountId": {
|
|
1177
|
+
"from": "instance",
|
|
1178
|
+
"path": "fields.propertyAccountId"
|
|
1179
|
+
},
|
|
1180
|
+
"sourceAccountId": {
|
|
1181
|
+
"from": "instance",
|
|
1182
|
+
"path": "refs.rateReserveAccountId"
|
|
1183
|
+
},
|
|
1184
|
+
"workspaceId": {
|
|
1185
|
+
"from": "instance",
|
|
1186
|
+
"path": "workspaceId"
|
|
1187
|
+
}
|
|
1188
|
+
},
|
|
1189
|
+
"capture": {
|
|
1190
|
+
"ratePayoutTransferId": "transferId"
|
|
1191
|
+
},
|
|
1192
|
+
"key": "transfer",
|
|
1193
|
+
"operation": "internal_transfer.create"
|
|
1194
|
+
}
|
|
1195
|
+
],
|
|
1196
|
+
"steps": [],
|
|
1197
|
+
"summary": "Complete a hotel stay"
|
|
1198
|
+
},
|
|
1199
|
+
"confirm": {
|
|
1200
|
+
"deadline": {
|
|
1201
|
+
"field": "holdExpiresAt"
|
|
1202
|
+
},
|
|
1203
|
+
"decision": {
|
|
1204
|
+
"capability": "lodging_supplier",
|
|
1205
|
+
"deadlineMs": 15000,
|
|
1206
|
+
"onTimeout": "decline"
|
|
1207
|
+
},
|
|
1208
|
+
"description": "Runs a just-in-time lodging supplier decision under a deadline, then settles the rate from the guest into the dedicated rate reserve and commits the stay. Refused once the hold expiry has passed, even if the expiry sweep has not fired yet.",
|
|
1209
|
+
"moves": [
|
|
1210
|
+
{
|
|
1211
|
+
"bind": {
|
|
1212
|
+
"amount": {
|
|
1213
|
+
"from": "instance",
|
|
1214
|
+
"path": "fields.rateAmount"
|
|
1215
|
+
},
|
|
1216
|
+
"currency": {
|
|
1217
|
+
"from": "instance",
|
|
1218
|
+
"path": "fields.currency"
|
|
1219
|
+
},
|
|
1220
|
+
"destinationAccountId": {
|
|
1221
|
+
"from": "instance",
|
|
1222
|
+
"path": "refs.rateReserveAccountId"
|
|
1223
|
+
},
|
|
1224
|
+
"sourceAccountId": {
|
|
1225
|
+
"from": "instance",
|
|
1226
|
+
"path": "fields.guestAccountId"
|
|
1227
|
+
},
|
|
1228
|
+
"workspaceId": {
|
|
1229
|
+
"from": "instance",
|
|
1230
|
+
"path": "workspaceId"
|
|
1231
|
+
}
|
|
1232
|
+
},
|
|
1233
|
+
"capture": {
|
|
1234
|
+
"rateTransferId": "transferId"
|
|
1235
|
+
},
|
|
1236
|
+
"key": "transfer",
|
|
1237
|
+
"operation": "internal_transfer.create"
|
|
1238
|
+
}
|
|
1239
|
+
],
|
|
1240
|
+
"steps": [],
|
|
1241
|
+
"summary": "Confirm a hotel stay"
|
|
1242
|
+
},
|
|
1243
|
+
"create": {
|
|
1244
|
+
"description": "Opens the stay as a hold against a lodging stay subject at the quoted rate and provisions the dedicated rate reserve. No money moves until the stay confirms; the hold carries its own expiry deadline. A stay holding a leg of a packaged trip names its travel package, admitted only while that package is still draft or booked.",
|
|
1245
|
+
"moves": [],
|
|
1246
|
+
"requiresRefs": [
|
|
1247
|
+
{
|
|
1248
|
+
"field": "travelPackageId",
|
|
1249
|
+
"optional": true,
|
|
1250
|
+
"statuses": [
|
|
1251
|
+
"draft",
|
|
1252
|
+
"booked"
|
|
1253
|
+
]
|
|
1254
|
+
}
|
|
1255
|
+
],
|
|
1256
|
+
"steps": [
|
|
1257
|
+
{
|
|
1258
|
+
"bind": {
|
|
1259
|
+
"currency": {
|
|
1260
|
+
"from": "instance",
|
|
1261
|
+
"path": "fields.currency"
|
|
1262
|
+
},
|
|
1263
|
+
"owner.id": {
|
|
1264
|
+
"from": "instance",
|
|
1265
|
+
"path": "workspaceId"
|
|
1266
|
+
},
|
|
1267
|
+
"owner.type": {
|
|
1268
|
+
"from": "const",
|
|
1269
|
+
"value": "workspace"
|
|
1270
|
+
},
|
|
1271
|
+
"role": {
|
|
1272
|
+
"from": "const",
|
|
1273
|
+
"value": "workspace_escrow"
|
|
1274
|
+
},
|
|
1275
|
+
"workspaceId": {
|
|
1276
|
+
"from": "instance",
|
|
1277
|
+
"path": "workspaceId"
|
|
1278
|
+
}
|
|
1279
|
+
},
|
|
1280
|
+
"capture": {
|
|
1281
|
+
"rateReserveAccountId": "accountId"
|
|
1282
|
+
},
|
|
1283
|
+
"operation": "account.escrow.provision"
|
|
1284
|
+
}
|
|
1285
|
+
],
|
|
1286
|
+
"summary": "Hold a hotel stay"
|
|
1287
|
+
},
|
|
1288
|
+
"expire": {
|
|
1289
|
+
"description": "Ends an unconfirmed hold at its deadline. No money has moved, so this is a pure lifecycle transition fired by the maintenance loop under the hold-expiry due-condition.",
|
|
1290
|
+
"due": {
|
|
1291
|
+
"field": "holdExpiresAt"
|
|
1292
|
+
},
|
|
1293
|
+
"moves": [],
|
|
1294
|
+
"requiresDrainedAccount": {
|
|
1295
|
+
"path": "refs.rateReserveAccountId"
|
|
1296
|
+
},
|
|
1297
|
+
"steps": [],
|
|
1298
|
+
"summary": "Expire a held hotel stay"
|
|
1299
|
+
},
|
|
1300
|
+
"package_cancel": {
|
|
1301
|
+
"description": "Fires under the machine principal for a leg of a cancelled travel package: refunds the full reserved rate to the guest, penalty-free, because the cancellation is the package's, not the guest's. Selectable once the hold window has passed (a confirmed leg is past it in practice); a held leg simply expires on its own deadline, and a completed stay is never cascade-cancelled.",
|
|
1302
|
+
"due": {
|
|
1303
|
+
"field": "holdExpiresAt",
|
|
1304
|
+
"whenParentStatus": {
|
|
1305
|
+
"nounId": "travel_package",
|
|
1306
|
+
"refField": "travelPackageId",
|
|
1307
|
+
"statuses": [
|
|
1308
|
+
"cancelled"
|
|
1309
|
+
]
|
|
1310
|
+
}
|
|
1311
|
+
},
|
|
1312
|
+
"moves": [
|
|
1313
|
+
{
|
|
1314
|
+
"bind": {
|
|
1315
|
+
"amount": {
|
|
1316
|
+
"from": "instance",
|
|
1317
|
+
"path": "fields.rateAmount"
|
|
1318
|
+
},
|
|
1319
|
+
"currency": {
|
|
1320
|
+
"from": "instance",
|
|
1321
|
+
"path": "fields.currency"
|
|
1322
|
+
},
|
|
1323
|
+
"destinationAccountId": {
|
|
1324
|
+
"from": "instance",
|
|
1325
|
+
"path": "fields.guestAccountId"
|
|
1326
|
+
},
|
|
1327
|
+
"sourceAccountId": {
|
|
1328
|
+
"from": "instance",
|
|
1329
|
+
"path": "refs.rateReserveAccountId"
|
|
1330
|
+
},
|
|
1331
|
+
"workspaceId": {
|
|
1332
|
+
"from": "instance",
|
|
1333
|
+
"path": "workspaceId"
|
|
1334
|
+
}
|
|
1335
|
+
},
|
|
1336
|
+
"capture": {
|
|
1337
|
+
"packageRefundTransferId": "transferId"
|
|
1338
|
+
},
|
|
1339
|
+
"key": "transfer",
|
|
1340
|
+
"operation": "internal_transfer.create"
|
|
1341
|
+
}
|
|
1342
|
+
],
|
|
1343
|
+
"steps": [],
|
|
1344
|
+
"summary": "Cancel a hotel stay with its cancelled package"
|
|
1345
|
+
},
|
|
1346
|
+
"release": {
|
|
1347
|
+
"description": "Closes a hold the guest abandoned before confirmation. No money has moved, so this is a pure lifecycle transition.",
|
|
1348
|
+
"moves": [],
|
|
1349
|
+
"requiresDrainedAccount": {
|
|
1350
|
+
"path": "refs.rateReserveAccountId"
|
|
1351
|
+
},
|
|
1352
|
+
"steps": [],
|
|
1353
|
+
"summary": "Release a held hotel stay"
|
|
1354
|
+
}
|
|
1355
|
+
}
|
|
1356
|
+
},
|
|
1357
|
+
{
|
|
1358
|
+
"description": "A travel package drafts a bundled trip for one traveler party. Confirming it is refused while any linked flight booking or hotel stay is not yet confirmed, so a booked package always means every leg's money is settled in its own reserve. Cancelling a booked package flips the status each leg's own package-cancel refund waits on, and completion closes a delivered trip. The package itself never moves money.",
|
|
1359
|
+
"fields": {
|
|
1360
|
+
"departAt": {
|
|
1361
|
+
"format": "hyperscale-date-time",
|
|
1362
|
+
"type": "string"
|
|
1363
|
+
},
|
|
1364
|
+
"memo": {
|
|
1365
|
+
"maxLength": 180,
|
|
1366
|
+
"minLength": 1,
|
|
1367
|
+
"type": "string"
|
|
1368
|
+
},
|
|
1369
|
+
"payerAccountId": {
|
|
1370
|
+
"description": "Hyperscale account ID",
|
|
1371
|
+
"pattern": "^acct_(sandbox|live)_[a-z0-9]{8,64}$",
|
|
1372
|
+
"type": "string",
|
|
1373
|
+
"x-hyperscale-reference-filter": {
|
|
1374
|
+
"column": "role",
|
|
1375
|
+
"values": [
|
|
1376
|
+
"customer_balance"
|
|
1377
|
+
]
|
|
1378
|
+
}
|
|
1379
|
+
}
|
|
1380
|
+
},
|
|
1381
|
+
"id": "travel_package",
|
|
1382
|
+
"idPrefix": "tpkg",
|
|
1383
|
+
"lifecycle": {
|
|
1384
|
+
"initial": "draft",
|
|
1385
|
+
"states": [
|
|
1386
|
+
"draft",
|
|
1387
|
+
"booked",
|
|
1388
|
+
"completed",
|
|
1389
|
+
"cancelled"
|
|
1390
|
+
],
|
|
1391
|
+
"transitions": {
|
|
1392
|
+
"cancel": {
|
|
1393
|
+
"from": [
|
|
1394
|
+
"booked"
|
|
1395
|
+
],
|
|
1396
|
+
"to": "cancelled"
|
|
1397
|
+
},
|
|
1398
|
+
"complete": {
|
|
1399
|
+
"from": [
|
|
1400
|
+
"booked"
|
|
1401
|
+
],
|
|
1402
|
+
"to": "completed"
|
|
1403
|
+
},
|
|
1404
|
+
"confirm": {
|
|
1405
|
+
"from": [
|
|
1406
|
+
"draft"
|
|
1407
|
+
],
|
|
1408
|
+
"to": "booked"
|
|
1409
|
+
}
|
|
1410
|
+
}
|
|
1411
|
+
},
|
|
1412
|
+
"parties": {
|
|
1413
|
+
"payer": "payerAccountId"
|
|
1414
|
+
},
|
|
1415
|
+
"required": [
|
|
1416
|
+
"payerAccountId",
|
|
1417
|
+
"departAt"
|
|
1418
|
+
],
|
|
1419
|
+
"subject": {
|
|
1420
|
+
"kinds": [
|
|
1421
|
+
"traveler_party"
|
|
1422
|
+
]
|
|
1423
|
+
},
|
|
1424
|
+
"summary": "One bundled trip whose flight and hotel legs confirm together.",
|
|
1425
|
+
"title": "Travel package",
|
|
1426
|
+
"verbs": {
|
|
1427
|
+
"cancel": {
|
|
1428
|
+
"description": "Cancels the bundled trip as one pure transition. The refunds are the legs' own: each confirmed flight booking and hotel stay referencing this package becomes due for its package_cancel verb under the parent-status gate and refunds its full reserve as its own receipted operation.",
|
|
1429
|
+
"moves": [],
|
|
1430
|
+
"steps": [],
|
|
1431
|
+
"summary": "Cancel a booked travel package"
|
|
1432
|
+
},
|
|
1433
|
+
"complete": {
|
|
1434
|
+
"description": "Closes a booked package once the trip has run. Pure transition: the legs' own departure and checkout due verbs already paid their operators from their reserves.",
|
|
1435
|
+
"moves": [],
|
|
1436
|
+
"steps": [],
|
|
1437
|
+
"summary": "Complete a delivered travel package"
|
|
1438
|
+
},
|
|
1439
|
+
"confirm": {
|
|
1440
|
+
"description": "Books the package once every linked leg has confirmed: refused (409 aggregate_condition_unmet) while any flight booking or hotel stay referencing this package is in any status but confirmed. Booking the package moves no money -- each leg's fare or rate already settled into that leg's own reserve at its own confirm.",
|
|
1441
|
+
"moves": [],
|
|
1442
|
+
"requiresAggregate": [
|
|
1443
|
+
{
|
|
1444
|
+
"check": {
|
|
1445
|
+
"kind": "all_in"
|
|
1446
|
+
},
|
|
1447
|
+
"nounId": "flight_booking",
|
|
1448
|
+
"over": "children",
|
|
1449
|
+
"refField": "travelPackageId",
|
|
1450
|
+
"statuses": [
|
|
1451
|
+
"confirmed"
|
|
1452
|
+
]
|
|
1453
|
+
},
|
|
1454
|
+
{
|
|
1455
|
+
"check": {
|
|
1456
|
+
"kind": "all_in"
|
|
1457
|
+
},
|
|
1458
|
+
"nounId": "hotel_stay",
|
|
1459
|
+
"over": "children",
|
|
1460
|
+
"refField": "travelPackageId",
|
|
1461
|
+
"statuses": [
|
|
1462
|
+
"confirmed"
|
|
1463
|
+
]
|
|
1464
|
+
}
|
|
1465
|
+
],
|
|
1466
|
+
"steps": [],
|
|
1467
|
+
"summary": "Confirm a travel package"
|
|
1468
|
+
},
|
|
1469
|
+
"create": {
|
|
1470
|
+
"description": "Opens the bundled trip for one traveler party and names the payer the legs will settle against. No money moves and no account is provisioned: every transfer of the trip belongs to a linked flight booking or hotel stay.",
|
|
1471
|
+
"examples": [
|
|
1472
|
+
{
|
|
1473
|
+
"input": {
|
|
1474
|
+
"departAt": "2026-09-01T21:00:00.000Z",
|
|
1475
|
+
"memo": "Jeddah corniche long weekend.",
|
|
1476
|
+
"payerAccountId": "acct_sandbox_traveler0001",
|
|
1477
|
+
"subject": "sbj_sandbox_travelparty01"
|
|
1478
|
+
},
|
|
1479
|
+
"name": "draft_jeddah_getaway"
|
|
1480
|
+
}
|
|
1481
|
+
],
|
|
1482
|
+
"moves": [],
|
|
1483
|
+
"steps": [],
|
|
1484
|
+
"summary": "Draft a travel package"
|
|
1485
|
+
}
|
|
1486
|
+
}
|
|
1487
|
+
},
|
|
1488
|
+
{
|
|
1489
|
+
"aggregateInvariants": [
|
|
1490
|
+
{
|
|
1491
|
+
"childField": "claimAmount",
|
|
1492
|
+
"childNounId": "claim",
|
|
1493
|
+
"childRefField": "policyId",
|
|
1494
|
+
"childStatuses": [
|
|
1495
|
+
"filed",
|
|
1496
|
+
"assessed",
|
|
1497
|
+
"approved",
|
|
1498
|
+
"paid"
|
|
1499
|
+
],
|
|
1500
|
+
"parentField": "coverageLimit"
|
|
1501
|
+
}
|
|
1502
|
+
],
|
|
1503
|
+
"description": "A policy quotes protection over one subject, binds after a carrier decision, activates at its declared start, and expires at term. Premium remains refundable while bound but not active; activation pays the insurer and opens the policy to claims.",
|
|
1504
|
+
"fields": {
|
|
1505
|
+
"coverageLimit": {
|
|
1506
|
+
"description": "Positive minor-unit integer amount serialized as a string (at most 18 digits)",
|
|
1507
|
+
"pattern": "^[1-9][0-9]{0,17}$",
|
|
1508
|
+
"type": "string"
|
|
1509
|
+
},
|
|
1510
|
+
"currency": {
|
|
1511
|
+
"description": "ISO 4217 currency code",
|
|
1512
|
+
"maxLength": 3,
|
|
1513
|
+
"minLength": 3,
|
|
1514
|
+
"pattern": "^[A-Z]{3}$",
|
|
1515
|
+
"type": "string"
|
|
1516
|
+
},
|
|
1517
|
+
"expiresAt": {
|
|
1518
|
+
"format": "hyperscale-date-time",
|
|
1519
|
+
"type": "string"
|
|
1520
|
+
},
|
|
1521
|
+
"insurerAccountId": {
|
|
1522
|
+
"description": "Hyperscale account ID",
|
|
1523
|
+
"pattern": "^acct_(sandbox|live)_[a-z0-9]{8,64}$",
|
|
1524
|
+
"type": "string",
|
|
1525
|
+
"x-hyperscale-reference-filter": {
|
|
1526
|
+
"column": "role",
|
|
1527
|
+
"values": [
|
|
1528
|
+
"customer_balance"
|
|
1529
|
+
]
|
|
1530
|
+
}
|
|
1531
|
+
},
|
|
1532
|
+
"perilSchedule": {
|
|
1533
|
+
"items": {
|
|
1534
|
+
"additionalProperties": false,
|
|
1535
|
+
"properties": {
|
|
1536
|
+
"deductibleBps": {
|
|
1537
|
+
"maximum": 10000,
|
|
1538
|
+
"minimum": 0,
|
|
1539
|
+
"type": "integer"
|
|
1540
|
+
},
|
|
1541
|
+
"limitAmount": {
|
|
1542
|
+
"description": "Positive minor-unit integer amount serialized as a string (at most 18 digits)",
|
|
1543
|
+
"pattern": "^[1-9][0-9]{0,17}$",
|
|
1544
|
+
"type": "string"
|
|
1545
|
+
},
|
|
1546
|
+
"peril": {
|
|
1547
|
+
"pattern": "^[a-z][a-z0-9_]{1,79}$",
|
|
1548
|
+
"type": "string"
|
|
1549
|
+
},
|
|
1550
|
+
"waitingPeriodDays": {
|
|
1551
|
+
"maximum": 3650,
|
|
1552
|
+
"minimum": 0,
|
|
1553
|
+
"type": "integer"
|
|
1554
|
+
}
|
|
1555
|
+
},
|
|
1556
|
+
"required": [
|
|
1557
|
+
"peril",
|
|
1558
|
+
"limitAmount",
|
|
1559
|
+
"deductibleBps",
|
|
1560
|
+
"waitingPeriodDays"
|
|
1561
|
+
],
|
|
1562
|
+
"type": "object"
|
|
1563
|
+
},
|
|
1564
|
+
"maxItems": 24,
|
|
1565
|
+
"minItems": 1,
|
|
1566
|
+
"type": "array"
|
|
1567
|
+
},
|
|
1568
|
+
"policyholderAccountId": {
|
|
1569
|
+
"description": "Hyperscale account ID",
|
|
1570
|
+
"pattern": "^acct_(sandbox|live)_[a-z0-9]{8,64}$",
|
|
1571
|
+
"type": "string",
|
|
1572
|
+
"x-hyperscale-reference-filter": {
|
|
1573
|
+
"column": "role",
|
|
1574
|
+
"values": [
|
|
1575
|
+
"customer_balance"
|
|
1576
|
+
]
|
|
1577
|
+
}
|
|
1578
|
+
},
|
|
1579
|
+
"premiumAmount": {
|
|
1580
|
+
"description": "Positive minor-unit integer amount serialized as a string (at most 18 digits)",
|
|
1581
|
+
"pattern": "^[1-9][0-9]{0,17}$",
|
|
1582
|
+
"type": "string"
|
|
1583
|
+
},
|
|
1584
|
+
"renewalOfPolicyId": {
|
|
1585
|
+
"description": "Prior policy this quote renews; the prior term must be active or already expired",
|
|
1586
|
+
"pattern": "^pol_(sandbox|live)_[a-z0-9]{8,64}$",
|
|
1587
|
+
"type": "string"
|
|
1588
|
+
},
|
|
1589
|
+
"startsAt": {
|
|
1590
|
+
"format": "hyperscale-date-time",
|
|
1591
|
+
"type": "string"
|
|
1592
|
+
},
|
|
1593
|
+
"termsSummary": {
|
|
1594
|
+
"maxLength": 1000,
|
|
1595
|
+
"minLength": 1,
|
|
1596
|
+
"type": "string"
|
|
1597
|
+
}
|
|
1598
|
+
},
|
|
1599
|
+
"id": "policy",
|
|
1600
|
+
"idPrefix": "pol",
|
|
1601
|
+
"lifecycle": {
|
|
1602
|
+
"initial": "quoted",
|
|
1603
|
+
"states": [
|
|
1604
|
+
"quoted",
|
|
1605
|
+
"bound",
|
|
1606
|
+
"active",
|
|
1607
|
+
"cancel_quoted",
|
|
1608
|
+
"canceled",
|
|
1609
|
+
"expired"
|
|
1610
|
+
],
|
|
1611
|
+
"transitions": {
|
|
1612
|
+
"activate": {
|
|
1613
|
+
"from": [
|
|
1614
|
+
"bound"
|
|
1615
|
+
],
|
|
1616
|
+
"to": "active"
|
|
1617
|
+
},
|
|
1618
|
+
"bind": {
|
|
1619
|
+
"from": [
|
|
1620
|
+
"quoted"
|
|
1621
|
+
],
|
|
1622
|
+
"to": "bound"
|
|
1623
|
+
},
|
|
1624
|
+
"cancel": {
|
|
1625
|
+
"from": [
|
|
1626
|
+
"cancel_quoted"
|
|
1627
|
+
],
|
|
1628
|
+
"to": "canceled"
|
|
1629
|
+
},
|
|
1630
|
+
"endorse": {
|
|
1631
|
+
"from": [
|
|
1632
|
+
"active"
|
|
1633
|
+
],
|
|
1634
|
+
"to": "active"
|
|
1635
|
+
},
|
|
1636
|
+
"expire": {
|
|
1637
|
+
"from": [
|
|
1638
|
+
"active"
|
|
1639
|
+
],
|
|
1640
|
+
"to": "expired"
|
|
1641
|
+
},
|
|
1642
|
+
"preview": {
|
|
1643
|
+
"from": [
|
|
1644
|
+
"bound"
|
|
1645
|
+
],
|
|
1646
|
+
"to": "cancel_quoted"
|
|
1647
|
+
},
|
|
1648
|
+
"withdraw": {
|
|
1649
|
+
"from": [
|
|
1650
|
+
"quoted"
|
|
1651
|
+
],
|
|
1652
|
+
"to": "canceled"
|
|
1653
|
+
}
|
|
1654
|
+
}
|
|
1655
|
+
},
|
|
1656
|
+
"parties": {
|
|
1657
|
+
"beneficiary": "insurerAccountId",
|
|
1658
|
+
"payer": "policyholderAccountId"
|
|
1659
|
+
},
|
|
1660
|
+
"required": [
|
|
1661
|
+
"policyholderAccountId",
|
|
1662
|
+
"insurerAccountId",
|
|
1663
|
+
"premiumAmount",
|
|
1664
|
+
"coverageLimit",
|
|
1665
|
+
"currency",
|
|
1666
|
+
"startsAt",
|
|
1667
|
+
"expiresAt",
|
|
1668
|
+
"perilSchedule"
|
|
1669
|
+
],
|
|
1670
|
+
"subject": {
|
|
1671
|
+
"kinds": [
|
|
1672
|
+
"policy_risk",
|
|
1673
|
+
"flight_itinerary",
|
|
1674
|
+
"lodging_stay",
|
|
1675
|
+
"vehicle",
|
|
1676
|
+
"pet",
|
|
1677
|
+
"traveler_party",
|
|
1678
|
+
"employee_census"
|
|
1679
|
+
]
|
|
1680
|
+
},
|
|
1681
|
+
"summary": "Carrier-backed protection over one declared-value subject.",
|
|
1682
|
+
"title": "Policy",
|
|
1683
|
+
"unwind": {
|
|
1684
|
+
"confirm": "cancel",
|
|
1685
|
+
"penalty": [
|
|
1686
|
+
{
|
|
1687
|
+
"bps": 0
|
|
1688
|
+
}
|
|
1689
|
+
],
|
|
1690
|
+
"quote": "preview",
|
|
1691
|
+
"refundDestinationField": "policyholderAccountId",
|
|
1692
|
+
"refundableField": "premiumAmount"
|
|
1693
|
+
},
|
|
1694
|
+
"update": {
|
|
1695
|
+
"fields": [
|
|
1696
|
+
"startsAt",
|
|
1697
|
+
"expiresAt",
|
|
1698
|
+
"perilSchedule",
|
|
1699
|
+
"termsSummary"
|
|
1700
|
+
],
|
|
1701
|
+
"states": [
|
|
1702
|
+
"quoted"
|
|
1703
|
+
]
|
|
1704
|
+
},
|
|
1705
|
+
"verbs": {
|
|
1706
|
+
"activate": {
|
|
1707
|
+
"description": "Starts cover at the declared time and pays the held premium to the insurer under the machine principal.",
|
|
1708
|
+
"due": {
|
|
1709
|
+
"field": "startsAt"
|
|
1710
|
+
},
|
|
1711
|
+
"earnable": true,
|
|
1712
|
+
"moves": [
|
|
1713
|
+
{
|
|
1714
|
+
"bind": {
|
|
1715
|
+
"amount": {
|
|
1716
|
+
"from": "instance",
|
|
1717
|
+
"path": "fields.premiumAmount"
|
|
1718
|
+
},
|
|
1719
|
+
"currency": {
|
|
1720
|
+
"from": "instance",
|
|
1721
|
+
"path": "fields.currency"
|
|
1722
|
+
},
|
|
1723
|
+
"destinationAccountId": {
|
|
1724
|
+
"from": "instance",
|
|
1725
|
+
"path": "fields.insurerAccountId"
|
|
1726
|
+
},
|
|
1727
|
+
"sourceAccountId": {
|
|
1728
|
+
"from": "instance",
|
|
1729
|
+
"path": "refs.premiumReserveAccountId"
|
|
1730
|
+
},
|
|
1731
|
+
"workspaceId": {
|
|
1732
|
+
"from": "instance",
|
|
1733
|
+
"path": "workspaceId"
|
|
1734
|
+
}
|
|
1735
|
+
},
|
|
1736
|
+
"capture": {
|
|
1737
|
+
"premiumTransferId": "transferId"
|
|
1738
|
+
},
|
|
1739
|
+
"key": "transfer",
|
|
1740
|
+
"operation": "internal_transfer.create"
|
|
1741
|
+
}
|
|
1742
|
+
],
|
|
1743
|
+
"steps": [],
|
|
1744
|
+
"summary": "Activate a policy"
|
|
1745
|
+
},
|
|
1746
|
+
"bind": {
|
|
1747
|
+
"decision": {
|
|
1748
|
+
"capability": "insurance_carrier",
|
|
1749
|
+
"deadlineMs": 15000,
|
|
1750
|
+
"onTimeout": "decline"
|
|
1751
|
+
},
|
|
1752
|
+
"description": "Asks the carrier to accept the risk, then moves the premium into its dedicated reserve until cover starts.",
|
|
1753
|
+
"eventName": "policy.bound",
|
|
1754
|
+
"moves": [
|
|
1755
|
+
{
|
|
1756
|
+
"bind": {
|
|
1757
|
+
"amount": {
|
|
1758
|
+
"from": "instance",
|
|
1759
|
+
"path": "fields.premiumAmount"
|
|
1760
|
+
},
|
|
1761
|
+
"currency": {
|
|
1762
|
+
"from": "instance",
|
|
1763
|
+
"path": "fields.currency"
|
|
1764
|
+
},
|
|
1765
|
+
"destinationAccountId": {
|
|
1766
|
+
"from": "instance",
|
|
1767
|
+
"path": "refs.premiumReserveAccountId"
|
|
1768
|
+
},
|
|
1769
|
+
"sourceAccountId": {
|
|
1770
|
+
"from": "instance",
|
|
1771
|
+
"path": "fields.policyholderAccountId"
|
|
1772
|
+
},
|
|
1773
|
+
"workspaceId": {
|
|
1774
|
+
"from": "instance",
|
|
1775
|
+
"path": "workspaceId"
|
|
1776
|
+
}
|
|
1777
|
+
},
|
|
1778
|
+
"capture": {
|
|
1779
|
+
"premiumFundingTransferId": "transferId"
|
|
1780
|
+
},
|
|
1781
|
+
"key": "transfer",
|
|
1782
|
+
"operation": "internal_transfer.create"
|
|
1783
|
+
}
|
|
1784
|
+
],
|
|
1785
|
+
"steps": [],
|
|
1786
|
+
"summary": "Bind a policy"
|
|
1787
|
+
},
|
|
1788
|
+
"cancel": {
|
|
1789
|
+
"description": "Confirms the previewed cancellation and returns the entire reserved premium to the policyholder before cover starts.",
|
|
1790
|
+
"moves": [
|
|
1791
|
+
{
|
|
1792
|
+
"bind": {
|
|
1793
|
+
"amount": {
|
|
1794
|
+
"from": "instance",
|
|
1795
|
+
"path": "refs.unwindRefund"
|
|
1796
|
+
},
|
|
1797
|
+
"currency": {
|
|
1798
|
+
"from": "instance",
|
|
1799
|
+
"path": "fields.currency"
|
|
1800
|
+
},
|
|
1801
|
+
"destinationAccountId": {
|
|
1802
|
+
"from": "instance",
|
|
1803
|
+
"path": "fields.policyholderAccountId"
|
|
1804
|
+
},
|
|
1805
|
+
"sourceAccountId": {
|
|
1806
|
+
"from": "instance",
|
|
1807
|
+
"path": "refs.premiumReserveAccountId"
|
|
1808
|
+
},
|
|
1809
|
+
"workspaceId": {
|
|
1810
|
+
"from": "instance",
|
|
1811
|
+
"path": "workspaceId"
|
|
1812
|
+
}
|
|
1813
|
+
},
|
|
1814
|
+
"capture": {
|
|
1815
|
+
"premiumRefundTransferId": "transferId"
|
|
1816
|
+
},
|
|
1817
|
+
"key": "transfer",
|
|
1818
|
+
"operation": "internal_transfer.create"
|
|
1819
|
+
}
|
|
1820
|
+
],
|
|
1821
|
+
"steps": [],
|
|
1822
|
+
"summary": "Cancel a policy"
|
|
1823
|
+
},
|
|
1824
|
+
"create": {
|
|
1825
|
+
"description": "Creates a quote against one declared-value risk and provisions the premium reserve. No premium moves until the carrier binds.",
|
|
1826
|
+
"eventName": "policy.quoted",
|
|
1827
|
+
"examples": [
|
|
1828
|
+
{
|
|
1829
|
+
"input": {
|
|
1830
|
+
"coverageLimit": "200000",
|
|
1831
|
+
"currency": "SAR",
|
|
1832
|
+
"expiresAt": "2027-08-01T00:00:00.000Z",
|
|
1833
|
+
"insurerAccountId": "acct_sandbox_insurer0001",
|
|
1834
|
+
"perilSchedule": [
|
|
1835
|
+
{
|
|
1836
|
+
"deductibleBps": 500,
|
|
1837
|
+
"limitAmount": "200000",
|
|
1838
|
+
"peril": "accidental_damage",
|
|
1839
|
+
"waitingPeriodDays": 0
|
|
1840
|
+
},
|
|
1841
|
+
{
|
|
1842
|
+
"deductibleBps": 250,
|
|
1843
|
+
"limitAmount": "200000",
|
|
1844
|
+
"peril": "theft",
|
|
1845
|
+
"waitingPeriodDays": 7
|
|
1846
|
+
}
|
|
1847
|
+
],
|
|
1848
|
+
"policyholderAccountId": "acct_sandbox_holder00001",
|
|
1849
|
+
"premiumAmount": "12500",
|
|
1850
|
+
"startsAt": "2026-08-01T00:00:00.000Z",
|
|
1851
|
+
"subject": "sbj_sandbox_protection001",
|
|
1852
|
+
"termsSummary": "Annual cover for accidental damage and theft."
|
|
1853
|
+
},
|
|
1854
|
+
"name": "quote_asset_protection"
|
|
1855
|
+
}
|
|
1856
|
+
],
|
|
1857
|
+
"moves": [],
|
|
1858
|
+
"requiresRefs": [
|
|
1859
|
+
{
|
|
1860
|
+
"field": "renewalOfPolicyId",
|
|
1861
|
+
"optional": true,
|
|
1862
|
+
"statuses": [
|
|
1863
|
+
"active",
|
|
1864
|
+
"expired"
|
|
1865
|
+
]
|
|
1866
|
+
}
|
|
1867
|
+
],
|
|
1868
|
+
"steps": [
|
|
1869
|
+
{
|
|
1870
|
+
"bind": {
|
|
1871
|
+
"currency": {
|
|
1872
|
+
"from": "instance",
|
|
1873
|
+
"path": "fields.currency"
|
|
1874
|
+
},
|
|
1875
|
+
"owner.id": {
|
|
1876
|
+
"from": "instance",
|
|
1877
|
+
"path": "workspaceId"
|
|
1878
|
+
},
|
|
1879
|
+
"owner.type": {
|
|
1880
|
+
"from": "const",
|
|
1881
|
+
"value": "workspace"
|
|
1882
|
+
},
|
|
1883
|
+
"role": {
|
|
1884
|
+
"from": "const",
|
|
1885
|
+
"value": "workspace_escrow"
|
|
1886
|
+
},
|
|
1887
|
+
"workspaceId": {
|
|
1888
|
+
"from": "instance",
|
|
1889
|
+
"path": "workspaceId"
|
|
1890
|
+
}
|
|
1891
|
+
},
|
|
1892
|
+
"capture": {
|
|
1893
|
+
"premiumReserveAccountId": "accountId"
|
|
1894
|
+
},
|
|
1895
|
+
"operation": "account.escrow.provision"
|
|
1896
|
+
}
|
|
1897
|
+
],
|
|
1898
|
+
"summary": "Quote a policy"
|
|
1899
|
+
},
|
|
1900
|
+
"endorse": {
|
|
1901
|
+
"decision": {
|
|
1902
|
+
"capability": "insurance_carrier",
|
|
1903
|
+
"deadlineMs": 15000,
|
|
1904
|
+
"onTimeout": "decline"
|
|
1905
|
+
},
|
|
1906
|
+
"description": "Applies a carrier-approved mid-term change to active cover: the peril schedule, terms summary, or expiry may be rewritten. No premium moves; mid-term premium adjustment is not modeled.",
|
|
1907
|
+
"examples": [
|
|
1908
|
+
{
|
|
1909
|
+
"input": {
|
|
1910
|
+
"expiresAt": "2027-11-01T00:00:00.000Z",
|
|
1911
|
+
"termsSummary": "Extended cover incl. water damage."
|
|
1912
|
+
},
|
|
1913
|
+
"name": "endorse_extend_active_cover"
|
|
1914
|
+
}
|
|
1915
|
+
],
|
|
1916
|
+
"input": {
|
|
1917
|
+
"additionalProperties": false,
|
|
1918
|
+
"properties": {
|
|
1919
|
+
"expiresAt": {
|
|
1920
|
+
"format": "hyperscale-date-time",
|
|
1921
|
+
"type": "string"
|
|
1922
|
+
},
|
|
1923
|
+
"perilSchedule": {
|
|
1924
|
+
"items": {
|
|
1925
|
+
"additionalProperties": false,
|
|
1926
|
+
"properties": {
|
|
1927
|
+
"deductibleBps": {
|
|
1928
|
+
"maximum": 10000,
|
|
1929
|
+
"minimum": 0,
|
|
1930
|
+
"type": "integer"
|
|
1931
|
+
},
|
|
1932
|
+
"limitAmount": {
|
|
1933
|
+
"description": "Positive minor-unit integer amount serialized as a string (at most 18 digits)",
|
|
1934
|
+
"pattern": "^[1-9][0-9]{0,17}$",
|
|
1935
|
+
"type": "string"
|
|
1936
|
+
},
|
|
1937
|
+
"peril": {
|
|
1938
|
+
"pattern": "^[a-z][a-z0-9_]{1,79}$",
|
|
1939
|
+
"type": "string"
|
|
1940
|
+
},
|
|
1941
|
+
"waitingPeriodDays": {
|
|
1942
|
+
"maximum": 3650,
|
|
1943
|
+
"minimum": 0,
|
|
1944
|
+
"type": "integer"
|
|
1945
|
+
}
|
|
1946
|
+
},
|
|
1947
|
+
"required": [
|
|
1948
|
+
"peril",
|
|
1949
|
+
"limitAmount",
|
|
1950
|
+
"deductibleBps",
|
|
1951
|
+
"waitingPeriodDays"
|
|
1952
|
+
],
|
|
1953
|
+
"type": "object"
|
|
1954
|
+
},
|
|
1955
|
+
"maxItems": 24,
|
|
1956
|
+
"minItems": 1,
|
|
1957
|
+
"type": "array"
|
|
1958
|
+
},
|
|
1959
|
+
"termsSummary": {
|
|
1960
|
+
"maxLength": 1000,
|
|
1961
|
+
"minLength": 1,
|
|
1962
|
+
"type": "string"
|
|
1963
|
+
}
|
|
1964
|
+
},
|
|
1965
|
+
"type": "object"
|
|
1966
|
+
},
|
|
1967
|
+
"moves": [],
|
|
1968
|
+
"steps": [],
|
|
1969
|
+
"summary": "Endorse a policy"
|
|
1970
|
+
},
|
|
1971
|
+
"expire": {
|
|
1972
|
+
"description": "Ends active cover at term under the machine principal. Earned premium remains with the insurer.",
|
|
1973
|
+
"due": {
|
|
1974
|
+
"field": "expiresAt"
|
|
1975
|
+
},
|
|
1976
|
+
"moves": [],
|
|
1977
|
+
"requiresDrainedAccount": {
|
|
1978
|
+
"path": "refs.premiumReserveAccountId"
|
|
1979
|
+
},
|
|
1980
|
+
"steps": [],
|
|
1981
|
+
"summary": "Expire a policy"
|
|
1982
|
+
},
|
|
1983
|
+
"preview": {
|
|
1984
|
+
"description": "Quotes the full premium refund while cover is bound but not active. No money moves until cancellation is confirmed.",
|
|
1985
|
+
"moves": [],
|
|
1986
|
+
"steps": [],
|
|
1987
|
+
"summary": "Preview policy cancellation"
|
|
1988
|
+
},
|
|
1989
|
+
"withdraw": {
|
|
1990
|
+
"description": "Closes an unbound quote. No premium moved, so no cancellation preview is required.",
|
|
1991
|
+
"eventName": "policy.withdrawn",
|
|
1992
|
+
"moves": [],
|
|
1993
|
+
"requiresDrainedAccount": {
|
|
1994
|
+
"path": "refs.premiumReserveAccountId"
|
|
1995
|
+
},
|
|
1996
|
+
"steps": [],
|
|
1997
|
+
"summary": "Withdraw a policy quote"
|
|
1998
|
+
}
|
|
1999
|
+
}
|
|
2000
|
+
},
|
|
2001
|
+
{
|
|
2002
|
+
"description": "A claim is filed against an active policy, assessed, approved or denied, and paid from the insurer account through a held transfer. Approval can be reversed before payment, releasing the insurer's hold without moving settled money.",
|
|
2003
|
+
"fields": {
|
|
2004
|
+
"claimAmount": {
|
|
2005
|
+
"description": "Positive minor-unit integer amount serialized as a string (at most 18 digits)",
|
|
2006
|
+
"pattern": "^[1-9][0-9]{0,17}$",
|
|
2007
|
+
"type": "string"
|
|
2008
|
+
},
|
|
2009
|
+
"claimantAccountId": {
|
|
2010
|
+
"description": "Hyperscale account ID",
|
|
2011
|
+
"pattern": "^acct_(sandbox|live)_[a-z0-9]{8,64}$",
|
|
2012
|
+
"type": "string",
|
|
2013
|
+
"x-hyperscale-reference-filter": {
|
|
2014
|
+
"column": "role",
|
|
2015
|
+
"values": [
|
|
2016
|
+
"customer_balance"
|
|
2017
|
+
]
|
|
2018
|
+
}
|
|
2019
|
+
},
|
|
2020
|
+
"currency": {
|
|
2021
|
+
"description": "ISO 4217 currency code",
|
|
2022
|
+
"maxLength": 3,
|
|
2023
|
+
"minLength": 3,
|
|
2024
|
+
"pattern": "^[A-Z]{3}$",
|
|
2025
|
+
"type": "string"
|
|
2026
|
+
},
|
|
2027
|
+
"evidenceSummary": {
|
|
2028
|
+
"maxLength": 2000,
|
|
2029
|
+
"minLength": 1,
|
|
2030
|
+
"type": "string"
|
|
2031
|
+
},
|
|
2032
|
+
"insurerAccountId": {
|
|
2033
|
+
"description": "Hyperscale account ID",
|
|
2034
|
+
"pattern": "^acct_(sandbox|live)_[a-z0-9]{8,64}$",
|
|
2035
|
+
"type": "string",
|
|
2036
|
+
"x-hyperscale-reference-filter": {
|
|
2037
|
+
"column": "role",
|
|
2038
|
+
"values": [
|
|
2039
|
+
"customer_balance"
|
|
2040
|
+
]
|
|
2041
|
+
}
|
|
2042
|
+
},
|
|
2043
|
+
"occurredAt": {
|
|
2044
|
+
"format": "hyperscale-date-time",
|
|
2045
|
+
"type": "string"
|
|
2046
|
+
},
|
|
2047
|
+
"peril": {
|
|
2048
|
+
"pattern": "^[a-z][a-z0-9_]{1,79}$",
|
|
2049
|
+
"type": "string"
|
|
2050
|
+
},
|
|
2051
|
+
"policyId": {
|
|
2052
|
+
"description": "Active policy this claim is made against",
|
|
2053
|
+
"pattern": "^pol_(sandbox|live)_[a-z0-9]{8,64}$",
|
|
2054
|
+
"type": "string"
|
|
2055
|
+
}
|
|
2056
|
+
},
|
|
2057
|
+
"id": "claim",
|
|
2058
|
+
"idPrefix": "clm",
|
|
2059
|
+
"lifecycle": {
|
|
2060
|
+
"initial": "filed",
|
|
2061
|
+
"states": [
|
|
2062
|
+
"filed",
|
|
2063
|
+
"assessed",
|
|
2064
|
+
"approved",
|
|
2065
|
+
"paid",
|
|
2066
|
+
"denied"
|
|
2067
|
+
],
|
|
2068
|
+
"transitions": {
|
|
2069
|
+
"approve": {
|
|
2070
|
+
"from": [
|
|
2071
|
+
"assessed"
|
|
2072
|
+
],
|
|
2073
|
+
"to": "approved"
|
|
2074
|
+
},
|
|
2075
|
+
"assess": {
|
|
2076
|
+
"from": [
|
|
2077
|
+
"filed"
|
|
2078
|
+
],
|
|
2079
|
+
"to": "assessed"
|
|
2080
|
+
},
|
|
2081
|
+
"attest": {
|
|
2082
|
+
"from": [
|
|
2083
|
+
"assessed"
|
|
2084
|
+
],
|
|
2085
|
+
"to": "approved"
|
|
2086
|
+
},
|
|
2087
|
+
"deny": {
|
|
2088
|
+
"from": [
|
|
2089
|
+
"filed",
|
|
2090
|
+
"assessed"
|
|
2091
|
+
],
|
|
2092
|
+
"to": "denied"
|
|
2093
|
+
},
|
|
2094
|
+
"pay": {
|
|
2095
|
+
"from": [
|
|
2096
|
+
"approved"
|
|
2097
|
+
],
|
|
2098
|
+
"to": "paid"
|
|
2099
|
+
},
|
|
2100
|
+
"reverse": {
|
|
2101
|
+
"from": [
|
|
2102
|
+
"approved"
|
|
2103
|
+
],
|
|
2104
|
+
"to": "denied"
|
|
2105
|
+
}
|
|
2106
|
+
}
|
|
2107
|
+
},
|
|
2108
|
+
"parties": {
|
|
2109
|
+
"beneficiary": "claimantAccountId",
|
|
2110
|
+
"payer": "insurerAccountId"
|
|
2111
|
+
},
|
|
2112
|
+
"required": [
|
|
2113
|
+
"policyId",
|
|
2114
|
+
"claimantAccountId",
|
|
2115
|
+
"insurerAccountId",
|
|
2116
|
+
"claimAmount",
|
|
2117
|
+
"currency",
|
|
2118
|
+
"peril",
|
|
2119
|
+
"occurredAt"
|
|
2120
|
+
],
|
|
2121
|
+
"subject": {
|
|
2122
|
+
"kinds": [
|
|
2123
|
+
"policy_risk",
|
|
2124
|
+
"flight_itinerary",
|
|
2125
|
+
"lodging_stay",
|
|
2126
|
+
"vehicle",
|
|
2127
|
+
"pet",
|
|
2128
|
+
"traveler_party",
|
|
2129
|
+
"employee_census"
|
|
2130
|
+
]
|
|
2131
|
+
},
|
|
2132
|
+
"summary": "Demand against active protection for one covered peril.",
|
|
2133
|
+
"title": "Claim",
|
|
2134
|
+
"update": {
|
|
2135
|
+
"fields": [
|
|
2136
|
+
"evidenceSummary"
|
|
2137
|
+
],
|
|
2138
|
+
"states": [
|
|
2139
|
+
"filed",
|
|
2140
|
+
"assessed"
|
|
2141
|
+
]
|
|
2142
|
+
},
|
|
2143
|
+
"verbs": {
|
|
2144
|
+
"approve": {
|
|
2145
|
+
"decision": {
|
|
2146
|
+
"capability": "insurance_claims_adjuster",
|
|
2147
|
+
"deadlineMs": 15000,
|
|
2148
|
+
"onTimeout": "decline"
|
|
2149
|
+
},
|
|
2150
|
+
"description": "Asks the claims adjuster to approve the assessed demand, then holds the immutable claim amount from the insurer for the claimant. For a carrier that exposes an adjudication API: the verdict is the provider's, taken just in time under a deadline.",
|
|
2151
|
+
"moves": [
|
|
2152
|
+
{
|
|
2153
|
+
"bind": {
|
|
2154
|
+
"amount": {
|
|
2155
|
+
"from": "instance",
|
|
2156
|
+
"path": "fields.claimAmount"
|
|
2157
|
+
},
|
|
2158
|
+
"currency": {
|
|
2159
|
+
"from": "instance",
|
|
2160
|
+
"path": "fields.currency"
|
|
2161
|
+
},
|
|
2162
|
+
"destinationAccountId": {
|
|
2163
|
+
"from": "instance",
|
|
2164
|
+
"path": "fields.claimantAccountId"
|
|
2165
|
+
},
|
|
2166
|
+
"sourceAccountId": {
|
|
2167
|
+
"from": "instance",
|
|
2168
|
+
"path": "fields.insurerAccountId"
|
|
2169
|
+
}
|
|
2170
|
+
},
|
|
2171
|
+
"capture": {
|
|
2172
|
+
"claimTransferId": "transferId"
|
|
2173
|
+
},
|
|
2174
|
+
"key": "transfer",
|
|
2175
|
+
"operation": "internal_transfer.reserve"
|
|
2176
|
+
}
|
|
2177
|
+
],
|
|
2178
|
+
"steps": [],
|
|
2179
|
+
"summary": "Approve a claim"
|
|
2180
|
+
},
|
|
2181
|
+
"assess": {
|
|
2182
|
+
"description": "Marks filed evidence ready for an approval decision. A claim validly filed during cover continues even if the policy term later expires.",
|
|
2183
|
+
"moves": [],
|
|
2184
|
+
"steps": [],
|
|
2185
|
+
"summary": "Assess a claim"
|
|
2186
|
+
},
|
|
2187
|
+
"attest": {
|
|
2188
|
+
"description": "Records the insurer's own approval of the assessed demand, taken outside the platform, and holds the immutable claim amount from the insurer for the claimant. The insurer must be asserted as the acting party. Use this where the carrier exposes no adjudication API; where one exists, approve calls it instead.",
|
|
2189
|
+
"moves": [
|
|
2190
|
+
{
|
|
2191
|
+
"bind": {
|
|
2192
|
+
"amount": {
|
|
2193
|
+
"from": "instance",
|
|
2194
|
+
"path": "fields.claimAmount"
|
|
2195
|
+
},
|
|
2196
|
+
"currency": {
|
|
2197
|
+
"from": "instance",
|
|
2198
|
+
"path": "fields.currency"
|
|
2199
|
+
},
|
|
2200
|
+
"destinationAccountId": {
|
|
2201
|
+
"from": "instance",
|
|
2202
|
+
"path": "fields.claimantAccountId"
|
|
2203
|
+
},
|
|
2204
|
+
"sourceAccountId": {
|
|
2205
|
+
"from": "instance",
|
|
2206
|
+
"path": "fields.insurerAccountId"
|
|
2207
|
+
}
|
|
2208
|
+
},
|
|
2209
|
+
"capture": {
|
|
2210
|
+
"claimTransferId": "transferId"
|
|
2211
|
+
},
|
|
2212
|
+
"key": "transfer",
|
|
2213
|
+
"operation": "internal_transfer.reserve"
|
|
2214
|
+
}
|
|
2215
|
+
],
|
|
2216
|
+
"port": {
|
|
2217
|
+
"allowedParties": [
|
|
2218
|
+
"payer"
|
|
2219
|
+
]
|
|
2220
|
+
},
|
|
2221
|
+
"steps": [],
|
|
2222
|
+
"summary": "Attest an out-of-band claim approval"
|
|
2223
|
+
},
|
|
2224
|
+
"create": {
|
|
2225
|
+
"description": "Records a demand against an active policy and reserves its filed amount against the policy's aggregate coverage limit.",
|
|
2226
|
+
"eventName": "claim.filed",
|
|
2227
|
+
"examples": [
|
|
2228
|
+
{
|
|
2229
|
+
"input": {
|
|
2230
|
+
"claimAmount": "75000",
|
|
2231
|
+
"claimantAccountId": "acct_sandbox_holder00001",
|
|
2232
|
+
"currency": "SAR",
|
|
2233
|
+
"evidenceSummary": "Covered equipment was damaged in an accidental fall.",
|
|
2234
|
+
"insurerAccountId": "acct_sandbox_insurer0001",
|
|
2235
|
+
"occurredAt": "2026-10-14T11:30:00.000Z",
|
|
2236
|
+
"peril": "accidental_damage",
|
|
2237
|
+
"policyId": "pol_sandbox_protection001",
|
|
2238
|
+
"subject": "sbj_sandbox_protection001"
|
|
2239
|
+
},
|
|
2240
|
+
"name": "file_accidental_damage_claim"
|
|
2241
|
+
}
|
|
2242
|
+
],
|
|
2243
|
+
"moves": [],
|
|
2244
|
+
"requiresRefs": [
|
|
2245
|
+
{
|
|
2246
|
+
"field": "policyId",
|
|
2247
|
+
"statuses": [
|
|
2248
|
+
"active"
|
|
2249
|
+
]
|
|
2250
|
+
}
|
|
2251
|
+
],
|
|
2252
|
+
"steps": [],
|
|
2253
|
+
"summary": "File a claim"
|
|
2254
|
+
},
|
|
2255
|
+
"deny": {
|
|
2256
|
+
"description": "Closes a filed or assessed demand before any payout hold exists.",
|
|
2257
|
+
"eventName": "claim.denied",
|
|
2258
|
+
"moves": [],
|
|
2259
|
+
"steps": [],
|
|
2260
|
+
"summary": "Deny a claim"
|
|
2261
|
+
},
|
|
2262
|
+
"pay": {
|
|
2263
|
+
"description": "Posts the approved hold and settles the claim amount into the claimant account.",
|
|
2264
|
+
"eventName": "claim.paid",
|
|
2265
|
+
"moves": [
|
|
2266
|
+
{
|
|
2267
|
+
"bind": {
|
|
2268
|
+
"transferId": {
|
|
2269
|
+
"from": "instance",
|
|
2270
|
+
"path": "refs.claimTransferId"
|
|
2271
|
+
}
|
|
2272
|
+
},
|
|
2273
|
+
"key": "transfer",
|
|
2274
|
+
"operation": "internal_transfer.post"
|
|
2275
|
+
}
|
|
2276
|
+
],
|
|
2277
|
+
"steps": [],
|
|
2278
|
+
"summary": "Pay a claim"
|
|
2279
|
+
},
|
|
2280
|
+
"reverse": {
|
|
2281
|
+
"description": "Voids an approved payout hold before payment and closes the claim denied. No settled money is reversed.",
|
|
2282
|
+
"moves": [
|
|
2283
|
+
{
|
|
2284
|
+
"bind": {
|
|
2285
|
+
"reason": {
|
|
2286
|
+
"from": "const",
|
|
2287
|
+
"value": "Claim approval reversed"
|
|
2288
|
+
},
|
|
2289
|
+
"transferId": {
|
|
2290
|
+
"from": "instance",
|
|
2291
|
+
"path": "refs.claimTransferId"
|
|
2292
|
+
}
|
|
2293
|
+
},
|
|
2294
|
+
"key": "transfer",
|
|
2295
|
+
"operation": "internal_transfer.void"
|
|
2296
|
+
}
|
|
2297
|
+
],
|
|
2298
|
+
"steps": [],
|
|
2299
|
+
"summary": "Reverse claim approval"
|
|
2300
|
+
}
|
|
2301
|
+
}
|
|
2302
|
+
}
|
|
2303
|
+
],
|
|
2304
|
+
"product": "insured_travel",
|
|
2305
|
+
"subjects": [
|
|
2306
|
+
{
|
|
2307
|
+
"declaredValue": "required",
|
|
2308
|
+
"kind": "vehicle",
|
|
2309
|
+
"schema": {
|
|
2310
|
+
"additionalProperties": false,
|
|
2311
|
+
"properties": {
|
|
2312
|
+
"make": {
|
|
2313
|
+
"maxLength": 60,
|
|
2314
|
+
"minLength": 1,
|
|
2315
|
+
"type": "string"
|
|
2316
|
+
},
|
|
2317
|
+
"mileageKm": {
|
|
2318
|
+
"maximum": 9007199254740991,
|
|
2319
|
+
"minimum": 0,
|
|
2320
|
+
"type": "integer"
|
|
2321
|
+
},
|
|
2322
|
+
"model": {
|
|
2323
|
+
"maxLength": 60,
|
|
2324
|
+
"minLength": 1,
|
|
2325
|
+
"type": "string"
|
|
2326
|
+
},
|
|
2327
|
+
"vin": {
|
|
2328
|
+
"maxLength": 17,
|
|
2329
|
+
"minLength": 11,
|
|
2330
|
+
"type": "string"
|
|
2331
|
+
},
|
|
2332
|
+
"year": {
|
|
2333
|
+
"pattern": "^\\d{4}$",
|
|
2334
|
+
"type": "string"
|
|
2335
|
+
}
|
|
2336
|
+
},
|
|
2337
|
+
"required": [
|
|
2338
|
+
"vin",
|
|
2339
|
+
"make",
|
|
2340
|
+
"model",
|
|
2341
|
+
"year",
|
|
2342
|
+
"mileageKm"
|
|
2343
|
+
],
|
|
2344
|
+
"type": "object"
|
|
2345
|
+
},
|
|
2346
|
+
"title": "Vehicle",
|
|
2347
|
+
"version": 1
|
|
2348
|
+
},
|
|
2349
|
+
{
|
|
2350
|
+
"declaredValue": "required",
|
|
2351
|
+
"kind": "policy_risk",
|
|
2352
|
+
"schema": {
|
|
2353
|
+
"additionalProperties": false,
|
|
2354
|
+
"properties": {
|
|
2355
|
+
"category": {
|
|
2356
|
+
"pattern": "^[a-z][a-z0-9_]{1,79}$",
|
|
2357
|
+
"type": "string"
|
|
2358
|
+
},
|
|
2359
|
+
"description": {
|
|
2360
|
+
"maxLength": 500,
|
|
2361
|
+
"minLength": 1,
|
|
2362
|
+
"type": "string"
|
|
2363
|
+
},
|
|
2364
|
+
"jurisdiction": {
|
|
2365
|
+
"maxLength": 80,
|
|
2366
|
+
"minLength": 2,
|
|
2367
|
+
"type": "string"
|
|
2368
|
+
},
|
|
2369
|
+
"reference": {
|
|
2370
|
+
"maxLength": 120,
|
|
2371
|
+
"minLength": 1,
|
|
2372
|
+
"type": "string"
|
|
2373
|
+
}
|
|
2374
|
+
},
|
|
2375
|
+
"required": [
|
|
2376
|
+
"category",
|
|
2377
|
+
"description",
|
|
2378
|
+
"jurisdiction"
|
|
2379
|
+
],
|
|
2380
|
+
"type": "object"
|
|
2381
|
+
},
|
|
2382
|
+
"title": "Policy risk",
|
|
2383
|
+
"version": 1
|
|
2384
|
+
},
|
|
2385
|
+
{
|
|
2386
|
+
"declaredValue": "required",
|
|
2387
|
+
"kind": "flight_itinerary",
|
|
2388
|
+
"schema": {
|
|
2389
|
+
"additionalProperties": false,
|
|
2390
|
+
"properties": {
|
|
2391
|
+
"cabin": {
|
|
2392
|
+
"enum": [
|
|
2393
|
+
"economy",
|
|
2394
|
+
"premium_economy",
|
|
2395
|
+
"business",
|
|
2396
|
+
"first"
|
|
2397
|
+
],
|
|
2398
|
+
"type": "string"
|
|
2399
|
+
},
|
|
2400
|
+
"carrierName": {
|
|
2401
|
+
"maxLength": 80,
|
|
2402
|
+
"minLength": 1,
|
|
2403
|
+
"type": "string"
|
|
2404
|
+
},
|
|
2405
|
+
"destination": {
|
|
2406
|
+
"pattern": "^[A-Z]{3}$",
|
|
2407
|
+
"type": "string"
|
|
2408
|
+
},
|
|
2409
|
+
"flightNumber": {
|
|
2410
|
+
"maxLength": 8,
|
|
2411
|
+
"minLength": 2,
|
|
2412
|
+
"type": "string"
|
|
2413
|
+
},
|
|
2414
|
+
"origin": {
|
|
2415
|
+
"pattern": "^[A-Z]{3}$",
|
|
2416
|
+
"type": "string"
|
|
2417
|
+
}
|
|
2418
|
+
},
|
|
2419
|
+
"required": [
|
|
2420
|
+
"carrierName",
|
|
2421
|
+
"flightNumber",
|
|
2422
|
+
"origin",
|
|
2423
|
+
"destination",
|
|
2424
|
+
"cabin"
|
|
2425
|
+
],
|
|
2426
|
+
"type": "object"
|
|
2427
|
+
},
|
|
2428
|
+
"title": "Flight itinerary",
|
|
2429
|
+
"version": 1
|
|
2430
|
+
},
|
|
2431
|
+
{
|
|
2432
|
+
"declaredValue": "required",
|
|
2433
|
+
"kind": "lodging_stay",
|
|
2434
|
+
"schema": {
|
|
2435
|
+
"additionalProperties": false,
|
|
2436
|
+
"properties": {
|
|
2437
|
+
"city": {
|
|
2438
|
+
"maxLength": 80,
|
|
2439
|
+
"minLength": 1,
|
|
2440
|
+
"type": "string"
|
|
2441
|
+
},
|
|
2442
|
+
"propertyName": {
|
|
2443
|
+
"maxLength": 120,
|
|
2444
|
+
"minLength": 1,
|
|
2445
|
+
"type": "string"
|
|
2446
|
+
},
|
|
2447
|
+
"roomType": {
|
|
2448
|
+
"maxLength": 60,
|
|
2449
|
+
"minLength": 1,
|
|
2450
|
+
"type": "string"
|
|
2451
|
+
}
|
|
2452
|
+
},
|
|
2453
|
+
"required": [
|
|
2454
|
+
"propertyName",
|
|
2455
|
+
"city",
|
|
2456
|
+
"roomType"
|
|
2457
|
+
],
|
|
2458
|
+
"type": "object"
|
|
2459
|
+
},
|
|
2460
|
+
"title": "Lodging stay",
|
|
2461
|
+
"version": 1
|
|
2462
|
+
},
|
|
2463
|
+
{
|
|
2464
|
+
"declaredValue": "required",
|
|
2465
|
+
"kind": "pet",
|
|
2466
|
+
"schema": {
|
|
2467
|
+
"additionalProperties": false,
|
|
2468
|
+
"properties": {
|
|
2469
|
+
"ageYears": {
|
|
2470
|
+
"maximum": 30,
|
|
2471
|
+
"minimum": 0,
|
|
2472
|
+
"type": "integer"
|
|
2473
|
+
},
|
|
2474
|
+
"breed": {
|
|
2475
|
+
"maxLength": 80,
|
|
2476
|
+
"minLength": 1,
|
|
2477
|
+
"type": "string"
|
|
2478
|
+
},
|
|
2479
|
+
"gender": {
|
|
2480
|
+
"enum": [
|
|
2481
|
+
"female",
|
|
2482
|
+
"male"
|
|
2483
|
+
],
|
|
2484
|
+
"type": "string"
|
|
2485
|
+
},
|
|
2486
|
+
"lastCheckupAt": {
|
|
2487
|
+
"format": "hyperscale-date",
|
|
2488
|
+
"type": "string"
|
|
2489
|
+
},
|
|
2490
|
+
"microchipNumber": {
|
|
2491
|
+
"maxLength": 40,
|
|
2492
|
+
"minLength": 1,
|
|
2493
|
+
"type": "string"
|
|
2494
|
+
},
|
|
2495
|
+
"name": {
|
|
2496
|
+
"maxLength": 80,
|
|
2497
|
+
"minLength": 1,
|
|
2498
|
+
"type": "string"
|
|
2499
|
+
},
|
|
2500
|
+
"neutered": {
|
|
2501
|
+
"type": "boolean"
|
|
2502
|
+
},
|
|
2503
|
+
"species": {
|
|
2504
|
+
"enum": [
|
|
2505
|
+
"cat",
|
|
2506
|
+
"dog"
|
|
2507
|
+
],
|
|
2508
|
+
"type": "string"
|
|
2509
|
+
}
|
|
2510
|
+
},
|
|
2511
|
+
"required": [
|
|
2512
|
+
"species",
|
|
2513
|
+
"breed",
|
|
2514
|
+
"ageYears",
|
|
2515
|
+
"gender"
|
|
2516
|
+
],
|
|
2517
|
+
"type": "object"
|
|
2518
|
+
},
|
|
2519
|
+
"title": "Pet",
|
|
2520
|
+
"version": 1
|
|
2521
|
+
},
|
|
2522
|
+
{
|
|
2523
|
+
"declaredValue": "required",
|
|
2524
|
+
"kind": "traveler_party",
|
|
2525
|
+
"schema": {
|
|
2526
|
+
"additionalProperties": false,
|
|
2527
|
+
"properties": {
|
|
2528
|
+
"destinationRegion": {
|
|
2529
|
+
"maxLength": 80,
|
|
2530
|
+
"minLength": 2,
|
|
2531
|
+
"type": "string"
|
|
2532
|
+
},
|
|
2533
|
+
"originCountry": {
|
|
2534
|
+
"pattern": "^[A-Z]{2}$",
|
|
2535
|
+
"type": "string"
|
|
2536
|
+
},
|
|
2537
|
+
"travelers": {
|
|
2538
|
+
"items": {
|
|
2539
|
+
"additionalProperties": false,
|
|
2540
|
+
"properties": {
|
|
2541
|
+
"role": {
|
|
2542
|
+
"enum": [
|
|
2543
|
+
"self",
|
|
2544
|
+
"spouse",
|
|
2545
|
+
"child"
|
|
2546
|
+
],
|
|
2547
|
+
"type": "string"
|
|
2548
|
+
},
|
|
2549
|
+
"yearOfBirth": {
|
|
2550
|
+
"maximum": 2030,
|
|
2551
|
+
"minimum": 1900,
|
|
2552
|
+
"type": "integer"
|
|
2553
|
+
}
|
|
2554
|
+
},
|
|
2555
|
+
"required": [
|
|
2556
|
+
"role",
|
|
2557
|
+
"yearOfBirth"
|
|
2558
|
+
],
|
|
2559
|
+
"type": "object"
|
|
2560
|
+
},
|
|
2561
|
+
"maxItems": 20,
|
|
2562
|
+
"minItems": 1,
|
|
2563
|
+
"type": "array"
|
|
2564
|
+
}
|
|
2565
|
+
},
|
|
2566
|
+
"required": [
|
|
2567
|
+
"travelers",
|
|
2568
|
+
"destinationRegion"
|
|
2569
|
+
],
|
|
2570
|
+
"type": "object"
|
|
2571
|
+
},
|
|
2572
|
+
"title": "Traveler party",
|
|
2573
|
+
"version": 1
|
|
2574
|
+
},
|
|
2575
|
+
{
|
|
2576
|
+
"declaredValue": "required",
|
|
2577
|
+
"kind": "employee_census",
|
|
2578
|
+
"schema": {
|
|
2579
|
+
"additionalProperties": false,
|
|
2580
|
+
"properties": {
|
|
2581
|
+
"dependentCount": {
|
|
2582
|
+
"maximum": 50000,
|
|
2583
|
+
"minimum": 0,
|
|
2584
|
+
"type": "integer"
|
|
2585
|
+
},
|
|
2586
|
+
"entityReference": {
|
|
2587
|
+
"maxLength": 120,
|
|
2588
|
+
"minLength": 1,
|
|
2589
|
+
"type": "string"
|
|
2590
|
+
},
|
|
2591
|
+
"insuranceClasses": {
|
|
2592
|
+
"items": {
|
|
2593
|
+
"maxLength": 60,
|
|
2594
|
+
"minLength": 1,
|
|
2595
|
+
"type": "string"
|
|
2596
|
+
},
|
|
2597
|
+
"maxItems": 12,
|
|
2598
|
+
"minItems": 1,
|
|
2599
|
+
"type": "array"
|
|
2600
|
+
},
|
|
2601
|
+
"primaryCount": {
|
|
2602
|
+
"maximum": 10000,
|
|
2603
|
+
"minimum": 1,
|
|
2604
|
+
"type": "integer"
|
|
2605
|
+
}
|
|
2606
|
+
},
|
|
2607
|
+
"required": [
|
|
2608
|
+
"entityReference",
|
|
2609
|
+
"primaryCount",
|
|
2610
|
+
"dependentCount"
|
|
2611
|
+
],
|
|
2612
|
+
"type": "object"
|
|
2613
|
+
},
|
|
2614
|
+
"title": "Employee census",
|
|
2615
|
+
"version": 1
|
|
2616
|
+
}
|
|
2617
|
+
],
|
|
2618
|
+
"title": "Insured travel",
|
|
2619
|
+
"udl": 1,
|
|
2620
|
+
"version": 1
|
|
2621
|
+
}
|