@revolugo/booking-api-client 7.9.2 → 7.10.0-rc.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.
@@ -1,4 +1,4 @@
1
- import { BookingApi, BookingCreateApi, BookingsApiResponse, PaymentMethodUpdatePayloadApi } from '../models/index.ts';
1
+ import { BookingApi, BookingCreateApi, BookingsApiResponse, PaymentMethodUpdatePayloadApi, RequestPayload } from '../models/index.ts';
2
2
  /**
3
3
  * Revolugo Booking API Reference
4
4
  * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator)
@@ -49,6 +49,10 @@ export interface BookingsConfirmPayLaterPayload {
49
49
  export interface BookingsConfirmPayload {
50
50
  id: string;
51
51
  }
52
+ export interface BookingsSubmitRequestPayload {
53
+ token: string;
54
+ requestPayload?: RequestPayload;
55
+ }
52
56
  export interface BookingsUpdatePaymentMethodsPayload {
53
57
  id: string;
54
58
  paymentMethodUpdatePayloadApi?: PaymentMethodUpdatePayloadApi;
@@ -249,6 +253,27 @@ export interface BookingsInterface {
249
253
  minCallCount?: number;
250
254
  maxCallCount?: number;
251
255
  }): Promise<BookingApi>;
256
+ /**
257
+ * Submit a categorised customer request linked to the booking. Triggers a notification email to the care team and a confirmation email to the customer.
258
+ * @summary Submit a customer request for a Booking
259
+ * @param {string} token Booking token returned by **[Retrieve Booking](/v1/documentation#operation/getV1BookingsId)**. ⚠️ For security reasons, this token is unique and once generated, it is valid during a period of 10 minutes.
260
+ * @param {RequestPayload} [requestPayload] Submit a customer request for a Booking
261
+ * @param {*} [options] Override http request option.
262
+ * @throws {RequiredError}
263
+ * @memberof BookingsInterface
264
+ */
265
+ submitRequestRaw(requestParameters: BookingsSubmitRequestPayload, initOverrides?: RequestInit & {
266
+ minCallCount?: number;
267
+ maxCallCount?: number;
268
+ }): Promise<runtime.ApiResponse<string>>;
269
+ /**
270
+ * Submit a categorised customer request linked to the booking. Triggers a notification email to the care team and a confirmation email to the customer.
271
+ * Submit a customer request for a Booking
272
+ */
273
+ submitRequest(requestParameters: BookingsSubmitRequestPayload, initOverrides?: RequestInit & {
274
+ minCallCount?: number;
275
+ maxCallCount?: number;
276
+ }): Promise<string>;
252
277
  /**
253
278
  * Updates an ongoing Booking payment methods
254
279
  * @summary Updates an ongoing Booking payment methods
@@ -392,6 +417,19 @@ export declare class Bookings extends runtime.BaseAPI implements BookingsInterfa
392
417
  * Confirm an ongoing Booking
393
418
  */
394
419
  confirm(requestParameters: BookingsConfirmPayload, initOverrides?: RequestInit): Promise<BookingApi>;
420
+ /**
421
+ * Submit a categorised customer request linked to the booking. Triggers a notification email to the care team and a confirmation email to the customer.
422
+ * Submit a customer request for a Booking
423
+ */
424
+ submitRequestRaw(requestParameters: BookingsSubmitRequestPayload, initOverrides?: RequestInit & {
425
+ minCallCount?: number;
426
+ maxCallCount?: number;
427
+ }): Promise<runtime.ApiResponse<string>>;
428
+ /**
429
+ * Submit a categorised customer request linked to the booking. Triggers a notification email to the care team and a confirmation email to the customer.
430
+ * Submit a customer request for a Booking
431
+ */
432
+ submitRequest(requestParameters: BookingsSubmitRequestPayload, initOverrides?: RequestInit): Promise<string>;
395
433
  /**
396
434
  * Updates an ongoing Booking payment methods
397
435
  * Updates an ongoing Booking payment methods
@@ -0,0 +1,50 @@
1
+ /**
2
+ * Revolugo Booking API Reference
3
+ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator)
4
+ *
5
+ * The version of the OpenAPI document: 1.5.0
6
+ *
7
+ *
8
+ * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
9
+ * https://openapi-generator.tech
10
+ * Do not edit the class manually.
11
+ */
12
+ /**
13
+ *
14
+ * @export
15
+ * @interface Addon
16
+ */
17
+ export interface Addon {
18
+ /**
19
+ *
20
+ * @type {number}
21
+ * @memberof Addon
22
+ */
23
+ price: number;
24
+ /**
25
+ *
26
+ * @type {number}
27
+ * @memberof Addon
28
+ */
29
+ taxIncludedPrice: number;
30
+ /**
31
+ *
32
+ * @type {string}
33
+ * @memberof Addon
34
+ */
35
+ type: AddonTypeEnum;
36
+ }
37
+ /**
38
+ * @export
39
+ */
40
+ export declare const AddonTypeEnum: {
41
+ readonly Insurance: "insurance";
42
+ };
43
+ export type AddonTypeEnum = typeof AddonTypeEnum[keyof typeof AddonTypeEnum];
44
+ /**
45
+ * Check if a given object implements the Addon interface.
46
+ */
47
+ export declare function instanceOfAddon(value: object): boolean;
48
+ export declare function AddonFromJSON(json: any): Addon;
49
+ export declare function AddonFromJSONTyped(json: any, ignoreDiscriminator: boolean): Addon;
50
+ export declare function AddonToJSON(value?: Addon | null): any;
@@ -0,0 +1,38 @@
1
+ /**
2
+ * Revolugo Booking API Reference
3
+ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator)
4
+ *
5
+ * The version of the OpenAPI document: 1.5.0
6
+ *
7
+ *
8
+ * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
9
+ * https://openapi-generator.tech
10
+ * Do not edit the class manually.
11
+ */
12
+ /**
13
+ *
14
+ * @export
15
+ * @interface AddonSelection
16
+ */
17
+ export interface AddonSelection {
18
+ /**
19
+ *
20
+ * @type {string}
21
+ * @memberof AddonSelection
22
+ */
23
+ type: AddonSelectionTypeEnum;
24
+ }
25
+ /**
26
+ * @export
27
+ */
28
+ export declare const AddonSelectionTypeEnum: {
29
+ readonly Insurance: "insurance";
30
+ };
31
+ export type AddonSelectionTypeEnum = typeof AddonSelectionTypeEnum[keyof typeof AddonSelectionTypeEnum];
32
+ /**
33
+ * Check if a given object implements the AddonSelection interface.
34
+ */
35
+ export declare function instanceOfAddonSelection(value: object): boolean;
36
+ export declare function AddonSelectionFromJSON(json: any): AddonSelection;
37
+ export declare function AddonSelectionFromJSONTyped(json: any, ignoreDiscriminator: boolean): AddonSelection;
38
+ export declare function AddonSelectionToJSON(value?: AddonSelection | null): any;
@@ -1,5 +1,6 @@
1
1
  import { BookingCreateApiGuestsListInner } from './BookingCreateApiGuestsListInner';
2
2
  import { ContactPersonApi } from './ContactPersonApi';
3
+ import { OrderAddonSelection } from './OrderAddonSelection';
3
4
  import { PaymentMethodRequestApi } from './PaymentMethodRequestApi';
4
5
  /**
5
6
  *
@@ -7,6 +8,12 @@ import { PaymentMethodRequestApi } from './PaymentMethodRequestApi';
7
8
  * @interface BookingCreateApi
8
9
  */
9
10
  export interface BookingCreateApi {
11
+ /**
12
+ * Selected add-ons (e.g. insurance) for this booking. Available add-ons are returned in the booking policy response.
13
+ * @type {Array<OrderAddonSelection>}
14
+ * @memberof BookingCreateApi
15
+ */
16
+ addons?: Array<OrderAddonSelection>;
10
17
  /**
11
18
  * Booking policy id to book, returned from previous **[Create Booking Policies endpoint](/v1/documentation#operation/postV1Booking_policies)** call
12
19
  * @type {string}
@@ -1,12 +1,19 @@
1
1
  import { CancellationPolicyApi } from './CancellationPolicyApi';
2
2
  import { CurrencyClient } from './CurrencyClient';
3
3
  import { HotelRoomOfferApi } from './HotelRoomOfferApi';
4
+ import { OrderAddon } from './OrderAddon';
4
5
  /**
5
6
  *
6
7
  * @export
7
8
  * @interface BookingPoliciesApi
8
9
  */
9
10
  export interface BookingPoliciesApi {
11
+ /**
12
+ * Available add-ons (e.g. insurance)
13
+ * @type {Array<OrderAddon>}
14
+ * @memberof BookingPoliciesApi
15
+ */
16
+ addons?: Array<OrderAddon>;
10
17
  /**
11
18
  * The total number of adults who will be staying in the property.
12
19
  * @type {number}
@@ -0,0 +1,72 @@
1
+ /**
2
+ * Revolugo Booking API Reference
3
+ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator)
4
+ *
5
+ * The version of the OpenAPI document: 1.5.0
6
+ *
7
+ *
8
+ * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
9
+ * https://openapi-generator.tech
10
+ * Do not edit the class manually.
11
+ */
12
+ /**
13
+ *
14
+ * @export
15
+ * @interface CustomerRequestPayload
16
+ */
17
+ export interface CustomerRequestPayload {
18
+ /**
19
+ * Free-text description of the requested change
20
+ * @type {string}
21
+ * @memberof CustomerRequestPayload
22
+ */
23
+ message: string;
24
+ /**
25
+ * Category of the customer request
26
+ * @type {string}
27
+ * @memberof CustomerRequestPayload
28
+ */
29
+ requestType: CustomerRequestPayloadRequestTypeEnum;
30
+ /**
31
+ * ID of the resource this request is submitted for
32
+ * @type {string}
33
+ * @memberof CustomerRequestPayload
34
+ */
35
+ resourceId: string;
36
+ /**
37
+ * Type of resource this request is submitted for
38
+ * @type {string}
39
+ * @memberof CustomerRequestPayload
40
+ */
41
+ resourceType: CustomerRequestPayloadResourceTypeEnum;
42
+ }
43
+ /**
44
+ * @export
45
+ */
46
+ export declare const CustomerRequestPayloadRequestTypeEnum: {
47
+ readonly AddOrRemoveNights: "add_or_remove_nights";
48
+ readonly AddOrRemovePerson: "add_or_remove_person";
49
+ readonly ChangeDates: "change_dates";
50
+ readonly ChangeGuestName: "change_guest_name";
51
+ readonly EarlyCheckIn: "early_check_in";
52
+ readonly EarlyCheckInLateCheckOut: "early_check_in_late_check_out";
53
+ readonly LateCheckOut: "late_check_out";
54
+ readonly Other: "other";
55
+ readonly SpecialRequest: "special_request";
56
+ };
57
+ export type CustomerRequestPayloadRequestTypeEnum = typeof CustomerRequestPayloadRequestTypeEnum[keyof typeof CustomerRequestPayloadRequestTypeEnum];
58
+ /**
59
+ * @export
60
+ */
61
+ export declare const CustomerRequestPayloadResourceTypeEnum: {
62
+ readonly Booking: "booking";
63
+ readonly BookingGroup: "booking-group";
64
+ };
65
+ export type CustomerRequestPayloadResourceTypeEnum = typeof CustomerRequestPayloadResourceTypeEnum[keyof typeof CustomerRequestPayloadResourceTypeEnum];
66
+ /**
67
+ * Check if a given object implements the CustomerRequestPayload interface.
68
+ */
69
+ export declare function instanceOfCustomerRequestPayload(value: object): boolean;
70
+ export declare function CustomerRequestPayloadFromJSON(json: any): CustomerRequestPayload;
71
+ export declare function CustomerRequestPayloadFromJSONTyped(json: any, ignoreDiscriminator: boolean): CustomerRequestPayload;
72
+ export declare function CustomerRequestPayloadToJSON(value?: CustomerRequestPayload | null): any;
@@ -0,0 +1,50 @@
1
+ /**
2
+ * Revolugo Booking API Reference
3
+ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator)
4
+ *
5
+ * The version of the OpenAPI document: 1.5.0
6
+ *
7
+ *
8
+ * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
9
+ * https://openapi-generator.tech
10
+ * Do not edit the class manually.
11
+ */
12
+ /**
13
+ *
14
+ * @export
15
+ * @interface OrderAddon
16
+ */
17
+ export interface OrderAddon {
18
+ /**
19
+ *
20
+ * @type {number}
21
+ * @memberof OrderAddon
22
+ */
23
+ price: number;
24
+ /**
25
+ *
26
+ * @type {number}
27
+ * @memberof OrderAddon
28
+ */
29
+ taxIncludedPrice: number;
30
+ /**
31
+ *
32
+ * @type {string}
33
+ * @memberof OrderAddon
34
+ */
35
+ type: OrderAddonTypeEnum;
36
+ }
37
+ /**
38
+ * @export
39
+ */
40
+ export declare const OrderAddonTypeEnum: {
41
+ readonly Insurance: "insurance";
42
+ };
43
+ export type OrderAddonTypeEnum = typeof OrderAddonTypeEnum[keyof typeof OrderAddonTypeEnum];
44
+ /**
45
+ * Check if a given object implements the OrderAddon interface.
46
+ */
47
+ export declare function instanceOfOrderAddon(value: object): boolean;
48
+ export declare function OrderAddonFromJSON(json: any): OrderAddon;
49
+ export declare function OrderAddonFromJSONTyped(json: any, ignoreDiscriminator: boolean): OrderAddon;
50
+ export declare function OrderAddonToJSON(value?: OrderAddon | null): any;
@@ -0,0 +1,38 @@
1
+ /**
2
+ * Revolugo Booking API Reference
3
+ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator)
4
+ *
5
+ * The version of the OpenAPI document: 1.5.0
6
+ *
7
+ *
8
+ * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
9
+ * https://openapi-generator.tech
10
+ * Do not edit the class manually.
11
+ */
12
+ /**
13
+ *
14
+ * @export
15
+ * @interface OrderAddonSelection
16
+ */
17
+ export interface OrderAddonSelection {
18
+ /**
19
+ *
20
+ * @type {string}
21
+ * @memberof OrderAddonSelection
22
+ */
23
+ type: OrderAddonSelectionTypeEnum;
24
+ }
25
+ /**
26
+ * @export
27
+ */
28
+ export declare const OrderAddonSelectionTypeEnum: {
29
+ readonly Insurance: "insurance";
30
+ };
31
+ export type OrderAddonSelectionTypeEnum = typeof OrderAddonSelectionTypeEnum[keyof typeof OrderAddonSelectionTypeEnum];
32
+ /**
33
+ * Check if a given object implements the OrderAddonSelection interface.
34
+ */
35
+ export declare function instanceOfOrderAddonSelection(value: object): boolean;
36
+ export declare function OrderAddonSelectionFromJSON(json: any): OrderAddonSelection;
37
+ export declare function OrderAddonSelectionFromJSONTyped(json: any, ignoreDiscriminator: boolean): OrderAddonSelection;
38
+ export declare function OrderAddonSelectionToJSON(value?: OrderAddonSelection | null): any;
@@ -0,0 +1,52 @@
1
+ /**
2
+ * Revolugo Booking API Reference
3
+ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator)
4
+ *
5
+ * The version of the OpenAPI document: 1.5.0
6
+ *
7
+ *
8
+ * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
9
+ * https://openapi-generator.tech
10
+ * Do not edit the class manually.
11
+ */
12
+ /**
13
+ *
14
+ * @export
15
+ * @interface RequestPayload
16
+ */
17
+ export interface RequestPayload {
18
+ /**
19
+ * Free-text description of the requested change
20
+ * @type {string}
21
+ * @memberof RequestPayload
22
+ */
23
+ message: string;
24
+ /**
25
+ * Category of the customer request
26
+ * @type {string}
27
+ * @memberof RequestPayload
28
+ */
29
+ requestType: RequestPayloadRequestTypeEnum;
30
+ }
31
+ /**
32
+ * @export
33
+ */
34
+ export declare const RequestPayloadRequestTypeEnum: {
35
+ readonly AddOrRemoveNights: "add_or_remove_nights";
36
+ readonly AddOrRemovePerson: "add_or_remove_person";
37
+ readonly ChangeDates: "change_dates";
38
+ readonly ChangeGuestName: "change_guest_name";
39
+ readonly EarlyCheckIn: "early_check_in";
40
+ readonly EarlyCheckInLateCheckOut: "early_check_in_late_check_out";
41
+ readonly LateCheckOut: "late_check_out";
42
+ readonly Other: "other";
43
+ readonly SpecialRequest: "special_request";
44
+ };
45
+ export type RequestPayloadRequestTypeEnum = typeof RequestPayloadRequestTypeEnum[keyof typeof RequestPayloadRequestTypeEnum];
46
+ /**
47
+ * Check if a given object implements the RequestPayload interface.
48
+ */
49
+ export declare function instanceOfRequestPayload(value: object): boolean;
50
+ export declare function RequestPayloadFromJSON(json: any): RequestPayload;
51
+ export declare function RequestPayloadFromJSONTyped(json: any, ignoreDiscriminator: boolean): RequestPayload;
52
+ export declare function RequestPayloadToJSON(value?: RequestPayload | null): any;
@@ -0,0 +1,52 @@
1
+ /**
2
+ * Revolugo Booking API Reference
3
+ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator)
4
+ *
5
+ * The version of the OpenAPI document: 1.5.0
6
+ *
7
+ *
8
+ * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
9
+ * https://openapi-generator.tech
10
+ * Do not edit the class manually.
11
+ */
12
+ /**
13
+ *
14
+ * @export
15
+ * @interface SendRequestPayload
16
+ */
17
+ export interface SendRequestPayload {
18
+ /**
19
+ * Free-text description of the requested change
20
+ * @type {string}
21
+ * @memberof SendRequestPayload
22
+ */
23
+ message: string;
24
+ /**
25
+ * Category of the send request
26
+ * @type {string}
27
+ * @memberof SendRequestPayload
28
+ */
29
+ requestType: SendRequestPayloadRequestTypeEnum;
30
+ }
31
+ /**
32
+ * @export
33
+ */
34
+ export declare const SendRequestPayloadRequestTypeEnum: {
35
+ readonly AddOrRemoveNights: "add_or_remove_nights";
36
+ readonly AddOrRemovePerson: "add_or_remove_person";
37
+ readonly ChangeDates: "change_dates";
38
+ readonly ChangeGuestName: "change_guest_name";
39
+ readonly EarlyCheckIn: "early_check_in";
40
+ readonly EarlyCheckInLateCheckOut: "early_check_in_late_check_out";
41
+ readonly LateCheckOut: "late_check_out";
42
+ readonly Other: "other";
43
+ readonly SpecialRequest: "special_request";
44
+ };
45
+ export type SendRequestPayloadRequestTypeEnum = typeof SendRequestPayloadRequestTypeEnum[keyof typeof SendRequestPayloadRequestTypeEnum];
46
+ /**
47
+ * Check if a given object implements the SendRequestPayload interface.
48
+ */
49
+ export declare function instanceOfSendRequestPayload(value: object): boolean;
50
+ export declare function SendRequestPayloadFromJSON(json: any): SendRequestPayload;
51
+ export declare function SendRequestPayloadFromJSONTyped(json: any, ignoreDiscriminator: boolean): SendRequestPayload;
52
+ export declare function SendRequestPayloadToJSON(value?: SendRequestPayload | null): any;
@@ -0,0 +1,37 @@
1
+ /**
2
+ * Revolugo Booking API Reference
3
+ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator)
4
+ *
5
+ * The version of the OpenAPI document: 1.5.0
6
+ *
7
+ *
8
+ * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
9
+ * https://openapi-generator.tech
10
+ * Do not edit the class manually.
11
+ */
12
+ /**
13
+ *
14
+ * @export
15
+ * @interface SendRequestResponse
16
+ */
17
+ export interface SendRequestResponse {
18
+ /**
19
+ *
20
+ * @type {string}
21
+ * @memberof SendRequestResponse
22
+ */
23
+ message: string;
24
+ /**
25
+ *
26
+ * @type {string}
27
+ * @memberof SendRequestResponse
28
+ */
29
+ requestType: string;
30
+ }
31
+ /**
32
+ * Check if a given object implements the SendRequestResponse interface.
33
+ */
34
+ export declare function instanceOfSendRequestResponse(value: object): boolean;
35
+ export declare function SendRequestResponseFromJSON(json: any): SendRequestResponse;
36
+ export declare function SendRequestResponseFromJSONTyped(json: any, ignoreDiscriminator: boolean): SendRequestResponse;
37
+ export declare function SendRequestResponseToJSON(value?: SendRequestResponse | null): any;
@@ -54,6 +54,8 @@ export * from './Locale';
54
54
  export * from './MetaPollingResponseApi';
55
55
  export * from './MetaPollingResponseApiAllOf';
56
56
  export * from './MetaResponseApi';
57
+ export * from './OrderAddon';
58
+ export * from './OrderAddonSelection';
57
59
  export * from './PaymentMethodApi';
58
60
  export * from './PaymentMethodApiOneOf';
59
61
  export * from './PaymentMethodApiOneOf1';
@@ -67,6 +69,7 @@ export * from './PaymentMethodRequestApi';
67
69
  export * from './PaymentMethodRequestPayloadApi';
68
70
  export * from './PaymentMethodUpdatePayloadApi';
69
71
  export * from './PollerStatus';
72
+ export * from './RequestPayload';
70
73
  export * from './SourceMarket';
71
74
  export * from './TagApi';
72
75
  export * from './TaxApi';
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@revolugo/booking-api-client",
3
- "version": "7.9.2",
3
+ "version": "7.10.0-rc.0",
4
4
  "private": false,
5
5
  "description": "Javascript Revolugo Booking API Client (browser + server)",
6
6
  "keywords": [
@@ -34,17 +34,17 @@
34
34
  "cross-fetch": "4.1.0",
35
35
  "joi": "18.1.2",
36
36
  "uuid": "14.0.0",
37
- "@revolugo/common": "7.9.2"
37
+ "@revolugo/common": "7.10.0"
38
38
  },
39
39
  "devDependencies": {
40
- "@hono/node-server": "1.19.14",
41
- "hono": "4.12.14",
42
- "@revolugo/booking-api": "7.9.2",
43
- "@revolugo/engines": "7.9.2",
44
- "@revolugo/env": "7.9.2",
45
- "@revolugo/models": "7.9.2",
46
- "@revolugo/node": "7.9.2",
47
- "@revolugo/root": "7.9.2"
40
+ "@hono/node-server": "2.0.0",
41
+ "hono": "4.12.15",
42
+ "@revolugo/booking-api": "7.10.0",
43
+ "@revolugo/env": "7.10.0",
44
+ "@revolugo/models": "7.10.0",
45
+ "@revolugo/engines": "7.10.0",
46
+ "@revolugo/node": "7.10.0",
47
+ "@revolugo/root": "7.10.0"
48
48
  },
49
49
  "engines": {
50
50
  "node": ">=20.18.1 <25"