@voyantjs/bookings 0.1.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 (42) hide show
  1. package/LICENSE +109 -0
  2. package/README.md +42 -0
  3. package/dist/availability-ref.d.ts +418 -0
  4. package/dist/availability-ref.d.ts.map +1 -0
  5. package/dist/availability-ref.js +28 -0
  6. package/dist/extensions/suppliers.d.ts +3 -0
  7. package/dist/extensions/suppliers.d.ts.map +1 -0
  8. package/dist/extensions/suppliers.js +103 -0
  9. package/dist/index.d.ts +20 -0
  10. package/dist/index.d.ts.map +1 -0
  11. package/dist/index.js +25 -0
  12. package/dist/pii.d.ts +29 -0
  13. package/dist/pii.d.ts.map +1 -0
  14. package/dist/pii.js +131 -0
  15. package/dist/products-ref.d.ts +1043 -0
  16. package/dist/products-ref.d.ts.map +1 -0
  17. package/dist/products-ref.js +76 -0
  18. package/dist/routes.d.ts +2171 -0
  19. package/dist/routes.d.ts.map +1 -0
  20. package/dist/routes.js +659 -0
  21. package/dist/schema/travel-details.d.ts +179 -0
  22. package/dist/schema/travel-details.d.ts.map +1 -0
  23. package/dist/schema/travel-details.js +46 -0
  24. package/dist/schema.d.ts +3180 -0
  25. package/dist/schema.d.ts.map +1 -0
  26. package/dist/schema.js +509 -0
  27. package/dist/service.d.ts +5000 -0
  28. package/dist/service.d.ts.map +1 -0
  29. package/dist/service.js +2016 -0
  30. package/dist/tasks/expire-stale-holds.d.ts +12 -0
  31. package/dist/tasks/expire-stale-holds.d.ts.map +1 -0
  32. package/dist/tasks/expire-stale-holds.js +7 -0
  33. package/dist/tasks/index.d.ts +2 -0
  34. package/dist/tasks/index.d.ts.map +1 -0
  35. package/dist/tasks/index.js +1 -0
  36. package/dist/transactions-ref.d.ts +2223 -0
  37. package/dist/transactions-ref.d.ts.map +1 -0
  38. package/dist/transactions-ref.js +147 -0
  39. package/dist/validation.d.ts +643 -0
  40. package/dist/validation.d.ts.map +1 -0
  41. package/dist/validation.js +355 -0
  42. package/package.json +68 -0
@@ -0,0 +1,2171 @@
1
+ import type { PostgresJsDatabase } from "drizzle-orm/postgres-js";
2
+ type KmsBindings = Partial<{
3
+ KMS_PROVIDER: string;
4
+ KMS_ENV_KEY: string;
5
+ KMS_LOCAL_KEY: string;
6
+ GCP_PROJECT_ID: string;
7
+ GCP_SERVICE_ACCOUNT_EMAIL: string;
8
+ GCP_PRIVATE_KEY: string;
9
+ GCP_KMS_KEYRING: string;
10
+ GCP_KMS_LOCATION: string;
11
+ GCP_KMS_PEOPLE_KEY_NAME: string;
12
+ GCP_KMS_INTEGRATIONS_KEY_NAME: string;
13
+ AWS_REGION: string;
14
+ AWS_ACCESS_KEY_ID: string;
15
+ AWS_SECRET_ACCESS_KEY: string;
16
+ AWS_SESSION_TOKEN: string;
17
+ AWS_KMS_ENDPOINT: string;
18
+ AWS_KMS_PEOPLE_KEY_ID: string;
19
+ AWS_KMS_INTEGRATIONS_KEY_ID: string;
20
+ }>;
21
+ type Env = {
22
+ Bindings: KmsBindings;
23
+ Variables: {
24
+ db: PostgresJsDatabase;
25
+ userId?: string;
26
+ actor?: "staff" | "customer" | "partner" | "supplier";
27
+ callerType?: "session" | "api_key" | "internal";
28
+ scopes?: string[] | null;
29
+ isInternalRequest?: boolean;
30
+ authorizeBookingPii?: (args: {
31
+ db: PostgresJsDatabase;
32
+ userId?: string;
33
+ actor?: "staff" | "customer" | "partner" | "supplier";
34
+ callerType?: "session" | "api_key" | "internal";
35
+ scopes?: string[] | null;
36
+ isInternalRequest?: boolean;
37
+ bookingId: string;
38
+ participantId: string;
39
+ action: "read" | "update" | "delete";
40
+ }) => boolean | Promise<boolean>;
41
+ };
42
+ };
43
+ export declare const bookingRoutes: import("hono/hono-base").HonoBase<Env, {
44
+ "/": {
45
+ $get: {
46
+ input: {};
47
+ output: {
48
+ data: {
49
+ id: string;
50
+ bookingNumber: string;
51
+ status: "cancelled" | "draft" | "on_hold" | "confirmed" | "in_progress" | "completed" | "expired";
52
+ personId: string | null;
53
+ organizationId: string | null;
54
+ sourceType: "internal" | "direct" | "manual" | "affiliate" | "ota" | "reseller" | "api_partner";
55
+ externalBookingRef: string | null;
56
+ communicationLanguage: string | null;
57
+ sellCurrency: string;
58
+ baseCurrency: string | null;
59
+ sellAmountCents: number | null;
60
+ baseSellAmountCents: number | null;
61
+ costAmountCents: number | null;
62
+ baseCostAmountCents: number | null;
63
+ marginPercent: number | null;
64
+ startDate: string | null;
65
+ endDate: string | null;
66
+ pax: number | null;
67
+ internalNotes: string | null;
68
+ holdExpiresAt: string | null;
69
+ confirmedAt: string | null;
70
+ expiredAt: string | null;
71
+ cancelledAt: string | null;
72
+ completedAt: string | null;
73
+ redeemedAt: string | null;
74
+ createdAt: string;
75
+ updatedAt: string;
76
+ }[];
77
+ total: number;
78
+ limit: number;
79
+ offset: number;
80
+ };
81
+ outputFormat: "json";
82
+ status: import("hono/utils/http-status").ContentfulStatusCode;
83
+ };
84
+ };
85
+ } & {
86
+ "/:id": {
87
+ $get: {
88
+ input: {
89
+ param: {
90
+ id: string;
91
+ };
92
+ };
93
+ output: {
94
+ error: string;
95
+ };
96
+ outputFormat: "json";
97
+ status: 404;
98
+ } | {
99
+ input: {
100
+ param: {
101
+ id: string;
102
+ };
103
+ };
104
+ output: {
105
+ data: {
106
+ id: string;
107
+ bookingNumber: string;
108
+ status: "cancelled" | "draft" | "on_hold" | "confirmed" | "in_progress" | "completed" | "expired";
109
+ personId: string | null;
110
+ organizationId: string | null;
111
+ sourceType: "internal" | "direct" | "manual" | "affiliate" | "ota" | "reseller" | "api_partner";
112
+ externalBookingRef: string | null;
113
+ communicationLanguage: string | null;
114
+ sellCurrency: string;
115
+ baseCurrency: string | null;
116
+ sellAmountCents: number | null;
117
+ baseSellAmountCents: number | null;
118
+ costAmountCents: number | null;
119
+ baseCostAmountCents: number | null;
120
+ marginPercent: number | null;
121
+ startDate: string | null;
122
+ endDate: string | null;
123
+ pax: number | null;
124
+ internalNotes: string | null;
125
+ holdExpiresAt: string | null;
126
+ confirmedAt: string | null;
127
+ expiredAt: string | null;
128
+ cancelledAt: string | null;
129
+ completedAt: string | null;
130
+ redeemedAt: string | null;
131
+ createdAt: string;
132
+ updatedAt: string;
133
+ };
134
+ };
135
+ outputFormat: "json";
136
+ status: import("hono/utils/http-status").ContentfulStatusCode;
137
+ };
138
+ };
139
+ } & {
140
+ "/reserve": {
141
+ $post: {
142
+ input: {};
143
+ output: {
144
+ data: {
145
+ id: string;
146
+ status: "cancelled" | "draft" | "on_hold" | "confirmed" | "in_progress" | "completed" | "expired";
147
+ createdAt: string;
148
+ updatedAt: string;
149
+ bookingNumber: string;
150
+ personId: string | null;
151
+ organizationId: string | null;
152
+ sourceType: "internal" | "direct" | "manual" | "affiliate" | "ota" | "reseller" | "api_partner";
153
+ externalBookingRef: string | null;
154
+ communicationLanguage: string | null;
155
+ sellCurrency: string;
156
+ baseCurrency: string | null;
157
+ sellAmountCents: number | null;
158
+ baseSellAmountCents: number | null;
159
+ costAmountCents: number | null;
160
+ baseCostAmountCents: number | null;
161
+ marginPercent: number | null;
162
+ startDate: string | null;
163
+ endDate: string | null;
164
+ pax: number | null;
165
+ internalNotes: string | null;
166
+ holdExpiresAt: string | null;
167
+ confirmedAt: string | null;
168
+ expiredAt: string | null;
169
+ cancelledAt: string | null;
170
+ completedAt: string | null;
171
+ redeemedAt: string | null;
172
+ };
173
+ };
174
+ outputFormat: "json";
175
+ status: 201;
176
+ } | {
177
+ input: {};
178
+ output: {
179
+ error: string;
180
+ };
181
+ outputFormat: "json";
182
+ status: 404;
183
+ } | {
184
+ input: {};
185
+ output: {
186
+ error: string;
187
+ };
188
+ outputFormat: "json";
189
+ status: 409;
190
+ } | {
191
+ input: {};
192
+ output: {
193
+ error: string;
194
+ };
195
+ outputFormat: "json";
196
+ status: 400;
197
+ };
198
+ };
199
+ } & {
200
+ "/from-product": {
201
+ $post: {
202
+ input: {};
203
+ output: {
204
+ error: string;
205
+ };
206
+ outputFormat: "json";
207
+ status: 404;
208
+ } | {
209
+ input: {};
210
+ output: {
211
+ data: {
212
+ id: string;
213
+ status: "cancelled" | "draft" | "on_hold" | "confirmed" | "in_progress" | "completed" | "expired";
214
+ createdAt: string;
215
+ updatedAt: string;
216
+ bookingNumber: string;
217
+ personId: string | null;
218
+ organizationId: string | null;
219
+ sourceType: "internal" | "direct" | "manual" | "affiliate" | "ota" | "reseller" | "api_partner";
220
+ externalBookingRef: string | null;
221
+ communicationLanguage: string | null;
222
+ sellCurrency: string;
223
+ baseCurrency: string | null;
224
+ sellAmountCents: number | null;
225
+ baseSellAmountCents: number | null;
226
+ costAmountCents: number | null;
227
+ baseCostAmountCents: number | null;
228
+ marginPercent: number | null;
229
+ startDate: string | null;
230
+ endDate: string | null;
231
+ pax: number | null;
232
+ internalNotes: string | null;
233
+ holdExpiresAt: string | null;
234
+ confirmedAt: string | null;
235
+ expiredAt: string | null;
236
+ cancelledAt: string | null;
237
+ completedAt: string | null;
238
+ redeemedAt: string | null;
239
+ };
240
+ };
241
+ outputFormat: "json";
242
+ status: 201;
243
+ };
244
+ };
245
+ } & {
246
+ "/from-offer/:offerId/reserve": {
247
+ $post: {
248
+ input: {
249
+ param: {
250
+ offerId: string;
251
+ };
252
+ };
253
+ output: {
254
+ error: string;
255
+ };
256
+ outputFormat: "json";
257
+ status: 404;
258
+ } | {
259
+ input: {
260
+ param: {
261
+ offerId: string;
262
+ };
263
+ };
264
+ output: {
265
+ error: string;
266
+ };
267
+ outputFormat: "json";
268
+ status: 409;
269
+ } | {
270
+ input: {
271
+ param: {
272
+ offerId: string;
273
+ };
274
+ };
275
+ output: {
276
+ data: import("hono/utils/types").JSONValue;
277
+ };
278
+ outputFormat: "json";
279
+ status: 201;
280
+ } | {
281
+ input: {
282
+ param: {
283
+ offerId: string;
284
+ };
285
+ };
286
+ output: {
287
+ error: string;
288
+ };
289
+ outputFormat: "json";
290
+ status: 400;
291
+ };
292
+ };
293
+ } & {
294
+ "/from-order/:orderId/reserve": {
295
+ $post: {
296
+ input: {
297
+ param: {
298
+ orderId: string;
299
+ };
300
+ };
301
+ output: {
302
+ error: string;
303
+ };
304
+ outputFormat: "json";
305
+ status: 404;
306
+ } | {
307
+ input: {
308
+ param: {
309
+ orderId: string;
310
+ };
311
+ };
312
+ output: {
313
+ error: string;
314
+ };
315
+ outputFormat: "json";
316
+ status: 409;
317
+ } | {
318
+ input: {
319
+ param: {
320
+ orderId: string;
321
+ };
322
+ };
323
+ output: {
324
+ data: import("hono/utils/types").JSONValue;
325
+ };
326
+ outputFormat: "json";
327
+ status: 201;
328
+ } | {
329
+ input: {
330
+ param: {
331
+ orderId: string;
332
+ };
333
+ };
334
+ output: {
335
+ error: string;
336
+ };
337
+ outputFormat: "json";
338
+ status: 400;
339
+ };
340
+ };
341
+ } & {
342
+ "/": {
343
+ $post: {
344
+ input: {};
345
+ output: {
346
+ error: string;
347
+ details: {
348
+ formErrors: string[];
349
+ fieldErrors: {
350
+ bookingNumber?: string[] | undefined;
351
+ status?: string[] | undefined;
352
+ sellCurrency?: string[] | undefined;
353
+ sourceType?: string[] | undefined;
354
+ personId?: string[] | undefined;
355
+ organizationId?: string[] | undefined;
356
+ externalBookingRef?: string[] | undefined;
357
+ communicationLanguage?: string[] | undefined;
358
+ baseCurrency?: string[] | undefined;
359
+ sellAmountCents?: string[] | undefined;
360
+ baseSellAmountCents?: string[] | undefined;
361
+ costAmountCents?: string[] | undefined;
362
+ baseCostAmountCents?: string[] | undefined;
363
+ marginPercent?: string[] | undefined;
364
+ startDate?: string[] | undefined;
365
+ endDate?: string[] | undefined;
366
+ pax?: string[] | undefined;
367
+ internalNotes?: string[] | undefined;
368
+ holdExpiresAt?: string[] | undefined;
369
+ confirmedAt?: string[] | undefined;
370
+ expiredAt?: string[] | undefined;
371
+ cancelledAt?: string[] | undefined;
372
+ completedAt?: string[] | undefined;
373
+ redeemedAt?: string[] | undefined;
374
+ };
375
+ };
376
+ };
377
+ outputFormat: "json";
378
+ status: 400;
379
+ } | {
380
+ input: {};
381
+ output: {
382
+ data: {
383
+ id: string;
384
+ status: "cancelled" | "draft" | "on_hold" | "confirmed" | "in_progress" | "completed" | "expired";
385
+ createdAt: string;
386
+ updatedAt: string;
387
+ bookingNumber: string;
388
+ personId: string | null;
389
+ organizationId: string | null;
390
+ sourceType: "internal" | "direct" | "manual" | "affiliate" | "ota" | "reseller" | "api_partner";
391
+ externalBookingRef: string | null;
392
+ communicationLanguage: string | null;
393
+ sellCurrency: string;
394
+ baseCurrency: string | null;
395
+ sellAmountCents: number | null;
396
+ baseSellAmountCents: number | null;
397
+ costAmountCents: number | null;
398
+ baseCostAmountCents: number | null;
399
+ marginPercent: number | null;
400
+ startDate: string | null;
401
+ endDate: string | null;
402
+ pax: number | null;
403
+ internalNotes: string | null;
404
+ holdExpiresAt: string | null;
405
+ confirmedAt: string | null;
406
+ expiredAt: string | null;
407
+ cancelledAt: string | null;
408
+ completedAt: string | null;
409
+ redeemedAt: string | null;
410
+ } | null;
411
+ };
412
+ outputFormat: "json";
413
+ status: 201;
414
+ };
415
+ };
416
+ } & {
417
+ "/:id": {
418
+ $patch: {
419
+ input: {
420
+ param: {
421
+ id: string;
422
+ };
423
+ };
424
+ output: {
425
+ error: string;
426
+ };
427
+ outputFormat: "json";
428
+ status: 404;
429
+ } | {
430
+ input: {
431
+ param: {
432
+ id: string;
433
+ };
434
+ };
435
+ output: {
436
+ data: {
437
+ id: string;
438
+ bookingNumber: string;
439
+ status: "cancelled" | "draft" | "on_hold" | "confirmed" | "in_progress" | "completed" | "expired";
440
+ personId: string | null;
441
+ organizationId: string | null;
442
+ sourceType: "internal" | "direct" | "manual" | "affiliate" | "ota" | "reseller" | "api_partner";
443
+ externalBookingRef: string | null;
444
+ communicationLanguage: string | null;
445
+ sellCurrency: string;
446
+ baseCurrency: string | null;
447
+ sellAmountCents: number | null;
448
+ baseSellAmountCents: number | null;
449
+ costAmountCents: number | null;
450
+ baseCostAmountCents: number | null;
451
+ marginPercent: number | null;
452
+ startDate: string | null;
453
+ endDate: string | null;
454
+ pax: number | null;
455
+ internalNotes: string | null;
456
+ holdExpiresAt: string | null;
457
+ confirmedAt: string | null;
458
+ expiredAt: string | null;
459
+ cancelledAt: string | null;
460
+ completedAt: string | null;
461
+ redeemedAt: string | null;
462
+ createdAt: string;
463
+ updatedAt: string;
464
+ };
465
+ };
466
+ outputFormat: "json";
467
+ status: import("hono/utils/http-status").ContentfulStatusCode;
468
+ };
469
+ };
470
+ } & {
471
+ "/:id": {
472
+ $delete: {
473
+ input: {
474
+ param: {
475
+ id: string;
476
+ };
477
+ };
478
+ output: {
479
+ error: string;
480
+ };
481
+ outputFormat: "json";
482
+ status: 404;
483
+ } | {
484
+ input: {
485
+ param: {
486
+ id: string;
487
+ };
488
+ };
489
+ output: {
490
+ success: true;
491
+ };
492
+ outputFormat: "json";
493
+ status: 200;
494
+ };
495
+ };
496
+ } & {
497
+ "/:id/status": {
498
+ $patch: {
499
+ input: {
500
+ param: {
501
+ id: string;
502
+ };
503
+ };
504
+ output: {
505
+ error: string;
506
+ };
507
+ outputFormat: "json";
508
+ status: 404;
509
+ } | {
510
+ input: {
511
+ param: {
512
+ id: string;
513
+ };
514
+ };
515
+ output: {
516
+ error: string;
517
+ };
518
+ outputFormat: "json";
519
+ status: 409;
520
+ } | {
521
+ input: {
522
+ param: {
523
+ id: string;
524
+ };
525
+ };
526
+ output: {
527
+ data: import("hono/utils/types").JSONValue;
528
+ };
529
+ outputFormat: "json";
530
+ status: import("hono/utils/http-status").ContentfulStatusCode;
531
+ } | {
532
+ input: {
533
+ param: {
534
+ id: string;
535
+ };
536
+ };
537
+ output: {
538
+ error: string;
539
+ };
540
+ outputFormat: "json";
541
+ status: 400;
542
+ };
543
+ };
544
+ } & {
545
+ "/:id/confirm": {
546
+ $post: {
547
+ input: {
548
+ param: {
549
+ id: string;
550
+ };
551
+ };
552
+ output: {
553
+ error: string;
554
+ };
555
+ outputFormat: "json";
556
+ status: 404;
557
+ } | {
558
+ input: {
559
+ param: {
560
+ id: string;
561
+ };
562
+ };
563
+ output: {
564
+ error: string;
565
+ };
566
+ outputFormat: "json";
567
+ status: 409;
568
+ } | {
569
+ input: {
570
+ param: {
571
+ id: string;
572
+ };
573
+ };
574
+ output: {
575
+ data: {
576
+ id: string;
577
+ bookingNumber: string;
578
+ status: "cancelled" | "draft" | "on_hold" | "confirmed" | "in_progress" | "completed" | "expired";
579
+ personId: string | null;
580
+ organizationId: string | null;
581
+ sourceType: "internal" | "direct" | "manual" | "affiliate" | "ota" | "reseller" | "api_partner";
582
+ externalBookingRef: string | null;
583
+ communicationLanguage: string | null;
584
+ sellCurrency: string;
585
+ baseCurrency: string | null;
586
+ sellAmountCents: number | null;
587
+ baseSellAmountCents: number | null;
588
+ costAmountCents: number | null;
589
+ baseCostAmountCents: number | null;
590
+ marginPercent: number | null;
591
+ startDate: string | null;
592
+ endDate: string | null;
593
+ pax: number | null;
594
+ internalNotes: string | null;
595
+ holdExpiresAt: string | null;
596
+ confirmedAt: string | null;
597
+ expiredAt: string | null;
598
+ cancelledAt: string | null;
599
+ completedAt: string | null;
600
+ redeemedAt: string | null;
601
+ createdAt: string;
602
+ updatedAt: string;
603
+ } | null;
604
+ };
605
+ outputFormat: "json";
606
+ status: import("hono/utils/http-status").ContentfulStatusCode;
607
+ } | {
608
+ input: {
609
+ param: {
610
+ id: string;
611
+ };
612
+ };
613
+ output: {
614
+ error: string;
615
+ };
616
+ outputFormat: "json";
617
+ status: 400;
618
+ };
619
+ };
620
+ } & {
621
+ "/:id/extend-hold": {
622
+ $post: {
623
+ input: {
624
+ param: {
625
+ id: string;
626
+ };
627
+ };
628
+ output: {
629
+ error: string;
630
+ };
631
+ outputFormat: "json";
632
+ status: 404;
633
+ } | {
634
+ input: {
635
+ param: {
636
+ id: string;
637
+ };
638
+ };
639
+ output: {
640
+ error: string;
641
+ };
642
+ outputFormat: "json";
643
+ status: 409;
644
+ } | {
645
+ input: {
646
+ param: {
647
+ id: string;
648
+ };
649
+ };
650
+ output: {
651
+ data: {
652
+ id: string;
653
+ bookingNumber: string;
654
+ status: "cancelled" | "draft" | "on_hold" | "confirmed" | "in_progress" | "completed" | "expired";
655
+ personId: string | null;
656
+ organizationId: string | null;
657
+ sourceType: "internal" | "direct" | "manual" | "affiliate" | "ota" | "reseller" | "api_partner";
658
+ externalBookingRef: string | null;
659
+ communicationLanguage: string | null;
660
+ sellCurrency: string;
661
+ baseCurrency: string | null;
662
+ sellAmountCents: number | null;
663
+ baseSellAmountCents: number | null;
664
+ costAmountCents: number | null;
665
+ baseCostAmountCents: number | null;
666
+ marginPercent: number | null;
667
+ startDate: string | null;
668
+ endDate: string | null;
669
+ pax: number | null;
670
+ internalNotes: string | null;
671
+ holdExpiresAt: string | null;
672
+ confirmedAt: string | null;
673
+ expiredAt: string | null;
674
+ cancelledAt: string | null;
675
+ completedAt: string | null;
676
+ redeemedAt: string | null;
677
+ createdAt: string;
678
+ updatedAt: string;
679
+ } | null;
680
+ };
681
+ outputFormat: "json";
682
+ status: import("hono/utils/http-status").ContentfulStatusCode;
683
+ } | {
684
+ input: {
685
+ param: {
686
+ id: string;
687
+ };
688
+ };
689
+ output: {
690
+ error: string;
691
+ };
692
+ outputFormat: "json";
693
+ status: 400;
694
+ };
695
+ };
696
+ } & {
697
+ "/:id/expire": {
698
+ $post: {
699
+ input: {
700
+ param: {
701
+ id: string;
702
+ };
703
+ };
704
+ output: {
705
+ error: string;
706
+ };
707
+ outputFormat: "json";
708
+ status: 404;
709
+ } | {
710
+ input: {
711
+ param: {
712
+ id: string;
713
+ };
714
+ };
715
+ output: {
716
+ error: string;
717
+ };
718
+ outputFormat: "json";
719
+ status: 409;
720
+ } | {
721
+ input: {
722
+ param: {
723
+ id: string;
724
+ };
725
+ };
726
+ output: {
727
+ data: {
728
+ id: string;
729
+ bookingNumber: string;
730
+ status: "cancelled" | "draft" | "on_hold" | "confirmed" | "in_progress" | "completed" | "expired";
731
+ personId: string | null;
732
+ organizationId: string | null;
733
+ sourceType: "internal" | "direct" | "manual" | "affiliate" | "ota" | "reseller" | "api_partner";
734
+ externalBookingRef: string | null;
735
+ communicationLanguage: string | null;
736
+ sellCurrency: string;
737
+ baseCurrency: string | null;
738
+ sellAmountCents: number | null;
739
+ baseSellAmountCents: number | null;
740
+ costAmountCents: number | null;
741
+ baseCostAmountCents: number | null;
742
+ marginPercent: number | null;
743
+ startDate: string | null;
744
+ endDate: string | null;
745
+ pax: number | null;
746
+ internalNotes: string | null;
747
+ holdExpiresAt: string | null;
748
+ confirmedAt: string | null;
749
+ expiredAt: string | null;
750
+ cancelledAt: string | null;
751
+ completedAt: string | null;
752
+ redeemedAt: string | null;
753
+ createdAt: string;
754
+ updatedAt: string;
755
+ } | null;
756
+ };
757
+ outputFormat: "json";
758
+ status: import("hono/utils/http-status").ContentfulStatusCode;
759
+ } | {
760
+ input: {
761
+ param: {
762
+ id: string;
763
+ };
764
+ };
765
+ output: {
766
+ error: string;
767
+ };
768
+ outputFormat: "json";
769
+ status: 400;
770
+ };
771
+ };
772
+ } & {
773
+ "/expire-stale": {
774
+ $post: {
775
+ input: {};
776
+ output: {
777
+ expiredIds: string[];
778
+ count: number;
779
+ cutoff: string;
780
+ };
781
+ outputFormat: "json";
782
+ status: import("hono/utils/http-status").ContentfulStatusCode;
783
+ };
784
+ };
785
+ } & {
786
+ "/:id/cancel": {
787
+ $post: {
788
+ input: {
789
+ param: {
790
+ id: string;
791
+ };
792
+ };
793
+ output: {
794
+ error: string;
795
+ };
796
+ outputFormat: "json";
797
+ status: 404;
798
+ } | {
799
+ input: {
800
+ param: {
801
+ id: string;
802
+ };
803
+ };
804
+ output: {
805
+ error: string;
806
+ };
807
+ outputFormat: "json";
808
+ status: 409;
809
+ } | {
810
+ input: {
811
+ param: {
812
+ id: string;
813
+ };
814
+ };
815
+ output: {
816
+ data: {
817
+ id: string;
818
+ bookingNumber: string;
819
+ status: "cancelled" | "draft" | "on_hold" | "confirmed" | "in_progress" | "completed" | "expired";
820
+ personId: string | null;
821
+ organizationId: string | null;
822
+ sourceType: "internal" | "direct" | "manual" | "affiliate" | "ota" | "reseller" | "api_partner";
823
+ externalBookingRef: string | null;
824
+ communicationLanguage: string | null;
825
+ sellCurrency: string;
826
+ baseCurrency: string | null;
827
+ sellAmountCents: number | null;
828
+ baseSellAmountCents: number | null;
829
+ costAmountCents: number | null;
830
+ baseCostAmountCents: number | null;
831
+ marginPercent: number | null;
832
+ startDate: string | null;
833
+ endDate: string | null;
834
+ pax: number | null;
835
+ internalNotes: string | null;
836
+ holdExpiresAt: string | null;
837
+ confirmedAt: string | null;
838
+ expiredAt: string | null;
839
+ cancelledAt: string | null;
840
+ completedAt: string | null;
841
+ redeemedAt: string | null;
842
+ createdAt: string;
843
+ updatedAt: string;
844
+ } | null;
845
+ };
846
+ outputFormat: "json";
847
+ status: import("hono/utils/http-status").ContentfulStatusCode;
848
+ } | {
849
+ input: {
850
+ param: {
851
+ id: string;
852
+ };
853
+ };
854
+ output: {
855
+ error: string;
856
+ };
857
+ outputFormat: "json";
858
+ status: 400;
859
+ };
860
+ };
861
+ } & {
862
+ "/:id/allocations": {
863
+ $get: {
864
+ input: {
865
+ param: {
866
+ id: string;
867
+ };
868
+ };
869
+ output: {
870
+ data: {
871
+ id: string;
872
+ bookingId: string;
873
+ bookingItemId: string;
874
+ productId: string | null;
875
+ optionId: string | null;
876
+ optionUnitId: string | null;
877
+ pricingCategoryId: string | null;
878
+ availabilitySlotId: string | null;
879
+ quantity: number;
880
+ allocationType: "unit" | "pickup" | "resource";
881
+ status: "cancelled" | "confirmed" | "expired" | "fulfilled" | "held" | "released";
882
+ holdExpiresAt: string | null;
883
+ confirmedAt: string | null;
884
+ releasedAt: string | null;
885
+ metadata: {
886
+ [x: string]: import("hono/utils/types").JSONValue;
887
+ } | null;
888
+ createdAt: string;
889
+ updatedAt: string;
890
+ }[];
891
+ };
892
+ outputFormat: "json";
893
+ status: import("hono/utils/http-status").ContentfulStatusCode;
894
+ };
895
+ };
896
+ } & {
897
+ "/:id/participants": {
898
+ $get: {
899
+ input: {
900
+ param: {
901
+ id: string;
902
+ };
903
+ };
904
+ output: {
905
+ data: {
906
+ id: string;
907
+ bookingId: string;
908
+ personId: string | null;
909
+ participantType: "staff" | "other" | "traveler" | "booker" | "contact" | "occupant";
910
+ travelerCategory: "other" | "adult" | "child" | "infant" | "senior" | null;
911
+ firstName: string;
912
+ lastName: string;
913
+ email: string | null;
914
+ phone: string | null;
915
+ preferredLanguage: string | null;
916
+ accessibilityNeeds: string | null;
917
+ specialRequests: string | null;
918
+ isPrimary: boolean;
919
+ notes: string | null;
920
+ createdAt: string;
921
+ updatedAt: string;
922
+ }[];
923
+ };
924
+ outputFormat: "json";
925
+ status: import("hono/utils/http-status").ContentfulStatusCode;
926
+ };
927
+ };
928
+ } & {
929
+ "/:id/participants/:participantId/travel-details": {
930
+ $get: {
931
+ input: {
932
+ param: {
933
+ id: string;
934
+ } & {
935
+ participantId: string;
936
+ };
937
+ };
938
+ output: {
939
+ error: string;
940
+ };
941
+ outputFormat: "json";
942
+ status: 401;
943
+ } | {
944
+ input: {
945
+ param: {
946
+ id: string;
947
+ } & {
948
+ participantId: string;
949
+ };
950
+ };
951
+ output: {
952
+ error: string;
953
+ };
954
+ outputFormat: "json";
955
+ status: 403;
956
+ } | {
957
+ input: {
958
+ param: {
959
+ id: string;
960
+ } & {
961
+ participantId: string;
962
+ };
963
+ };
964
+ output: {
965
+ error: string;
966
+ };
967
+ outputFormat: "json";
968
+ status: 500;
969
+ } | {
970
+ input: {
971
+ param: {
972
+ id: string;
973
+ } & {
974
+ participantId: string;
975
+ };
976
+ };
977
+ output: {
978
+ error: string;
979
+ };
980
+ outputFormat: "json";
981
+ status: 404;
982
+ } | {
983
+ input: {
984
+ param: {
985
+ id: string;
986
+ } & {
987
+ participantId: string;
988
+ };
989
+ };
990
+ output: {
991
+ data: {
992
+ participantId: string;
993
+ nationality: string | null;
994
+ passportNumber: string | null;
995
+ passportExpiry: string | null;
996
+ dateOfBirth: string | null;
997
+ dietaryRequirements: string | null;
998
+ isLeadTraveler: boolean;
999
+ createdAt: string;
1000
+ updatedAt: string;
1001
+ };
1002
+ };
1003
+ outputFormat: "json";
1004
+ status: import("hono/utils/http-status").ContentfulStatusCode;
1005
+ };
1006
+ };
1007
+ } & {
1008
+ "/:id/participants": {
1009
+ $post: {
1010
+ input: {
1011
+ param: {
1012
+ id: string;
1013
+ };
1014
+ };
1015
+ output: {
1016
+ error: string;
1017
+ };
1018
+ outputFormat: "json";
1019
+ status: 404;
1020
+ } | {
1021
+ input: {
1022
+ param: {
1023
+ id: string;
1024
+ };
1025
+ };
1026
+ output: {
1027
+ data: {
1028
+ id: string;
1029
+ notes: string | null;
1030
+ createdAt: string;
1031
+ updatedAt: string;
1032
+ email: string | null;
1033
+ personId: string | null;
1034
+ bookingId: string;
1035
+ participantType: "staff" | "other" | "traveler" | "booker" | "contact" | "occupant";
1036
+ travelerCategory: "other" | "adult" | "child" | "infant" | "senior" | null;
1037
+ firstName: string;
1038
+ lastName: string;
1039
+ phone: string | null;
1040
+ preferredLanguage: string | null;
1041
+ accessibilityNeeds: string | null;
1042
+ specialRequests: string | null;
1043
+ isPrimary: boolean;
1044
+ };
1045
+ };
1046
+ outputFormat: "json";
1047
+ status: 201;
1048
+ };
1049
+ };
1050
+ } & {
1051
+ "/:id/participants/:participantId/travel-details": {
1052
+ $patch: {
1053
+ input: {
1054
+ param: {
1055
+ id: string;
1056
+ } & {
1057
+ participantId: string;
1058
+ };
1059
+ };
1060
+ output: {
1061
+ error: string;
1062
+ };
1063
+ outputFormat: "json";
1064
+ status: 401;
1065
+ } | {
1066
+ input: {
1067
+ param: {
1068
+ id: string;
1069
+ } & {
1070
+ participantId: string;
1071
+ };
1072
+ };
1073
+ output: {
1074
+ error: string;
1075
+ };
1076
+ outputFormat: "json";
1077
+ status: 403;
1078
+ } | {
1079
+ input: {
1080
+ param: {
1081
+ id: string;
1082
+ } & {
1083
+ participantId: string;
1084
+ };
1085
+ };
1086
+ output: {
1087
+ error: string;
1088
+ };
1089
+ outputFormat: "json";
1090
+ status: 500;
1091
+ } | {
1092
+ input: {
1093
+ param: {
1094
+ id: string;
1095
+ } & {
1096
+ participantId: string;
1097
+ };
1098
+ };
1099
+ output: {
1100
+ error: string;
1101
+ };
1102
+ outputFormat: "json";
1103
+ status: 404;
1104
+ } | {
1105
+ input: {
1106
+ param: {
1107
+ id: string;
1108
+ } & {
1109
+ participantId: string;
1110
+ };
1111
+ };
1112
+ output: {
1113
+ data: {
1114
+ participantId: string;
1115
+ nationality: string | null;
1116
+ passportNumber: string | null;
1117
+ passportExpiry: string | null;
1118
+ dateOfBirth: string | null;
1119
+ dietaryRequirements: string | null;
1120
+ isLeadTraveler: boolean;
1121
+ createdAt: string;
1122
+ updatedAt: string;
1123
+ };
1124
+ };
1125
+ outputFormat: "json";
1126
+ status: import("hono/utils/http-status").ContentfulStatusCode;
1127
+ };
1128
+ };
1129
+ } & {
1130
+ "/:id/participants/:participantId": {
1131
+ $patch: {
1132
+ input: {
1133
+ param: {
1134
+ id: string;
1135
+ } & {
1136
+ participantId: string;
1137
+ };
1138
+ };
1139
+ output: {
1140
+ error: string;
1141
+ };
1142
+ outputFormat: "json";
1143
+ status: 404;
1144
+ } | {
1145
+ input: {
1146
+ param: {
1147
+ id: string;
1148
+ } & {
1149
+ participantId: string;
1150
+ };
1151
+ };
1152
+ output: {
1153
+ data: {
1154
+ id: string;
1155
+ bookingId: string;
1156
+ personId: string | null;
1157
+ participantType: "staff" | "other" | "traveler" | "booker" | "contact" | "occupant";
1158
+ travelerCategory: "other" | "adult" | "child" | "infant" | "senior" | null;
1159
+ firstName: string;
1160
+ lastName: string;
1161
+ email: string | null;
1162
+ phone: string | null;
1163
+ preferredLanguage: string | null;
1164
+ accessibilityNeeds: string | null;
1165
+ specialRequests: string | null;
1166
+ isPrimary: boolean;
1167
+ notes: string | null;
1168
+ createdAt: string;
1169
+ updatedAt: string;
1170
+ };
1171
+ };
1172
+ outputFormat: "json";
1173
+ status: import("hono/utils/http-status").ContentfulStatusCode;
1174
+ };
1175
+ };
1176
+ } & {
1177
+ "/:id/participants/:participantId/travel-details": {
1178
+ $delete: {
1179
+ input: {
1180
+ param: {
1181
+ id: string;
1182
+ } & {
1183
+ participantId: string;
1184
+ };
1185
+ };
1186
+ output: {
1187
+ error: string;
1188
+ };
1189
+ outputFormat: "json";
1190
+ status: 401;
1191
+ } | {
1192
+ input: {
1193
+ param: {
1194
+ id: string;
1195
+ } & {
1196
+ participantId: string;
1197
+ };
1198
+ };
1199
+ output: {
1200
+ error: string;
1201
+ };
1202
+ outputFormat: "json";
1203
+ status: 403;
1204
+ } | {
1205
+ input: {
1206
+ param: {
1207
+ id: string;
1208
+ } & {
1209
+ participantId: string;
1210
+ };
1211
+ };
1212
+ output: {
1213
+ error: string;
1214
+ };
1215
+ outputFormat: "json";
1216
+ status: 500;
1217
+ } | {
1218
+ input: {
1219
+ param: {
1220
+ id: string;
1221
+ } & {
1222
+ participantId: string;
1223
+ };
1224
+ };
1225
+ output: {
1226
+ error: string;
1227
+ };
1228
+ outputFormat: "json";
1229
+ status: 404;
1230
+ } | {
1231
+ input: {
1232
+ param: {
1233
+ id: string;
1234
+ } & {
1235
+ participantId: string;
1236
+ };
1237
+ };
1238
+ output: {
1239
+ success: true;
1240
+ };
1241
+ outputFormat: "json";
1242
+ status: 200;
1243
+ };
1244
+ };
1245
+ } & {
1246
+ "/:id/participants/:participantId": {
1247
+ $delete: {
1248
+ input: {
1249
+ param: {
1250
+ id: string;
1251
+ } & {
1252
+ participantId: string;
1253
+ };
1254
+ };
1255
+ output: {
1256
+ error: string;
1257
+ };
1258
+ outputFormat: "json";
1259
+ status: 404;
1260
+ } | {
1261
+ input: {
1262
+ param: {
1263
+ id: string;
1264
+ } & {
1265
+ participantId: string;
1266
+ };
1267
+ };
1268
+ output: {
1269
+ success: true;
1270
+ };
1271
+ outputFormat: "json";
1272
+ status: 200;
1273
+ };
1274
+ };
1275
+ } & {
1276
+ "/:id/passengers": {
1277
+ $get: {
1278
+ input: {
1279
+ param: {
1280
+ id: string;
1281
+ };
1282
+ };
1283
+ output: {
1284
+ data: {
1285
+ id: string;
1286
+ bookingId: string;
1287
+ firstName: string;
1288
+ lastName: string;
1289
+ email: string | null;
1290
+ phone: string | null;
1291
+ specialRequests: string | null;
1292
+ isLeadPassenger: boolean;
1293
+ createdAt: string;
1294
+ updatedAt: string;
1295
+ }[];
1296
+ };
1297
+ outputFormat: "json";
1298
+ status: import("hono/utils/http-status").ContentfulStatusCode;
1299
+ };
1300
+ };
1301
+ } & {
1302
+ "/:id/passengers": {
1303
+ $post: {
1304
+ input: {
1305
+ param: {
1306
+ id: string;
1307
+ };
1308
+ };
1309
+ output: {
1310
+ error: string;
1311
+ };
1312
+ outputFormat: "json";
1313
+ status: 404;
1314
+ } | {
1315
+ input: {
1316
+ param: {
1317
+ id: string;
1318
+ };
1319
+ };
1320
+ output: {
1321
+ data: {
1322
+ id: string;
1323
+ bookingId: string;
1324
+ firstName: string;
1325
+ lastName: string;
1326
+ email: string | null;
1327
+ phone: string | null;
1328
+ specialRequests: string | null;
1329
+ isLeadPassenger: boolean;
1330
+ createdAt: string;
1331
+ updatedAt: string;
1332
+ };
1333
+ };
1334
+ outputFormat: "json";
1335
+ status: 201;
1336
+ };
1337
+ };
1338
+ } & {
1339
+ "/:id/passengers/:passengerId": {
1340
+ $patch: {
1341
+ input: {
1342
+ param: {
1343
+ id: string;
1344
+ } & {
1345
+ passengerId: string;
1346
+ };
1347
+ };
1348
+ output: {
1349
+ error: string;
1350
+ };
1351
+ outputFormat: "json";
1352
+ status: 404;
1353
+ } | {
1354
+ input: {
1355
+ param: {
1356
+ id: string;
1357
+ } & {
1358
+ passengerId: string;
1359
+ };
1360
+ };
1361
+ output: {
1362
+ data: {
1363
+ id: string;
1364
+ bookingId: string;
1365
+ firstName: string;
1366
+ lastName: string;
1367
+ email: string | null;
1368
+ phone: string | null;
1369
+ specialRequests: string | null;
1370
+ isLeadPassenger: boolean;
1371
+ createdAt: string;
1372
+ updatedAt: string;
1373
+ };
1374
+ };
1375
+ outputFormat: "json";
1376
+ status: import("hono/utils/http-status").ContentfulStatusCode;
1377
+ };
1378
+ };
1379
+ } & {
1380
+ "/:id/passengers/:passengerId": {
1381
+ $delete: {
1382
+ input: {
1383
+ param: {
1384
+ id: string;
1385
+ } & {
1386
+ passengerId: string;
1387
+ };
1388
+ };
1389
+ output: {
1390
+ error: string;
1391
+ };
1392
+ outputFormat: "json";
1393
+ status: 404;
1394
+ } | {
1395
+ input: {
1396
+ param: {
1397
+ id: string;
1398
+ } & {
1399
+ passengerId: string;
1400
+ };
1401
+ };
1402
+ output: {
1403
+ success: true;
1404
+ };
1405
+ outputFormat: "json";
1406
+ status: 200;
1407
+ };
1408
+ };
1409
+ } & {
1410
+ "/:id/items": {
1411
+ $get: {
1412
+ input: {
1413
+ param: {
1414
+ id: string;
1415
+ };
1416
+ };
1417
+ output: {
1418
+ data: {
1419
+ id: string;
1420
+ bookingId: string;
1421
+ title: string;
1422
+ description: string | null;
1423
+ itemType: "other" | "unit" | "extra" | "service" | "fee" | "tax" | "discount" | "adjustment" | "accommodation" | "transport";
1424
+ status: "cancelled" | "draft" | "on_hold" | "confirmed" | "expired" | "fulfilled";
1425
+ serviceDate: string | null;
1426
+ startsAt: string | null;
1427
+ endsAt: string | null;
1428
+ quantity: number;
1429
+ sellCurrency: string;
1430
+ unitSellAmountCents: number | null;
1431
+ totalSellAmountCents: number | null;
1432
+ costCurrency: string | null;
1433
+ unitCostAmountCents: number | null;
1434
+ totalCostAmountCents: number | null;
1435
+ notes: string | null;
1436
+ productId: string | null;
1437
+ optionId: string | null;
1438
+ optionUnitId: string | null;
1439
+ pricingCategoryId: string | null;
1440
+ sourceSnapshotId: string | null;
1441
+ sourceOfferId: string | null;
1442
+ metadata: {
1443
+ [x: string]: import("hono/utils/types").JSONValue;
1444
+ } | null;
1445
+ createdAt: string;
1446
+ updatedAt: string;
1447
+ }[];
1448
+ };
1449
+ outputFormat: "json";
1450
+ status: import("hono/utils/http-status").ContentfulStatusCode;
1451
+ };
1452
+ };
1453
+ } & {
1454
+ "/:id/items": {
1455
+ $post: {
1456
+ input: {
1457
+ param: {
1458
+ id: string;
1459
+ };
1460
+ };
1461
+ output: {
1462
+ error: string;
1463
+ };
1464
+ outputFormat: "json";
1465
+ status: 404;
1466
+ } | {
1467
+ input: {
1468
+ param: {
1469
+ id: string;
1470
+ };
1471
+ };
1472
+ output: {
1473
+ data: {
1474
+ id: string;
1475
+ productId: string | null;
1476
+ optionId: string | null;
1477
+ startsAt: string | null;
1478
+ endsAt: string | null;
1479
+ status: "cancelled" | "draft" | "on_hold" | "confirmed" | "expired" | "fulfilled";
1480
+ notes: string | null;
1481
+ createdAt: string;
1482
+ updatedAt: string;
1483
+ sellCurrency: string;
1484
+ bookingId: string;
1485
+ metadata: {
1486
+ [x: string]: import("hono/utils/types").JSONValue;
1487
+ } | null;
1488
+ title: string;
1489
+ description: string | null;
1490
+ itemType: "other" | "unit" | "extra" | "service" | "fee" | "tax" | "discount" | "adjustment" | "accommodation" | "transport";
1491
+ serviceDate: string | null;
1492
+ quantity: number;
1493
+ unitSellAmountCents: number | null;
1494
+ totalSellAmountCents: number | null;
1495
+ costCurrency: string | null;
1496
+ unitCostAmountCents: number | null;
1497
+ totalCostAmountCents: number | null;
1498
+ optionUnitId: string | null;
1499
+ pricingCategoryId: string | null;
1500
+ sourceSnapshotId: string | null;
1501
+ sourceOfferId: string | null;
1502
+ };
1503
+ };
1504
+ outputFormat: "json";
1505
+ status: 201;
1506
+ };
1507
+ };
1508
+ } & {
1509
+ "/:id/items/:itemId": {
1510
+ $patch: {
1511
+ input: {
1512
+ param: {
1513
+ id: string;
1514
+ } & {
1515
+ itemId: string;
1516
+ };
1517
+ };
1518
+ output: {
1519
+ error: string;
1520
+ };
1521
+ outputFormat: "json";
1522
+ status: 404;
1523
+ } | {
1524
+ input: {
1525
+ param: {
1526
+ id: string;
1527
+ } & {
1528
+ itemId: string;
1529
+ };
1530
+ };
1531
+ output: {
1532
+ data: {
1533
+ id: string;
1534
+ bookingId: string;
1535
+ title: string;
1536
+ description: string | null;
1537
+ itemType: "other" | "unit" | "extra" | "service" | "fee" | "tax" | "discount" | "adjustment" | "accommodation" | "transport";
1538
+ status: "cancelled" | "draft" | "on_hold" | "confirmed" | "expired" | "fulfilled";
1539
+ serviceDate: string | null;
1540
+ startsAt: string | null;
1541
+ endsAt: string | null;
1542
+ quantity: number;
1543
+ sellCurrency: string;
1544
+ unitSellAmountCents: number | null;
1545
+ totalSellAmountCents: number | null;
1546
+ costCurrency: string | null;
1547
+ unitCostAmountCents: number | null;
1548
+ totalCostAmountCents: number | null;
1549
+ notes: string | null;
1550
+ productId: string | null;
1551
+ optionId: string | null;
1552
+ optionUnitId: string | null;
1553
+ pricingCategoryId: string | null;
1554
+ sourceSnapshotId: string | null;
1555
+ sourceOfferId: string | null;
1556
+ metadata: {
1557
+ [x: string]: import("hono/utils/types").JSONValue;
1558
+ } | null;
1559
+ createdAt: string;
1560
+ updatedAt: string;
1561
+ };
1562
+ };
1563
+ outputFormat: "json";
1564
+ status: import("hono/utils/http-status").ContentfulStatusCode;
1565
+ };
1566
+ };
1567
+ } & {
1568
+ "/:id/items/:itemId": {
1569
+ $delete: {
1570
+ input: {
1571
+ param: {
1572
+ id: string;
1573
+ } & {
1574
+ itemId: string;
1575
+ };
1576
+ };
1577
+ output: {
1578
+ error: string;
1579
+ };
1580
+ outputFormat: "json";
1581
+ status: 404;
1582
+ } | {
1583
+ input: {
1584
+ param: {
1585
+ id: string;
1586
+ } & {
1587
+ itemId: string;
1588
+ };
1589
+ };
1590
+ output: {
1591
+ success: true;
1592
+ };
1593
+ outputFormat: "json";
1594
+ status: 200;
1595
+ };
1596
+ };
1597
+ } & {
1598
+ "/:id/items/:itemId/participants": {
1599
+ $get: {
1600
+ input: {
1601
+ param: {
1602
+ id: string;
1603
+ } & {
1604
+ itemId: string;
1605
+ };
1606
+ };
1607
+ output: {
1608
+ data: {
1609
+ id: string;
1610
+ bookingItemId: string;
1611
+ participantId: string;
1612
+ role: "other" | "traveler" | "occupant" | "primary_contact" | "service_assignee" | "beneficiary";
1613
+ isPrimary: boolean;
1614
+ createdAt: string;
1615
+ }[];
1616
+ };
1617
+ outputFormat: "json";
1618
+ status: import("hono/utils/http-status").ContentfulStatusCode;
1619
+ };
1620
+ };
1621
+ } & {
1622
+ "/:id/items/:itemId/participants": {
1623
+ $post: {
1624
+ input: {
1625
+ param: {
1626
+ id: string;
1627
+ } & {
1628
+ itemId: string;
1629
+ };
1630
+ };
1631
+ output: {
1632
+ error: string;
1633
+ };
1634
+ outputFormat: "json";
1635
+ status: 404;
1636
+ } | {
1637
+ input: {
1638
+ param: {
1639
+ id: string;
1640
+ } & {
1641
+ itemId: string;
1642
+ };
1643
+ };
1644
+ output: {
1645
+ data: {
1646
+ id: string;
1647
+ createdAt: string;
1648
+ isPrimary: boolean;
1649
+ participantId: string;
1650
+ bookingItemId: string;
1651
+ role: "other" | "traveler" | "occupant" | "primary_contact" | "service_assignee" | "beneficiary";
1652
+ };
1653
+ };
1654
+ outputFormat: "json";
1655
+ status: 201;
1656
+ };
1657
+ };
1658
+ } & {
1659
+ "/:id/items/:itemId/participants/:linkId": {
1660
+ $delete: {
1661
+ input: {
1662
+ param: {
1663
+ id: string;
1664
+ } & {
1665
+ itemId: string;
1666
+ } & {
1667
+ linkId: string;
1668
+ };
1669
+ };
1670
+ output: {
1671
+ error: string;
1672
+ };
1673
+ outputFormat: "json";
1674
+ status: 404;
1675
+ } | {
1676
+ input: {
1677
+ param: {
1678
+ id: string;
1679
+ } & {
1680
+ itemId: string;
1681
+ } & {
1682
+ linkId: string;
1683
+ };
1684
+ };
1685
+ output: {
1686
+ success: true;
1687
+ };
1688
+ outputFormat: "json";
1689
+ status: 200;
1690
+ };
1691
+ };
1692
+ } & {
1693
+ "/:id/supplier-statuses": {
1694
+ $get: {
1695
+ input: {
1696
+ param: {
1697
+ id: string;
1698
+ };
1699
+ };
1700
+ output: {
1701
+ data: {
1702
+ id: string;
1703
+ bookingId: string;
1704
+ supplierServiceId: string | null;
1705
+ serviceName: string;
1706
+ status: "cancelled" | "confirmed" | "pending" | "rejected";
1707
+ supplierReference: string | null;
1708
+ costCurrency: string;
1709
+ costAmountCents: number;
1710
+ notes: string | null;
1711
+ confirmedAt: string | null;
1712
+ createdAt: string;
1713
+ updatedAt: string;
1714
+ }[];
1715
+ };
1716
+ outputFormat: "json";
1717
+ status: import("hono/utils/http-status").ContentfulStatusCode;
1718
+ };
1719
+ };
1720
+ } & {
1721
+ "/:id/supplier-statuses": {
1722
+ $post: {
1723
+ input: {
1724
+ param: {
1725
+ id: string;
1726
+ };
1727
+ };
1728
+ output: {
1729
+ error: string;
1730
+ };
1731
+ outputFormat: "json";
1732
+ status: 404;
1733
+ } | {
1734
+ input: {
1735
+ param: {
1736
+ id: string;
1737
+ };
1738
+ };
1739
+ output: {
1740
+ data: {
1741
+ id: string;
1742
+ status: "cancelled" | "confirmed" | "pending" | "rejected";
1743
+ notes: string | null;
1744
+ createdAt: string;
1745
+ updatedAt: string;
1746
+ costAmountCents: number;
1747
+ confirmedAt: string | null;
1748
+ bookingId: string;
1749
+ costCurrency: string;
1750
+ supplierServiceId: string | null;
1751
+ serviceName: string;
1752
+ supplierReference: string | null;
1753
+ };
1754
+ };
1755
+ outputFormat: "json";
1756
+ status: 201;
1757
+ };
1758
+ };
1759
+ } & {
1760
+ "/:id/supplier-statuses/:statusId": {
1761
+ $patch: {
1762
+ input: {
1763
+ param: {
1764
+ id: string;
1765
+ } & {
1766
+ statusId: string;
1767
+ };
1768
+ };
1769
+ output: {
1770
+ error: string;
1771
+ };
1772
+ outputFormat: "json";
1773
+ status: 404;
1774
+ } | {
1775
+ input: {
1776
+ param: {
1777
+ id: string;
1778
+ } & {
1779
+ statusId: string;
1780
+ };
1781
+ };
1782
+ output: {
1783
+ data: {
1784
+ id: string;
1785
+ bookingId: string;
1786
+ supplierServiceId: string | null;
1787
+ serviceName: string;
1788
+ status: "cancelled" | "confirmed" | "pending" | "rejected";
1789
+ supplierReference: string | null;
1790
+ costCurrency: string;
1791
+ costAmountCents: number;
1792
+ notes: string | null;
1793
+ confirmedAt: string | null;
1794
+ createdAt: string;
1795
+ updatedAt: string;
1796
+ };
1797
+ };
1798
+ outputFormat: "json";
1799
+ status: import("hono/utils/http-status").ContentfulStatusCode;
1800
+ };
1801
+ };
1802
+ } & {
1803
+ "/:id/fulfillments": {
1804
+ $get: {
1805
+ input: {
1806
+ param: {
1807
+ id: string;
1808
+ };
1809
+ };
1810
+ output: {
1811
+ data: {
1812
+ id: string;
1813
+ bookingId: string;
1814
+ bookingItemId: string | null;
1815
+ participantId: string | null;
1816
+ fulfillmentType: "other" | "voucher" | "ticket" | "pdf" | "qr_code" | "barcode" | "mobile";
1817
+ deliveryChannel: "other" | "download" | "email" | "api" | "wallet";
1818
+ status: "pending" | "issued" | "reissued" | "revoked" | "failed";
1819
+ artifactUrl: string | null;
1820
+ payload: {
1821
+ [x: string]: import("hono/utils/types").JSONValue;
1822
+ } | null;
1823
+ issuedAt: string | null;
1824
+ revokedAt: string | null;
1825
+ createdAt: string;
1826
+ updatedAt: string;
1827
+ }[];
1828
+ };
1829
+ outputFormat: "json";
1830
+ status: import("hono/utils/http-status").ContentfulStatusCode;
1831
+ };
1832
+ };
1833
+ } & {
1834
+ "/:id/fulfillments": {
1835
+ $post: {
1836
+ input: {
1837
+ param: {
1838
+ id: string;
1839
+ };
1840
+ };
1841
+ output: {
1842
+ error: string;
1843
+ };
1844
+ outputFormat: "json";
1845
+ status: 404;
1846
+ } | {
1847
+ input: {
1848
+ param: {
1849
+ id: string;
1850
+ };
1851
+ };
1852
+ output: {
1853
+ data: {
1854
+ id: string;
1855
+ status: "pending" | "issued" | "reissued" | "revoked" | "failed";
1856
+ createdAt: string;
1857
+ updatedAt: string;
1858
+ bookingId: string;
1859
+ participantId: string | null;
1860
+ bookingItemId: string | null;
1861
+ fulfillmentType: "other" | "voucher" | "ticket" | "pdf" | "qr_code" | "barcode" | "mobile";
1862
+ deliveryChannel: "other" | "download" | "email" | "api" | "wallet";
1863
+ artifactUrl: string | null;
1864
+ payload: {
1865
+ [x: string]: import("hono/utils/types").JSONValue;
1866
+ } | null;
1867
+ issuedAt: string | null;
1868
+ revokedAt: string | null;
1869
+ };
1870
+ };
1871
+ outputFormat: "json";
1872
+ status: 201;
1873
+ };
1874
+ };
1875
+ } & {
1876
+ "/:id/fulfillments/:fulfillmentId": {
1877
+ $patch: {
1878
+ input: {
1879
+ param: {
1880
+ id: string;
1881
+ } & {
1882
+ fulfillmentId: string;
1883
+ };
1884
+ };
1885
+ output: {
1886
+ error: string;
1887
+ };
1888
+ outputFormat: "json";
1889
+ status: 404;
1890
+ } | {
1891
+ input: {
1892
+ param: {
1893
+ id: string;
1894
+ } & {
1895
+ fulfillmentId: string;
1896
+ };
1897
+ };
1898
+ output: {
1899
+ data: {
1900
+ id: string;
1901
+ bookingId: string;
1902
+ bookingItemId: string | null;
1903
+ participantId: string | null;
1904
+ fulfillmentType: "other" | "voucher" | "ticket" | "pdf" | "qr_code" | "barcode" | "mobile";
1905
+ deliveryChannel: "other" | "download" | "email" | "api" | "wallet";
1906
+ status: "pending" | "issued" | "reissued" | "revoked" | "failed";
1907
+ artifactUrl: string | null;
1908
+ payload: {
1909
+ [x: string]: import("hono/utils/types").JSONValue;
1910
+ } | null;
1911
+ issuedAt: string | null;
1912
+ revokedAt: string | null;
1913
+ createdAt: string;
1914
+ updatedAt: string;
1915
+ };
1916
+ };
1917
+ outputFormat: "json";
1918
+ status: import("hono/utils/http-status").ContentfulStatusCode;
1919
+ };
1920
+ };
1921
+ } & {
1922
+ "/:id/redemptions": {
1923
+ $get: {
1924
+ input: {
1925
+ param: {
1926
+ id: string;
1927
+ };
1928
+ };
1929
+ output: {
1930
+ data: {
1931
+ id: string;
1932
+ bookingId: string;
1933
+ bookingItemId: string | null;
1934
+ participantId: string | null;
1935
+ redeemedAt: string;
1936
+ redeemedBy: string | null;
1937
+ location: string | null;
1938
+ method: "other" | "manual" | "api" | "scan";
1939
+ metadata: {
1940
+ [x: string]: import("hono/utils/types").JSONValue;
1941
+ } | null;
1942
+ createdAt: string;
1943
+ }[];
1944
+ };
1945
+ outputFormat: "json";
1946
+ status: import("hono/utils/http-status").ContentfulStatusCode;
1947
+ };
1948
+ };
1949
+ } & {
1950
+ "/:id/redemptions": {
1951
+ $post: {
1952
+ input: {
1953
+ param: {
1954
+ id: string;
1955
+ };
1956
+ };
1957
+ output: {
1958
+ error: string;
1959
+ };
1960
+ outputFormat: "json";
1961
+ status: 404;
1962
+ } | {
1963
+ input: {
1964
+ param: {
1965
+ id: string;
1966
+ };
1967
+ };
1968
+ output: {
1969
+ data: {
1970
+ id: string;
1971
+ createdAt: string;
1972
+ method: "other" | "manual" | "api" | "scan";
1973
+ redeemedAt: string;
1974
+ bookingId: string;
1975
+ participantId: string | null;
1976
+ metadata: {
1977
+ [x: string]: import("hono/utils/types").JSONValue;
1978
+ } | null;
1979
+ bookingItemId: string | null;
1980
+ redeemedBy: string | null;
1981
+ location: string | null;
1982
+ };
1983
+ };
1984
+ outputFormat: "json";
1985
+ status: 201;
1986
+ };
1987
+ };
1988
+ } & {
1989
+ "/:id/activity": {
1990
+ $get: {
1991
+ input: {
1992
+ param: {
1993
+ id: string;
1994
+ };
1995
+ };
1996
+ output: {
1997
+ data: {
1998
+ id: string;
1999
+ bookingId: string;
2000
+ actorId: string | null;
2001
+ activityType: "booking_created" | "booking_reserved" | "booking_converted" | "booking_confirmed" | "hold_extended" | "hold_expired" | "status_change" | "item_update" | "allocation_released" | "fulfillment_issued" | "fulfillment_updated" | "redemption_recorded" | "supplier_update" | "passenger_update" | "note_added";
2002
+ description: string;
2003
+ metadata: {
2004
+ [x: string]: import("hono/utils/types").JSONValue;
2005
+ } | null;
2006
+ createdAt: string;
2007
+ }[];
2008
+ };
2009
+ outputFormat: "json";
2010
+ status: import("hono/utils/http-status").ContentfulStatusCode;
2011
+ };
2012
+ };
2013
+ } & {
2014
+ "/:id/notes": {
2015
+ $get: {
2016
+ input: {
2017
+ param: {
2018
+ id: string;
2019
+ };
2020
+ };
2021
+ output: {
2022
+ data: {
2023
+ id: string;
2024
+ bookingId: string;
2025
+ authorId: string;
2026
+ content: string;
2027
+ createdAt: string;
2028
+ }[];
2029
+ };
2030
+ outputFormat: "json";
2031
+ status: import("hono/utils/http-status").ContentfulStatusCode;
2032
+ };
2033
+ };
2034
+ } & {
2035
+ "/:id/notes": {
2036
+ $post: {
2037
+ input: {
2038
+ param: {
2039
+ id: string;
2040
+ };
2041
+ };
2042
+ output: {
2043
+ error: string;
2044
+ };
2045
+ outputFormat: "json";
2046
+ status: 400;
2047
+ } | {
2048
+ input: {
2049
+ param: {
2050
+ id: string;
2051
+ };
2052
+ };
2053
+ output: {
2054
+ error: string;
2055
+ };
2056
+ outputFormat: "json";
2057
+ status: 404;
2058
+ } | {
2059
+ input: {
2060
+ param: {
2061
+ id: string;
2062
+ };
2063
+ };
2064
+ output: {
2065
+ data: {
2066
+ id: string;
2067
+ createdAt: string;
2068
+ bookingId: string;
2069
+ authorId: string;
2070
+ content: string;
2071
+ };
2072
+ };
2073
+ outputFormat: "json";
2074
+ status: 201;
2075
+ };
2076
+ };
2077
+ } & {
2078
+ "/:id/documents": {
2079
+ $get: {
2080
+ input: {
2081
+ param: {
2082
+ id: string;
2083
+ };
2084
+ };
2085
+ output: {
2086
+ data: {
2087
+ id: string;
2088
+ bookingId: string;
2089
+ participantId: string | null;
2090
+ type: "visa" | "insurance" | "health" | "passport_copy" | "other";
2091
+ fileName: string;
2092
+ fileUrl: string;
2093
+ expiresAt: string | null;
2094
+ notes: string | null;
2095
+ createdAt: string;
2096
+ }[];
2097
+ };
2098
+ outputFormat: "json";
2099
+ status: import("hono/utils/http-status").ContentfulStatusCode;
2100
+ };
2101
+ };
2102
+ } & {
2103
+ "/:id/documents": {
2104
+ $post: {
2105
+ input: {
2106
+ param: {
2107
+ id: string;
2108
+ };
2109
+ };
2110
+ output: {
2111
+ error: string;
2112
+ };
2113
+ outputFormat: "json";
2114
+ status: 404;
2115
+ } | {
2116
+ input: {
2117
+ param: {
2118
+ id: string;
2119
+ };
2120
+ };
2121
+ output: {
2122
+ data: {
2123
+ type: "visa" | "insurance" | "health" | "passport_copy" | "other";
2124
+ id: string;
2125
+ notes: string | null;
2126
+ createdAt: string;
2127
+ bookingId: string;
2128
+ participantId: string | null;
2129
+ fileName: string;
2130
+ fileUrl: string;
2131
+ expiresAt: string | null;
2132
+ };
2133
+ };
2134
+ outputFormat: "json";
2135
+ status: 201;
2136
+ };
2137
+ };
2138
+ } & {
2139
+ "/:id/documents/:documentId": {
2140
+ $delete: {
2141
+ input: {
2142
+ param: {
2143
+ id: string;
2144
+ } & {
2145
+ documentId: string;
2146
+ };
2147
+ };
2148
+ output: {
2149
+ error: string;
2150
+ };
2151
+ outputFormat: "json";
2152
+ status: 404;
2153
+ } | {
2154
+ input: {
2155
+ param: {
2156
+ id: string;
2157
+ } & {
2158
+ documentId: string;
2159
+ };
2160
+ };
2161
+ output: {
2162
+ success: true;
2163
+ };
2164
+ outputFormat: "json";
2165
+ status: 200;
2166
+ };
2167
+ };
2168
+ }, "/", "/:id/documents/:documentId">;
2169
+ export type BookingRoutes = typeof bookingRoutes;
2170
+ export {};
2171
+ //# sourceMappingURL=routes.d.ts.map