@qite/tide-client 1.0.75 → 1.0.78
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/build/index.js.map +1 -1
- package/build/types/offer/booking-v2/request/booking-package-details-request.d.ts +2 -1
- package/build/types/offer/booking-v2/request/booking-package-search-request.d.ts +24 -23
- package/build/types/offer/booking-v2/request/index.d.ts +1 -0
- package/build/types/offer/booking-v2/request/selected-flight.d.ts +2 -0
- package/build/types/offer/booking-v2/request/selected-hotel.d.ts +5 -0
- package/build/types/offer/booking-v2/response/booking-package-item.d.ts +2 -0
- package/build/types/offer/booking-v2/response/index.d.ts +1 -0
- package/build/types/offer/booking-v2/response/tide-response.d.ts +8 -0
- package/build/utils/booking-v2-client.d.ts +2 -1
- package/package.json +56 -56
- package/src/types/offer/booking-v2/request/booking-package-details-request.ts +2 -1
- package/src/types/offer/booking-v2/request/booking-package-search-request.ts +27 -26
- package/src/types/offer/booking-v2/request/index.ts +1 -0
- package/src/types/offer/booking-v2/request/selected-flight.ts +2 -0
- package/src/types/offer/booking-v2/request/selected-hotel.ts +5 -0
- package/src/types/offer/booking-v2/response/booking-package-item.ts +2 -0
- package/src/types/offer/booking-v2/response/index.ts +1 -0
- package/src/types/offer/booking-v2/response/tide-response.ts +6 -0
- package/src/utils/booking-v2-client.ts +2 -1
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
import { BookingPackageRequestRoom } from "../shared/booking-package-request-room";
|
|
2
2
|
import { SelectedFlight } from "./selected-flight";
|
|
3
|
+
import { SelectedHotel } from "./selected-hotel";
|
|
3
4
|
export interface BookingPackageDetailsRequest {
|
|
4
5
|
catalogueId?: number;
|
|
5
6
|
rooms: BookingPackageRequestRoom[];
|
|
@@ -13,7 +14,7 @@ export interface BookingPackageDetailsRequest {
|
|
|
13
14
|
postNights?: number;
|
|
14
15
|
includeFlights?: boolean;
|
|
15
16
|
checkExternalAvailability?: boolean;
|
|
16
|
-
|
|
17
|
+
hotel?: SelectedHotel;
|
|
17
18
|
outwardFlight?: SelectedFlight;
|
|
18
19
|
returnFlight?: SelectedFlight;
|
|
19
20
|
}
|
|
@@ -1,23 +1,24 @@
|
|
|
1
|
-
import { BookingPackageRequestRoom } from "../shared/booking-package-request-room";
|
|
2
|
-
import { BookingPackageDestination } from "./booking-package-destination";
|
|
3
|
-
export interface BookingPackageSearchRequest {
|
|
4
|
-
catalogueIds: number[];
|
|
5
|
-
rooms: BookingPackageRequestRoom[];
|
|
6
|
-
serviceType?: number;
|
|
7
|
-
searchType?: number;
|
|
8
|
-
destination?: BookingPackageDestination;
|
|
9
|
-
productIds?: number[];
|
|
10
|
-
productCodes?: string[];
|
|
11
|
-
fromDate: string;
|
|
12
|
-
toDate: string;
|
|
13
|
-
productTagIds?: number[];
|
|
14
|
-
includeFlights?: boolean;
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
1
|
+
import { BookingPackageRequestRoom } from "../shared/booking-package-request-room";
|
|
2
|
+
import { BookingPackageDestination } from "./booking-package-destination";
|
|
3
|
+
export interface BookingPackageSearchRequest {
|
|
4
|
+
catalogueIds: number[];
|
|
5
|
+
rooms: BookingPackageRequestRoom[];
|
|
6
|
+
serviceType?: number;
|
|
7
|
+
searchType?: number;
|
|
8
|
+
destination?: BookingPackageDestination;
|
|
9
|
+
productIds?: number[];
|
|
10
|
+
productCodes?: string[];
|
|
11
|
+
fromDate: string;
|
|
12
|
+
toDate: string;
|
|
13
|
+
productTagIds?: number[];
|
|
14
|
+
includeFlights?: boolean;
|
|
15
|
+
useExactDates: boolean;
|
|
16
|
+
minPrice?: number;
|
|
17
|
+
maxPrice?: number;
|
|
18
|
+
allotmentName?: string;
|
|
19
|
+
tourCode?: string;
|
|
20
|
+
allotmentTagIds?: number[];
|
|
21
|
+
includeClosedAllotments?: boolean;
|
|
22
|
+
includeFullyBookedAllotments?: boolean;
|
|
23
|
+
onlyCachedResults?: boolean;
|
|
24
|
+
}
|
|
@@ -14,10 +14,12 @@ export interface BookingPackageItem {
|
|
|
14
14
|
outwardFlightCode?: string;
|
|
15
15
|
outwardFlightNumbers?: string[];
|
|
16
16
|
outwardFlightStartDate?: string;
|
|
17
|
+
outwardFlightEndDate?: string;
|
|
17
18
|
price: number;
|
|
18
19
|
regimeCode?: string;
|
|
19
20
|
returnFlightCode?: string;
|
|
20
21
|
returnFlightNumbers?: string[];
|
|
22
|
+
returnFlightStartDate?: string;
|
|
21
23
|
returnFlightEndDate?: string;
|
|
22
24
|
flightDescription?: string;
|
|
23
25
|
tagIds: number[];
|
|
@@ -12,6 +12,7 @@ import {
|
|
|
12
12
|
BookingPackageSearchRequest,
|
|
13
13
|
BookingPriceDetails,
|
|
14
14
|
BookingTravelAgent,
|
|
15
|
+
TideResponse,
|
|
15
16
|
} from "../types";
|
|
16
17
|
export declare const readPackageSearchList: (
|
|
17
18
|
config: TideClientConfig,
|
|
@@ -27,7 +28,7 @@ export declare const details: (
|
|
|
27
28
|
config: TideClientConfig,
|
|
28
29
|
request: BookingPackageRequest<BookingPackageDetailsRequest>,
|
|
29
30
|
signal?: AbortSignal | undefined
|
|
30
|
-
) => Promise<BookingPackage
|
|
31
|
+
) => Promise<TideResponse<BookingPackage>>;
|
|
31
32
|
export declare const alternateHotels: (
|
|
32
33
|
config: TideClientConfig,
|
|
33
34
|
transactionId: string,
|
package/package.json
CHANGED
|
@@ -1,56 +1,56 @@
|
|
|
1
|
-
{
|
|
2
|
-
"name": "@qite/tide-client",
|
|
3
|
-
"version": "1.0.
|
|
4
|
-
"description": "Frontend client for Tide",
|
|
5
|
-
"main": "build/index.js",
|
|
6
|
-
"scripts": {
|
|
7
|
-
"build": "rollup -c",
|
|
8
|
-
"tsc": "tsc --noEmit",
|
|
9
|
-
"format": "prettier --write .",
|
|
10
|
-
"test": "jest"
|
|
11
|
-
},
|
|
12
|
-
"repository": {
|
|
13
|
-
"type": "git",
|
|
14
|
-
"url": "git+ssh://git@bitbucket.org/qitegeneral/tide-client.git"
|
|
15
|
-
},
|
|
16
|
-
"keywords": [
|
|
17
|
-
"tide",
|
|
18
|
-
"client"
|
|
19
|
-
],
|
|
20
|
-
"author": "Kristof Colpaert <kristof.colpaert@qite.be>",
|
|
21
|
-
"license": "OBSD",
|
|
22
|
-
"homepage": "https://bitbucket.org/qitegeneral/tide-client#readme",
|
|
23
|
-
"devDependencies": {
|
|
24
|
-
"@rollup/plugin-commonjs": "^19.0.0",
|
|
25
|
-
"@rollup/plugin-node-resolve": "^13.0.0",
|
|
26
|
-
"@types/jest": "^26.0.23",
|
|
27
|
-
"@types/moment": "^2.13.0",
|
|
28
|
-
"dotenv": "^9.0.2",
|
|
29
|
-
"jest": "^26.6.3",
|
|
30
|
-
"jest-fetch-mock": "^3.0.3",
|
|
31
|
-
"momentjs": "^2.0.0",
|
|
32
|
-
"prettier": "^2.3.0",
|
|
33
|
-
"rollup": "^2.48.0",
|
|
34
|
-
"rollup-plugin-typescript2": "^0.30.0",
|
|
35
|
-
"ts-jest": "^26.5.6",
|
|
36
|
-
"tslib": "^2.2.0",
|
|
37
|
-
"typescript": "^4.2.4"
|
|
38
|
-
},
|
|
39
|
-
"jest": {
|
|
40
|
-
"moduleFileExtensions": [
|
|
41
|
-
"ts",
|
|
42
|
-
"js"
|
|
43
|
-
],
|
|
44
|
-
"transform": {
|
|
45
|
-
"^.+\\.ts$": "ts-jest"
|
|
46
|
-
},
|
|
47
|
-
"globals": {
|
|
48
|
-
"ts-jest": {
|
|
49
|
-
"tsconfig": "tsconfig.json"
|
|
50
|
-
}
|
|
51
|
-
},
|
|
52
|
-
"testMatch": [
|
|
53
|
-
"**/tests/**/*.test.ts"
|
|
54
|
-
]
|
|
55
|
-
}
|
|
56
|
-
}
|
|
1
|
+
{
|
|
2
|
+
"name": "@qite/tide-client",
|
|
3
|
+
"version": "1.0.78",
|
|
4
|
+
"description": "Frontend client for Tide",
|
|
5
|
+
"main": "build/index.js",
|
|
6
|
+
"scripts": {
|
|
7
|
+
"build": "rollup -c",
|
|
8
|
+
"tsc": "tsc --noEmit",
|
|
9
|
+
"format": "prettier --write .",
|
|
10
|
+
"test": "jest"
|
|
11
|
+
},
|
|
12
|
+
"repository": {
|
|
13
|
+
"type": "git",
|
|
14
|
+
"url": "git+ssh://git@bitbucket.org/qitegeneral/tide-client.git"
|
|
15
|
+
},
|
|
16
|
+
"keywords": [
|
|
17
|
+
"tide",
|
|
18
|
+
"client"
|
|
19
|
+
],
|
|
20
|
+
"author": "Kristof Colpaert <kristof.colpaert@qite.be>",
|
|
21
|
+
"license": "OBSD",
|
|
22
|
+
"homepage": "https://bitbucket.org/qitegeneral/tide-client#readme",
|
|
23
|
+
"devDependencies": {
|
|
24
|
+
"@rollup/plugin-commonjs": "^19.0.0",
|
|
25
|
+
"@rollup/plugin-node-resolve": "^13.0.0",
|
|
26
|
+
"@types/jest": "^26.0.23",
|
|
27
|
+
"@types/moment": "^2.13.0",
|
|
28
|
+
"dotenv": "^9.0.2",
|
|
29
|
+
"jest": "^26.6.3",
|
|
30
|
+
"jest-fetch-mock": "^3.0.3",
|
|
31
|
+
"momentjs": "^2.0.0",
|
|
32
|
+
"prettier": "^2.3.0",
|
|
33
|
+
"rollup": "^2.48.0",
|
|
34
|
+
"rollup-plugin-typescript2": "^0.30.0",
|
|
35
|
+
"ts-jest": "^26.5.6",
|
|
36
|
+
"tslib": "^2.2.0",
|
|
37
|
+
"typescript": "^4.2.4"
|
|
38
|
+
},
|
|
39
|
+
"jest": {
|
|
40
|
+
"moduleFileExtensions": [
|
|
41
|
+
"ts",
|
|
42
|
+
"js"
|
|
43
|
+
],
|
|
44
|
+
"transform": {
|
|
45
|
+
"^.+\\.ts$": "ts-jest"
|
|
46
|
+
},
|
|
47
|
+
"globals": {
|
|
48
|
+
"ts-jest": {
|
|
49
|
+
"tsconfig": "tsconfig.json"
|
|
50
|
+
}
|
|
51
|
+
},
|
|
52
|
+
"testMatch": [
|
|
53
|
+
"**/tests/**/*.test.ts"
|
|
54
|
+
]
|
|
55
|
+
}
|
|
56
|
+
}
|
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
import { BookingPackageRequestRoom } from "../shared/booking-package-request-room";
|
|
2
2
|
import { SelectedFlight } from "./selected-flight";
|
|
3
|
+
import { SelectedHotel } from "./selected-hotel";
|
|
3
4
|
|
|
4
5
|
export interface BookingPackageDetailsRequest {
|
|
5
6
|
catalogueId?: number;
|
|
@@ -16,7 +17,7 @@ export interface BookingPackageDetailsRequest {
|
|
|
16
17
|
checkExternalAvailability?: boolean;
|
|
17
18
|
|
|
18
19
|
// lazy loading
|
|
19
|
-
|
|
20
|
+
hotel?: SelectedHotel;
|
|
20
21
|
outwardFlight?: SelectedFlight;
|
|
21
22
|
returnFlight?: SelectedFlight;
|
|
22
23
|
}
|
|
@@ -1,26 +1,27 @@
|
|
|
1
|
-
import { BookingPackageRequestRoom } from "../shared/booking-package-request-room";
|
|
2
|
-
import { BookingPackageDestination } from "./booking-package-destination";
|
|
3
|
-
|
|
4
|
-
export interface BookingPackageSearchRequest {
|
|
5
|
-
catalogueIds: number[];
|
|
6
|
-
rooms: BookingPackageRequestRoom[];
|
|
7
|
-
serviceType?: number;
|
|
8
|
-
searchType?: number;
|
|
9
|
-
destination?: BookingPackageDestination;
|
|
10
|
-
productIds?: number[];
|
|
11
|
-
productCodes?: string[];
|
|
12
|
-
fromDate: string;
|
|
13
|
-
toDate: string;
|
|
14
|
-
productTagIds?: number[];
|
|
15
|
-
includeFlights?: boolean;
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
1
|
+
import { BookingPackageRequestRoom } from "../shared/booking-package-request-room";
|
|
2
|
+
import { BookingPackageDestination } from "./booking-package-destination";
|
|
3
|
+
|
|
4
|
+
export interface BookingPackageSearchRequest {
|
|
5
|
+
catalogueIds: number[];
|
|
6
|
+
rooms: BookingPackageRequestRoom[];
|
|
7
|
+
serviceType?: number;
|
|
8
|
+
searchType?: number;
|
|
9
|
+
destination?: BookingPackageDestination;
|
|
10
|
+
productIds?: number[];
|
|
11
|
+
productCodes?: string[];
|
|
12
|
+
fromDate: string;
|
|
13
|
+
toDate: string;
|
|
14
|
+
productTagIds?: number[];
|
|
15
|
+
includeFlights?: boolean;
|
|
16
|
+
useExactDates: boolean;
|
|
17
|
+
|
|
18
|
+
minPrice?: number;
|
|
19
|
+
maxPrice?: number;
|
|
20
|
+
|
|
21
|
+
allotmentName?: string;
|
|
22
|
+
tourCode?: string;
|
|
23
|
+
allotmentTagIds?: number[];
|
|
24
|
+
includeClosedAllotments?: boolean;
|
|
25
|
+
includeFullyBookedAllotments?: boolean;
|
|
26
|
+
onlyCachedResults?: boolean;
|
|
27
|
+
}
|
|
@@ -15,10 +15,12 @@ export interface BookingPackageItem {
|
|
|
15
15
|
outwardFlightCode?: string;
|
|
16
16
|
outwardFlightNumbers?: string[];
|
|
17
17
|
outwardFlightStartDate?: string;
|
|
18
|
+
outwardFlightEndDate?: string;
|
|
18
19
|
price: number;
|
|
19
20
|
regimeCode?: string;
|
|
20
21
|
returnFlightCode?: string;
|
|
21
22
|
returnFlightNumbers?: string[];
|
|
23
|
+
returnFlightStartDate?: string;
|
|
22
24
|
returnFlightEndDate?: string;
|
|
23
25
|
flightDescription?: string;
|
|
24
26
|
tagIds: number[];
|
|
@@ -13,6 +13,7 @@ import {
|
|
|
13
13
|
BookingPackageSearchRequest,
|
|
14
14
|
BookingPriceDetails,
|
|
15
15
|
BookingTravelAgent,
|
|
16
|
+
TideResponse,
|
|
16
17
|
} from "../types";
|
|
17
18
|
import { get, post } from "./common-client";
|
|
18
19
|
|
|
@@ -55,7 +56,7 @@ export const details = (
|
|
|
55
56
|
config: TideClientConfig,
|
|
56
57
|
request: BookingPackageRequest<BookingPackageDetailsRequest>,
|
|
57
58
|
signal?: AbortSignal
|
|
58
|
-
): Promise<BookingPackage
|
|
59
|
+
): Promise<TideResponse<BookingPackage>> => {
|
|
59
60
|
const url = `${config.host}${ENDPOINT_DETAILS}`;
|
|
60
61
|
const apiKey = config.apiKey;
|
|
61
62
|
const body = JSON.stringify(request);
|