@qite/tide-client 1.0.85 → 1.0.87

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.
@@ -14,6 +14,7 @@ export interface BookingPackageDetailsRequest {
14
14
  postNights?: number;
15
15
  includeFlights?: boolean;
16
16
  checkExternalAvailability?: boolean;
17
+ cachedAllotmentPriceInfos?: number[];
17
18
  hotel?: SelectedHotel;
18
19
  outwardFlight?: SelectedFlight;
19
20
  returnFlight?: SelectedFlight;
@@ -0,0 +1,4 @@
1
+ export interface BookableDates {
2
+ outward: Date[];
3
+ return: Date[];
4
+ }
@@ -13,4 +13,5 @@ export interface BookingPackageAllotmentInfo {
13
13
  customAllotmentStatus?: string;
14
14
  tagIds: number[];
15
15
  allotmentIds: number[];
16
+ cachedAllotmentPriceInfos?: number[];
16
17
  }
@@ -10,3 +10,4 @@ export * from "./booking-package-flight-pool";
10
10
  export * from "./booking-package-hotel-pool";
11
11
  export * from "./tide-response";
12
12
  export * from "./booking-product-notification";
13
+ export * from "./bookable-dates";
@@ -1,6 +1,7 @@
1
1
  import { PackageSearchRequest, TideClientConfig } from "..";
2
2
  import {
3
3
  AvailablePackage,
4
+ BookableDates,
4
5
  BookingPackage,
5
6
  BookingPackageBookRequest,
6
7
  BookingPackageDetailsRequest,
@@ -65,3 +66,9 @@ export declare const searchFlightPool: (
65
66
  request: BookingPackageRequest<BookingPackageFlightPoolRequest>,
66
67
  signal?: AbortSignal | undefined
67
68
  ) => Promise<BookingPackageFlightPool>;
69
+ export declare const bookableDates: (
70
+ config: TideClientConfig,
71
+ productCode: string,
72
+ allotmentTourCode: string,
73
+ signal?: AbortSignal | undefined
74
+ ) => Promise<BookableDates>;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@qite/tide-client",
3
- "version": "1.0.85",
3
+ "version": "1.0.87",
4
4
  "description": "Frontend client for Tide",
5
5
  "main": "build/index.js",
6
6
  "scripts": {
@@ -15,6 +15,7 @@ export interface BookingPackageDetailsRequest {
15
15
  postNights?: number;
16
16
  includeFlights?: boolean;
17
17
  checkExternalAvailability?: boolean;
18
+ cachedAllotmentPriceInfos?: number[];
18
19
 
19
20
  // lazy loading
20
21
  hotel?: SelectedHotel;
@@ -0,0 +1,4 @@
1
+ export interface BookableDates {
2
+ outward: Date[];
3
+ return: Date[];
4
+ }
@@ -13,4 +13,5 @@ export interface BookingPackageAllotmentInfo {
13
13
  customAllotmentStatus?: string;
14
14
  tagIds: number[];
15
15
  allotmentIds: number[];
16
+ cachedAllotmentPriceInfos?: number[];
16
17
  }
@@ -10,3 +10,4 @@ export * from "./booking-package-flight-pool";
10
10
  export * from "./booking-package-hotel-pool";
11
11
  export * from "./tide-response";
12
12
  export * from "./booking-product-notification";
13
+ export * from "./bookable-dates";
@@ -2,6 +2,7 @@ import { PackageSearchRequest, TideClientConfig } from "..";
2
2
 
3
3
  import {
4
4
  AvailablePackage,
5
+ BookableDates,
5
6
  BookingPackage,
6
7
  BookingPackageBookRequest,
7
8
  BookingPackageDetailsRequest,
@@ -30,6 +31,7 @@ const ENDPOINT_BOOK = `${ENDPOINT}/book`;
30
31
  const ENDPOINT_AGENTS = `${ENDPOINT}/agents`;
31
32
  const ENDPOINT_AVAILABLE_ALLOTMENTS = `${ENDPOINT}/get-allotment-availability`;
32
33
  const ENDPOINT_FLIGHT_POOL = `${ENDPOINT}/flight-pool`;
34
+ const ENDPOINT_BOOKABLE_DATES = `${ENDPOINT}/bookable-dates`;
33
35
 
34
36
  export const readPackageSearchList = (
35
37
  config: TideClientConfig,
@@ -146,3 +148,15 @@ export const searchFlightPool = (
146
148
 
147
149
  return post(url, apiKey, body, signal, true);
148
150
  };
151
+
152
+ export const bookableDates = (
153
+ config: TideClientConfig,
154
+ productCode: string,
155
+ allotmentTourCode: string,
156
+ signal?: AbortSignal
157
+ ): Promise<BookableDates> => {
158
+ const url = `${config.host}${ENDPOINT_BOOKABLE_DATES}/${productCode}/${allotmentTourCode}`;
159
+ const apiKey = config.apiKey;
160
+
161
+ return get(url, apiKey, signal, true);
162
+ };