@mtnmanager/sdk 1.7.0 → 1.7.1
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/esm/models/FullReport.d.ts +8 -0
- package/dist/esm/models/FullReport.js +3 -0
- package/dist/esm/models/Webcam.d.ts +34 -0
- package/dist/esm/models/Webcam.js +16 -0
- package/dist/esm/models/WebcamHistoryFrame.d.ts +7 -0
- package/dist/esm/models/WebcamHistoryFrame.js +4 -0
- package/dist/models/FullReport.d.ts +8 -0
- package/dist/models/FullReport.js +3 -0
- package/dist/models/Webcam.d.ts +34 -0
- package/dist/models/Webcam.js +16 -0
- package/dist/models/WebcamHistoryFrame.d.ts +7 -0
- package/dist/models/WebcamHistoryFrame.js +4 -0
- package/package.json +1 -1
|
@@ -14,6 +14,7 @@ import type { Weather } from './Weather';
|
|
|
14
14
|
import type { ResortInfo } from './ResortInfo';
|
|
15
15
|
import type { ParkingLot } from './ParkingLot';
|
|
16
16
|
import type { SnowReport } from './SnowReport';
|
|
17
|
+
import type { Webcam } from './Webcam';
|
|
17
18
|
import type { Overview } from './Overview';
|
|
18
19
|
import type { Run } from './Run';
|
|
19
20
|
import type { SummerTrail } from './SummerTrail';
|
|
@@ -95,6 +96,13 @@ export interface FullReport {
|
|
|
95
96
|
* @memberof FullReport
|
|
96
97
|
*/
|
|
97
98
|
weather?: Array<Weather>;
|
|
99
|
+
/**
|
|
100
|
+
* Enabled webcams with the URLs of their current and last-daylight frames
|
|
101
|
+
* plus thumbnails. Empty when the resort does not have webcams.
|
|
102
|
+
* @type {Array<Webcam>}
|
|
103
|
+
* @memberof FullReport
|
|
104
|
+
*/
|
|
105
|
+
webcams?: Array<Webcam>;
|
|
98
106
|
}
|
|
99
107
|
/**
|
|
100
108
|
* Check if a given object implements the FullReport interface.
|
|
@@ -16,6 +16,7 @@ import { WeatherFromJSON, WeatherToJSON, } from './Weather';
|
|
|
16
16
|
import { ResortInfoFromJSON, ResortInfoToJSON, } from './ResortInfo';
|
|
17
17
|
import { ParkingLotFromJSON, ParkingLotToJSON, } from './ParkingLot';
|
|
18
18
|
import { SnowReportFromJSON, SnowReportToJSON, } from './SnowReport';
|
|
19
|
+
import { WebcamFromJSON, WebcamToJSON, } from './Webcam';
|
|
19
20
|
import { OverviewFromJSON, OverviewToJSON, } from './Overview';
|
|
20
21
|
import { RunFromJSON, RunToJSON, } from './Run';
|
|
21
22
|
import { SummerTrailFromJSON, SummerTrailToJSON, } from './SummerTrail';
|
|
@@ -63,6 +64,7 @@ export function FullReportFromJSONTyped(json, ignoreDiscriminator) {
|
|
|
63
64
|
'summerTrails': (json['summer_trails'].map(SummerTrailFromJSON)),
|
|
64
65
|
'hours': OperatingHoursFromJSON(json['hours']),
|
|
65
66
|
'weather': json['weather'] == null ? undefined : (json['weather'].map(WeatherFromJSON)),
|
|
67
|
+
'webcams': json['webcams'] == null ? undefined : (json['webcams'].map(WebcamFromJSON)),
|
|
66
68
|
};
|
|
67
69
|
}
|
|
68
70
|
export function FullReportToJSON(json) {
|
|
@@ -83,5 +85,6 @@ export function FullReportToJSONTyped(value, ignoreDiscriminator = false) {
|
|
|
83
85
|
'summer_trails': (value['summerTrails'].map(SummerTrailToJSON)),
|
|
84
86
|
'hours': OperatingHoursToJSON(value['hours']),
|
|
85
87
|
'weather': value['weather'] == null ? undefined : (value['weather'].map(WeatherToJSON)),
|
|
88
|
+
'webcams': value['webcams'] == null ? undefined : (value['webcams'].map(WebcamToJSON)),
|
|
86
89
|
};
|
|
87
90
|
}
|
|
@@ -71,6 +71,40 @@ export interface Webcam {
|
|
|
71
71
|
* @memberof Webcam
|
|
72
72
|
*/
|
|
73
73
|
latestDaylightThumbUrl: string;
|
|
74
|
+
/**
|
|
75
|
+
* ThumbHash of the `latest` frame (standard base64) — a compact blur
|
|
76
|
+
* placeholder to render while the image loads. Empty string until the first
|
|
77
|
+
* frame (or on cameras predating the feature).
|
|
78
|
+
* @type {string}
|
|
79
|
+
* @memberof Webcam
|
|
80
|
+
*/
|
|
81
|
+
latestThumbhash: string;
|
|
82
|
+
/**
|
|
83
|
+
* ThumbHash of the `latest-daylight` frame (standard base64). Empty string
|
|
84
|
+
* until the first daylight frame.
|
|
85
|
+
* @type {string}
|
|
86
|
+
* @memberof Webcam
|
|
87
|
+
*/
|
|
88
|
+
latestDaylightThumbhash: string;
|
|
89
|
+
/**
|
|
90
|
+
* Whether this camera archives frames — i.e. whether its history endpoint
|
|
91
|
+
* returns anything. When `false`, don't call the history API for it.
|
|
92
|
+
* @type {boolean}
|
|
93
|
+
* @memberof Webcam
|
|
94
|
+
*/
|
|
95
|
+
hasHistory: boolean;
|
|
96
|
+
/**
|
|
97
|
+
* Camera elevation in both units; omitted when unset.
|
|
98
|
+
* @type {number}
|
|
99
|
+
* @memberof Webcam
|
|
100
|
+
*/
|
|
101
|
+
elevationFt?: number | null;
|
|
102
|
+
/**
|
|
103
|
+
*
|
|
104
|
+
* @type {number}
|
|
105
|
+
* @memberof Webcam
|
|
106
|
+
*/
|
|
107
|
+
elevationM?: number | null;
|
|
74
108
|
/**
|
|
75
109
|
* Time of the most recently published frame; omitted until the first frame.
|
|
76
110
|
* @type {string}
|
|
@@ -27,6 +27,12 @@ export function instanceOfWebcam(value) {
|
|
|
27
27
|
return false;
|
|
28
28
|
if ((!('latestDaylightThumbUrl' in value) && !('latest_daylight_thumb_url' in value)) || (value['latestDaylightThumbUrl'] === undefined && value['latest_daylight_thumb_url'] === undefined))
|
|
29
29
|
return false;
|
|
30
|
+
if ((!('latestThumbhash' in value) && !('latest_thumbhash' in value)) || (value['latestThumbhash'] === undefined && value['latest_thumbhash'] === undefined))
|
|
31
|
+
return false;
|
|
32
|
+
if ((!('latestDaylightThumbhash' in value) && !('latest_daylight_thumbhash' in value)) || (value['latestDaylightThumbhash'] === undefined && value['latest_daylight_thumbhash'] === undefined))
|
|
33
|
+
return false;
|
|
34
|
+
if ((!('hasHistory' in value) && !('has_history' in value)) || (value['hasHistory'] === undefined && value['has_history'] === undefined))
|
|
35
|
+
return false;
|
|
30
36
|
return true;
|
|
31
37
|
}
|
|
32
38
|
export function WebcamFromJSON(json) {
|
|
@@ -46,6 +52,11 @@ export function WebcamFromJSONTyped(json, ignoreDiscriminator) {
|
|
|
46
52
|
'latestDaylightImageUrl': json['latest_daylight_image_url'],
|
|
47
53
|
'latestThumbUrl': json['latest_thumb_url'],
|
|
48
54
|
'latestDaylightThumbUrl': json['latest_daylight_thumb_url'],
|
|
55
|
+
'latestThumbhash': json['latest_thumbhash'],
|
|
56
|
+
'latestDaylightThumbhash': json['latest_daylight_thumbhash'],
|
|
57
|
+
'hasHistory': json['has_history'],
|
|
58
|
+
'elevationFt': json['elevation_ft'] == null ? undefined : json['elevation_ft'],
|
|
59
|
+
'elevationM': json['elevation_m'] == null ? undefined : json['elevation_m'],
|
|
49
60
|
'lastFrameAt': json['last_frame_at'] == null ? undefined : json['last_frame_at'],
|
|
50
61
|
};
|
|
51
62
|
}
|
|
@@ -66,6 +77,11 @@ export function WebcamToJSONTyped(value, ignoreDiscriminator = false) {
|
|
|
66
77
|
'latest_daylight_image_url': value['latestDaylightImageUrl'],
|
|
67
78
|
'latest_thumb_url': value['latestThumbUrl'],
|
|
68
79
|
'latest_daylight_thumb_url': value['latestDaylightThumbUrl'],
|
|
80
|
+
'latest_thumbhash': value['latestThumbhash'],
|
|
81
|
+
'latest_daylight_thumbhash': value['latestDaylightThumbhash'],
|
|
82
|
+
'has_history': value['hasHistory'],
|
|
83
|
+
'elevation_ft': value['elevationFt'],
|
|
84
|
+
'elevation_m': value['elevationM'],
|
|
69
85
|
'last_frame_at': value['lastFrameAt'],
|
|
70
86
|
};
|
|
71
87
|
}
|
|
@@ -33,6 +33,13 @@ export interface WebcamHistoryFrame {
|
|
|
33
33
|
* @memberof WebcamHistoryFrame
|
|
34
34
|
*/
|
|
35
35
|
thumbUrl: string;
|
|
36
|
+
/**
|
|
37
|
+
* ThumbHash of the frame (standard base64), recovered from the thumb object's
|
|
38
|
+
* key. Empty string for legacy frames archived without one.
|
|
39
|
+
* @type {string}
|
|
40
|
+
* @memberof WebcamHistoryFrame
|
|
41
|
+
*/
|
|
42
|
+
thumbhash: string;
|
|
36
43
|
}
|
|
37
44
|
/**
|
|
38
45
|
* Check if a given object implements the WebcamHistoryFrame interface.
|
|
@@ -21,6 +21,8 @@ export function instanceOfWebcamHistoryFrame(value) {
|
|
|
21
21
|
return false;
|
|
22
22
|
if ((!('thumbUrl' in value) && !('thumb_url' in value)) || (value['thumbUrl'] === undefined && value['thumb_url'] === undefined))
|
|
23
23
|
return false;
|
|
24
|
+
if (!('thumbhash' in value) || value['thumbhash'] === undefined)
|
|
25
|
+
return false;
|
|
24
26
|
return true;
|
|
25
27
|
}
|
|
26
28
|
export function WebcamHistoryFrameFromJSON(json) {
|
|
@@ -34,6 +36,7 @@ export function WebcamHistoryFrameFromJSONTyped(json, ignoreDiscriminator) {
|
|
|
34
36
|
'capturedAt': json['captured_at'],
|
|
35
37
|
'imageUrl': json['image_url'],
|
|
36
38
|
'thumbUrl': json['thumb_url'],
|
|
39
|
+
'thumbhash': json['thumbhash'],
|
|
37
40
|
};
|
|
38
41
|
}
|
|
39
42
|
export function WebcamHistoryFrameToJSON(json) {
|
|
@@ -47,5 +50,6 @@ export function WebcamHistoryFrameToJSONTyped(value, ignoreDiscriminator = false
|
|
|
47
50
|
'captured_at': value['capturedAt'],
|
|
48
51
|
'image_url': value['imageUrl'],
|
|
49
52
|
'thumb_url': value['thumbUrl'],
|
|
53
|
+
'thumbhash': value['thumbhash'],
|
|
50
54
|
};
|
|
51
55
|
}
|
|
@@ -14,6 +14,7 @@ import type { Weather } from './Weather';
|
|
|
14
14
|
import type { ResortInfo } from './ResortInfo';
|
|
15
15
|
import type { ParkingLot } from './ParkingLot';
|
|
16
16
|
import type { SnowReport } from './SnowReport';
|
|
17
|
+
import type { Webcam } from './Webcam';
|
|
17
18
|
import type { Overview } from './Overview';
|
|
18
19
|
import type { Run } from './Run';
|
|
19
20
|
import type { SummerTrail } from './SummerTrail';
|
|
@@ -95,6 +96,13 @@ export interface FullReport {
|
|
|
95
96
|
* @memberof FullReport
|
|
96
97
|
*/
|
|
97
98
|
weather?: Array<Weather>;
|
|
99
|
+
/**
|
|
100
|
+
* Enabled webcams with the URLs of their current and last-daylight frames
|
|
101
|
+
* plus thumbnails. Empty when the resort does not have webcams.
|
|
102
|
+
* @type {Array<Webcam>}
|
|
103
|
+
* @memberof FullReport
|
|
104
|
+
*/
|
|
105
|
+
webcams?: Array<Webcam>;
|
|
98
106
|
}
|
|
99
107
|
/**
|
|
100
108
|
* Check if a given object implements the FullReport interface.
|
|
@@ -23,6 +23,7 @@ const Weather_1 = require("./Weather");
|
|
|
23
23
|
const ResortInfo_1 = require("./ResortInfo");
|
|
24
24
|
const ParkingLot_1 = require("./ParkingLot");
|
|
25
25
|
const SnowReport_1 = require("./SnowReport");
|
|
26
|
+
const Webcam_1 = require("./Webcam");
|
|
26
27
|
const Overview_1 = require("./Overview");
|
|
27
28
|
const Run_1 = require("./Run");
|
|
28
29
|
const SummerTrail_1 = require("./SummerTrail");
|
|
@@ -70,6 +71,7 @@ function FullReportFromJSONTyped(json, ignoreDiscriminator) {
|
|
|
70
71
|
'summerTrails': (json['summer_trails'].map(SummerTrail_1.SummerTrailFromJSON)),
|
|
71
72
|
'hours': (0, OperatingHours_1.OperatingHoursFromJSON)(json['hours']),
|
|
72
73
|
'weather': json['weather'] == null ? undefined : (json['weather'].map(Weather_1.WeatherFromJSON)),
|
|
74
|
+
'webcams': json['webcams'] == null ? undefined : (json['webcams'].map(Webcam_1.WebcamFromJSON)),
|
|
73
75
|
};
|
|
74
76
|
}
|
|
75
77
|
function FullReportToJSON(json) {
|
|
@@ -90,5 +92,6 @@ function FullReportToJSONTyped(value, ignoreDiscriminator = false) {
|
|
|
90
92
|
'summer_trails': (value['summerTrails'].map(SummerTrail_1.SummerTrailToJSON)),
|
|
91
93
|
'hours': (0, OperatingHours_1.OperatingHoursToJSON)(value['hours']),
|
|
92
94
|
'weather': value['weather'] == null ? undefined : (value['weather'].map(Weather_1.WeatherToJSON)),
|
|
95
|
+
'webcams': value['webcams'] == null ? undefined : (value['webcams'].map(Webcam_1.WebcamToJSON)),
|
|
93
96
|
};
|
|
94
97
|
}
|
package/dist/models/Webcam.d.ts
CHANGED
|
@@ -71,6 +71,40 @@ export interface Webcam {
|
|
|
71
71
|
* @memberof Webcam
|
|
72
72
|
*/
|
|
73
73
|
latestDaylightThumbUrl: string;
|
|
74
|
+
/**
|
|
75
|
+
* ThumbHash of the `latest` frame (standard base64) — a compact blur
|
|
76
|
+
* placeholder to render while the image loads. Empty string until the first
|
|
77
|
+
* frame (or on cameras predating the feature).
|
|
78
|
+
* @type {string}
|
|
79
|
+
* @memberof Webcam
|
|
80
|
+
*/
|
|
81
|
+
latestThumbhash: string;
|
|
82
|
+
/**
|
|
83
|
+
* ThumbHash of the `latest-daylight` frame (standard base64). Empty string
|
|
84
|
+
* until the first daylight frame.
|
|
85
|
+
* @type {string}
|
|
86
|
+
* @memberof Webcam
|
|
87
|
+
*/
|
|
88
|
+
latestDaylightThumbhash: string;
|
|
89
|
+
/**
|
|
90
|
+
* Whether this camera archives frames — i.e. whether its history endpoint
|
|
91
|
+
* returns anything. When `false`, don't call the history API for it.
|
|
92
|
+
* @type {boolean}
|
|
93
|
+
* @memberof Webcam
|
|
94
|
+
*/
|
|
95
|
+
hasHistory: boolean;
|
|
96
|
+
/**
|
|
97
|
+
* Camera elevation in both units; omitted when unset.
|
|
98
|
+
* @type {number}
|
|
99
|
+
* @memberof Webcam
|
|
100
|
+
*/
|
|
101
|
+
elevationFt?: number | null;
|
|
102
|
+
/**
|
|
103
|
+
*
|
|
104
|
+
* @type {number}
|
|
105
|
+
* @memberof Webcam
|
|
106
|
+
*/
|
|
107
|
+
elevationM?: number | null;
|
|
74
108
|
/**
|
|
75
109
|
* Time of the most recently published frame; omitted until the first frame.
|
|
76
110
|
* @type {string}
|
package/dist/models/Webcam.js
CHANGED
|
@@ -34,6 +34,12 @@ function instanceOfWebcam(value) {
|
|
|
34
34
|
return false;
|
|
35
35
|
if ((!('latestDaylightThumbUrl' in value) && !('latest_daylight_thumb_url' in value)) || (value['latestDaylightThumbUrl'] === undefined && value['latest_daylight_thumb_url'] === undefined))
|
|
36
36
|
return false;
|
|
37
|
+
if ((!('latestThumbhash' in value) && !('latest_thumbhash' in value)) || (value['latestThumbhash'] === undefined && value['latest_thumbhash'] === undefined))
|
|
38
|
+
return false;
|
|
39
|
+
if ((!('latestDaylightThumbhash' in value) && !('latest_daylight_thumbhash' in value)) || (value['latestDaylightThumbhash'] === undefined && value['latest_daylight_thumbhash'] === undefined))
|
|
40
|
+
return false;
|
|
41
|
+
if ((!('hasHistory' in value) && !('has_history' in value)) || (value['hasHistory'] === undefined && value['has_history'] === undefined))
|
|
42
|
+
return false;
|
|
37
43
|
return true;
|
|
38
44
|
}
|
|
39
45
|
function WebcamFromJSON(json) {
|
|
@@ -53,6 +59,11 @@ function WebcamFromJSONTyped(json, ignoreDiscriminator) {
|
|
|
53
59
|
'latestDaylightImageUrl': json['latest_daylight_image_url'],
|
|
54
60
|
'latestThumbUrl': json['latest_thumb_url'],
|
|
55
61
|
'latestDaylightThumbUrl': json['latest_daylight_thumb_url'],
|
|
62
|
+
'latestThumbhash': json['latest_thumbhash'],
|
|
63
|
+
'latestDaylightThumbhash': json['latest_daylight_thumbhash'],
|
|
64
|
+
'hasHistory': json['has_history'],
|
|
65
|
+
'elevationFt': json['elevation_ft'] == null ? undefined : json['elevation_ft'],
|
|
66
|
+
'elevationM': json['elevation_m'] == null ? undefined : json['elevation_m'],
|
|
56
67
|
'lastFrameAt': json['last_frame_at'] == null ? undefined : json['last_frame_at'],
|
|
57
68
|
};
|
|
58
69
|
}
|
|
@@ -73,6 +84,11 @@ function WebcamToJSONTyped(value, ignoreDiscriminator = false) {
|
|
|
73
84
|
'latest_daylight_image_url': value['latestDaylightImageUrl'],
|
|
74
85
|
'latest_thumb_url': value['latestThumbUrl'],
|
|
75
86
|
'latest_daylight_thumb_url': value['latestDaylightThumbUrl'],
|
|
87
|
+
'latest_thumbhash': value['latestThumbhash'],
|
|
88
|
+
'latest_daylight_thumbhash': value['latestDaylightThumbhash'],
|
|
89
|
+
'has_history': value['hasHistory'],
|
|
90
|
+
'elevation_ft': value['elevationFt'],
|
|
91
|
+
'elevation_m': value['elevationM'],
|
|
76
92
|
'last_frame_at': value['lastFrameAt'],
|
|
77
93
|
};
|
|
78
94
|
}
|
|
@@ -33,6 +33,13 @@ export interface WebcamHistoryFrame {
|
|
|
33
33
|
* @memberof WebcamHistoryFrame
|
|
34
34
|
*/
|
|
35
35
|
thumbUrl: string;
|
|
36
|
+
/**
|
|
37
|
+
* ThumbHash of the frame (standard base64), recovered from the thumb object's
|
|
38
|
+
* key. Empty string for legacy frames archived without one.
|
|
39
|
+
* @type {string}
|
|
40
|
+
* @memberof WebcamHistoryFrame
|
|
41
|
+
*/
|
|
42
|
+
thumbhash: string;
|
|
36
43
|
}
|
|
37
44
|
/**
|
|
38
45
|
* Check if a given object implements the WebcamHistoryFrame interface.
|
|
@@ -28,6 +28,8 @@ function instanceOfWebcamHistoryFrame(value) {
|
|
|
28
28
|
return false;
|
|
29
29
|
if ((!('thumbUrl' in value) && !('thumb_url' in value)) || (value['thumbUrl'] === undefined && value['thumb_url'] === undefined))
|
|
30
30
|
return false;
|
|
31
|
+
if (!('thumbhash' in value) || value['thumbhash'] === undefined)
|
|
32
|
+
return false;
|
|
31
33
|
return true;
|
|
32
34
|
}
|
|
33
35
|
function WebcamHistoryFrameFromJSON(json) {
|
|
@@ -41,6 +43,7 @@ function WebcamHistoryFrameFromJSONTyped(json, ignoreDiscriminator) {
|
|
|
41
43
|
'capturedAt': json['captured_at'],
|
|
42
44
|
'imageUrl': json['image_url'],
|
|
43
45
|
'thumbUrl': json['thumb_url'],
|
|
46
|
+
'thumbhash': json['thumbhash'],
|
|
44
47
|
};
|
|
45
48
|
}
|
|
46
49
|
function WebcamHistoryFrameToJSON(json) {
|
|
@@ -54,5 +57,6 @@ function WebcamHistoryFrameToJSONTyped(value, ignoreDiscriminator = false) {
|
|
|
54
57
|
'captured_at': value['capturedAt'],
|
|
55
58
|
'image_url': value['imageUrl'],
|
|
56
59
|
'thumb_url': value['thumbUrl'],
|
|
60
|
+
'thumbhash': value['thumbhash'],
|
|
57
61
|
};
|
|
58
62
|
}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@mtnmanager/sdk",
|
|
3
|
-
"version": "1.7.
|
|
3
|
+
"version": "1.7.1",
|
|
4
4
|
"description": "SDK for interacting with the MtnManager API, providing real-time access to your ski resort's public operational data.",
|
|
5
5
|
"author": "OpenAPI-Generator",
|
|
6
6
|
"main": "./dist/index.js",
|