@digital8/security-registers-backend-ts-sdk 0.0.537 → 0.0.539

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 (30) hide show
  1. package/.openapi-generator/FILES +4 -0
  2. package/README.md +2 -2
  3. package/dist/apis/GeneralApi.d.ts +12 -1
  4. package/dist/apis/GeneralApi.js +55 -0
  5. package/dist/models/AddressResource.d.ts +1 -1
  6. package/dist/models/AddressResource.js +1 -3
  7. package/dist/models/IncidentVideosRecentRequest.d.ts +82 -0
  8. package/dist/models/IncidentVideosRecentRequest.js +71 -0
  9. package/dist/models/PaginatedRecentVideoListResourceResponse.d.ts +40 -0
  10. package/dist/models/PaginatedRecentVideoListResourceResponse.js +57 -0
  11. package/dist/models/RecentVideoListResource.d.ts +69 -0
  12. package/dist/models/RecentVideoListResource.js +71 -0
  13. package/dist/models/RecentVideoListResourceArrayResponse.d.ts +33 -0
  14. package/dist/models/RecentVideoListResourceArrayResponse.js +50 -0
  15. package/dist/models/RegisterListResource.d.ts +2 -2
  16. package/dist/models/RegisterListResource.js +2 -6
  17. package/dist/models/RegisterResource.d.ts +2 -2
  18. package/dist/models/RegisterResource.js +4 -4
  19. package/dist/models/index.d.ts +4 -0
  20. package/dist/models/index.js +4 -0
  21. package/package.json +1 -1
  22. package/src/apis/GeneralApi.ts +50 -0
  23. package/src/models/AddressResource.ts +2 -3
  24. package/src/models/IncidentVideosRecentRequest.ts +132 -0
  25. package/src/models/PaginatedRecentVideoListResourceResponse.ts +90 -0
  26. package/src/models/RecentVideoListResource.ts +125 -0
  27. package/src/models/RecentVideoListResourceArrayResponse.ts +73 -0
  28. package/src/models/RegisterListResource.ts +4 -6
  29. package/src/models/RegisterResource.ts +5 -5
  30. package/src/models/index.ts +4 -0
@@ -64,7 +64,7 @@ export interface RegisterListResource {
64
64
  * @type {string}
65
65
  * @memberof RegisterListResource
66
66
  */
67
- badgeNumber: string;
67
+ badgeNumber?: string | null;
68
68
  /**
69
69
  *
70
70
  * @type {Date}
@@ -154,7 +154,7 @@ export interface RegisterListResource {
154
154
  * @type {number}
155
155
  * @memberof RegisterListResource
156
156
  */
157
- signOffLat: number;
157
+ signOffLat?: number | null;
158
158
  /**
159
159
  *
160
160
  * @type {number}
@@ -43,8 +43,6 @@ function instanceOfRegisterListResource(value) {
43
43
  return false;
44
44
  if (!('signOffStatus' in value) || value['signOffStatus'] === undefined)
45
45
  return false;
46
- if (!('badgeNumber' in value) || value['badgeNumber'] === undefined)
47
- return false;
48
46
  if (!('licenceNumber' in value) || value['licenceNumber'] === undefined)
49
47
  return false;
50
48
  if (!('licenceFirstName' in value) || value['licenceFirstName'] === undefined)
@@ -71,8 +69,6 @@ function instanceOfRegisterListResource(value) {
71
69
  return false;
72
70
  if (!('signOnLong' in value) || value['signOnLong'] === undefined)
73
71
  return false;
74
- if (!('signOffLat' in value) || value['signOffLat'] === undefined)
75
- return false;
76
72
  if (!('hasIncidents' in value) || value['hasIncidents'] === undefined)
77
73
  return false;
78
74
  return true;
@@ -92,7 +88,7 @@ function RegisterListResourceFromJSONTyped(json, ignoreDiscriminator) {
92
88
  'finishDateTime': json['finishDateTime'] == null ? undefined : (new Date(json['finishDateTime'])),
93
89
  'shiftLength': json['shiftLength'],
94
90
  'signOffStatus': json['signOffStatus'],
95
- 'badgeNumber': json['badgeNumber'],
91
+ 'badgeNumber': json['badgeNumber'] == null ? undefined : json['badgeNumber'],
96
92
  'rampReadAt': json['rampReadAt'] == null ? undefined : (new Date(json['rampReadAt'])),
97
93
  'licenceNumber': json['licenceNumber'],
98
94
  'licenceFirstName': json['licenceFirstName'],
@@ -107,7 +103,7 @@ function RegisterListResourceFromJSONTyped(json, ignoreDiscriminator) {
107
103
  'firstAid': json['firstAid'],
108
104
  'signOnLat': json['signOnLat'],
109
105
  'signOnLong': json['signOnLong'],
110
- 'signOffLat': json['signOffLat'],
106
+ 'signOffLat': json['signOffLat'] == null ? undefined : json['signOffLat'],
111
107
  'signOffLong': json['signOffLong'] == null ? undefined : json['signOffLong'],
112
108
  'hasIncidents': json['hasIncidents'],
113
109
  };
@@ -112,7 +112,7 @@ export interface RegisterResource {
112
112
  * @type {number}
113
113
  * @memberof RegisterResource
114
114
  */
115
- signOffLat: number;
115
+ signOffLat?: number | null;
116
116
  /**
117
117
  *
118
118
  * @type {number}
@@ -148,7 +148,7 @@ export interface RegisterResource {
148
148
  * @type {string}
149
149
  * @memberof RegisterResource
150
150
  */
151
- badgeNumber?: string | null;
151
+ badgeNumber: string;
152
152
  /**
153
153
  *
154
154
  * @type {Date}
@@ -59,8 +59,6 @@ function instanceOfRegisterResource(value) {
59
59
  return false;
60
60
  if (!('signOnLong' in value) || value['signOnLong'] === undefined)
61
61
  return false;
62
- if (!('signOffLat' in value) || value['signOffLat'] === undefined)
63
- return false;
64
62
  if (!('signOffLong' in value) || value['signOffLong'] === undefined)
65
63
  return false;
66
64
  if (!('licenceNumber' in value) || value['licenceNumber'] === undefined)
@@ -71,6 +69,8 @@ function instanceOfRegisterResource(value) {
71
69
  return false;
72
70
  if (!('licenceLastName' in value) || value['licenceLastName'] === undefined)
73
71
  return false;
72
+ if (!('badgeNumber' in value) || value['badgeNumber'] === undefined)
73
+ return false;
74
74
  return true;
75
75
  }
76
76
  function RegisterResourceFromJSON(json) {
@@ -96,13 +96,13 @@ function RegisterResourceFromJSONTyped(json, ignoreDiscriminator) {
96
96
  'firstAidImage': json['firstAidImage'],
97
97
  'signOnLat': json['signOnLat'],
98
98
  'signOnLong': json['signOnLong'],
99
- 'signOffLat': json['signOffLat'],
99
+ 'signOffLat': json['signOffLat'] == null ? undefined : json['signOffLat'],
100
100
  'signOffLong': json['signOffLong'],
101
101
  'licenceNumber': json['licenceNumber'],
102
102
  'licenceExpiry': json['licenceExpiry'],
103
103
  'licenceFirstName': json['licenceFirstName'],
104
104
  'licenceLastName': json['licenceLastName'],
105
- 'badgeNumber': json['badgeNumber'] == null ? undefined : json['badgeNumber'],
105
+ 'badgeNumber': json['badgeNumber'],
106
106
  'rampReadAt': json['rampReadAt'] == null ? undefined : (new Date(json['rampReadAt'])),
107
107
  'createdAt': json['createdAt'] == null ? undefined : (new Date(json['createdAt'])),
108
108
  'updatedAt': json['updatedAt'] == null ? undefined : (new Date(json['updatedAt'])),
@@ -47,6 +47,7 @@ export * from './IncidentVideoSignedUrlResource';
47
47
  export * from './IncidentVideoSignedUrlResourceArrayResponse';
48
48
  export * from './IncidentVideoUploadTokenResource';
49
49
  export * from './IncidentVideoUploadTokenResourceArrayResponse';
50
+ export * from './IncidentVideosRecentRequest';
50
51
  export * from './IncidentsApproveRequest';
51
52
  export * from './IncidentsEligibleOwnersRequest';
52
53
  export * from './IncidentsExportCsvBulkRequest';
@@ -94,6 +95,7 @@ export * from './PaginatedIncidentListResourceResponse';
94
95
  export * from './PaginatedLicenceCheckLogResourceResponse';
95
96
  export * from './PaginatedLicenceListResourceResponse';
96
97
  export * from './PaginatedLicenceResourceResponse';
98
+ export * from './PaginatedRecentVideoListResourceResponse';
97
99
  export * from './PaginatedRegisterGroupedByRosterResourceResponse';
98
100
  export * from './PaginatedRegisterListResourceResponse';
99
101
  export * from './PaginatedRegisterResourceResponse';
@@ -106,6 +108,8 @@ export * from './PaginatedVenueResourceResponse';
106
108
  export * from './PagingMetadata';
107
109
  export * from './PdfExportResource';
108
110
  export * from './PdfExportResourceArrayResponse';
111
+ export * from './RecentVideoListResource';
112
+ export * from './RecentVideoListResourceArrayResponse';
109
113
  export * from './RegisterGroupedByRosterResource';
110
114
  export * from './RegisterGroupedByRosterResourceArrayResponse';
111
115
  export * from './RegisterListResource';
@@ -65,6 +65,7 @@ __exportStar(require("./IncidentVideoSignedUrlResource"), exports);
65
65
  __exportStar(require("./IncidentVideoSignedUrlResourceArrayResponse"), exports);
66
66
  __exportStar(require("./IncidentVideoUploadTokenResource"), exports);
67
67
  __exportStar(require("./IncidentVideoUploadTokenResourceArrayResponse"), exports);
68
+ __exportStar(require("./IncidentVideosRecentRequest"), exports);
68
69
  __exportStar(require("./IncidentsApproveRequest"), exports);
69
70
  __exportStar(require("./IncidentsEligibleOwnersRequest"), exports);
70
71
  __exportStar(require("./IncidentsExportCsvBulkRequest"), exports);
@@ -112,6 +113,7 @@ __exportStar(require("./PaginatedIncidentListResourceResponse"), exports);
112
113
  __exportStar(require("./PaginatedLicenceCheckLogResourceResponse"), exports);
113
114
  __exportStar(require("./PaginatedLicenceListResourceResponse"), exports);
114
115
  __exportStar(require("./PaginatedLicenceResourceResponse"), exports);
116
+ __exportStar(require("./PaginatedRecentVideoListResourceResponse"), exports);
115
117
  __exportStar(require("./PaginatedRegisterGroupedByRosterResourceResponse"), exports);
116
118
  __exportStar(require("./PaginatedRegisterListResourceResponse"), exports);
117
119
  __exportStar(require("./PaginatedRegisterResourceResponse"), exports);
@@ -124,6 +126,8 @@ __exportStar(require("./PaginatedVenueResourceResponse"), exports);
124
126
  __exportStar(require("./PagingMetadata"), exports);
125
127
  __exportStar(require("./PdfExportResource"), exports);
126
128
  __exportStar(require("./PdfExportResourceArrayResponse"), exports);
129
+ __exportStar(require("./RecentVideoListResource"), exports);
130
+ __exportStar(require("./RecentVideoListResourceArrayResponse"), exports);
127
131
  __exportStar(require("./RegisterGroupedByRosterResource"), exports);
128
132
  __exportStar(require("./RegisterGroupedByRosterResourceArrayResponse"), exports);
129
133
  __exportStar(require("./RegisterListResource"), exports);
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@digital8/security-registers-backend-ts-sdk",
3
- "version": "0.0.537",
3
+ "version": "0.0.539",
4
4
  "description": "OpenAPI client for @digital8/security-registers-backend-ts-sdk",
5
5
  "author": "OpenAPI-Generator",
6
6
  "repository": {
@@ -33,6 +33,7 @@ import type {
33
33
  IncidentVideoResourceArrayResponse,
34
34
  IncidentVideoSignedUrlResource,
35
35
  IncidentVideoUploadTokenResource,
36
+ IncidentVideosRecentRequest,
36
37
  IncidentsApproveRequest,
37
38
  IncidentsEligibleOwnersRequest,
38
39
  IncidentsExportCsvBulkRequest,
@@ -66,6 +67,7 @@ import type {
66
67
  PaginatedIncidentListResourceResponse,
67
68
  PaginatedLicenceCheckLogResourceResponse,
68
69
  PaginatedLicenceListResourceResponse,
70
+ PaginatedRecentVideoListResourceResponse,
69
71
  PaginatedRegisterGroupedByRosterResourceResponse,
70
72
  PaginatedRosterListResourceResponse,
71
73
  PaginatedRosterWithRegistersResourceResponse,
@@ -161,6 +163,8 @@ import {
161
163
  IncidentVideoSignedUrlResourceToJSON,
162
164
  IncidentVideoUploadTokenResourceFromJSON,
163
165
  IncidentVideoUploadTokenResourceToJSON,
166
+ IncidentVideosRecentRequestFromJSON,
167
+ IncidentVideosRecentRequestToJSON,
164
168
  IncidentsApproveRequestFromJSON,
165
169
  IncidentsApproveRequestToJSON,
166
170
  IncidentsEligibleOwnersRequestFromJSON,
@@ -227,6 +231,8 @@ import {
227
231
  PaginatedLicenceCheckLogResourceResponseToJSON,
228
232
  PaginatedLicenceListResourceResponseFromJSON,
229
233
  PaginatedLicenceListResourceResponseToJSON,
234
+ PaginatedRecentVideoListResourceResponseFromJSON,
235
+ PaginatedRecentVideoListResourceResponseToJSON,
230
236
  PaginatedRegisterGroupedByRosterResourceResponseFromJSON,
231
237
  PaginatedRegisterGroupedByRosterResourceResponseToJSON,
232
238
  PaginatedRosterListResourceResponseFromJSON,
@@ -383,6 +389,10 @@ export interface IncidentFieldSchemasShowOperationRequest {
383
389
  incidentFieldSchemasShowRequest?: IncidentFieldSchemasShowRequest;
384
390
  }
385
391
 
392
+ export interface IncidentVideosRecentOperationRequest {
393
+ incidentVideosRecentRequest?: IncidentVideosRecentRequest;
394
+ }
395
+
386
396
  export interface IncidentsApproveOperationRequest {
387
397
  incident: number;
388
398
  incidentsApproveRequest?: IncidentsApproveRequest;
@@ -1238,6 +1248,46 @@ export class GeneralApi extends runtime.BaseAPI {
1238
1248
  return await response.value();
1239
1249
  }
1240
1250
 
1251
+ /**
1252
+ * Auto-generated: incidentVideos.recent
1253
+ */
1254
+ async incidentVideosRecentRaw(requestParameters: IncidentVideosRecentOperationRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<PaginatedRecentVideoListResourceResponse>> {
1255
+ const queryParameters: any = {};
1256
+
1257
+ const headerParameters: runtime.HTTPHeaders = {};
1258
+
1259
+ headerParameters['Content-Type'] = 'application/json';
1260
+
1261
+ if (this.configuration && this.configuration.accessToken) {
1262
+ const token = this.configuration.accessToken;
1263
+ const tokenString = await token("bearerAuth", []);
1264
+
1265
+ if (tokenString) {
1266
+ headerParameters["Authorization"] = `Bearer ${tokenString}`;
1267
+ }
1268
+ }
1269
+
1270
+ let urlPath = `/api/incident-videos/recent`;
1271
+
1272
+ const response = await this.request({
1273
+ path: urlPath,
1274
+ method: 'POST',
1275
+ headers: headerParameters,
1276
+ query: queryParameters,
1277
+ body: IncidentVideosRecentRequestToJSON(requestParameters['incidentVideosRecentRequest']),
1278
+ }, initOverrides);
1279
+
1280
+ return new runtime.JSONApiResponse(response, (jsonValue) => PaginatedRecentVideoListResourceResponseFromJSON(jsonValue));
1281
+ }
1282
+
1283
+ /**
1284
+ * Auto-generated: incidentVideos.recent
1285
+ */
1286
+ async incidentVideosRecent(requestParameters: IncidentVideosRecentOperationRequest = {}, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<PaginatedRecentVideoListResourceResponse> {
1287
+ const response = await this.incidentVideosRecentRaw(requestParameters, initOverrides);
1288
+ return await response.value();
1289
+ }
1290
+
1241
1291
  /**
1242
1292
  * Auto-generated: incidents.approve
1243
1293
  */
@@ -36,7 +36,7 @@ export interface AddressResource {
36
36
  * @type {string}
37
37
  * @memberof AddressResource
38
38
  */
39
- addressLine2: string;
39
+ addressLine2?: string | null;
40
40
  /**
41
41
  *
42
42
  * @type {string}
@@ -80,7 +80,6 @@ export interface AddressResource {
80
80
  */
81
81
  export function instanceOfAddressResource(value: object): value is AddressResource {
82
82
  if (!('addressLine1' in value) || value['addressLine1'] === undefined) return false;
83
- if (!('addressLine2' in value) || value['addressLine2'] === undefined) return false;
84
83
  if (!('suburb' in value) || value['suburb'] === undefined) return false;
85
84
  if (!('city' in value) || value['city'] === undefined) return false;
86
85
  if (!('state' in value) || value['state'] === undefined) return false;
@@ -102,7 +101,7 @@ export function AddressResourceFromJSONTyped(json: any, ignoreDiscriminator: boo
102
101
 
103
102
  'id': json['id'] == null ? undefined : json['id'],
104
103
  'addressLine1': json['addressLine1'],
105
- 'addressLine2': json['addressLine2'],
104
+ 'addressLine2': json['addressLine2'] == null ? undefined : json['addressLine2'],
106
105
  'suburb': json['suburb'],
107
106
  'city': json['city'],
108
107
  'state': json['state'],
@@ -0,0 +1,132 @@
1
+ /* tslint:disable */
2
+ /* eslint-disable */
3
+ /**
4
+ * My API
5
+ * API documentation for my Laravel app
6
+ *
7
+ * The version of the OpenAPI document: 1.0.0
8
+ *
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
+
15
+ import { mapValues } from '../runtime';
16
+ /**
17
+ *
18
+ * @export
19
+ * @interface IncidentVideosRecentRequest
20
+ */
21
+ export interface IncidentVideosRecentRequest {
22
+ /**
23
+ *
24
+ * @type {string}
25
+ * @memberof IncidentVideosRecentRequest
26
+ */
27
+ search?: string;
28
+ /**
29
+ *
30
+ * @type {string}
31
+ * @memberof IncidentVideosRecentRequest
32
+ */
33
+ sortBy?: string;
34
+ /**
35
+ *
36
+ * @type {string}
37
+ * @memberof IncidentVideosRecentRequest
38
+ */
39
+ sortDirection?: IncidentVideosRecentRequestSortDirectionEnum;
40
+ /**
41
+ *
42
+ * @type {number}
43
+ * @memberof IncidentVideosRecentRequest
44
+ */
45
+ perPage?: number;
46
+ /**
47
+ *
48
+ * @type {string}
49
+ * @memberof IncidentVideosRecentRequest
50
+ */
51
+ page?: string;
52
+ /**
53
+ *
54
+ * @type {number}
55
+ * @memberof IncidentVideosRecentRequest
56
+ */
57
+ relatedId?: number;
58
+ /**
59
+ *
60
+ * @type {string}
61
+ * @memberof IncidentVideosRecentRequest
62
+ */
63
+ relatedType?: string;
64
+ /**
65
+ *
66
+ * @type {boolean}
67
+ * @memberof IncidentVideosRecentRequest
68
+ */
69
+ includesRelations?: boolean;
70
+ }
71
+
72
+
73
+ /**
74
+ * @export
75
+ */
76
+ export const IncidentVideosRecentRequestSortDirectionEnum = {
77
+ Asc: 'asc',
78
+ Desc: 'desc'
79
+ } as const;
80
+ export type IncidentVideosRecentRequestSortDirectionEnum = typeof IncidentVideosRecentRequestSortDirectionEnum[keyof typeof IncidentVideosRecentRequestSortDirectionEnum];
81
+
82
+
83
+ /**
84
+ * Check if a given object implements the IncidentVideosRecentRequest interface.
85
+ */
86
+ export function instanceOfIncidentVideosRecentRequest(value: object): value is IncidentVideosRecentRequest {
87
+ return true;
88
+ }
89
+
90
+ export function IncidentVideosRecentRequestFromJSON(json: any): IncidentVideosRecentRequest {
91
+ return IncidentVideosRecentRequestFromJSONTyped(json, false);
92
+ }
93
+
94
+ export function IncidentVideosRecentRequestFromJSONTyped(json: any, ignoreDiscriminator: boolean): IncidentVideosRecentRequest {
95
+ if (json == null) {
96
+ return json;
97
+ }
98
+ return {
99
+
100
+ 'search': json['search'] == null ? undefined : json['search'],
101
+ 'sortBy': json['sort_by'] == null ? undefined : json['sort_by'],
102
+ 'sortDirection': json['sort_direction'] == null ? undefined : json['sort_direction'],
103
+ 'perPage': json['per_page'] == null ? undefined : json['per_page'],
104
+ 'page': json['page'] == null ? undefined : json['page'],
105
+ 'relatedId': json['related_id'] == null ? undefined : json['related_id'],
106
+ 'relatedType': json['related_type'] == null ? undefined : json['related_type'],
107
+ 'includesRelations': json['includes_relations'] == null ? undefined : json['includes_relations'],
108
+ };
109
+ }
110
+
111
+ export function IncidentVideosRecentRequestToJSON(json: any): IncidentVideosRecentRequest {
112
+ return IncidentVideosRecentRequestToJSONTyped(json, false);
113
+ }
114
+
115
+ export function IncidentVideosRecentRequestToJSONTyped(value?: IncidentVideosRecentRequest | null, ignoreDiscriminator: boolean = false): any {
116
+ if (value == null) {
117
+ return value;
118
+ }
119
+
120
+ return {
121
+
122
+ 'search': value['search'],
123
+ 'sort_by': value['sortBy'],
124
+ 'sort_direction': value['sortDirection'],
125
+ 'per_page': value['perPage'],
126
+ 'page': value['page'],
127
+ 'related_id': value['relatedId'],
128
+ 'related_type': value['relatedType'],
129
+ 'includes_relations': value['includesRelations'],
130
+ };
131
+ }
132
+
@@ -0,0 +1,90 @@
1
+ /* tslint:disable */
2
+ /* eslint-disable */
3
+ /**
4
+ * My API
5
+ * API documentation for my Laravel app
6
+ *
7
+ * The version of the OpenAPI document: 1.0.0
8
+ *
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
+
15
+ import { mapValues } from '../runtime';
16
+ import type { PagingMetadata } from './PagingMetadata';
17
+ import {
18
+ PagingMetadataFromJSON,
19
+ PagingMetadataFromJSONTyped,
20
+ PagingMetadataToJSON,
21
+ PagingMetadataToJSONTyped,
22
+ } from './PagingMetadata';
23
+ import type { RecentVideoListResource } from './RecentVideoListResource';
24
+ import {
25
+ RecentVideoListResourceFromJSON,
26
+ RecentVideoListResourceFromJSONTyped,
27
+ RecentVideoListResourceToJSON,
28
+ RecentVideoListResourceToJSONTyped,
29
+ } from './RecentVideoListResource';
30
+
31
+ /**
32
+ *
33
+ * @export
34
+ * @interface PaginatedRecentVideoListResourceResponse
35
+ */
36
+ export interface PaginatedRecentVideoListResourceResponse {
37
+ /**
38
+ *
39
+ * @type {Array<RecentVideoListResource>}
40
+ * @memberof PaginatedRecentVideoListResourceResponse
41
+ */
42
+ data: Array<RecentVideoListResource>;
43
+ /**
44
+ *
45
+ * @type {PagingMetadata}
46
+ * @memberof PaginatedRecentVideoListResourceResponse
47
+ */
48
+ meta: PagingMetadata;
49
+ }
50
+
51
+ /**
52
+ * Check if a given object implements the PaginatedRecentVideoListResourceResponse interface.
53
+ */
54
+ export function instanceOfPaginatedRecentVideoListResourceResponse(value: object): value is PaginatedRecentVideoListResourceResponse {
55
+ if (!('data' in value) || value['data'] === undefined) return false;
56
+ if (!('meta' in value) || value['meta'] === undefined) return false;
57
+ return true;
58
+ }
59
+
60
+ export function PaginatedRecentVideoListResourceResponseFromJSON(json: any): PaginatedRecentVideoListResourceResponse {
61
+ return PaginatedRecentVideoListResourceResponseFromJSONTyped(json, false);
62
+ }
63
+
64
+ export function PaginatedRecentVideoListResourceResponseFromJSONTyped(json: any, ignoreDiscriminator: boolean): PaginatedRecentVideoListResourceResponse {
65
+ if (json == null) {
66
+ return json;
67
+ }
68
+ return {
69
+
70
+ 'data': ((json['data'] as Array<any>).map(RecentVideoListResourceFromJSON)),
71
+ 'meta': PagingMetadataFromJSON(json['meta']),
72
+ };
73
+ }
74
+
75
+ export function PaginatedRecentVideoListResourceResponseToJSON(json: any): PaginatedRecentVideoListResourceResponse {
76
+ return PaginatedRecentVideoListResourceResponseToJSONTyped(json, false);
77
+ }
78
+
79
+ export function PaginatedRecentVideoListResourceResponseToJSONTyped(value?: PaginatedRecentVideoListResourceResponse | null, ignoreDiscriminator: boolean = false): any {
80
+ if (value == null) {
81
+ return value;
82
+ }
83
+
84
+ return {
85
+
86
+ 'data': ((value['data'] as Array<any>).map(RecentVideoListResourceToJSON)),
87
+ 'meta': PagingMetadataToJSON(value['meta']),
88
+ };
89
+ }
90
+
@@ -0,0 +1,125 @@
1
+ /* tslint:disable */
2
+ /* eslint-disable */
3
+ /**
4
+ * My API
5
+ * API documentation for my Laravel app
6
+ *
7
+ * The version of the OpenAPI document: 1.0.0
8
+ *
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
+
15
+ import { mapValues } from '../runtime';
16
+ import type { VenueLiteResource } from './VenueLiteResource';
17
+ import {
18
+ VenueLiteResourceFromJSON,
19
+ VenueLiteResourceFromJSONTyped,
20
+ VenueLiteResourceToJSON,
21
+ VenueLiteResourceToJSONTyped,
22
+ } from './VenueLiteResource';
23
+
24
+ /**
25
+ *
26
+ * @export
27
+ * @interface RecentVideoListResource
28
+ */
29
+ export interface RecentVideoListResource {
30
+ /**
31
+ *
32
+ * @type {number}
33
+ * @memberof RecentVideoListResource
34
+ */
35
+ id?: number | null;
36
+ /**
37
+ *
38
+ * @type {number}
39
+ * @memberof RecentVideoListResource
40
+ */
41
+ incidentId?: number | null;
42
+ /**
43
+ *
44
+ * @type {VenueLiteResource}
45
+ * @memberof RecentVideoListResource
46
+ */
47
+ venue: VenueLiteResource | null;
48
+ /**
49
+ *
50
+ * @type {string}
51
+ * @memberof RecentVideoListResource
52
+ */
53
+ originalFilename: string;
54
+ /**
55
+ *
56
+ * @type {number}
57
+ * @memberof RecentVideoListResource
58
+ */
59
+ sizeBytes: number;
60
+ /**
61
+ *
62
+ * @type {Date}
63
+ * @memberof RecentVideoListResource
64
+ */
65
+ createdAt?: Date | null;
66
+ /**
67
+ *
68
+ * @type {string}
69
+ * @memberof RecentVideoListResource
70
+ */
71
+ playbackUrl: string;
72
+ }
73
+
74
+ /**
75
+ * Check if a given object implements the RecentVideoListResource interface.
76
+ */
77
+ export function instanceOfRecentVideoListResource(value: object): value is RecentVideoListResource {
78
+ if (!('venue' in value) || value['venue'] === undefined) return false;
79
+ if (!('originalFilename' in value) || value['originalFilename'] === undefined) return false;
80
+ if (!('sizeBytes' in value) || value['sizeBytes'] === undefined) return false;
81
+ if (!('playbackUrl' in value) || value['playbackUrl'] === undefined) return false;
82
+ return true;
83
+ }
84
+
85
+ export function RecentVideoListResourceFromJSON(json: any): RecentVideoListResource {
86
+ return RecentVideoListResourceFromJSONTyped(json, false);
87
+ }
88
+
89
+ export function RecentVideoListResourceFromJSONTyped(json: any, ignoreDiscriminator: boolean): RecentVideoListResource {
90
+ if (json == null) {
91
+ return json;
92
+ }
93
+ return {
94
+
95
+ 'id': json['id'] == null ? undefined : json['id'],
96
+ 'incidentId': json['incidentId'] == null ? undefined : json['incidentId'],
97
+ 'venue': VenueLiteResourceFromJSON(json['venue']),
98
+ 'originalFilename': json['originalFilename'],
99
+ 'sizeBytes': json['sizeBytes'],
100
+ 'createdAt': json['createdAt'] == null ? undefined : (new Date(json['createdAt'])),
101
+ 'playbackUrl': json['playbackUrl'],
102
+ };
103
+ }
104
+
105
+ export function RecentVideoListResourceToJSON(json: any): RecentVideoListResource {
106
+ return RecentVideoListResourceToJSONTyped(json, false);
107
+ }
108
+
109
+ export function RecentVideoListResourceToJSONTyped(value?: RecentVideoListResource | null, ignoreDiscriminator: boolean = false): any {
110
+ if (value == null) {
111
+ return value;
112
+ }
113
+
114
+ return {
115
+
116
+ 'id': value['id'],
117
+ 'incidentId': value['incidentId'],
118
+ 'venue': VenueLiteResourceToJSON(value['venue']),
119
+ 'originalFilename': value['originalFilename'],
120
+ 'sizeBytes': value['sizeBytes'],
121
+ 'createdAt': value['createdAt'] === null ? null : ((value['createdAt'] as any)?.toISOString()),
122
+ 'playbackUrl': value['playbackUrl'],
123
+ };
124
+ }
125
+