@themeparks/typelib 1.0.0 → 1.0.2
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/types/entities.types.d.ts +48 -0
- package/dist/types/entities.types.d.ts.map +1 -0
- package/dist/types/entities.types.js +135 -0
- package/dist/types/index.d.ts +8 -2
- package/dist/types/index.d.ts.map +1 -1
- package/dist/types/index.js +8 -2
- package/dist/types/livedata.types.d.ts +107 -0
- package/dist/types/livedata.types.d.ts.map +1 -0
- package/dist/types/livedata.types.js +313 -0
- package/dist/types/pricedata.types.d.ts +18 -0
- package/dist/types/pricedata.types.d.ts.map +1 -0
- package/dist/types/pricedata.types.js +56 -0
- package/dist/types/schedule.types.d.ts +31 -0
- package/dist/types/schedule.types.d.ts.map +1 -0
- package/dist/types/schedule.types.js +98 -0
- package/package.json +1 -1
- package/typesrc/entities.json +111 -0
- package/typesrc/livedata.json +257 -0
- package/typesrc/pricedata.json +38 -0
- package/typesrc/schedule.json +77 -0
- package/typesrc/v1.json +0 -25
|
@@ -0,0 +1,48 @@
|
|
|
1
|
+
export declare enum EntityTypeEnum {
|
|
2
|
+
"DESTINATION" = "DESTINATION",
|
|
3
|
+
"PARK" = "PARK",
|
|
4
|
+
"ATTRACTION" = "ATTRACTION",
|
|
5
|
+
"RESTAURANT" = "RESTAURANT",
|
|
6
|
+
"SHOW" = "SHOW",
|
|
7
|
+
"HOTEL" = "HOTEL"
|
|
8
|
+
}
|
|
9
|
+
/** Possible types of entity in ThemeParks.wiki */
|
|
10
|
+
export type EntityType = keyof typeof EntityTypeEnum;
|
|
11
|
+
export declare function StringToEntityType(value: string): EntityTypeEnum;
|
|
12
|
+
export type EntityLocation = {
|
|
13
|
+
/** Latitude coordinate of the entity location */
|
|
14
|
+
latitude?: number | null;
|
|
15
|
+
/** Longitude coordinate of the entity location */
|
|
16
|
+
longitude?: number | null;
|
|
17
|
+
};
|
|
18
|
+
export type TagData = {
|
|
19
|
+
/** Tag identifier */
|
|
20
|
+
tag: string;
|
|
21
|
+
/** Human readable tag name */
|
|
22
|
+
tagName: string;
|
|
23
|
+
/** Unique identifier */
|
|
24
|
+
id?: string;
|
|
25
|
+
/** Tag value - can be string, number or object */
|
|
26
|
+
value?: any;
|
|
27
|
+
};
|
|
28
|
+
export type Entity = {
|
|
29
|
+
/** Unique entity identifier */
|
|
30
|
+
id: string;
|
|
31
|
+
/** Entity name */
|
|
32
|
+
name: string;
|
|
33
|
+
/** Type of entity */
|
|
34
|
+
entityType: EntityType;
|
|
35
|
+
/** Parent entity identifier, must always be set when entityType is not DESTINATION */
|
|
36
|
+
parentId?: string | null;
|
|
37
|
+
/** Destination identifier, must always be set when entityType is not DESTINATION */
|
|
38
|
+
destinationId?: string | null;
|
|
39
|
+
/** Park identifier, must be set if any parent entity in the hierarchy is a park */
|
|
40
|
+
parkId?: string | null;
|
|
41
|
+
/** Entity timezone */
|
|
42
|
+
timezone: string;
|
|
43
|
+
/** Entity location coordinates */
|
|
44
|
+
location?: EntityLocation;
|
|
45
|
+
/** Array of tags associated with the entity */
|
|
46
|
+
tags?: TagData[];
|
|
47
|
+
};
|
|
48
|
+
//# sourceMappingURL=entities.types.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"entities.types.d.ts","sourceRoot":"","sources":["../../src/types/entities.types.ts"],"names":[],"mappings":"AAEA,oBAAY,cAAc;IACtB,aAAa,gBAAgB;IAC7B,MAAM,SAAS;IACf,YAAY,eAAe;IAC3B,YAAY,eAAe;IAC3B,MAAM,SAAS;IACf,OAAO,UAAU;CACpB;AAED,kDAAkD;AAClD,MAAM,MAAM,UAAU,GAAG,MAAM,OAAO,cAAc,CAAC;AAGrD,wBAAgB,kBAAkB,CAAC,KAAK,EAAE,MAAM,GAAG,cAAc,CAiBhE;AAED,MAAM,MAAM,cAAc,GAAG;IAEzB,iDAAiD;IACjD,QAAQ,CAAC,EAAE,MAAM,GAAG,IAAI,CAAC;IAEzB,kDAAkD;IAClD,SAAS,CAAC,EAAE,MAAM,GAAG,IAAI,CAAC;CAC7B,CAAA;AAED,MAAM,MAAM,OAAO,GAAG;IAElB,qBAAqB;IACrB,GAAG,EAAE,MAAM,CAAC;IAEZ,8BAA8B;IAC9B,OAAO,EAAE,MAAM,CAAC;IAEhB,wBAAwB;IACxB,EAAE,CAAC,EAAE,MAAM,CAAC;IAEZ,kDAAkD;IAClD,KAAK,CAAC,EAAE,GAAG,CAAC;CACf,CAAA;AAED,MAAM,MAAM,MAAM,GAAG;IAEjB,+BAA+B;IAC/B,EAAE,EAAE,MAAM,CAAC;IAEX,kBAAkB;IAClB,IAAI,EAAE,MAAM,CAAC;IAEb,qBAAqB;IACrB,UAAU,EAAE,UAAU,CAAC;IAEvB,sFAAsF;IACtF,QAAQ,CAAC,EAAE,MAAM,GAAG,IAAI,CAAC;IAEzB,oFAAoF;IACpF,aAAa,CAAC,EAAE,MAAM,GAAG,IAAI,CAAC;IAE9B,mFAAmF;IACnF,MAAM,CAAC,EAAE,MAAM,GAAG,IAAI,CAAC;IAEvB,sBAAsB;IACtB,QAAQ,EAAE,MAAM,CAAC;IAEjB,kCAAkC;IAClC,QAAQ,CAAC,EAAE,cAAc,CAAC;IAE1B,+CAA+C;IAC/C,IAAI,CAAC,EAAE,OAAO,EAAE,CAAC;CACpB,CAAA"}
|
|
@@ -0,0 +1,135 @@
|
|
|
1
|
+
// THIS FILE IS GENERATED - DO NOT EDIT DIRECTLY
|
|
2
|
+
export var EntityTypeEnum;
|
|
3
|
+
(function (EntityTypeEnum) {
|
|
4
|
+
EntityTypeEnum["DESTINATION"] = "DESTINATION";
|
|
5
|
+
EntityTypeEnum["PARK"] = "PARK";
|
|
6
|
+
EntityTypeEnum["ATTRACTION"] = "ATTRACTION";
|
|
7
|
+
EntityTypeEnum["RESTAURANT"] = "RESTAURANT";
|
|
8
|
+
EntityTypeEnum["SHOW"] = "SHOW";
|
|
9
|
+
EntityTypeEnum["HOTEL"] = "HOTEL";
|
|
10
|
+
})(EntityTypeEnum || (EntityTypeEnum = {}));
|
|
11
|
+
// Function to convert string to EntityTypeEnum
|
|
12
|
+
export function StringToEntityType(value) {
|
|
13
|
+
const lowerValue = value.toLowerCase();
|
|
14
|
+
switch (lowerValue) {
|
|
15
|
+
case 'destination':
|
|
16
|
+
return EntityTypeEnum.DESTINATION;
|
|
17
|
+
case 'park':
|
|
18
|
+
return EntityTypeEnum.PARK;
|
|
19
|
+
case 'attraction':
|
|
20
|
+
return EntityTypeEnum.ATTRACTION;
|
|
21
|
+
case 'restaurant':
|
|
22
|
+
return EntityTypeEnum.RESTAURANT;
|
|
23
|
+
case 'show':
|
|
24
|
+
return EntityTypeEnum.SHOW;
|
|
25
|
+
case 'hotel':
|
|
26
|
+
return EntityTypeEnum.HOTEL;
|
|
27
|
+
}
|
|
28
|
+
throw new Error('Unknown EntityType value: ' + value);
|
|
29
|
+
}
|
|
30
|
+
// Runtime Schema Registration
|
|
31
|
+
import { registerTypeSchema } from "../type_register.js";
|
|
32
|
+
registerTypeSchema("EntityType", {
|
|
33
|
+
"type": "string",
|
|
34
|
+
"enum": [
|
|
35
|
+
"DESTINATION",
|
|
36
|
+
"PARK",
|
|
37
|
+
"ATTRACTION",
|
|
38
|
+
"RESTAURANT",
|
|
39
|
+
"SHOW",
|
|
40
|
+
"HOTEL"
|
|
41
|
+
],
|
|
42
|
+
"description": "Possible types of entity in ThemeParks.wiki"
|
|
43
|
+
});
|
|
44
|
+
registerTypeSchema("EntityLocation", {
|
|
45
|
+
"type": "object",
|
|
46
|
+
"properties": {
|
|
47
|
+
"latitude": {
|
|
48
|
+
"type": "number",
|
|
49
|
+
"description": "Latitude coordinate of the entity location",
|
|
50
|
+
"nullable": true
|
|
51
|
+
},
|
|
52
|
+
"longitude": {
|
|
53
|
+
"type": "number",
|
|
54
|
+
"description": "Longitude coordinate of the entity location",
|
|
55
|
+
"nullable": true
|
|
56
|
+
}
|
|
57
|
+
}
|
|
58
|
+
});
|
|
59
|
+
registerTypeSchema("TagData", {
|
|
60
|
+
"type": "object",
|
|
61
|
+
"required": [
|
|
62
|
+
"tag",
|
|
63
|
+
"tagName"
|
|
64
|
+
],
|
|
65
|
+
"properties": {
|
|
66
|
+
"tag": {
|
|
67
|
+
"type": "string",
|
|
68
|
+
"description": "Tag identifier"
|
|
69
|
+
},
|
|
70
|
+
"tagName": {
|
|
71
|
+
"type": "string",
|
|
72
|
+
"description": "Human readable tag name"
|
|
73
|
+
},
|
|
74
|
+
"id": {
|
|
75
|
+
"type": "string",
|
|
76
|
+
"description": "Unique identifier"
|
|
77
|
+
},
|
|
78
|
+
"value": {
|
|
79
|
+
"description": "Tag value - can be string, number or object"
|
|
80
|
+
}
|
|
81
|
+
}
|
|
82
|
+
});
|
|
83
|
+
registerTypeSchema("Entity", {
|
|
84
|
+
"type": "object",
|
|
85
|
+
"required": [
|
|
86
|
+
"id",
|
|
87
|
+
"name",
|
|
88
|
+
"entityType",
|
|
89
|
+
"timezone"
|
|
90
|
+
],
|
|
91
|
+
"properties": {
|
|
92
|
+
"id": {
|
|
93
|
+
"type": "string",
|
|
94
|
+
"description": "Unique entity identifier"
|
|
95
|
+
},
|
|
96
|
+
"name": {
|
|
97
|
+
"type": "string",
|
|
98
|
+
"description": "Entity name"
|
|
99
|
+
},
|
|
100
|
+
"entityType": {
|
|
101
|
+
"$ref": "#/properties/EntityType",
|
|
102
|
+
"description": "Type of entity"
|
|
103
|
+
},
|
|
104
|
+
"parentId": {
|
|
105
|
+
"type": "string",
|
|
106
|
+
"nullable": true,
|
|
107
|
+
"description": "Parent entity identifier, must always be set when entityType is not DESTINATION"
|
|
108
|
+
},
|
|
109
|
+
"destinationId": {
|
|
110
|
+
"type": "string",
|
|
111
|
+
"nullable": true,
|
|
112
|
+
"description": "Destination identifier, must always be set when entityType is not DESTINATION"
|
|
113
|
+
},
|
|
114
|
+
"parkId": {
|
|
115
|
+
"type": "string",
|
|
116
|
+
"nullable": true,
|
|
117
|
+
"description": "Park identifier, must be set if any parent entity in the hierarchy is a park"
|
|
118
|
+
},
|
|
119
|
+
"timezone": {
|
|
120
|
+
"type": "string",
|
|
121
|
+
"description": "Entity timezone"
|
|
122
|
+
},
|
|
123
|
+
"location": {
|
|
124
|
+
"$ref": "#/properties/EntityLocation",
|
|
125
|
+
"description": "Entity location coordinates"
|
|
126
|
+
},
|
|
127
|
+
"tags": {
|
|
128
|
+
"type": "array",
|
|
129
|
+
"items": {
|
|
130
|
+
"$ref": "#/properties/TagData"
|
|
131
|
+
},
|
|
132
|
+
"description": "Array of tags associated with the entity"
|
|
133
|
+
}
|
|
134
|
+
}
|
|
135
|
+
});
|
package/dist/types/index.d.ts
CHANGED
|
@@ -1,3 +1,9 @@
|
|
|
1
|
-
import './
|
|
2
|
-
|
|
1
|
+
import './entities.types.js';
|
|
2
|
+
import './livedata.types.js';
|
|
3
|
+
import './pricedata.types.js';
|
|
4
|
+
import './schedule.types.js';
|
|
5
|
+
export * from './entities.types.js';
|
|
6
|
+
export * from './livedata.types.js';
|
|
7
|
+
export * from './pricedata.types.js';
|
|
8
|
+
export * from './schedule.types.js';
|
|
3
9
|
//# sourceMappingURL=index.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/types/index.ts"],"names":[],"mappings":"AAGA,OAAO,
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/types/index.ts"],"names":[],"mappings":"AAGA,OAAO,qBAAqB,CAAC;AAC7B,OAAO,qBAAqB,CAAC;AAC7B,OAAO,sBAAsB,CAAC;AAC9B,OAAO,qBAAqB,CAAC;AAG7B,cAAc,qBAAqB,CAAC;AACpC,cAAc,qBAAqB,CAAC;AACpC,cAAc,sBAAsB,CAAC;AACrC,cAAc,qBAAqB,CAAC"}
|
package/dist/types/index.js
CHANGED
|
@@ -1,5 +1,11 @@
|
|
|
1
1
|
// THIS FILE IS GENERATED - DO NOT EDIT DIRECTLY
|
|
2
2
|
// Import all type files to trigger schema registration
|
|
3
|
-
import './
|
|
3
|
+
import './entities.types.js';
|
|
4
|
+
import './livedata.types.js';
|
|
5
|
+
import './pricedata.types.js';
|
|
6
|
+
import './schedule.types.js';
|
|
4
7
|
// Re-export types
|
|
5
|
-
export * from './
|
|
8
|
+
export * from './entities.types.js';
|
|
9
|
+
export * from './livedata.types.js';
|
|
10
|
+
export * from './pricedata.types.js';
|
|
11
|
+
export * from './schedule.types.js';
|
|
@@ -0,0 +1,107 @@
|
|
|
1
|
+
import { PriceData } from './pricedata.types.js';
|
|
2
|
+
export declare enum LiveStatusTypeEnum {
|
|
3
|
+
"OPERATING" = "OPERATING",
|
|
4
|
+
"DOWN" = "DOWN",
|
|
5
|
+
"CLOSED" = "CLOSED",
|
|
6
|
+
"REFURBISHMENT" = "REFURBISHMENT"
|
|
7
|
+
}
|
|
8
|
+
/** Current operating status of an entity */
|
|
9
|
+
export type LiveStatusType = keyof typeof LiveStatusTypeEnum;
|
|
10
|
+
export declare function StringToLiveStatusType(value: string): LiveStatusTypeEnum;
|
|
11
|
+
export declare enum ReturnTimeStateEnum {
|
|
12
|
+
"AVAILABLE" = "AVAILABLE",
|
|
13
|
+
"TEMP_FULL" = "TEMP_FULL",
|
|
14
|
+
"FINISHED" = "FINISHED"
|
|
15
|
+
}
|
|
16
|
+
/** State of return time availability */
|
|
17
|
+
export type ReturnTimeState = keyof typeof ReturnTimeStateEnum;
|
|
18
|
+
export declare function StringToReturnTimeState(value: string): ReturnTimeStateEnum;
|
|
19
|
+
export declare enum BoardingGroupStateEnum {
|
|
20
|
+
"AVAILABLE" = "AVAILABLE",
|
|
21
|
+
"PAUSED" = "PAUSED",
|
|
22
|
+
"CLOSED" = "CLOSED"
|
|
23
|
+
}
|
|
24
|
+
/** State of boarding group availability */
|
|
25
|
+
export type BoardingGroupState = keyof typeof BoardingGroupStateEnum;
|
|
26
|
+
export declare function StringToBoardingGroupState(value: string): BoardingGroupStateEnum;
|
|
27
|
+
export type LiveQueue = {
|
|
28
|
+
/** Standard queue type for most attractions. Wait in line for attraction, no additional cost. */
|
|
29
|
+
STANDBY?: {
|
|
30
|
+
/** Current standby wait time in minutes */
|
|
31
|
+
waitTime?: number;
|
|
32
|
+
};
|
|
33
|
+
/** Single Rider queue type for attractions that offer it. Usually a shorter wait time, but you may be separated from your party. No additional cost. */
|
|
34
|
+
SINGLE_RIDER?: {
|
|
35
|
+
/** Current single rider wait time in minutes */
|
|
36
|
+
waitTime: number | null;
|
|
37
|
+
};
|
|
38
|
+
/** Return Time queue type for attractions that offer it. You get a return time to come back and ride the attraction later, instead of waiting in a physical line. No additional cost. */
|
|
39
|
+
RETURN_TIME?: {
|
|
40
|
+
/** State of return time availability */
|
|
41
|
+
state: ReturnTimeState;
|
|
42
|
+
/** Start time of return window */
|
|
43
|
+
returnStart: string | null;
|
|
44
|
+
/** End time of return window */
|
|
45
|
+
returnEnd: string | null;
|
|
46
|
+
};
|
|
47
|
+
/** Paid Return Time queue type for attractions that offer it. You pay an additional cost to get a return time to come back and ride the attraction later, instead of waiting in a physical line. */
|
|
48
|
+
PAID_RETURN_TIME?: {
|
|
49
|
+
/** State of return time availability */
|
|
50
|
+
state: ReturnTimeState;
|
|
51
|
+
/** Start time of return window */
|
|
52
|
+
returnStart: string | null;
|
|
53
|
+
/** End time of return window */
|
|
54
|
+
returnEnd: string | null;
|
|
55
|
+
/** Price information for paid return time */
|
|
56
|
+
price: PriceData;
|
|
57
|
+
};
|
|
58
|
+
/** Boarding Group queue type for attractions that offer it. You get allocated a boarding group number and wait until your group is called. No additional cost. */
|
|
59
|
+
BOARDING_GROUP?: {
|
|
60
|
+
/** State of boarding group availability */
|
|
61
|
+
allocationStatus: BoardingGroupState;
|
|
62
|
+
/** Current boarding group start number */
|
|
63
|
+
currentGroupStart: number | null;
|
|
64
|
+
/** Current boarding group end number */
|
|
65
|
+
currentGroupEnd: number | null;
|
|
66
|
+
/** Next boarding group allocation time */
|
|
67
|
+
nextAllocationTime: string | null;
|
|
68
|
+
/** Estimated wait time in minutes */
|
|
69
|
+
estimatedWait: number | null;
|
|
70
|
+
};
|
|
71
|
+
/** Paid Standby queue type for attractions that offer it. You pay an additional cost to use a separate standby line, usually with a shorter wait time. */
|
|
72
|
+
PAID_STANDBY?: {
|
|
73
|
+
/** Current paid standby wait time in minutes */
|
|
74
|
+
waitTime: number | null;
|
|
75
|
+
};
|
|
76
|
+
};
|
|
77
|
+
/** Time entry for shows or attraction operating hours */
|
|
78
|
+
export type LiveTimeSlot = {
|
|
79
|
+
/** Type of time entry */
|
|
80
|
+
type: string;
|
|
81
|
+
/** Start time */
|
|
82
|
+
startTime?: string | null;
|
|
83
|
+
/** End time */
|
|
84
|
+
endTime?: string | null;
|
|
85
|
+
};
|
|
86
|
+
/** Dining availability information for restaurants */
|
|
87
|
+
export type DiningAvailability = {
|
|
88
|
+
/** Available party size */
|
|
89
|
+
partySize?: number | null;
|
|
90
|
+
/** Current wait time in minutes */
|
|
91
|
+
waitTime?: number | null;
|
|
92
|
+
};
|
|
93
|
+
export type LiveData = {
|
|
94
|
+
/** Entity identifier */
|
|
95
|
+
id: string;
|
|
96
|
+
/** Current operating status of the entity */
|
|
97
|
+
status?: LiveStatusType;
|
|
98
|
+
/** Current queue information for entities with queues (e.g. attractions) */
|
|
99
|
+
queue?: LiveQueue;
|
|
100
|
+
/** Array of showtime entries for entities that have scheduled showtimes (e.g. shows) */
|
|
101
|
+
showtimes?: LiveTimeSlot[];
|
|
102
|
+
/** Array of operating hours entries for entities that have specific operating hours (e.g. parks, restaurants) */
|
|
103
|
+
operatingHours?: LiveTimeSlot[];
|
|
104
|
+
/** Array of dining availability entries for entities that have dining options (e.g. restaurants) */
|
|
105
|
+
diningAvailability?: DiningAvailability[];
|
|
106
|
+
};
|
|
107
|
+
//# sourceMappingURL=livedata.types.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"livedata.types.d.ts","sourceRoot":"","sources":["../../src/types/livedata.types.ts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AAE,cAAc,CAAC;IAExB,4EAA4E;IAC5E,KAAK,CAAC,EAAE,SAAS,CAAC;IAElB,wFAAwF;IACxF,SAAS,CAAC,EAAE,YAAY,EAAE,CAAC;IAE3B,iHAAiH;IACjH,cAAc,CAAC,EAAE,YAAY,EAAE,CAAC;IAEhC,oGAAoG;IACpG,kBAAkB,CAAC,EAAE,kBAAkB,EAAE,CAAC;CAC7C,CAAA"}
|
|
@@ -0,0 +1,313 @@
|
|
|
1
|
+
// THIS FILE IS GENERATED - DO NOT EDIT DIRECTLY
|
|
2
|
+
export var LiveStatusTypeEnum;
|
|
3
|
+
(function (LiveStatusTypeEnum) {
|
|
4
|
+
LiveStatusTypeEnum["OPERATING"] = "OPERATING";
|
|
5
|
+
LiveStatusTypeEnum["DOWN"] = "DOWN";
|
|
6
|
+
LiveStatusTypeEnum["CLOSED"] = "CLOSED";
|
|
7
|
+
LiveStatusTypeEnum["REFURBISHMENT"] = "REFURBISHMENT";
|
|
8
|
+
})(LiveStatusTypeEnum || (LiveStatusTypeEnum = {}));
|
|
9
|
+
// Function to convert string to LiveStatusTypeEnum
|
|
10
|
+
export function StringToLiveStatusType(value) {
|
|
11
|
+
const lowerValue = value.toLowerCase();
|
|
12
|
+
switch (lowerValue) {
|
|
13
|
+
case 'operating':
|
|
14
|
+
return LiveStatusTypeEnum.OPERATING;
|
|
15
|
+
case 'down':
|
|
16
|
+
return LiveStatusTypeEnum.DOWN;
|
|
17
|
+
case 'closed':
|
|
18
|
+
return LiveStatusTypeEnum.CLOSED;
|
|
19
|
+
case 'refurbishment':
|
|
20
|
+
return LiveStatusTypeEnum.REFURBISHMENT;
|
|
21
|
+
}
|
|
22
|
+
throw new Error('Unknown LiveStatusType value: ' + value);
|
|
23
|
+
}
|
|
24
|
+
export var ReturnTimeStateEnum;
|
|
25
|
+
(function (ReturnTimeStateEnum) {
|
|
26
|
+
ReturnTimeStateEnum["AVAILABLE"] = "AVAILABLE";
|
|
27
|
+
ReturnTimeStateEnum["TEMP_FULL"] = "TEMP_FULL";
|
|
28
|
+
ReturnTimeStateEnum["FINISHED"] = "FINISHED";
|
|
29
|
+
})(ReturnTimeStateEnum || (ReturnTimeStateEnum = {}));
|
|
30
|
+
// Function to convert string to ReturnTimeStateEnum
|
|
31
|
+
export function StringToReturnTimeState(value) {
|
|
32
|
+
const lowerValue = value.toLowerCase();
|
|
33
|
+
switch (lowerValue) {
|
|
34
|
+
case 'available':
|
|
35
|
+
return ReturnTimeStateEnum.AVAILABLE;
|
|
36
|
+
case 'temp_full':
|
|
37
|
+
return ReturnTimeStateEnum.TEMP_FULL;
|
|
38
|
+
case 'finished':
|
|
39
|
+
return ReturnTimeStateEnum.FINISHED;
|
|
40
|
+
}
|
|
41
|
+
throw new Error('Unknown ReturnTimeState value: ' + value);
|
|
42
|
+
}
|
|
43
|
+
export var BoardingGroupStateEnum;
|
|
44
|
+
(function (BoardingGroupStateEnum) {
|
|
45
|
+
BoardingGroupStateEnum["AVAILABLE"] = "AVAILABLE";
|
|
46
|
+
BoardingGroupStateEnum["PAUSED"] = "PAUSED";
|
|
47
|
+
BoardingGroupStateEnum["CLOSED"] = "CLOSED";
|
|
48
|
+
})(BoardingGroupStateEnum || (BoardingGroupStateEnum = {}));
|
|
49
|
+
// Function to convert string to BoardingGroupStateEnum
|
|
50
|
+
export function StringToBoardingGroupState(value) {
|
|
51
|
+
const lowerValue = value.toLowerCase();
|
|
52
|
+
switch (lowerValue) {
|
|
53
|
+
case 'available':
|
|
54
|
+
return BoardingGroupStateEnum.AVAILABLE;
|
|
55
|
+
case 'paused':
|
|
56
|
+
return BoardingGroupStateEnum.PAUSED;
|
|
57
|
+
case 'closed':
|
|
58
|
+
return BoardingGroupStateEnum.CLOSED;
|
|
59
|
+
}
|
|
60
|
+
throw new Error('Unknown BoardingGroupState value: ' + value);
|
|
61
|
+
}
|
|
62
|
+
// Runtime Schema Registration
|
|
63
|
+
import { registerTypeSchema } from "../type_register.js";
|
|
64
|
+
registerTypeSchema("LiveStatusType", {
|
|
65
|
+
"type": "string",
|
|
66
|
+
"enum": [
|
|
67
|
+
"OPERATING",
|
|
68
|
+
"DOWN",
|
|
69
|
+
"CLOSED",
|
|
70
|
+
"REFURBISHMENT"
|
|
71
|
+
],
|
|
72
|
+
"description": "Current operating status of an entity"
|
|
73
|
+
});
|
|
74
|
+
registerTypeSchema("ReturnTimeState", {
|
|
75
|
+
"type": "string",
|
|
76
|
+
"enum": [
|
|
77
|
+
"AVAILABLE",
|
|
78
|
+
"TEMP_FULL",
|
|
79
|
+
"FINISHED"
|
|
80
|
+
],
|
|
81
|
+
"description": "State of return time availability"
|
|
82
|
+
});
|
|
83
|
+
registerTypeSchema("BoardingGroupState", {
|
|
84
|
+
"type": "string",
|
|
85
|
+
"enum": [
|
|
86
|
+
"AVAILABLE",
|
|
87
|
+
"PAUSED",
|
|
88
|
+
"CLOSED"
|
|
89
|
+
],
|
|
90
|
+
"description": "State of boarding group availability"
|
|
91
|
+
});
|
|
92
|
+
registerTypeSchema("LiveQueue", {
|
|
93
|
+
"type": "object",
|
|
94
|
+
"properties": {
|
|
95
|
+
"STANDBY": {
|
|
96
|
+
"type": "object",
|
|
97
|
+
"properties": {
|
|
98
|
+
"waitTime": {
|
|
99
|
+
"type": "number",
|
|
100
|
+
"description": "Current standby wait time in minutes"
|
|
101
|
+
}
|
|
102
|
+
},
|
|
103
|
+
"description": "Standard queue type for most attractions. Wait in line for attraction, no additional cost."
|
|
104
|
+
},
|
|
105
|
+
"SINGLE_RIDER": {
|
|
106
|
+
"type": "object",
|
|
107
|
+
"required": [
|
|
108
|
+
"waitTime"
|
|
109
|
+
],
|
|
110
|
+
"properties": {
|
|
111
|
+
"waitTime": {
|
|
112
|
+
"type": "number",
|
|
113
|
+
"nullable": true,
|
|
114
|
+
"description": "Current single rider wait time in minutes"
|
|
115
|
+
}
|
|
116
|
+
},
|
|
117
|
+
"description": "Single Rider queue type for attractions that offer it. Usually a shorter wait time, but you may be separated from your party. No additional cost."
|
|
118
|
+
},
|
|
119
|
+
"RETURN_TIME": {
|
|
120
|
+
"type": "object",
|
|
121
|
+
"required": [
|
|
122
|
+
"state",
|
|
123
|
+
"returnStart",
|
|
124
|
+
"returnEnd"
|
|
125
|
+
],
|
|
126
|
+
"properties": {
|
|
127
|
+
"state": {
|
|
128
|
+
"$ref": "#/properties/ReturnTimeState",
|
|
129
|
+
"description": "State of return time availability"
|
|
130
|
+
},
|
|
131
|
+
"returnStart": {
|
|
132
|
+
"type": "string",
|
|
133
|
+
"format": "date-time",
|
|
134
|
+
"nullable": true,
|
|
135
|
+
"description": "Start time of return window"
|
|
136
|
+
},
|
|
137
|
+
"returnEnd": {
|
|
138
|
+
"type": "string",
|
|
139
|
+
"format": "date-time",
|
|
140
|
+
"nullable": true,
|
|
141
|
+
"description": "End time of return window"
|
|
142
|
+
}
|
|
143
|
+
},
|
|
144
|
+
"description": "Return Time queue type for attractions that offer it. You get a return time to come back and ride the attraction later, instead of waiting in a physical line. No additional cost."
|
|
145
|
+
},
|
|
146
|
+
"PAID_RETURN_TIME": {
|
|
147
|
+
"type": "object",
|
|
148
|
+
"required": [
|
|
149
|
+
"state",
|
|
150
|
+
"returnStart",
|
|
151
|
+
"returnEnd",
|
|
152
|
+
"price"
|
|
153
|
+
],
|
|
154
|
+
"properties": {
|
|
155
|
+
"state": {
|
|
156
|
+
"$ref": "#/properties/ReturnTimeState",
|
|
157
|
+
"description": "State of return time availability"
|
|
158
|
+
},
|
|
159
|
+
"returnStart": {
|
|
160
|
+
"type": "string",
|
|
161
|
+
"format": "date-time",
|
|
162
|
+
"nullable": true,
|
|
163
|
+
"description": "Start time of return window"
|
|
164
|
+
},
|
|
165
|
+
"returnEnd": {
|
|
166
|
+
"type": "string",
|
|
167
|
+
"format": "date-time",
|
|
168
|
+
"nullable": true,
|
|
169
|
+
"description": "End time of return window"
|
|
170
|
+
},
|
|
171
|
+
"price": {
|
|
172
|
+
"$ref": "#/properties/PriceData",
|
|
173
|
+
"description": "Price information for paid return time"
|
|
174
|
+
}
|
|
175
|
+
},
|
|
176
|
+
"description": "Paid Return Time queue type for attractions that offer it. You pay an additional cost to get a return time to come back and ride the attraction later, instead of waiting in a physical line."
|
|
177
|
+
},
|
|
178
|
+
"BOARDING_GROUP": {
|
|
179
|
+
"type": "object",
|
|
180
|
+
"required": [
|
|
181
|
+
"allocationStatus",
|
|
182
|
+
"currentGroupStart",
|
|
183
|
+
"currentGroupEnd",
|
|
184
|
+
"nextAllocationTime",
|
|
185
|
+
"estimatedWait"
|
|
186
|
+
],
|
|
187
|
+
"properties": {
|
|
188
|
+
"allocationStatus": {
|
|
189
|
+
"$ref": "#/properties/BoardingGroupState",
|
|
190
|
+
"description": "State of boarding group availability"
|
|
191
|
+
},
|
|
192
|
+
"currentGroupStart": {
|
|
193
|
+
"type": "number",
|
|
194
|
+
"nullable": true,
|
|
195
|
+
"description": "Current boarding group start number"
|
|
196
|
+
},
|
|
197
|
+
"currentGroupEnd": {
|
|
198
|
+
"type": "number",
|
|
199
|
+
"nullable": true,
|
|
200
|
+
"description": "Current boarding group end number"
|
|
201
|
+
},
|
|
202
|
+
"nextAllocationTime": {
|
|
203
|
+
"type": "string",
|
|
204
|
+
"format": "date-time",
|
|
205
|
+
"nullable": true,
|
|
206
|
+
"description": "Next boarding group allocation time"
|
|
207
|
+
},
|
|
208
|
+
"estimatedWait": {
|
|
209
|
+
"type": "number",
|
|
210
|
+
"nullable": true,
|
|
211
|
+
"description": "Estimated wait time in minutes"
|
|
212
|
+
}
|
|
213
|
+
},
|
|
214
|
+
"description": "Boarding Group queue type for attractions that offer it. You get allocated a boarding group number and wait until your group is called. No additional cost."
|
|
215
|
+
},
|
|
216
|
+
"PAID_STANDBY": {
|
|
217
|
+
"type": "object",
|
|
218
|
+
"required": [
|
|
219
|
+
"waitTime"
|
|
220
|
+
],
|
|
221
|
+
"properties": {
|
|
222
|
+
"waitTime": {
|
|
223
|
+
"type": "number",
|
|
224
|
+
"nullable": true,
|
|
225
|
+
"description": "Current paid standby wait time in minutes"
|
|
226
|
+
}
|
|
227
|
+
},
|
|
228
|
+
"description": "Paid Standby queue type for attractions that offer it. You pay an additional cost to use a separate standby line, usually with a shorter wait time."
|
|
229
|
+
}
|
|
230
|
+
}
|
|
231
|
+
});
|
|
232
|
+
registerTypeSchema("LiveTimeSlot", {
|
|
233
|
+
"type": "object",
|
|
234
|
+
"required": [
|
|
235
|
+
"type"
|
|
236
|
+
],
|
|
237
|
+
"properties": {
|
|
238
|
+
"type": {
|
|
239
|
+
"type": "string",
|
|
240
|
+
"description": "Type of time entry"
|
|
241
|
+
},
|
|
242
|
+
"startTime": {
|
|
243
|
+
"type": "string",
|
|
244
|
+
"format": "date-time",
|
|
245
|
+
"nullable": true,
|
|
246
|
+
"description": "Start time"
|
|
247
|
+
},
|
|
248
|
+
"endTime": {
|
|
249
|
+
"type": "string",
|
|
250
|
+
"format": "date-time",
|
|
251
|
+
"nullable": true,
|
|
252
|
+
"description": "End time"
|
|
253
|
+
}
|
|
254
|
+
},
|
|
255
|
+
"description": "Time entry for shows or attraction operating hours"
|
|
256
|
+
});
|
|
257
|
+
registerTypeSchema("DiningAvailability", {
|
|
258
|
+
"type": "object",
|
|
259
|
+
"properties": {
|
|
260
|
+
"partySize": {
|
|
261
|
+
"type": "number",
|
|
262
|
+
"nullable": true,
|
|
263
|
+
"description": "Available party size"
|
|
264
|
+
},
|
|
265
|
+
"waitTime": {
|
|
266
|
+
"type": "number",
|
|
267
|
+
"nullable": true,
|
|
268
|
+
"description": "Current wait time in minutes"
|
|
269
|
+
}
|
|
270
|
+
},
|
|
271
|
+
"description": "Dining availability information for restaurants"
|
|
272
|
+
});
|
|
273
|
+
registerTypeSchema("LiveData", {
|
|
274
|
+
"type": "object",
|
|
275
|
+
"required": [
|
|
276
|
+
"id"
|
|
277
|
+
],
|
|
278
|
+
"properties": {
|
|
279
|
+
"id": {
|
|
280
|
+
"type": "string",
|
|
281
|
+
"description": "Entity identifier"
|
|
282
|
+
},
|
|
283
|
+
"status": {
|
|
284
|
+
"$ref": "#/properties/LiveStatusType",
|
|
285
|
+
"description": "Current operating status of the entity"
|
|
286
|
+
},
|
|
287
|
+
"queue": {
|
|
288
|
+
"$ref": "#/properties/LiveQueue",
|
|
289
|
+
"description": "Current queue information for entities with queues (e.g. attractions)"
|
|
290
|
+
},
|
|
291
|
+
"showtimes": {
|
|
292
|
+
"type": "array",
|
|
293
|
+
"items": {
|
|
294
|
+
"$ref": "#/properties/LiveTimeSlot"
|
|
295
|
+
},
|
|
296
|
+
"description": "Array of showtime entries for entities that have scheduled showtimes (e.g. shows)"
|
|
297
|
+
},
|
|
298
|
+
"operatingHours": {
|
|
299
|
+
"type": "array",
|
|
300
|
+
"items": {
|
|
301
|
+
"$ref": "#/properties/LiveTimeSlot"
|
|
302
|
+
},
|
|
303
|
+
"description": "Array of operating hours entries for entities that have specific operating hours (e.g. parks, restaurants)"
|
|
304
|
+
},
|
|
305
|
+
"diningAvailability": {
|
|
306
|
+
"type": "array",
|
|
307
|
+
"items": {
|
|
308
|
+
"$ref": "#/properties/DiningAvailability"
|
|
309
|
+
},
|
|
310
|
+
"description": "Array of dining availability entries for entities that have dining options (e.g. restaurants)"
|
|
311
|
+
}
|
|
312
|
+
}
|
|
313
|
+
});
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
export declare enum CurrencyTypesEnum {
|
|
2
|
+
"USD" = "USD",
|
|
3
|
+
"EUR" = "EUR",
|
|
4
|
+
"GBP" = "GBP",
|
|
5
|
+
"JPY" = "JPY"
|
|
6
|
+
}
|
|
7
|
+
/** Currently supported currency codes by ThemeParks.wiki */
|
|
8
|
+
export type CurrencyTypes = keyof typeof CurrencyTypesEnum;
|
|
9
|
+
export declare function StringToCurrencyTypes(value: string): CurrencyTypesEnum;
|
|
10
|
+
export type PriceData = {
|
|
11
|
+
/** Numerical price amount. Always in the lowest denomination (e.g. cents for USD) */
|
|
12
|
+
amount: number;
|
|
13
|
+
/** Currency code */
|
|
14
|
+
currency: CurrencyTypes;
|
|
15
|
+
/** Formatted price string in human-readable format. E.g. $12.00 */
|
|
16
|
+
formatted?: string;
|
|
17
|
+
};
|
|
18
|
+
//# sourceMappingURL=pricedata.types.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"pricedata.types.d.ts","sourceRoot":"","sources":["../../src/types/pricedata.types.ts"],"names":[],"mappings":"AAEA,oBAAY,iBAAiB;IACzB,KAAK,QAAQ;IACb,KAAK,QAAQ;IACb,KAAK,QAAQ;IACb,KAAK,QAAQ;CAChB;AAED,4DAA4D;AAC5D,MAAM,MAAM,aAAa,GAAG,MAAM,OAAO,iBAAiB,CAAC;AAG3D,wBAAgB,qBAAqB,CAAC,KAAK,EAAE,MAAM,GAAG,iBAAiB,CAatE;AAED,MAAM,MAAM,SAAS,GAAG;IAEpB,qFAAqF;IACrF,MAAM,EAAE,MAAM,CAAC;IAEf,oBAAoB;IACpB,QAAQ,EAAE,aAAa,CAAC;IAExB,mEAAmE;IACnE,SAAS,CAAC,EAAE,MAAM,CAAC;CACtB,CAAA"}
|