@voyantjs/customer-portal 0.6.8 → 0.6.9
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/dist/index.d.ts +2 -2
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +1 -1
- package/dist/routes-public.d.ts +20 -50
- package/dist/routes-public.d.ts.map +1 -1
- package/dist/routes-public.js +3 -3
- package/dist/service-public.d.ts +4 -3
- package/dist/service-public.d.ts.map +1 -1
- package/dist/service-public.js +119 -172
- package/dist/validation-public.d.ts +85 -49
- package/dist/validation-public.d.ts.map +1 -1
- package/dist/validation-public.js +17 -33
- package/package.json +10 -10
package/dist/index.d.ts
CHANGED
|
@@ -6,8 +6,8 @@ export { customerPortalRoutes } from "./routes.js";
|
|
|
6
6
|
export type { PublicCustomerPortalRoutes } from "./routes-public.js";
|
|
7
7
|
export { createPublicCustomerPortalRoutes, publicCustomerPortalRoutes } from "./routes-public.js";
|
|
8
8
|
export { publicCustomerPortalService } from "./service-public.js";
|
|
9
|
-
export type { BootstrapCustomerPortalInput, BootstrapCustomerPortalResult, CreateCustomerPortalCompanionInput, CustomerPortalAddress, CustomerPortalBookingBillingContact, CustomerPortalBookingDetail, CustomerPortalBookingDocument, CustomerPortalBookingFinancialDocument, CustomerPortalBookingFinancials, CustomerPortalBookingPayment, CustomerPortalBookingSummary, CustomerPortalBootstrapCandidate, CustomerPortalCompanion, CustomerPortalContactExistsQuery, CustomerPortalContactExistsResult, CustomerPortalPhoneContactExistsQuery, CustomerPortalPhoneContactExistsResult, CustomerPortalProfile, ImportCustomerPortalBookingParticipantsInput, ImportCustomerPortalBookingParticipantsResult, UpdateCustomerPortalAddressInput, UpdateCustomerPortalCompanionInput, UpdateCustomerPortalProfileInput, } from "./validation-public.js";
|
|
10
|
-
export { bootstrapCustomerPortalResultSchema, bootstrapCustomerPortalSchema, createCustomerPortalCompanionSchema, customerPortalAddressSchema, customerPortalBookingBillingContactSchema, customerPortalBookingDetailSchema, customerPortalBookingDocumentSchema, customerPortalBookingFinancialDocumentSchema, customerPortalBookingFinancialsSchema, customerPortalBookingPaymentSchema, customerPortalBookingSummarySchema, customerPortalBootstrapCandidateSchema, customerPortalCompanionSchema, customerPortalContactExistsQuerySchema, customerPortalContactExistsResultSchema, customerPortalPhoneContactExistsQuerySchema, customerPortalPhoneContactExistsResultSchema, customerPortalProfileSchema, importCustomerPortalBookingParticipantsResultSchema, importCustomerPortalBookingParticipantsSchema, updateCustomerPortalAddressSchema, updateCustomerPortalCompanionSchema, updateCustomerPortalProfileSchema, } from "./validation-public.js";
|
|
9
|
+
export type { BootstrapCustomerPortalInput, BootstrapCustomerPortalResult, CreateCustomerPortalCompanionInput, CustomerPortalAddress, CustomerPortalBookingBillingContact, CustomerPortalBookingDetail, CustomerPortalBookingDocument, CustomerPortalBookingFinancialDocument, CustomerPortalBookingFinancials, CustomerPortalBookingPayment, CustomerPortalBookingSummary, CustomerPortalBootstrapCandidate, CustomerPortalCompanion, CustomerPortalContactExistsQuery, CustomerPortalContactExistsResult, CustomerPortalPhoneContactExistsQuery, CustomerPortalPhoneContactExistsResult, CustomerPortalProfile, ImportCustomerPortalBookingParticipantsInput, ImportCustomerPortalBookingParticipantsResult, ImportCustomerPortalBookingTravelersInput, ImportCustomerPortalBookingTravelersResult, UpdateCustomerPortalAddressInput, UpdateCustomerPortalCompanionInput, UpdateCustomerPortalProfileInput, } from "./validation-public.js";
|
|
10
|
+
export { bootstrapCustomerPortalResultSchema, bootstrapCustomerPortalSchema, createCustomerPortalCompanionSchema, customerPortalAddressSchema, customerPortalBookingBillingContactSchema, customerPortalBookingDetailSchema, customerPortalBookingDocumentSchema, customerPortalBookingFinancialDocumentSchema, customerPortalBookingFinancialsSchema, customerPortalBookingPaymentSchema, customerPortalBookingSummarySchema, customerPortalBootstrapCandidateSchema, customerPortalCompanionSchema, customerPortalContactExistsQuerySchema, customerPortalContactExistsResultSchema, customerPortalPhoneContactExistsQuerySchema, customerPortalPhoneContactExistsResultSchema, customerPortalProfileSchema, importCustomerPortalBookingParticipantsResultSchema, importCustomerPortalBookingParticipantsSchema, importCustomerPortalBookingTravelersResultSchema, importCustomerPortalBookingTravelersSchema, updateCustomerPortalAddressSchema, updateCustomerPortalCompanionSchema, updateCustomerPortalProfileSchema, } from "./validation-public.js";
|
|
11
11
|
export declare const customerPortalModule: Module;
|
|
12
12
|
export declare function createCustomerPortalHonoModule(options?: PublicCustomerPortalRouteOptions): HonoModule;
|
|
13
13
|
export declare const customerPortalHonoModule: HonoModule;
|
package/dist/index.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,MAAM,EAAE,MAAM,gBAAgB,CAAA;AAC5C,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,uBAAuB,CAAA;AAMvD,OAAO,EAEL,KAAK,gCAAgC,EACtC,MAAM,oBAAoB,CAAA;AAE3B,YAAY,EAAE,oBAAoB,EAAE,MAAM,aAAa,CAAA;AACvD,OAAO,EAAE,oBAAoB,EAAE,MAAM,aAAa,CAAA;AAClD,YAAY,EAAE,0BAA0B,EAAE,MAAM,oBAAoB,CAAA;AACpE,OAAO,EAAE,gCAAgC,EAAE,0BAA0B,EAAE,MAAM,oBAAoB,CAAA;AACjG,OAAO,EAAE,2BAA2B,EAAE,MAAM,qBAAqB,CAAA;AACjE,YAAY,EACV,4BAA4B,EAC5B,6BAA6B,EAC7B,kCAAkC,EAClC,qBAAqB,EACrB,mCAAmC,EACnC,2BAA2B,EAC3B,6BAA6B,EAC7B,sCAAsC,EACtC,+BAA+B,EAC/B,4BAA4B,EAC5B,4BAA4B,EAC5B,gCAAgC,EAChC,uBAAuB,EACvB,gCAAgC,EAChC,iCAAiC,EACjC,qCAAqC,EACrC,sCAAsC,EACtC,qBAAqB,EACrB,4CAA4C,EAC5C,6CAA6C,EAC7C,gCAAgC,EAChC,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+3,7 @@ import { createPublicCustomerPortalRoutes, } from "./routes-public.js";
|
|
|
3
3
|
export { customerPortalRoutes } from "./routes.js";
|
|
4
4
|
export { createPublicCustomerPortalRoutes, publicCustomerPortalRoutes } from "./routes-public.js";
|
|
5
5
|
export { publicCustomerPortalService } from "./service-public.js";
|
|
6
|
-
export { bootstrapCustomerPortalResultSchema, bootstrapCustomerPortalSchema, createCustomerPortalCompanionSchema, customerPortalAddressSchema, customerPortalBookingBillingContactSchema, customerPortalBookingDetailSchema, customerPortalBookingDocumentSchema, customerPortalBookingFinancialDocumentSchema, customerPortalBookingFinancialsSchema, customerPortalBookingPaymentSchema, customerPortalBookingSummarySchema, customerPortalBootstrapCandidateSchema, customerPortalCompanionSchema, customerPortalContactExistsQuerySchema, customerPortalContactExistsResultSchema, customerPortalPhoneContactExistsQuerySchema, customerPortalPhoneContactExistsResultSchema, customerPortalProfileSchema, importCustomerPortalBookingParticipantsResultSchema, importCustomerPortalBookingParticipantsSchema, updateCustomerPortalAddressSchema, updateCustomerPortalCompanionSchema, updateCustomerPortalProfileSchema, } from "./validation-public.js";
|
|
6
|
+
export { bootstrapCustomerPortalResultSchema, bootstrapCustomerPortalSchema, createCustomerPortalCompanionSchema, customerPortalAddressSchema, customerPortalBookingBillingContactSchema, customerPortalBookingDetailSchema, customerPortalBookingDocumentSchema, customerPortalBookingFinancialDocumentSchema, customerPortalBookingFinancialsSchema, customerPortalBookingPaymentSchema, customerPortalBookingSummarySchema, customerPortalBootstrapCandidateSchema, customerPortalCompanionSchema, customerPortalContactExistsQuerySchema, customerPortalContactExistsResultSchema, customerPortalPhoneContactExistsQuerySchema, customerPortalPhoneContactExistsResultSchema, customerPortalProfileSchema, importCustomerPortalBookingParticipantsResultSchema, importCustomerPortalBookingParticipantsSchema, importCustomerPortalBookingTravelersResultSchema, importCustomerPortalBookingTravelersSchema, updateCustomerPortalAddressSchema, updateCustomerPortalCompanionSchema, updateCustomerPortalProfileSchema, } from "./validation-public.js";
|
|
7
7
|
export const customerPortalModule = {
|
|
8
8
|
name: "customer-portal",
|
|
9
9
|
};
|
package/dist/routes-public.d.ts
CHANGED
|
@@ -63,9 +63,6 @@ export declare function createPublicCustomerPortalRoutes(options?: PublicCustome
|
|
|
63
63
|
birthday: string | null;
|
|
64
64
|
email: string | null;
|
|
65
65
|
phone: string | null;
|
|
66
|
-
address: string | null;
|
|
67
|
-
city: string | null;
|
|
68
|
-
country: string | null;
|
|
69
66
|
billingAddress: {
|
|
70
67
|
id: string;
|
|
71
68
|
label: "service" | "primary" | "other" | "billing" | "shipping" | "mailing" | "meeting" | "legal";
|
|
@@ -177,9 +174,6 @@ export declare function createPublicCustomerPortalRoutes(options?: PublicCustome
|
|
|
177
174
|
birthday: string | null;
|
|
178
175
|
email: string | null;
|
|
179
176
|
phone: string | null;
|
|
180
|
-
address: string | null;
|
|
181
|
-
city: string | null;
|
|
182
|
-
country: string | null;
|
|
183
177
|
billingAddress: {
|
|
184
178
|
id: string;
|
|
185
179
|
label: "service" | "primary" | "other" | "billing" | "shipping" | "mailing" | "meeting" | "legal";
|
|
@@ -274,9 +268,6 @@ export declare function createPublicCustomerPortalRoutes(options?: PublicCustome
|
|
|
274
268
|
birthday: string | null;
|
|
275
269
|
email: string | null;
|
|
276
270
|
phone: string | null;
|
|
277
|
-
address: string | null;
|
|
278
|
-
city: string | null;
|
|
279
|
-
country: string | null;
|
|
280
271
|
billingAddress: {
|
|
281
272
|
id: string;
|
|
282
273
|
label: "service" | "primary" | "other" | "billing" | "shipping" | "mailing" | "meeting" | "legal";
|
|
@@ -366,9 +357,6 @@ export declare function createPublicCustomerPortalRoutes(options?: PublicCustome
|
|
|
366
357
|
birthday: string | null;
|
|
367
358
|
email: string | null;
|
|
368
359
|
phone: string | null;
|
|
369
|
-
address: string | null;
|
|
370
|
-
city: string | null;
|
|
371
|
-
country: string | null;
|
|
372
360
|
billingAddress: {
|
|
373
361
|
id: string;
|
|
374
362
|
label: "service" | "primary" | "other" | "billing" | "shipping" | "mailing" | "meeting" | "legal";
|
|
@@ -394,9 +382,6 @@ export declare function createPublicCustomerPortalRoutes(options?: PublicCustome
|
|
|
394
382
|
birthday: string | null;
|
|
395
383
|
email: string | null;
|
|
396
384
|
phone: string | null;
|
|
397
|
-
address: string | null;
|
|
398
|
-
city: string | null;
|
|
399
|
-
country: string | null;
|
|
400
385
|
billingAddress: {
|
|
401
386
|
id: string;
|
|
402
387
|
label: "service" | "primary" | "other" | "billing" | "shipping" | "mailing" | "meeting" | "legal";
|
|
@@ -524,7 +509,7 @@ export declare function createPublicCustomerPortalRoutes(options?: PublicCustome
|
|
|
524
509
|
};
|
|
525
510
|
};
|
|
526
511
|
}) & {
|
|
527
|
-
"/companions/import-booking-
|
|
512
|
+
"/companions/import-booking-travelers": {
|
|
528
513
|
$post: {
|
|
529
514
|
input: {};
|
|
530
515
|
output: {
|
|
@@ -632,7 +617,7 @@ export declare function createPublicCustomerPortalRoutes(options?: PublicCustome
|
|
|
632
617
|
pax: number | null;
|
|
633
618
|
confirmedAt: string | null;
|
|
634
619
|
completedAt: string | null;
|
|
635
|
-
|
|
620
|
+
travelerCount: number;
|
|
636
621
|
primaryTravelerName: string | null;
|
|
637
622
|
}[];
|
|
638
623
|
};
|
|
@@ -672,9 +657,9 @@ export declare function createPublicCustomerPortalRoutes(options?: PublicCustome
|
|
|
672
657
|
confirmedAt: string | null;
|
|
673
658
|
cancelledAt: string | null;
|
|
674
659
|
completedAt: string | null;
|
|
675
|
-
|
|
660
|
+
travelers: {
|
|
676
661
|
id: string;
|
|
677
|
-
participantType: "
|
|
662
|
+
participantType: "other" | "traveler" | "occupant";
|
|
678
663
|
firstName: string;
|
|
679
664
|
lastName: string;
|
|
680
665
|
isPrimary: boolean;
|
|
@@ -693,10 +678,10 @@ export declare function createPublicCustomerPortalRoutes(options?: PublicCustome
|
|
|
693
678
|
unitSellAmountCents: number | null;
|
|
694
679
|
totalSellAmountCents: number | null;
|
|
695
680
|
notes: string | null;
|
|
696
|
-
|
|
681
|
+
travelerLinks: {
|
|
697
682
|
id: string;
|
|
698
|
-
|
|
699
|
-
role: "other" | "traveler" | "occupant" | "
|
|
683
|
+
travelerId: string;
|
|
684
|
+
role: "other" | "traveler" | "occupant" | "beneficiary";
|
|
700
685
|
isPrimary: boolean;
|
|
701
686
|
}[];
|
|
702
687
|
}[];
|
|
@@ -714,7 +699,7 @@ export declare function createPublicCustomerPortalRoutes(options?: PublicCustome
|
|
|
714
699
|
documents: {
|
|
715
700
|
id: string;
|
|
716
701
|
source: "legal" | "finance" | "booking_document";
|
|
717
|
-
|
|
702
|
+
travelerId: string | null;
|
|
718
703
|
type: "visa" | "other" | "insurance" | "health" | "passport_copy" | "invoice" | "proforma" | "credit_note" | "contract";
|
|
719
704
|
fileName: string;
|
|
720
705
|
fileUrl: string;
|
|
@@ -755,7 +740,7 @@ export declare function createPublicCustomerPortalRoutes(options?: PublicCustome
|
|
|
755
740
|
fulfillments: {
|
|
756
741
|
id: string;
|
|
757
742
|
bookingItemId: string | null;
|
|
758
|
-
|
|
743
|
+
travelerId: string | null;
|
|
759
744
|
fulfillmentType: "other" | "voucher" | "ticket" | "pdf" | "qr_code" | "barcode" | "mobile";
|
|
760
745
|
deliveryChannel: "email" | "other" | "download" | "api" | "wallet";
|
|
761
746
|
status: "pending" | "issued" | "reissued" | "revoked" | "failed";
|
|
@@ -790,7 +775,7 @@ export declare function createPublicCustomerPortalRoutes(options?: PublicCustome
|
|
|
790
775
|
data: {
|
|
791
776
|
id: string;
|
|
792
777
|
source: "legal" | "finance" | "booking_document";
|
|
793
|
-
|
|
778
|
+
travelerId: string | null;
|
|
794
779
|
type: "visa" | "other" | "insurance" | "health" | "passport_copy" | "invoice" | "proforma" | "credit_note" | "contract";
|
|
795
780
|
fileName: string;
|
|
796
781
|
fileUrl: string;
|
|
@@ -891,9 +876,6 @@ export declare const publicCustomerPortalRoutes: import("hono/hono-base").HonoBa
|
|
|
891
876
|
birthday: string | null;
|
|
892
877
|
email: string | null;
|
|
893
878
|
phone: string | null;
|
|
894
|
-
address: string | null;
|
|
895
|
-
city: string | null;
|
|
896
|
-
country: string | null;
|
|
897
879
|
billingAddress: {
|
|
898
880
|
id: string;
|
|
899
881
|
label: "service" | "primary" | "other" | "billing" | "shipping" | "mailing" | "meeting" | "legal";
|
|
@@ -1005,9 +987,6 @@ export declare const publicCustomerPortalRoutes: import("hono/hono-base").HonoBa
|
|
|
1005
987
|
birthday: string | null;
|
|
1006
988
|
email: string | null;
|
|
1007
989
|
phone: string | null;
|
|
1008
|
-
address: string | null;
|
|
1009
|
-
city: string | null;
|
|
1010
|
-
country: string | null;
|
|
1011
990
|
billingAddress: {
|
|
1012
991
|
id: string;
|
|
1013
992
|
label: "service" | "primary" | "other" | "billing" | "shipping" | "mailing" | "meeting" | "legal";
|
|
@@ -1102,9 +1081,6 @@ export declare const publicCustomerPortalRoutes: import("hono/hono-base").HonoBa
|
|
|
1102
1081
|
birthday: string | null;
|
|
1103
1082
|
email: string | null;
|
|
1104
1083
|
phone: string | null;
|
|
1105
|
-
address: string | null;
|
|
1106
|
-
city: string | null;
|
|
1107
|
-
country: string | null;
|
|
1108
1084
|
billingAddress: {
|
|
1109
1085
|
id: string;
|
|
1110
1086
|
label: "service" | "primary" | "other" | "billing" | "shipping" | "mailing" | "meeting" | "legal";
|
|
@@ -1194,9 +1170,6 @@ export declare const publicCustomerPortalRoutes: import("hono/hono-base").HonoBa
|
|
|
1194
1170
|
birthday: string | null;
|
|
1195
1171
|
email: string | null;
|
|
1196
1172
|
phone: string | null;
|
|
1197
|
-
address: string | null;
|
|
1198
|
-
city: string | null;
|
|
1199
|
-
country: string | null;
|
|
1200
1173
|
billingAddress: {
|
|
1201
1174
|
id: string;
|
|
1202
1175
|
label: "service" | "primary" | "other" | "billing" | "shipping" | "mailing" | "meeting" | "legal";
|
|
@@ -1222,9 +1195,6 @@ export declare const publicCustomerPortalRoutes: import("hono/hono-base").HonoBa
|
|
|
1222
1195
|
birthday: string | null;
|
|
1223
1196
|
email: string | null;
|
|
1224
1197
|
phone: string | null;
|
|
1225
|
-
address: string | null;
|
|
1226
|
-
city: string | null;
|
|
1227
|
-
country: string | null;
|
|
1228
1198
|
billingAddress: {
|
|
1229
1199
|
id: string;
|
|
1230
1200
|
label: "service" | "primary" | "other" | "billing" | "shipping" | "mailing" | "meeting" | "legal";
|
|
@@ -1352,7 +1322,7 @@ export declare const publicCustomerPortalRoutes: import("hono/hono-base").HonoBa
|
|
|
1352
1322
|
};
|
|
1353
1323
|
};
|
|
1354
1324
|
}) & {
|
|
1355
|
-
"/companions/import-booking-
|
|
1325
|
+
"/companions/import-booking-travelers": {
|
|
1356
1326
|
$post: {
|
|
1357
1327
|
input: {};
|
|
1358
1328
|
output: {
|
|
@@ -1460,7 +1430,7 @@ export declare const publicCustomerPortalRoutes: import("hono/hono-base").HonoBa
|
|
|
1460
1430
|
pax: number | null;
|
|
1461
1431
|
confirmedAt: string | null;
|
|
1462
1432
|
completedAt: string | null;
|
|
1463
|
-
|
|
1433
|
+
travelerCount: number;
|
|
1464
1434
|
primaryTravelerName: string | null;
|
|
1465
1435
|
}[];
|
|
1466
1436
|
};
|
|
@@ -1500,9 +1470,9 @@ export declare const publicCustomerPortalRoutes: import("hono/hono-base").HonoBa
|
|
|
1500
1470
|
confirmedAt: string | null;
|
|
1501
1471
|
cancelledAt: string | null;
|
|
1502
1472
|
completedAt: string | null;
|
|
1503
|
-
|
|
1473
|
+
travelers: {
|
|
1504
1474
|
id: string;
|
|
1505
|
-
participantType: "
|
|
1475
|
+
participantType: "other" | "traveler" | "occupant";
|
|
1506
1476
|
firstName: string;
|
|
1507
1477
|
lastName: string;
|
|
1508
1478
|
isPrimary: boolean;
|
|
@@ -1521,10 +1491,10 @@ export declare const publicCustomerPortalRoutes: import("hono/hono-base").HonoBa
|
|
|
1521
1491
|
unitSellAmountCents: number | null;
|
|
1522
1492
|
totalSellAmountCents: number | null;
|
|
1523
1493
|
notes: string | null;
|
|
1524
|
-
|
|
1494
|
+
travelerLinks: {
|
|
1525
1495
|
id: string;
|
|
1526
|
-
|
|
1527
|
-
role: "other" | "traveler" | "occupant" | "
|
|
1496
|
+
travelerId: string;
|
|
1497
|
+
role: "other" | "traveler" | "occupant" | "beneficiary";
|
|
1528
1498
|
isPrimary: boolean;
|
|
1529
1499
|
}[];
|
|
1530
1500
|
}[];
|
|
@@ -1542,7 +1512,7 @@ export declare const publicCustomerPortalRoutes: import("hono/hono-base").HonoBa
|
|
|
1542
1512
|
documents: {
|
|
1543
1513
|
id: string;
|
|
1544
1514
|
source: "legal" | "finance" | "booking_document";
|
|
1545
|
-
|
|
1515
|
+
travelerId: string | null;
|
|
1546
1516
|
type: "visa" | "other" | "insurance" | "health" | "passport_copy" | "invoice" | "proforma" | "credit_note" | "contract";
|
|
1547
1517
|
fileName: string;
|
|
1548
1518
|
fileUrl: string;
|
|
@@ -1583,7 +1553,7 @@ export declare const publicCustomerPortalRoutes: import("hono/hono-base").HonoBa
|
|
|
1583
1553
|
fulfillments: {
|
|
1584
1554
|
id: string;
|
|
1585
1555
|
bookingItemId: string | null;
|
|
1586
|
-
|
|
1556
|
+
travelerId: string | null;
|
|
1587
1557
|
fulfillmentType: "other" | "voucher" | "ticket" | "pdf" | "qr_code" | "barcode" | "mobile";
|
|
1588
1558
|
deliveryChannel: "email" | "other" | "download" | "api" | "wallet";
|
|
1589
1559
|
status: "pending" | "issued" | "reissued" | "revoked" | "failed";
|
|
@@ -1618,7 +1588,7 @@ export declare const publicCustomerPortalRoutes: import("hono/hono-base").HonoBa
|
|
|
1618
1588
|
data: {
|
|
1619
1589
|
id: string;
|
|
1620
1590
|
source: "legal" | "finance" | "booking_document";
|
|
1621
|
-
|
|
1591
|
+
travelerId: string | null;
|
|
1622
1592
|
type: "visa" | "other" | "insurance" | "health" | "passport_copy" | "invoice" | "proforma" | "credit_note" | "contract";
|
|
1623
1593
|
fileName: string;
|
|
1624
1594
|
fileUrl: string;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"routes-public.d.ts","sourceRoot":"","sources":["../src/routes-public.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,gBAAgB,CAAA;AAErD,OAAO,KAAK,EAAE,kBAAkB,EAAE,MAAM,yBAAyB,CAAA;AAkBjE,KAAK,GAAG,GAAG;IACT,QAAQ,EAAE,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,CAAA;IACjC,SAAS,EAAE;QACT,SAAS,CAAC,EAAE,eAAe,CAAA;QAC3B,EAAE,EAAE,kBAAkB,CAAA;QACtB,MAAM,CAAC,EAAE,MAAM,CAAA;KAChB,CAAA;CACF,CAAA;AAoBD,MAAM,WAAW,gCAAgC;IAC/C,0BAA0B,CAAC,EAAE,CAC3B,QAAQ,EAAE,OAAO,EACjB,UAAU,EAAE,MAAM,KACf,OAAO,CAAC,MAAM,GAAG,IAAI,CAAC,GAAG,MAAM,GAAG,IAAI,CAAA;CAC5C;AAED,wBAAgB,gCAAgC,CAAC,OAAO,GAAE,gCAAqC
|
|
1
|
+
{"version":3,"file":"routes-public.d.ts","sourceRoot":"","sources":["../src/routes-public.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,gBAAgB,CAAA;AAErD,OAAO,KAAK,EAAE,kBAAkB,EAAE,MAAM,yBAAyB,CAAA;AAkBjE,KAAK,GAAG,GAAG;IACT,QAAQ,EAAE,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,CAAA;IACjC,SAAS,EAAE;QACT,SAAS,CAAC,EAAE,eAAe,CAAA;QAC3B,EAAE,EAAE,kBAAkB,CAAA;QACtB,MAAM,CAAC,EAAE,MAAM,CAAA;KAChB,CAAA;CACF,CAAA;AAoBD,MAAM,WAAW,gCAAgC;IAC/C,0BAA0B,CAAC,EAAE,CAC3B,QAAQ,EAAE,OAAO,EACjB,UAAU,EAAE,MAAM,KACf,OAAO,CAAC,MAAM,GAAG,IAAI,CAAC,GAAG,MAAM,GA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;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;+CAAqC,CAAA;AAE5E,MAAM,MAAM,0BAA0B,GAAG,OAAO,0BAA0B,CAAA"}
|
package/dist/routes-public.js
CHANGED
|
@@ -3,7 +3,7 @@ import { Hono } from "hono";
|
|
|
3
3
|
import { buildPublicCustomerPortalRouteRuntime, CUSTOMER_PORTAL_ROUTE_RUNTIME_CONTAINER_KEY, } from "./route-runtime.js";
|
|
4
4
|
import { customerPortalRoutes } from "./routes.js";
|
|
5
5
|
import { publicCustomerPortalService } from "./service-public.js";
|
|
6
|
-
import { bootstrapCustomerPortalSchema, createCustomerPortalCompanionSchema,
|
|
6
|
+
import { bootstrapCustomerPortalSchema, createCustomerPortalCompanionSchema, importCustomerPortalBookingTravelersSchema, updateCustomerPortalCompanionSchema, updateCustomerPortalProfileSchema, } from "./validation-public.js";
|
|
7
7
|
function notFound(c, error) {
|
|
8
8
|
return c.json({ error }, 404);
|
|
9
9
|
}
|
|
@@ -68,9 +68,9 @@ export function createPublicCustomerPortalRoutes(options = {}) {
|
|
|
68
68
|
}
|
|
69
69
|
return c.json({ data: companion }, 201);
|
|
70
70
|
})
|
|
71
|
-
.post("/companions/import-booking-
|
|
71
|
+
.post("/companions/import-booking-travelers", async (c) => {
|
|
72
72
|
const userId = requireUserId(c);
|
|
73
|
-
const result = await publicCustomerPortalService.
|
|
73
|
+
const result = await publicCustomerPortalService.importBookingTravelersAsCompanions(c.get("db"), userId, await parseJsonBody(c, importCustomerPortalBookingTravelersSchema));
|
|
74
74
|
if (!result) {
|
|
75
75
|
return c.json({ error: "Customer record is not linked to this account" }, 409);
|
|
76
76
|
}
|
package/dist/service-public.d.ts
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { type KmsProvider } from "@voyantjs/utils";
|
|
2
2
|
import type { PostgresJsDatabase } from "drizzle-orm/postgres-js";
|
|
3
|
-
import type { BootstrapCustomerPortalInput, BootstrapCustomerPortalResult, CreateCustomerPortalCompanionInput, CustomerPortalBookingDetail, CustomerPortalBookingSummary, CustomerPortalCompanion, CustomerPortalContactExistsResult, CustomerPortalPhoneContactExistsResult, CustomerPortalProfile,
|
|
3
|
+
import type { BootstrapCustomerPortalInput, BootstrapCustomerPortalResult, CreateCustomerPortalCompanionInput, CustomerPortalBookingDetail, CustomerPortalBookingSummary, CustomerPortalCompanion, CustomerPortalContactExistsResult, CustomerPortalPhoneContactExistsResult, CustomerPortalProfile, ImportCustomerPortalBookingTravelersInput, ImportCustomerPortalBookingTravelersResult, UpdateCustomerPortalCompanionInput, UpdateCustomerPortalProfileInput } from "./validation-public.js";
|
|
4
4
|
interface CustomerPortalServiceOptions {
|
|
5
5
|
kms?: KmsProvider | null;
|
|
6
6
|
resolveDocumentDownloadUrl?: (storageKey: string) => Promise<string | null> | string | null;
|
|
@@ -24,7 +24,8 @@ export declare const publicCustomerPortalService: {
|
|
|
24
24
|
error: "not_found" | "customer_record_not_found" | "customer_record_claimed";
|
|
25
25
|
}>;
|
|
26
26
|
listCompanions(db: PostgresJsDatabase, userId: string): Promise<CustomerPortalCompanion[]>;
|
|
27
|
-
|
|
27
|
+
importBookingTravelersAsCompanions(db: PostgresJsDatabase, userId: string, input: ImportCustomerPortalBookingTravelersInput): Promise<ImportCustomerPortalBookingTravelersResult | null>;
|
|
28
|
+
importBookingParticipantsAsCompanions(db: PostgresJsDatabase, userId: string, input: ImportCustomerPortalBookingTravelersInput): Promise<ImportCustomerPortalBookingTravelersResult | null>;
|
|
28
29
|
createCompanion(db: PostgresJsDatabase, userId: string, input: CreateCustomerPortalCompanionInput): Promise<CustomerPortalCompanion | null>;
|
|
29
30
|
updateCompanion(db: PostgresJsDatabase, userId: string, companionId: string, input: UpdateCustomerPortalCompanionInput): Promise<CustomerPortalCompanion | null | "forbidden">;
|
|
30
31
|
deleteCompanion(db: PostgresJsDatabase, userId: string, companionId: string): Promise<"deleted" | "not_found" | "forbidden">;
|
|
@@ -33,7 +34,7 @@ export declare const publicCustomerPortalService: {
|
|
|
33
34
|
listBookingDocuments(db: PostgresJsDatabase, userId: string, bookingId: string, options?: CustomerPortalServiceOptions): Promise<{
|
|
34
35
|
id: string;
|
|
35
36
|
source: "legal" | "finance" | "booking_document";
|
|
36
|
-
|
|
37
|
+
travelerId: string | null;
|
|
37
38
|
type: "visa" | "other" | "insurance" | "health" | "passport_copy" | "invoice" | "proforma" | "credit_note" | "contract";
|
|
38
39
|
fileName: string;
|
|
39
40
|
fileUrl: string;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"service-public.d.ts","sourceRoot":"","sources":["../src/service-public.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"service-public.d.ts","sourceRoot":"","sources":["../src/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