@mtnmanager/sdk 1.2.1 → 1.4.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.
Files changed (168) hide show
  1. package/README.md +24 -0
  2. package/dist/apis/MtnManagerApi.d.ts +166 -1
  3. package/dist/apis/MtnManagerApi.js +204 -40
  4. package/dist/esm/apis/MtnManagerApi.d.ts +166 -1
  5. package/dist/esm/apis/MtnManagerApi.js +205 -41
  6. package/dist/esm/models/Amenity.d.ts +69 -0
  7. package/dist/esm/models/Amenity.js +64 -0
  8. package/dist/esm/models/AmenityCategory.d.ts +12 -3
  9. package/dist/esm/models/AmenityCategory.js +12 -3
  10. package/dist/esm/models/CalendarDay.d.ts +1 -1
  11. package/dist/esm/models/CalendarDay.js +2 -2
  12. package/dist/esm/models/CurrentWeather.js +1 -1
  13. package/dist/esm/models/CurrentWeatherImperial.js +2 -2
  14. package/dist/esm/models/CurrentWeatherMetric.js +2 -2
  15. package/dist/esm/models/DailyForecast.js +1 -1
  16. package/dist/esm/models/DailyForecastImperial.js +2 -2
  17. package/dist/esm/models/DailyForecastMetric.js +2 -2
  18. package/dist/esm/models/FullReport.js +3 -3
  19. package/dist/esm/models/GeoControlPoint.d.ts +50 -0
  20. package/dist/esm/models/GeoControlPoint.js +55 -0
  21. package/dist/esm/models/HourlyForecast.js +1 -1
  22. package/dist/esm/models/HourlyForecastImperial.js +1 -1
  23. package/dist/esm/models/HourlyForecastMetric.js +1 -1
  24. package/dist/esm/models/LabelOffset.d.ts +38 -0
  25. package/dist/esm/models/LabelOffset.js +47 -0
  26. package/dist/esm/models/Lift.d.ts +30 -0
  27. package/dist/esm/models/Lift.js +13 -3
  28. package/dist/esm/models/MarkerIcon.d.ts +45 -0
  29. package/dist/esm/models/MarkerIcon.js +63 -0
  30. package/dist/esm/models/OperatingHours.js +1 -1
  31. package/dist/esm/models/Overview.d.ts +20 -100
  32. package/dist/esm/models/Overview.js +19 -52
  33. package/dist/esm/models/OverviewLifts.d.ts +45 -0
  34. package/dist/esm/models/OverviewLifts.js +49 -0
  35. package/dist/esm/models/OverviewNews.d.ts +44 -0
  36. package/dist/esm/models/OverviewNews.js +51 -0
  37. package/dist/esm/models/OverviewRuns.d.ts +66 -0
  38. package/dist/esm/models/OverviewRuns.js +55 -0
  39. package/dist/esm/models/OverviewSummerTrails.d.ts +45 -0
  40. package/dist/esm/models/OverviewSummerTrails.js +49 -0
  41. package/dist/esm/models/OverviewTerrainParks.d.ts +45 -0
  42. package/dist/esm/models/OverviewTerrainParks.js +49 -0
  43. package/dist/esm/models/ParkingLot.js +2 -2
  44. package/dist/esm/models/PathUuid.d.ts +32 -0
  45. package/dist/esm/models/PathUuid.js +43 -0
  46. package/dist/esm/models/PointMarker.d.ts +24 -0
  47. package/dist/esm/models/PointMarker.js +58 -0
  48. package/dist/esm/models/PointMarkerOneOf.d.ts +77 -0
  49. package/dist/esm/models/PointMarkerOneOf.js +71 -0
  50. package/dist/esm/models/PointMarkerOneOf1.d.ts +77 -0
  51. package/dist/esm/models/PointMarkerOneOf1.js +71 -0
  52. package/dist/esm/models/PointMarkerOneOf2.d.ts +82 -0
  53. package/dist/esm/models/PointMarkerOneOf2.js +74 -0
  54. package/dist/esm/models/ResortInfo.js +1 -1
  55. package/dist/esm/models/Run.js +4 -4
  56. package/dist/esm/models/Schedule.js +9 -9
  57. package/dist/esm/models/SeasonType.d.ts +4 -9
  58. package/dist/esm/models/SeasonType.js +23 -24
  59. package/dist/esm/models/SnowMetrics.js +4 -4
  60. package/dist/esm/models/SnowReport.d.ts +34 -0
  61. package/dist/esm/models/SnowReport.js +4 -4
  62. package/dist/esm/models/SummerTrail.d.ts +1 -1
  63. package/dist/esm/models/SummerTrail.js +3 -3
  64. package/dist/esm/models/TerrainPark.js +2 -2
  65. package/dist/esm/models/TerrainParkFeature.d.ts +1 -1
  66. package/dist/esm/models/TerrainParkFeature.js +1 -1
  67. package/dist/esm/models/TrailMap.d.ts +84 -0
  68. package/dist/esm/models/TrailMap.js +77 -0
  69. package/dist/esm/models/TrailMapElement.d.ts +26 -0
  70. package/dist/esm/models/TrailMapElement.js +72 -0
  71. package/dist/esm/models/TrailMapElementOneOf.d.ts +64 -0
  72. package/dist/esm/models/TrailMapElementOneOf.js +64 -0
  73. package/dist/esm/models/TrailMapElementOneOf1.d.ts +64 -0
  74. package/dist/esm/models/TrailMapElementOneOf1.js +64 -0
  75. package/dist/esm/models/TrailMapElementOneOf2.d.ts +71 -0
  76. package/dist/esm/models/TrailMapElementOneOf2.js +67 -0
  77. package/dist/esm/models/TrailMapElementOneOf3.d.ts +64 -0
  78. package/dist/esm/models/TrailMapElementOneOf3.js +64 -0
  79. package/dist/esm/models/TrailMapElementOneOf4.d.ts +39 -0
  80. package/dist/esm/models/TrailMapElementOneOf4.js +48 -0
  81. package/dist/esm/models/TrailMapSummary.d.ts +57 -0
  82. package/dist/esm/models/TrailMapSummary.js +60 -0
  83. package/dist/esm/models/Weather.js +3 -3
  84. package/dist/esm/models/index.d.ts +22 -0
  85. package/dist/esm/models/index.js +22 -0
  86. package/dist/esm/runtime.js +16 -1
  87. package/dist/models/Amenity.d.ts +69 -0
  88. package/dist/models/Amenity.js +71 -0
  89. package/dist/models/AmenityCategory.d.ts +12 -3
  90. package/dist/models/AmenityCategory.js +12 -3
  91. package/dist/models/CalendarDay.d.ts +1 -1
  92. package/dist/models/CalendarDay.js +2 -2
  93. package/dist/models/CurrentWeather.js +1 -1
  94. package/dist/models/CurrentWeatherImperial.js +2 -2
  95. package/dist/models/CurrentWeatherMetric.js +2 -2
  96. package/dist/models/DailyForecast.js +1 -1
  97. package/dist/models/DailyForecastImperial.js +2 -2
  98. package/dist/models/DailyForecastMetric.js +2 -2
  99. package/dist/models/FullReport.js +3 -3
  100. package/dist/models/GeoControlPoint.d.ts +50 -0
  101. package/dist/models/GeoControlPoint.js +62 -0
  102. package/dist/models/HourlyForecast.js +1 -1
  103. package/dist/models/HourlyForecastImperial.js +1 -1
  104. package/dist/models/HourlyForecastMetric.js +1 -1
  105. package/dist/models/LabelOffset.d.ts +38 -0
  106. package/dist/models/LabelOffset.js +54 -0
  107. package/dist/models/Lift.d.ts +30 -0
  108. package/dist/models/Lift.js +13 -3
  109. package/dist/models/MarkerIcon.d.ts +45 -0
  110. package/dist/models/MarkerIcon.js +71 -0
  111. package/dist/models/OperatingHours.js +1 -1
  112. package/dist/models/Overview.d.ts +20 -100
  113. package/dist/models/Overview.js +19 -52
  114. package/dist/models/OverviewLifts.d.ts +45 -0
  115. package/dist/models/OverviewLifts.js +56 -0
  116. package/dist/models/OverviewNews.d.ts +44 -0
  117. package/dist/models/OverviewNews.js +58 -0
  118. package/dist/models/OverviewRuns.d.ts +66 -0
  119. package/dist/models/OverviewRuns.js +62 -0
  120. package/dist/models/OverviewSummerTrails.d.ts +45 -0
  121. package/dist/models/OverviewSummerTrails.js +56 -0
  122. package/dist/models/OverviewTerrainParks.d.ts +45 -0
  123. package/dist/models/OverviewTerrainParks.js +56 -0
  124. package/dist/models/ParkingLot.js +2 -2
  125. package/dist/models/PathUuid.d.ts +32 -0
  126. package/dist/models/PathUuid.js +50 -0
  127. package/dist/models/PointMarker.d.ts +24 -0
  128. package/dist/models/PointMarker.js +64 -0
  129. package/dist/models/PointMarkerOneOf.d.ts +77 -0
  130. package/dist/models/PointMarkerOneOf.js +79 -0
  131. package/dist/models/PointMarkerOneOf1.d.ts +77 -0
  132. package/dist/models/PointMarkerOneOf1.js +79 -0
  133. package/dist/models/PointMarkerOneOf2.d.ts +82 -0
  134. package/dist/models/PointMarkerOneOf2.js +82 -0
  135. package/dist/models/ResortInfo.js +1 -1
  136. package/dist/models/Run.js +4 -4
  137. package/dist/models/Schedule.js +9 -9
  138. package/dist/models/SeasonType.d.ts +4 -9
  139. package/dist/models/SeasonType.js +23 -26
  140. package/dist/models/SnowMetrics.js +4 -4
  141. package/dist/models/SnowReport.d.ts +34 -0
  142. package/dist/models/SnowReport.js +4 -4
  143. package/dist/models/SummerTrail.d.ts +1 -1
  144. package/dist/models/SummerTrail.js +3 -3
  145. package/dist/models/TerrainPark.js +2 -2
  146. package/dist/models/TerrainParkFeature.d.ts +1 -1
  147. package/dist/models/TerrainParkFeature.js +1 -1
  148. package/dist/models/TrailMap.d.ts +84 -0
  149. package/dist/models/TrailMap.js +84 -0
  150. package/dist/models/TrailMapElement.d.ts +26 -0
  151. package/dist/models/TrailMapElement.js +78 -0
  152. package/dist/models/TrailMapElementOneOf.d.ts +64 -0
  153. package/dist/models/TrailMapElementOneOf.js +72 -0
  154. package/dist/models/TrailMapElementOneOf1.d.ts +64 -0
  155. package/dist/models/TrailMapElementOneOf1.js +72 -0
  156. package/dist/models/TrailMapElementOneOf2.d.ts +71 -0
  157. package/dist/models/TrailMapElementOneOf2.js +75 -0
  158. package/dist/models/TrailMapElementOneOf3.d.ts +64 -0
  159. package/dist/models/TrailMapElementOneOf3.js +72 -0
  160. package/dist/models/TrailMapElementOneOf4.d.ts +39 -0
  161. package/dist/models/TrailMapElementOneOf4.js +56 -0
  162. package/dist/models/TrailMapSummary.d.ts +57 -0
  163. package/dist/models/TrailMapSummary.js +67 -0
  164. package/dist/models/Weather.js +3 -3
  165. package/dist/models/index.d.ts +22 -0
  166. package/dist/models/index.js +22 -0
  167. package/dist/runtime.js +16 -1
  168. package/package.json +1 -1
@@ -11,34 +11,33 @@
11
11
  * https://openapi-generator.tech
12
12
  * Do not edit the class manually.
13
13
  */
14
- /**
15
- * Current operating season of the resort.
16
- * @export
17
- */
18
- export const SeasonType = {
19
- Winter: 'winter',
20
- Summer: 'summer',
21
- Closed: 'closed'
22
- };
23
- export function instanceOfSeasonType(value) {
24
- for (const key in SeasonType) {
25
- if (Object.prototype.hasOwnProperty.call(SeasonType, key)) {
26
- if (SeasonType[key] === value) {
27
- return true;
28
- }
29
- }
30
- }
31
- return false;
32
- }
33
14
  export function SeasonTypeFromJSON(json) {
34
15
  return SeasonTypeFromJSONTyped(json, false);
35
16
  }
36
17
  export function SeasonTypeFromJSONTyped(json, ignoreDiscriminator) {
37
- return json;
18
+ if (json == null) {
19
+ return json;
20
+ }
21
+ if (typeof json === 'string' && (json === 'winter' || json === 'summer')) {
22
+ return json;
23
+ }
24
+ if (typeof json === 'string' && (json === 'closed')) {
25
+ return json;
26
+ }
27
+ return {};
38
28
  }
39
- export function SeasonTypeToJSON(value) {
40
- return value;
29
+ export function SeasonTypeToJSON(json) {
30
+ return SeasonTypeToJSONTyped(json, false);
41
31
  }
42
- export function SeasonTypeToJSONTyped(value, ignoreDiscriminator) {
43
- return value;
32
+ export function SeasonTypeToJSONTyped(value, ignoreDiscriminator = false) {
33
+ if (value == null) {
34
+ return value;
35
+ }
36
+ if (typeof value === 'string' && (value === 'winter' || value === 'summer')) {
37
+ return value;
38
+ }
39
+ if (typeof value === 'string' && (value === 'closed')) {
40
+ return value;
41
+ }
42
+ return {};
44
43
  }
@@ -17,13 +17,13 @@
17
17
  export function instanceOfSnowMetrics(value) {
18
18
  if (!('overnight' in value) || value['overnight'] === undefined)
19
19
  return false;
20
- if (!('last24h' in value) || value['last24h'] === undefined)
20
+ if ((!('last24h' in value) && !('last_24h' in value)) || (value['last24h'] === undefined && value['last_24h'] === undefined))
21
21
  return false;
22
- if (!('last48h' in value) || value['last48h'] === undefined)
22
+ if ((!('last48h' in value) && !('last_48h' in value)) || (value['last48h'] === undefined && value['last_48h'] === undefined))
23
23
  return false;
24
- if (!('last7days' in value) || value['last7days'] === undefined)
24
+ if ((!('last7days' in value) && !('last_7days' in value)) || (value['last7days'] === undefined && value['last_7days'] === undefined))
25
25
  return false;
26
- if (!('seasonTotal' in value) || value['seasonTotal'] === undefined)
26
+ if ((!('seasonTotal' in value) && !('season_total' in value)) || (value['seasonTotal'] === undefined && value['season_total'] === undefined))
27
27
  return false;
28
28
  return true;
29
29
  }
@@ -59,13 +59,47 @@ export interface SnowReport {
59
59
  */
60
60
  baseDepthIn?: number | null;
61
61
  /**
62
+ * Primary surface condition using industry standard codes.
63
+ * Not included if the snow surface condition feature is disabled.
62
64
  *
65
+ * - BS (Bare Spots)
66
+ * - CO (Corn Snow)
67
+ * - FG (Frozen Granular)
68
+ * - HP (Hard Pack)
69
+ * - IP (Ice Patches)
70
+ * - IS (Icy Surface)
71
+ * - LG (Loose Granular)
72
+ * - MG (Machine Groomed)
73
+ * - P (Powder)
74
+ * - PP (Packed Powder)
75
+ * - SC (Spring Conditions)
76
+ * - TC (Thin Cover)
77
+ * - V (Variable)
78
+ * - WG (Wet Granular)
79
+ * - WP (Wet Powder)
63
80
  * @type {SurfaceCondition}
64
81
  * @memberof SnowReport
65
82
  */
66
83
  surfaceCondition?: SurfaceCondition | null;
67
84
  /**
85
+ * Secondary surface condition using industry standard codes.
86
+ * Not included if the secondary snow surface condition feature is disabled.
68
87
  *
88
+ * - BS (Bare Spots)
89
+ * - CO (Corn Snow)
90
+ * - FG (Frozen Granular)
91
+ * - HP (Hard Pack)
92
+ * - IP (Ice Patches)
93
+ * - IS (Icy Surface)
94
+ * - LG (Loose Granular)
95
+ * - MG (Machine Groomed)
96
+ * - P (Powder)
97
+ * - PP (Packed Powder)
98
+ * - SC (Spring Conditions)
99
+ * - TC (Thin Cover)
100
+ * - V (Variable)
101
+ * - WG (Wet Granular)
102
+ * - WP (Wet Powder)
69
103
  * @type {SurfaceCondition}
70
104
  * @memberof SnowReport
71
105
  */
@@ -19,13 +19,13 @@ import { SurfaceConditionFromJSON, SurfaceConditionToJSON, } from './SurfaceCond
19
19
  export function instanceOfSnowReport(value) {
20
20
  if (!('uuid' in value) || value['uuid'] === undefined)
21
21
  return false;
22
- if (!('conditionNotes' in value) || value['conditionNotes'] === undefined)
22
+ if ((!('conditionNotes' in value) && !('condition_notes' in value)) || (value['conditionNotes'] === undefined && value['condition_notes'] === undefined))
23
23
  return false;
24
- if (!('snowfallCm' in value) || value['snowfallCm'] === undefined)
24
+ if ((!('snowfallCm' in value) && !('snowfall_cm' in value)) || (value['snowfallCm'] === undefined && value['snowfall_cm'] === undefined))
25
25
  return false;
26
- if (!('snowfallIn' in value) || value['snowfallIn'] === undefined)
26
+ if ((!('snowfallIn' in value) && !('snowfall_in' in value)) || (value['snowfallIn'] === undefined && value['snowfall_in'] === undefined))
27
27
  return false;
28
- if (!('reportedAt' in value) || value['reportedAt'] === undefined)
28
+ if ((!('reportedAt' in value) && !('reported_at' in value)) || (value['reportedAt'] === undefined && value['reported_at'] === undefined))
29
29
  return false;
30
30
  return true;
31
31
  }
@@ -50,7 +50,7 @@ export interface SummerTrail {
50
50
  */
51
51
  trailType: Array<SummerTrailType>;
52
52
  /**
53
- *
53
+ * Difficulty rating of the trail (optional for summer trails).
54
54
  * @type {SummerTrailDifficulty}
55
55
  * @memberof SummerTrail
56
56
  */
@@ -24,13 +24,13 @@ export function instanceOfSummerTrail(value) {
24
24
  return false;
25
25
  if (!('slug' in value) || value['slug'] === undefined)
26
26
  return false;
27
- if (!('trailType' in value) || value['trailType'] === undefined)
27
+ if ((!('trailType' in value) && !('trail_type' in value)) || (value['trailType'] === undefined && value['trail_type'] === undefined))
28
28
  return false;
29
29
  if (!('status' in value) || value['status'] === undefined)
30
30
  return false;
31
- if (!('conditionNotes' in value) || value['conditionNotes'] === undefined)
31
+ if ((!('conditionNotes' in value) && !('condition_notes' in value)) || (value['conditionNotes'] === undefined && value['condition_notes'] === undefined))
32
32
  return false;
33
- if (!('updatedAt' in value) || value['updatedAt'] === undefined)
33
+ if ((!('updatedAt' in value) && !('updated_at' in value)) || (value['updatedAt'] === undefined && value['updated_at'] === undefined))
34
34
  return false;
35
35
  return true;
36
36
  }
@@ -25,11 +25,11 @@ export function instanceOfTerrainPark(value) {
25
25
  return false;
26
26
  if (!('status' in value) || value['status'] === undefined)
27
27
  return false;
28
- if (!('conditionNotes' in value) || value['conditionNotes'] === undefined)
28
+ if ((!('conditionNotes' in value) && !('condition_notes' in value)) || (value['conditionNotes'] === undefined && value['condition_notes'] === undefined))
29
29
  return false;
30
30
  if (!('features' in value) || value['features'] === undefined)
31
31
  return false;
32
- if (!('updatedAt' in value) || value['updatedAt'] === undefined)
32
+ if ((!('updatedAt' in value) && !('updated_at' in value)) || (value['updatedAt'] === undefined && value['updated_at'] === undefined))
33
33
  return false;
34
34
  return true;
35
35
  }
@@ -50,7 +50,7 @@ export interface TerrainParkFeature {
50
50
  */
51
51
  featureType: FeatureType;
52
52
  /**
53
- *
53
+ * Optional size rating of the feature (S, M, L, XL).
54
54
  * @type {FeatureSize}
55
55
  * @memberof TerrainParkFeature
56
56
  */
@@ -24,7 +24,7 @@ export function instanceOfTerrainParkFeature(value) {
24
24
  return false;
25
25
  if (!('slug' in value) || value['slug'] === undefined)
26
26
  return false;
27
- if (!('featureType' in value) || value['featureType'] === undefined)
27
+ if ((!('featureType' in value) && !('feature_type' in value)) || (value['featureType'] === undefined && value['feature_type'] === undefined))
28
28
  return false;
29
29
  if (!('status' in value) || value['status'] === undefined)
30
30
  return false;
@@ -0,0 +1,84 @@
1
+ /**
2
+ * MtnManager API
3
+ * The MtnManager API provides real-time access to your ski resort’s public operational data. Use it to display current conditions on your website, mobile app, or digital signage.
4
+ *
5
+ * The version of the OpenAPI document: 1.0.0
6
+ * Contact: support@mtnmanager.com
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
+ import type { ResortInfo } from './ResortInfo';
13
+ import type { TrailMapElement } from './TrailMapElement';
14
+ import type { SeasonType } from './SeasonType';
15
+ import type { GeoControlPoint } from './GeoControlPoint';
16
+ /**
17
+ * A public trail map with enriched entity data.
18
+ * @export
19
+ * @interface TrailMap
20
+ */
21
+ export interface TrailMap {
22
+ /**
23
+ *
24
+ * @type {string}
25
+ * @memberof TrailMap
26
+ */
27
+ uuid: string;
28
+ /**
29
+ *
30
+ * @type {string}
31
+ * @memberof TrailMap
32
+ */
33
+ name: string;
34
+ /**
35
+ *
36
+ * @type {string}
37
+ * @memberof TrailMap
38
+ */
39
+ slug: string;
40
+ /**
41
+ *
42
+ * @type {SeasonType}
43
+ * @memberof TrailMap
44
+ */
45
+ season: SeasonType;
46
+ /**
47
+ *
48
+ * @type {number}
49
+ * @memberof TrailMap
50
+ */
51
+ displayOrder: number;
52
+ /**
53
+ *
54
+ * @type {string}
55
+ * @memberof TrailMap
56
+ */
57
+ backgroundImageUrl: string;
58
+ /**
59
+ *
60
+ * @type {ResortInfo}
61
+ * @memberof TrailMap
62
+ */
63
+ resort: ResortInfo;
64
+ /**
65
+ *
66
+ * @type {Array<TrailMapElement>}
67
+ * @memberof TrailMap
68
+ */
69
+ elements: Array<TrailMapElement>;
70
+ /**
71
+ *
72
+ * @type {Array<GeoControlPoint>}
73
+ * @memberof TrailMap
74
+ */
75
+ geoControlPoints?: Array<GeoControlPoint> | null;
76
+ }
77
+ /**
78
+ * Check if a given object implements the TrailMap interface.
79
+ */
80
+ export declare function instanceOfTrailMap(value: object): value is TrailMap;
81
+ export declare function TrailMapFromJSON(json: any): TrailMap;
82
+ export declare function TrailMapFromJSONTyped(json: any, ignoreDiscriminator: boolean): TrailMap;
83
+ export declare function TrailMapToJSON(json: any): TrailMap;
84
+ export declare function TrailMapToJSONTyped(value?: TrailMap | null, ignoreDiscriminator?: boolean): any;
@@ -0,0 +1,77 @@
1
+ /* tslint:disable */
2
+ /* eslint-disable */
3
+ /**
4
+ * MtnManager API
5
+ * The MtnManager API provides real-time access to your ski resort’s public operational data. Use it to display current conditions on your website, mobile app, or digital signage.
6
+ *
7
+ * The version of the OpenAPI document: 1.0.0
8
+ * Contact: support@mtnmanager.com
9
+ *
10
+ * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
11
+ * https://openapi-generator.tech
12
+ * Do not edit the class manually.
13
+ */
14
+ import { ResortInfoFromJSON, ResortInfoToJSON, } from './ResortInfo';
15
+ import { TrailMapElementFromJSON, TrailMapElementToJSON, } from './TrailMapElement';
16
+ import { SeasonTypeFromJSON, SeasonTypeToJSON, } from './SeasonType';
17
+ import { GeoControlPointFromJSON, GeoControlPointToJSON, } from './GeoControlPoint';
18
+ /**
19
+ * Check if a given object implements the TrailMap interface.
20
+ */
21
+ export function instanceOfTrailMap(value) {
22
+ if (!('uuid' in value) || value['uuid'] === undefined)
23
+ return false;
24
+ if (!('name' in value) || value['name'] === undefined)
25
+ return false;
26
+ if (!('slug' in value) || value['slug'] === undefined)
27
+ return false;
28
+ if (!('season' in value) || value['season'] === undefined)
29
+ return false;
30
+ if ((!('displayOrder' in value) && !('display_order' in value)) || (value['displayOrder'] === undefined && value['display_order'] === undefined))
31
+ return false;
32
+ if ((!('backgroundImageUrl' in value) && !('background_image_url' in value)) || (value['backgroundImageUrl'] === undefined && value['background_image_url'] === undefined))
33
+ return false;
34
+ if (!('resort' in value) || value['resort'] === undefined)
35
+ return false;
36
+ if (!('elements' in value) || value['elements'] === undefined)
37
+ return false;
38
+ return true;
39
+ }
40
+ export function TrailMapFromJSON(json) {
41
+ return TrailMapFromJSONTyped(json, false);
42
+ }
43
+ export function TrailMapFromJSONTyped(json, ignoreDiscriminator) {
44
+ if (json == null) {
45
+ return json;
46
+ }
47
+ return {
48
+ 'uuid': json['uuid'],
49
+ 'name': json['name'],
50
+ 'slug': json['slug'],
51
+ 'season': SeasonTypeFromJSON(json['season']),
52
+ 'displayOrder': json['display_order'],
53
+ 'backgroundImageUrl': json['background_image_url'],
54
+ 'resort': ResortInfoFromJSON(json['resort']),
55
+ 'elements': (json['elements'].map(TrailMapElementFromJSON)),
56
+ 'geoControlPoints': json['geo_control_points'] == null ? undefined : (json['geo_control_points'].map(GeoControlPointFromJSON)),
57
+ };
58
+ }
59
+ export function TrailMapToJSON(json) {
60
+ return TrailMapToJSONTyped(json, false);
61
+ }
62
+ export function TrailMapToJSONTyped(value, ignoreDiscriminator = false) {
63
+ if (value == null) {
64
+ return value;
65
+ }
66
+ return {
67
+ 'uuid': value['uuid'],
68
+ 'name': value['name'],
69
+ 'slug': value['slug'],
70
+ 'season': SeasonTypeToJSON(value['season']),
71
+ 'display_order': value['displayOrder'],
72
+ 'background_image_url': value['backgroundImageUrl'],
73
+ 'resort': ResortInfoToJSON(value['resort']),
74
+ 'elements': (value['elements'].map(TrailMapElementToJSON)),
75
+ 'geo_control_points': value['geoControlPoints'] == null ? undefined : (value['geoControlPoints'].map(GeoControlPointToJSON)),
76
+ };
77
+ }
@@ -0,0 +1,26 @@
1
+ /**
2
+ * MtnManager API
3
+ * The MtnManager API provides real-time access to your ski resort’s public operational data. Use it to display current conditions on your website, mobile app, or digital signage.
4
+ *
5
+ * The version of the OpenAPI document: 1.0.0
6
+ * Contact: support@mtnmanager.com
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
+ import type { TrailMapElementOneOf } from './TrailMapElementOneOf';
13
+ import type { TrailMapElementOneOf1 } from './TrailMapElementOneOf1';
14
+ import type { TrailMapElementOneOf2 } from './TrailMapElementOneOf2';
15
+ import type { TrailMapElementOneOf3 } from './TrailMapElementOneOf3';
16
+ import type { TrailMapElementOneOf4 } from './TrailMapElementOneOf4';
17
+ /**
18
+ * @type TrailMapElement
19
+ * A trail map element with full entity data from existing public models.
20
+ * @export
21
+ */
22
+ export type TrailMapElement = TrailMapElementOneOf | TrailMapElementOneOf1 | TrailMapElementOneOf2 | TrailMapElementOneOf3 | TrailMapElementOneOf4;
23
+ export declare function TrailMapElementFromJSON(json: any): TrailMapElement;
24
+ export declare function TrailMapElementFromJSONTyped(json: any, ignoreDiscriminator: boolean): TrailMapElement;
25
+ export declare function TrailMapElementToJSON(json: any): any;
26
+ export declare function TrailMapElementToJSONTyped(value?: TrailMapElement | null, ignoreDiscriminator?: boolean): any;
@@ -0,0 +1,72 @@
1
+ /* tslint:disable */
2
+ /* eslint-disable */
3
+ /**
4
+ * MtnManager API
5
+ * The MtnManager API provides real-time access to your ski resort’s public operational data. Use it to display current conditions on your website, mobile app, or digital signage.
6
+ *
7
+ * The version of the OpenAPI document: 1.0.0
8
+ * Contact: support@mtnmanager.com
9
+ *
10
+ * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
11
+ * https://openapi-generator.tech
12
+ * Do not edit the class manually.
13
+ */
14
+ import { instanceOfTrailMapElementOneOf, TrailMapElementOneOfFromJSONTyped, TrailMapElementOneOfToJSON, } from './TrailMapElementOneOf';
15
+ import { instanceOfTrailMapElementOneOf1, TrailMapElementOneOf1FromJSONTyped, TrailMapElementOneOf1ToJSON, } from './TrailMapElementOneOf1';
16
+ import { instanceOfTrailMapElementOneOf2, TrailMapElementOneOf2FromJSONTyped, TrailMapElementOneOf2ToJSON, } from './TrailMapElementOneOf2';
17
+ import { instanceOfTrailMapElementOneOf3, TrailMapElementOneOf3FromJSONTyped, TrailMapElementOneOf3ToJSON, } from './TrailMapElementOneOf3';
18
+ import { instanceOfTrailMapElementOneOf4, TrailMapElementOneOf4FromJSONTyped, TrailMapElementOneOf4ToJSON, } from './TrailMapElementOneOf4';
19
+ export function TrailMapElementFromJSON(json) {
20
+ return TrailMapElementFromJSONTyped(json, false);
21
+ }
22
+ export function TrailMapElementFromJSONTyped(json, ignoreDiscriminator) {
23
+ if (json == null) {
24
+ return json;
25
+ }
26
+ if (typeof json !== 'object') {
27
+ return json;
28
+ }
29
+ if (instanceOfTrailMapElementOneOf(json)) {
30
+ return TrailMapElementOneOfFromJSONTyped(json, true);
31
+ }
32
+ if (instanceOfTrailMapElementOneOf1(json)) {
33
+ return TrailMapElementOneOf1FromJSONTyped(json, true);
34
+ }
35
+ if (instanceOfTrailMapElementOneOf2(json)) {
36
+ return TrailMapElementOneOf2FromJSONTyped(json, true);
37
+ }
38
+ if (instanceOfTrailMapElementOneOf3(json)) {
39
+ return TrailMapElementOneOf3FromJSONTyped(json, true);
40
+ }
41
+ if (instanceOfTrailMapElementOneOf4(json)) {
42
+ return TrailMapElementOneOf4FromJSONTyped(json, true);
43
+ }
44
+ return {};
45
+ }
46
+ export function TrailMapElementToJSON(json) {
47
+ return TrailMapElementToJSONTyped(json, false);
48
+ }
49
+ export function TrailMapElementToJSONTyped(value, ignoreDiscriminator = false) {
50
+ if (value == null) {
51
+ return value;
52
+ }
53
+ if (typeof value !== 'object') {
54
+ return value;
55
+ }
56
+ if (instanceOfTrailMapElementOneOf(value)) {
57
+ return TrailMapElementOneOfToJSON(value);
58
+ }
59
+ if (instanceOfTrailMapElementOneOf1(value)) {
60
+ return TrailMapElementOneOf1ToJSON(value);
61
+ }
62
+ if (instanceOfTrailMapElementOneOf2(value)) {
63
+ return TrailMapElementOneOf2ToJSON(value);
64
+ }
65
+ if (instanceOfTrailMapElementOneOf3(value)) {
66
+ return TrailMapElementOneOf3ToJSON(value);
67
+ }
68
+ if (instanceOfTrailMapElementOneOf4(value)) {
69
+ return TrailMapElementOneOf4ToJSON(value);
70
+ }
71
+ return {};
72
+ }
@@ -0,0 +1,64 @@
1
+ /**
2
+ * MtnManager API
3
+ * The MtnManager API provides real-time access to your ski resort’s public operational data. Use it to display current conditions on your website, mobile app, or digital signage.
4
+ *
5
+ * The version of the OpenAPI document: 1.0.0
6
+ * Contact: support@mtnmanager.com
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
+ import type { Lift } from './Lift';
13
+ /**
14
+ *
15
+ * @export
16
+ * @interface TrailMapElementOneOf
17
+ */
18
+ export interface TrailMapElementOneOf {
19
+ /**
20
+ *
21
+ * @type {TrailMapElementOneOfTypeEnum}
22
+ * @memberof TrailMapElementOneOf
23
+ */
24
+ type: TrailMapElementOneOfTypeEnum;
25
+ /**
26
+ *
27
+ * @type {string}
28
+ * @memberof TrailMapElementOneOf
29
+ */
30
+ uuid: string;
31
+ /**
32
+ *
33
+ * @type {Array<number>}
34
+ * @memberof TrailMapElementOneOf
35
+ */
36
+ points: Array<number>;
37
+ /**
38
+ *
39
+ * @type {number}
40
+ * @memberof TrailMapElementOneOf
41
+ */
42
+ tension?: number | null;
43
+ /**
44
+ *
45
+ * @type {Lift}
46
+ * @memberof TrailMapElementOneOf
47
+ */
48
+ lift?: Lift | null;
49
+ }
50
+ /**
51
+ * @export
52
+ */
53
+ export declare const TrailMapElementOneOfTypeEnum: {
54
+ readonly Lift: "lift";
55
+ };
56
+ export type TrailMapElementOneOfTypeEnum = typeof TrailMapElementOneOfTypeEnum[keyof typeof TrailMapElementOneOfTypeEnum];
57
+ /**
58
+ * Check if a given object implements the TrailMapElementOneOf interface.
59
+ */
60
+ export declare function instanceOfTrailMapElementOneOf(value: object): value is TrailMapElementOneOf;
61
+ export declare function TrailMapElementOneOfFromJSON(json: any): TrailMapElementOneOf;
62
+ export declare function TrailMapElementOneOfFromJSONTyped(json: any, ignoreDiscriminator: boolean): TrailMapElementOneOf;
63
+ export declare function TrailMapElementOneOfToJSON(json: any): TrailMapElementOneOf;
64
+ export declare function TrailMapElementOneOfToJSONTyped(value?: TrailMapElementOneOf | null, ignoreDiscriminator?: boolean): any;
@@ -0,0 +1,64 @@
1
+ /* tslint:disable */
2
+ /* eslint-disable */
3
+ /**
4
+ * MtnManager API
5
+ * The MtnManager API provides real-time access to your ski resort’s public operational data. Use it to display current conditions on your website, mobile app, or digital signage.
6
+ *
7
+ * The version of the OpenAPI document: 1.0.0
8
+ * Contact: support@mtnmanager.com
9
+ *
10
+ * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
11
+ * https://openapi-generator.tech
12
+ * Do not edit the class manually.
13
+ */
14
+ import { LiftFromJSON, LiftToJSON, } from './Lift';
15
+ /**
16
+ * @export
17
+ */
18
+ export const TrailMapElementOneOfTypeEnum = {
19
+ Lift: 'lift'
20
+ };
21
+ /**
22
+ * Check if a given object implements the TrailMapElementOneOf interface.
23
+ */
24
+ export function instanceOfTrailMapElementOneOf(value) {
25
+ if (!('type' in value) || value['type'] === undefined)
26
+ return false;
27
+ if (value['type'] !== 'lift')
28
+ return false;
29
+ if (!('uuid' in value) || value['uuid'] === undefined)
30
+ return false;
31
+ if (!('points' in value) || value['points'] === undefined)
32
+ return false;
33
+ return true;
34
+ }
35
+ export function TrailMapElementOneOfFromJSON(json) {
36
+ return TrailMapElementOneOfFromJSONTyped(json, false);
37
+ }
38
+ export function TrailMapElementOneOfFromJSONTyped(json, ignoreDiscriminator) {
39
+ if (json == null) {
40
+ return json;
41
+ }
42
+ return {
43
+ 'type': json['type'],
44
+ 'uuid': json['uuid'],
45
+ 'points': json['points'],
46
+ 'tension': json['tension'] == null ? undefined : json['tension'],
47
+ 'lift': json['lift'] == null ? undefined : LiftFromJSON(json['lift']),
48
+ };
49
+ }
50
+ export function TrailMapElementOneOfToJSON(json) {
51
+ return TrailMapElementOneOfToJSONTyped(json, false);
52
+ }
53
+ export function TrailMapElementOneOfToJSONTyped(value, ignoreDiscriminator = false) {
54
+ if (value == null) {
55
+ return value;
56
+ }
57
+ return {
58
+ 'type': value['type'],
59
+ 'uuid': value['uuid'],
60
+ 'points': value['points'],
61
+ 'tension': value['tension'],
62
+ 'lift': LiftToJSON(value['lift']),
63
+ };
64
+ }
@@ -0,0 +1,64 @@
1
+ /**
2
+ * MtnManager API
3
+ * The MtnManager API provides real-time access to your ski resort’s public operational data. Use it to display current conditions on your website, mobile app, or digital signage.
4
+ *
5
+ * The version of the OpenAPI document: 1.0.0
6
+ * Contact: support@mtnmanager.com
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
+ import type { Run } from './Run';
13
+ /**
14
+ *
15
+ * @export
16
+ * @interface TrailMapElementOneOf1
17
+ */
18
+ export interface TrailMapElementOneOf1 {
19
+ /**
20
+ *
21
+ * @type {TrailMapElementOneOf1TypeEnum}
22
+ * @memberof TrailMapElementOneOf1
23
+ */
24
+ type: TrailMapElementOneOf1TypeEnum;
25
+ /**
26
+ *
27
+ * @type {string}
28
+ * @memberof TrailMapElementOneOf1
29
+ */
30
+ uuid: string;
31
+ /**
32
+ *
33
+ * @type {Array<number>}
34
+ * @memberof TrailMapElementOneOf1
35
+ */
36
+ points: Array<number>;
37
+ /**
38
+ *
39
+ * @type {number}
40
+ * @memberof TrailMapElementOneOf1
41
+ */
42
+ tension?: number | null;
43
+ /**
44
+ *
45
+ * @type {Run}
46
+ * @memberof TrailMapElementOneOf1
47
+ */
48
+ run?: Run | null;
49
+ }
50
+ /**
51
+ * @export
52
+ */
53
+ export declare const TrailMapElementOneOf1TypeEnum: {
54
+ readonly Run: "run";
55
+ };
56
+ export type TrailMapElementOneOf1TypeEnum = typeof TrailMapElementOneOf1TypeEnum[keyof typeof TrailMapElementOneOf1TypeEnum];
57
+ /**
58
+ * Check if a given object implements the TrailMapElementOneOf1 interface.
59
+ */
60
+ export declare function instanceOfTrailMapElementOneOf1(value: object): value is TrailMapElementOneOf1;
61
+ export declare function TrailMapElementOneOf1FromJSON(json: any): TrailMapElementOneOf1;
62
+ export declare function TrailMapElementOneOf1FromJSONTyped(json: any, ignoreDiscriminator: boolean): TrailMapElementOneOf1;
63
+ export declare function TrailMapElementOneOf1ToJSON(json: any): TrailMapElementOneOf1;
64
+ export declare function TrailMapElementOneOf1ToJSONTyped(value?: TrailMapElementOneOf1 | null, ignoreDiscriminator?: boolean): any;