@epilot/metering-client 0.1.31 → 0.2.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/CHANGELOG.md +5 -0
- package/package.json +5 -5
- package/src/openapi.d.ts +0 -859
package/CHANGELOG.md
ADDED
|
@@ -0,0 +1,5 @@
|
|
|
1
|
+
# Changelog
|
|
2
|
+
|
|
3
|
+
All notable changes to this project will be documented in this file. See [standard-version](https://github.com/conventional-changelog/standard-version) for commit guidelines.
|
|
4
|
+
|
|
5
|
+
### [0.1.1](https://github.com/epilot-dev/sdk-js/compare/v1.0.0...v0.1.1) (2022-03-09)
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@epilot/metering-client",
|
|
3
|
-
"version": "0.1
|
|
3
|
+
"version": "0.2.1",
|
|
4
4
|
"description": "API Client for epilot Metering API",
|
|
5
5
|
"main": "dist/index.js",
|
|
6
6
|
"types": "dist/index.d.ts",
|
|
@@ -34,23 +34,23 @@
|
|
|
34
34
|
"author": "epilot GmbH",
|
|
35
35
|
"license": "UNLICENSED",
|
|
36
36
|
"peerDependencies": {
|
|
37
|
-
"axios": "^0.
|
|
37
|
+
"axios": "^0.25.0"
|
|
38
38
|
},
|
|
39
39
|
"dependencies": {
|
|
40
40
|
"buffer": "^6.0.3",
|
|
41
41
|
"https-browserify": "^1.0.0",
|
|
42
|
-
"openapi-client-axios": "^
|
|
42
|
+
"openapi-client-axios": "^6.0.0",
|
|
43
43
|
"stream-http": "^3.1.1",
|
|
44
44
|
"url": "^0.11.0",
|
|
45
45
|
"util": "^0.12.3"
|
|
46
46
|
},
|
|
47
47
|
"devDependencies": {
|
|
48
48
|
"@types/jest": "^26.0.20",
|
|
49
|
-
"axios": "^0.
|
|
49
|
+
"axios": "^0.25.0",
|
|
50
50
|
"copy-webpack-plugin": "^7.0.0",
|
|
51
51
|
"jest": "^26.6.3",
|
|
52
52
|
"json-loader": "^0.5.7",
|
|
53
|
-
"openapi-client-axios-typegen": "^
|
|
53
|
+
"openapi-client-axios-typegen": "^6.0.0",
|
|
54
54
|
"openapicmd": "^1.8.2",
|
|
55
55
|
"ts-jest": "^26.5.6",
|
|
56
56
|
"ts-loader": "^8.3.0",
|
package/src/openapi.d.ts
DELETED
|
@@ -1,859 +0,0 @@
|
|
|
1
|
-
/* eslint-disable */
|
|
2
|
-
import type {
|
|
3
|
-
OpenAPIClient,
|
|
4
|
-
Parameters,
|
|
5
|
-
UnknownParamsObject,
|
|
6
|
-
OperationResponse,
|
|
7
|
-
AxiosRequestConfig,
|
|
8
|
-
} from 'openapi-client-axios';
|
|
9
|
-
|
|
10
|
-
declare namespace Components {
|
|
11
|
-
namespace Schemas {
|
|
12
|
-
/**
|
|
13
|
-
* example:
|
|
14
|
-
* {
|
|
15
|
-
* "_id": "3fa85f64-5717-4562-b3fc-2c963f66afa6",
|
|
16
|
-
* "_org": "123",
|
|
17
|
-
* "_schema": "contact",
|
|
18
|
-
* "_tags": [
|
|
19
|
-
* "example",
|
|
20
|
-
* "mock"
|
|
21
|
-
* ],
|
|
22
|
-
* "_created_at": "2021-02-09T12:41:43.662Z",
|
|
23
|
-
* "_updated_at": "2021-02-09T12:41:43.662Z"
|
|
24
|
-
* }
|
|
25
|
-
*/
|
|
26
|
-
export interface BaseEntity {
|
|
27
|
-
_id: EntityId /* uuid */;
|
|
28
|
-
/**
|
|
29
|
-
* Title of entity
|
|
30
|
-
*/
|
|
31
|
-
_title: string;
|
|
32
|
-
/**
|
|
33
|
-
* Organization Id the entity belongs to
|
|
34
|
-
*/
|
|
35
|
-
_org: string;
|
|
36
|
-
_schema: /**
|
|
37
|
-
* URL-friendly identifier for the entity schema
|
|
38
|
-
* example:
|
|
39
|
-
* contact
|
|
40
|
-
*/
|
|
41
|
-
EntitySlug;
|
|
42
|
-
_tags?: string[];
|
|
43
|
-
_created_at: string; // date-time
|
|
44
|
-
_updated_at: string; // date-time
|
|
45
|
-
}
|
|
46
|
-
export type Direction = "feed-in" | "feed-out";
|
|
47
|
-
export type EntityId = string; // uuid
|
|
48
|
-
export interface EntityRelation {
|
|
49
|
-
/**
|
|
50
|
-
* example:
|
|
51
|
-
* 9a2081a2-1615-44b8-b988-d757983290dd
|
|
52
|
-
*/
|
|
53
|
-
entity_id?: string;
|
|
54
|
-
_slug?: "contact" | "contract";
|
|
55
|
-
}
|
|
56
|
-
/**
|
|
57
|
-
* URL-friendly identifier for the entity schema
|
|
58
|
-
* example:
|
|
59
|
-
* contact
|
|
60
|
-
*/
|
|
61
|
-
export type EntitySlug = string;
|
|
62
|
-
export type Id = string;
|
|
63
|
-
/**
|
|
64
|
-
* example:
|
|
65
|
-
* {
|
|
66
|
-
* "_id": "3fa85f64-5717-4562-b3fc-2c963f66afa6",
|
|
67
|
-
* "_org": "123",
|
|
68
|
-
* "_schema": "contact",
|
|
69
|
-
* "_tags": [
|
|
70
|
-
* "example",
|
|
71
|
-
* "mock"
|
|
72
|
-
* ],
|
|
73
|
-
* "_created_at": {},
|
|
74
|
-
* "_updated_at": {}
|
|
75
|
-
* }
|
|
76
|
-
*/
|
|
77
|
-
export interface Meter {
|
|
78
|
-
_id: EntityId /* uuid */;
|
|
79
|
-
/**
|
|
80
|
-
* Title of entity
|
|
81
|
-
*/
|
|
82
|
-
_title: string;
|
|
83
|
-
/**
|
|
84
|
-
* Organization Id the entity belongs to
|
|
85
|
-
*/
|
|
86
|
-
_org: string;
|
|
87
|
-
_schema: /**
|
|
88
|
-
* URL-friendly identifier for the entity schema
|
|
89
|
-
* example:
|
|
90
|
-
* contact
|
|
91
|
-
*/
|
|
92
|
-
EntitySlug;
|
|
93
|
-
_tags?: string[];
|
|
94
|
-
_created_at: string; // date-time
|
|
95
|
-
_updated_at: string; // date-time
|
|
96
|
-
/**
|
|
97
|
-
* example:
|
|
98
|
-
* A09-123
|
|
99
|
-
*/
|
|
100
|
-
ma_lo_id?: string;
|
|
101
|
-
meter_type?: "three-phase-meter" | "bellow-gas-meter" | "rotary-piston-meter" | "smart-meter" | "performance-meter" | "maximum-meter" | "turbine-gas-meter" | "ultrasonic-gas-meter" | "alternating-current-meter" | "modern-metering-system" | "intelligent-measuring-system" | "electronic-meter";
|
|
102
|
-
/**
|
|
103
|
-
* example:
|
|
104
|
-
* Peak load tariff
|
|
105
|
-
*/
|
|
106
|
-
tariff_type?: string;
|
|
107
|
-
/**
|
|
108
|
-
* example:
|
|
109
|
-
* J-1093-1AK
|
|
110
|
-
*/
|
|
111
|
-
meter_number?: string;
|
|
112
|
-
sector?: "power" | "water" | "gas";
|
|
113
|
-
/**
|
|
114
|
-
* example:
|
|
115
|
-
* [
|
|
116
|
-
* {
|
|
117
|
-
* "country": "Germany",
|
|
118
|
-
* "city": "Koln",
|
|
119
|
-
* "postal_code": 81475,
|
|
120
|
-
* "street": "Melatengürtel",
|
|
121
|
-
* "street_number": 71,
|
|
122
|
-
* "additional_info": "5. Etage",
|
|
123
|
-
* "_tags": [
|
|
124
|
-
* "billing",
|
|
125
|
-
* "delivery"
|
|
126
|
-
* ]
|
|
127
|
-
* }
|
|
128
|
-
* ]
|
|
129
|
-
*/
|
|
130
|
-
location?: {
|
|
131
|
-
[key: string]: any;
|
|
132
|
-
};
|
|
133
|
-
/**
|
|
134
|
-
* example:
|
|
135
|
-
* Domestic Usage
|
|
136
|
-
*/
|
|
137
|
-
used_for?: string;
|
|
138
|
-
/**
|
|
139
|
-
* example:
|
|
140
|
-
* Energy One
|
|
141
|
-
*/
|
|
142
|
-
manufacturer?: string;
|
|
143
|
-
/**
|
|
144
|
-
* example:
|
|
145
|
-
* {}
|
|
146
|
-
*/
|
|
147
|
-
calibration_date?: string;
|
|
148
|
-
contract?: {
|
|
149
|
-
$relation?: EntityRelation[];
|
|
150
|
-
};
|
|
151
|
-
customer?: {
|
|
152
|
-
$relation?: EntityRelation[];
|
|
153
|
-
};
|
|
154
|
-
}
|
|
155
|
-
/**
|
|
156
|
-
* example:
|
|
157
|
-
* {
|
|
158
|
-
* "_id": "3fa85f64-5717-4562-b3fc-2c963f66afa6",
|
|
159
|
-
* "_org": "123",
|
|
160
|
-
* "_schema": "contact",
|
|
161
|
-
* "_tags": [
|
|
162
|
-
* "example",
|
|
163
|
-
* "mock"
|
|
164
|
-
* ],
|
|
165
|
-
* "_created_at": {},
|
|
166
|
-
* "_updated_at": {}
|
|
167
|
-
* }
|
|
168
|
-
*/
|
|
169
|
-
export interface MeterCounter {
|
|
170
|
-
_id: EntityId /* uuid */;
|
|
171
|
-
/**
|
|
172
|
-
* Title of entity
|
|
173
|
-
*/
|
|
174
|
-
_title: string;
|
|
175
|
-
/**
|
|
176
|
-
* Organization Id the entity belongs to
|
|
177
|
-
*/
|
|
178
|
-
_org: string;
|
|
179
|
-
_schema: /**
|
|
180
|
-
* URL-friendly identifier for the entity schema
|
|
181
|
-
* example:
|
|
182
|
-
* contact
|
|
183
|
-
*/
|
|
184
|
-
EntitySlug;
|
|
185
|
-
_tags?: string[];
|
|
186
|
-
_created_at: string; // date-time
|
|
187
|
-
_updated_at: string; // date-time
|
|
188
|
-
/**
|
|
189
|
-
* example:
|
|
190
|
-
* A-34
|
|
191
|
-
*/
|
|
192
|
-
obis_number?: string;
|
|
193
|
-
direction?: Direction;
|
|
194
|
-
/**
|
|
195
|
-
* example:
|
|
196
|
-
* 70
|
|
197
|
-
*/
|
|
198
|
-
transformer_ratio?: number;
|
|
199
|
-
unit?: Unit;
|
|
200
|
-
/**
|
|
201
|
-
* example:
|
|
202
|
-
* 270
|
|
203
|
-
*/
|
|
204
|
-
forecast_reading_value?: string;
|
|
205
|
-
/**
|
|
206
|
-
* example:
|
|
207
|
-
* {}
|
|
208
|
-
*/
|
|
209
|
-
forecast_as_of?: string;
|
|
210
|
-
/**
|
|
211
|
-
* example:
|
|
212
|
-
* 240
|
|
213
|
-
*/
|
|
214
|
-
current_consumption?: number;
|
|
215
|
-
/**
|
|
216
|
-
* example:
|
|
217
|
-
* {}
|
|
218
|
-
*/
|
|
219
|
-
last_reading?: string;
|
|
220
|
-
/**
|
|
221
|
-
* example:
|
|
222
|
-
* 3
|
|
223
|
-
*/
|
|
224
|
-
conversion_factor?: number;
|
|
225
|
-
tariff_type?: TariffType;
|
|
226
|
-
}
|
|
227
|
-
export interface MeterReading {
|
|
228
|
-
/**
|
|
229
|
-
* example:
|
|
230
|
-
* 240
|
|
231
|
-
*/
|
|
232
|
-
value?: number;
|
|
233
|
-
/**
|
|
234
|
-
* example:
|
|
235
|
-
* John Doe
|
|
236
|
-
*/
|
|
237
|
-
read_by?: string;
|
|
238
|
-
/**
|
|
239
|
-
* example:
|
|
240
|
-
* Storing the feed-in record
|
|
241
|
-
*/
|
|
242
|
-
reason?: string;
|
|
243
|
-
/**
|
|
244
|
-
* example:
|
|
245
|
-
* 1446829f-4b6f-474e-b978-3997d89a7928
|
|
246
|
-
*/
|
|
247
|
-
meter_id?: string;
|
|
248
|
-
/**
|
|
249
|
-
* example:
|
|
250
|
-
* 991a1821-43bc-46b8-967d-64a3d87c31f8
|
|
251
|
-
*/
|
|
252
|
-
counter_id?: string;
|
|
253
|
-
direction?: Direction;
|
|
254
|
-
/**
|
|
255
|
-
* If the value is not provided, the system will be set with the time the request is processed.
|
|
256
|
-
* example:
|
|
257
|
-
* "2022-10-10T00:00:00.000Z"
|
|
258
|
-
*/
|
|
259
|
-
timestamp?: string;
|
|
260
|
-
source?: Source;
|
|
261
|
-
}
|
|
262
|
-
export interface ReadingWithMeter {
|
|
263
|
-
/**
|
|
264
|
-
* example:
|
|
265
|
-
* A09-123
|
|
266
|
-
*/
|
|
267
|
-
ma_lo_id?: string;
|
|
268
|
-
meter_id?: Id;
|
|
269
|
-
/**
|
|
270
|
-
* example:
|
|
271
|
-
* A-34
|
|
272
|
-
*/
|
|
273
|
-
obis_number?: string;
|
|
274
|
-
unit?: Unit;
|
|
275
|
-
direction?: Direction;
|
|
276
|
-
tariff_type?: TariffType;
|
|
277
|
-
/**
|
|
278
|
-
* example:
|
|
279
|
-
* 240
|
|
280
|
-
*/
|
|
281
|
-
value?: number;
|
|
282
|
-
/**
|
|
283
|
-
* example:
|
|
284
|
-
* John Doe
|
|
285
|
-
*/
|
|
286
|
-
read_by?: string;
|
|
287
|
-
/**
|
|
288
|
-
* example:
|
|
289
|
-
* Storing the feed-in record
|
|
290
|
-
*/
|
|
291
|
-
reason?: string;
|
|
292
|
-
/**
|
|
293
|
-
* If the value is not provided, the system will be set with the time the request is processed.
|
|
294
|
-
* example:
|
|
295
|
-
* "2022-10-10T10:10:00.000Z"
|
|
296
|
-
*/
|
|
297
|
-
timestamp?: string;
|
|
298
|
-
source?: Source;
|
|
299
|
-
}
|
|
300
|
-
export type Source = "ECP" | "ERP" | "360" | "journey-submission";
|
|
301
|
-
export interface SubmissionMeterReading {
|
|
302
|
-
[name: string]: any;
|
|
303
|
-
}
|
|
304
|
-
export type TariffType = "ht" | "nt";
|
|
305
|
-
export type Unit = "w" | "wh" | "kw" | "kWh" | "kvarh" | "mw" | "mWh" | "unit" | "cubic-meter" | "hour" | "day" | "month" | "year" | "percentage";
|
|
306
|
-
}
|
|
307
|
-
}
|
|
308
|
-
declare namespace Paths {
|
|
309
|
-
namespace CreateMeterReading {
|
|
310
|
-
export type RequestBody = Components.Schemas.MeterReading;
|
|
311
|
-
namespace Responses {
|
|
312
|
-
export interface $200 {
|
|
313
|
-
data?: Components.Schemas.MeterReading;
|
|
314
|
-
}
|
|
315
|
-
}
|
|
316
|
-
}
|
|
317
|
-
namespace CreateMeterReadingFromSubmission {
|
|
318
|
-
export type RequestBody = Components.Schemas.SubmissionMeterReading;
|
|
319
|
-
namespace Responses {
|
|
320
|
-
export interface $200 {
|
|
321
|
-
data?: Components.Schemas.MeterReading;
|
|
322
|
-
}
|
|
323
|
-
}
|
|
324
|
-
}
|
|
325
|
-
namespace CreateMeterReadings {
|
|
326
|
-
export interface RequestBody {
|
|
327
|
-
readings?: Components.Schemas.MeterReading[];
|
|
328
|
-
}
|
|
329
|
-
namespace Responses {
|
|
330
|
-
export interface $200 {
|
|
331
|
-
data?: Components.Schemas.MeterReading[];
|
|
332
|
-
}
|
|
333
|
-
}
|
|
334
|
-
}
|
|
335
|
-
namespace CreateReadingWithMeter {
|
|
336
|
-
export type RequestBody = Components.Schemas.ReadingWithMeter;
|
|
337
|
-
namespace Responses {
|
|
338
|
-
export interface $200 {
|
|
339
|
-
data?: Components.Schemas.MeterReading;
|
|
340
|
-
}
|
|
341
|
-
}
|
|
342
|
-
}
|
|
343
|
-
namespace DeleteMeterReading {
|
|
344
|
-
namespace Parameters {
|
|
345
|
-
export type CounterId = Components.Schemas.Id;
|
|
346
|
-
export type MeterId = Components.Schemas.Id;
|
|
347
|
-
/**
|
|
348
|
-
* example:
|
|
349
|
-
* "2022-10-01T20:00:00.000Z"
|
|
350
|
-
*/
|
|
351
|
-
export type Timestamp = string;
|
|
352
|
-
}
|
|
353
|
-
export interface PathParameters {
|
|
354
|
-
meter_id: Parameters.MeterId;
|
|
355
|
-
counter_id: Parameters.CounterId;
|
|
356
|
-
}
|
|
357
|
-
export interface QueryParameters {
|
|
358
|
-
timestamp: /**
|
|
359
|
-
* example:
|
|
360
|
-
* "2022-10-01T20:00:00.000Z"
|
|
361
|
-
*/
|
|
362
|
-
Parameters.Timestamp;
|
|
363
|
-
}
|
|
364
|
-
namespace Responses {
|
|
365
|
-
export interface $200 {
|
|
366
|
-
data?: {
|
|
367
|
-
meterId?: Components.Schemas.Id;
|
|
368
|
-
counterId?: Components.Schemas.Id;
|
|
369
|
-
/**
|
|
370
|
-
* example:
|
|
371
|
-
* "2022-10-01T20:00:00.000Z"
|
|
372
|
-
*/
|
|
373
|
-
timestamp?: string;
|
|
374
|
-
};
|
|
375
|
-
}
|
|
376
|
-
}
|
|
377
|
-
}
|
|
378
|
-
namespace GetCounterDetails {
|
|
379
|
-
namespace Parameters {
|
|
380
|
-
export type CounterId = Components.Schemas.Id;
|
|
381
|
-
}
|
|
382
|
-
export interface PathParameters {
|
|
383
|
-
counter_id: Parameters.CounterId;
|
|
384
|
-
}
|
|
385
|
-
namespace Responses {
|
|
386
|
-
export interface $200 {
|
|
387
|
-
data?: /**
|
|
388
|
-
* example:
|
|
389
|
-
* {
|
|
390
|
-
* "_id": "3fa85f64-5717-4562-b3fc-2c963f66afa6",
|
|
391
|
-
* "_org": "123",
|
|
392
|
-
* "_schema": "contact",
|
|
393
|
-
* "_tags": [
|
|
394
|
-
* "example",
|
|
395
|
-
* "mock"
|
|
396
|
-
* ],
|
|
397
|
-
* "_created_at": {},
|
|
398
|
-
* "_updated_at": {}
|
|
399
|
-
* }
|
|
400
|
-
*/
|
|
401
|
-
Components.Schemas.MeterCounter;
|
|
402
|
-
}
|
|
403
|
-
}
|
|
404
|
-
}
|
|
405
|
-
namespace GetCustomerMeters {
|
|
406
|
-
namespace Responses {
|
|
407
|
-
export interface $200 {
|
|
408
|
-
data?: /**
|
|
409
|
-
* example:
|
|
410
|
-
* {
|
|
411
|
-
* "_id": "3fa85f64-5717-4562-b3fc-2c963f66afa6",
|
|
412
|
-
* "_org": "123",
|
|
413
|
-
* "_schema": "contact",
|
|
414
|
-
* "_tags": [
|
|
415
|
-
* "example",
|
|
416
|
-
* "mock"
|
|
417
|
-
* ],
|
|
418
|
-
* "_created_at": {},
|
|
419
|
-
* "_updated_at": {}
|
|
420
|
-
* }
|
|
421
|
-
*/
|
|
422
|
-
Components.Schemas.Meter[];
|
|
423
|
-
}
|
|
424
|
-
}
|
|
425
|
-
}
|
|
426
|
-
namespace GetDownSampleReadingsByInterval {
|
|
427
|
-
namespace Parameters {
|
|
428
|
-
export type CounterId = Components.Schemas.Id;
|
|
429
|
-
export type Direction = Components.Schemas.Direction;
|
|
430
|
-
/**
|
|
431
|
-
* example:
|
|
432
|
-
* "2022-10-10T00:00:00.000Z"
|
|
433
|
-
*/
|
|
434
|
-
export type EndDate = string;
|
|
435
|
-
export type GroupBy = "day" | "week" | "month" | "year";
|
|
436
|
-
export type MeterId = Components.Schemas.Id;
|
|
437
|
-
/**
|
|
438
|
-
* example:
|
|
439
|
-
* "2022-10-01T00:00:00.000Z"
|
|
440
|
-
*/
|
|
441
|
-
export type StartDate = string;
|
|
442
|
-
}
|
|
443
|
-
export interface PathParameters {
|
|
444
|
-
meter_id: Parameters.MeterId;
|
|
445
|
-
counter_id: Parameters.CounterId;
|
|
446
|
-
}
|
|
447
|
-
export interface QueryParameters {
|
|
448
|
-
start_date?: /**
|
|
449
|
-
* example:
|
|
450
|
-
* "2022-10-01T00:00:00.000Z"
|
|
451
|
-
*/
|
|
452
|
-
Parameters.StartDate;
|
|
453
|
-
end_date?: /**
|
|
454
|
-
* example:
|
|
455
|
-
* "2022-10-10T00:00:00.000Z"
|
|
456
|
-
*/
|
|
457
|
-
Parameters.EndDate;
|
|
458
|
-
group_by?: Parameters.GroupBy;
|
|
459
|
-
direction?: Parameters.Direction;
|
|
460
|
-
}
|
|
461
|
-
namespace Responses {
|
|
462
|
-
export interface $200 {
|
|
463
|
-
data?: Components.Schemas.MeterReading[];
|
|
464
|
-
}
|
|
465
|
-
}
|
|
466
|
-
}
|
|
467
|
-
namespace GetMeterCounters {
|
|
468
|
-
namespace Parameters {
|
|
469
|
-
/**
|
|
470
|
-
* example:
|
|
471
|
-
* 1446829f-4b6f-474e-b978-3997d89a7928
|
|
472
|
-
*/
|
|
473
|
-
export type MeterId = string;
|
|
474
|
-
}
|
|
475
|
-
export interface QueryParameters {
|
|
476
|
-
meter_id: /**
|
|
477
|
-
* example:
|
|
478
|
-
* 1446829f-4b6f-474e-b978-3997d89a7928
|
|
479
|
-
*/
|
|
480
|
-
Parameters.MeterId;
|
|
481
|
-
}
|
|
482
|
-
namespace Responses {
|
|
483
|
-
export interface $200 {
|
|
484
|
-
data?: /**
|
|
485
|
-
* example:
|
|
486
|
-
* {
|
|
487
|
-
* "_id": "3fa85f64-5717-4562-b3fc-2c963f66afa6",
|
|
488
|
-
* "_org": "123",
|
|
489
|
-
* "_schema": "contact",
|
|
490
|
-
* "_tags": [
|
|
491
|
-
* "example",
|
|
492
|
-
* "mock"
|
|
493
|
-
* ],
|
|
494
|
-
* "_created_at": {},
|
|
495
|
-
* "_updated_at": {}
|
|
496
|
-
* }
|
|
497
|
-
*/
|
|
498
|
-
Components.Schemas.MeterCounter[];
|
|
499
|
-
}
|
|
500
|
-
}
|
|
501
|
-
}
|
|
502
|
-
namespace GetReadingsByInterval {
|
|
503
|
-
namespace Parameters {
|
|
504
|
-
export type CounterId = Components.Schemas.Id;
|
|
505
|
-
export type Direction = Components.Schemas.Direction;
|
|
506
|
-
/**
|
|
507
|
-
* example:
|
|
508
|
-
* "2022-10-10T00:00:00.000Z"
|
|
509
|
-
*/
|
|
510
|
-
export type EndDate = string;
|
|
511
|
-
/**
|
|
512
|
-
* example:
|
|
513
|
-
* 0
|
|
514
|
-
*/
|
|
515
|
-
export type From = number;
|
|
516
|
-
export type MeterId = Components.Schemas.Id;
|
|
517
|
-
/**
|
|
518
|
-
* example:
|
|
519
|
-
* 20
|
|
520
|
-
*/
|
|
521
|
-
export type Size = number;
|
|
522
|
-
/**
|
|
523
|
-
* example:
|
|
524
|
-
* "2022-10-01T00:00:00.000Z"
|
|
525
|
-
*/
|
|
526
|
-
export type StartDate = string;
|
|
527
|
-
export type Type = "cumulative" | "relative";
|
|
528
|
-
}
|
|
529
|
-
export interface PathParameters {
|
|
530
|
-
meter_id: Parameters.MeterId;
|
|
531
|
-
counter_id: Parameters.CounterId;
|
|
532
|
-
}
|
|
533
|
-
export interface QueryParameters {
|
|
534
|
-
start_date?: /**
|
|
535
|
-
* example:
|
|
536
|
-
* "2022-10-01T00:00:00.000Z"
|
|
537
|
-
*/
|
|
538
|
-
Parameters.StartDate;
|
|
539
|
-
end_date?: /**
|
|
540
|
-
* example:
|
|
541
|
-
* "2022-10-10T00:00:00.000Z"
|
|
542
|
-
*/
|
|
543
|
-
Parameters.EndDate;
|
|
544
|
-
direction?: Parameters.Direction;
|
|
545
|
-
size?: /**
|
|
546
|
-
* example:
|
|
547
|
-
* 20
|
|
548
|
-
*/
|
|
549
|
-
Parameters.Size;
|
|
550
|
-
from?: /**
|
|
551
|
-
* example:
|
|
552
|
-
* 0
|
|
553
|
-
*/
|
|
554
|
-
Parameters.From;
|
|
555
|
-
type: Parameters.Type;
|
|
556
|
-
}
|
|
557
|
-
namespace Responses {
|
|
558
|
-
export interface $200 {
|
|
559
|
-
results?: Components.Schemas.MeterReading[];
|
|
560
|
-
/**
|
|
561
|
-
* example:
|
|
562
|
-
* 120
|
|
563
|
-
*/
|
|
564
|
-
hits?: number;
|
|
565
|
-
/**
|
|
566
|
-
* example:
|
|
567
|
-
* "2022-10-01T20:00:00.000Z"
|
|
568
|
-
*/
|
|
569
|
-
firstRecordCreatedAt?: string;
|
|
570
|
-
}
|
|
571
|
-
}
|
|
572
|
-
}
|
|
573
|
-
namespace UpdateMeterReading {
|
|
574
|
-
namespace Parameters {
|
|
575
|
-
export type CounterId = Components.Schemas.Id;
|
|
576
|
-
export type MeterId = Components.Schemas.Id;
|
|
577
|
-
/**
|
|
578
|
-
* example:
|
|
579
|
-
* "2022-10-01T20:00:00.000Z"
|
|
580
|
-
*/
|
|
581
|
-
export type Timestamp = string;
|
|
582
|
-
}
|
|
583
|
-
export interface PathParameters {
|
|
584
|
-
meter_id: Parameters.MeterId;
|
|
585
|
-
counter_id: Parameters.CounterId;
|
|
586
|
-
}
|
|
587
|
-
export interface QueryParameters {
|
|
588
|
-
timestamp: /**
|
|
589
|
-
* example:
|
|
590
|
-
* "2022-10-01T20:00:00.000Z"
|
|
591
|
-
*/
|
|
592
|
-
Parameters.Timestamp;
|
|
593
|
-
}
|
|
594
|
-
export type RequestBody = Components.Schemas.MeterReading;
|
|
595
|
-
namespace Responses {
|
|
596
|
-
export interface $200 {
|
|
597
|
-
data?: Components.Schemas.MeterReading;
|
|
598
|
-
}
|
|
599
|
-
}
|
|
600
|
-
}
|
|
601
|
-
}
|
|
602
|
-
|
|
603
|
-
export interface OperationMethods {
|
|
604
|
-
/**
|
|
605
|
-
* getCustomerMeters - getCustomerMeters
|
|
606
|
-
*
|
|
607
|
-
* Get All meters related to a customer
|
|
608
|
-
*/
|
|
609
|
-
'getCustomerMeters'(
|
|
610
|
-
parameters?: Parameters<UnknownParamsObject> | null,
|
|
611
|
-
data?: any,
|
|
612
|
-
config?: AxiosRequestConfig
|
|
613
|
-
): OperationResponse<Paths.GetCustomerMeters.Responses.$200>
|
|
614
|
-
/**
|
|
615
|
-
* getMeterCounters - getMeterCounters
|
|
616
|
-
*
|
|
617
|
-
* Get all counters for a given meter
|
|
618
|
-
*/
|
|
619
|
-
'getMeterCounters'(
|
|
620
|
-
parameters?: Parameters<Paths.GetMeterCounters.QueryParameters> | null,
|
|
621
|
-
data?: any,
|
|
622
|
-
config?: AxiosRequestConfig
|
|
623
|
-
): OperationResponse<Paths.GetMeterCounters.Responses.$200>
|
|
624
|
-
/**
|
|
625
|
-
* getCounterDetails - getCounterDetails
|
|
626
|
-
*
|
|
627
|
-
* Get details for a meter counter
|
|
628
|
-
*/
|
|
629
|
-
'getCounterDetails'(
|
|
630
|
-
parameters?: Parameters<Paths.GetCounterDetails.PathParameters> | null,
|
|
631
|
-
data?: any,
|
|
632
|
-
config?: AxiosRequestConfig
|
|
633
|
-
): OperationResponse<Paths.GetCounterDetails.Responses.$200>
|
|
634
|
-
/**
|
|
635
|
-
* createMeterReading - createMeterReading
|
|
636
|
-
*
|
|
637
|
-
* This operation inserts a new meter reading
|
|
638
|
-
*/
|
|
639
|
-
'createMeterReading'(
|
|
640
|
-
parameters?: Parameters<UnknownParamsObject> | null,
|
|
641
|
-
data?: Paths.CreateMeterReading.RequestBody,
|
|
642
|
-
config?: AxiosRequestConfig
|
|
643
|
-
): OperationResponse<Paths.CreateMeterReading.Responses.$200>
|
|
644
|
-
/**
|
|
645
|
-
* createMeterReadings - createMeterReadings
|
|
646
|
-
*
|
|
647
|
-
* This operation inserts a multiple meter readings at once, e.g; to submit bi-directional data (feed-in & feed-out) in a journey
|
|
648
|
-
*/
|
|
649
|
-
'createMeterReadings'(
|
|
650
|
-
parameters?: Parameters<UnknownParamsObject> | null,
|
|
651
|
-
data?: Paths.CreateMeterReadings.RequestBody,
|
|
652
|
-
config?: AxiosRequestConfig
|
|
653
|
-
): OperationResponse<Paths.CreateMeterReadings.Responses.$200>
|
|
654
|
-
/**
|
|
655
|
-
* createMeterReadingFromSubmission - createMeterReadingFromSubmission
|
|
656
|
-
*
|
|
657
|
-
* This operation lets to create reading from a journey submission.
|
|
658
|
-
*/
|
|
659
|
-
'createMeterReadingFromSubmission'(
|
|
660
|
-
parameters?: Parameters<UnknownParamsObject> | null,
|
|
661
|
-
data?: Paths.CreateMeterReadingFromSubmission.RequestBody,
|
|
662
|
-
config?: AxiosRequestConfig
|
|
663
|
-
): OperationResponse<Paths.CreateMeterReadingFromSubmission.Responses.$200>
|
|
664
|
-
/**
|
|
665
|
-
* createReadingWithMeter - createReadingWithMeter
|
|
666
|
-
*
|
|
667
|
-
* This operation lets to create reading along with a meter.
|
|
668
|
-
*/
|
|
669
|
-
'createReadingWithMeter'(
|
|
670
|
-
parameters?: Parameters<UnknownParamsObject> | null,
|
|
671
|
-
data?: Paths.CreateReadingWithMeter.RequestBody,
|
|
672
|
-
config?: AxiosRequestConfig
|
|
673
|
-
): OperationResponse<Paths.CreateReadingWithMeter.Responses.$200>
|
|
674
|
-
/**
|
|
675
|
-
* getReadingsByInterval - getReadingsByInterval
|
|
676
|
-
*
|
|
677
|
-
* - Get all readings specified in an interval
|
|
678
|
-
* - If the start_date & end_date are equal, then returns the readings of the specified date
|
|
679
|
-
* - start_date should <= end_date
|
|
680
|
-
*
|
|
681
|
-
*/
|
|
682
|
-
'getReadingsByInterval'(
|
|
683
|
-
parameters?: Parameters<Paths.GetReadingsByInterval.PathParameters & Paths.GetReadingsByInterval.QueryParameters> | null,
|
|
684
|
-
data?: any,
|
|
685
|
-
config?: AxiosRequestConfig
|
|
686
|
-
): OperationResponse<Paths.GetReadingsByInterval.Responses.$200>
|
|
687
|
-
/**
|
|
688
|
-
* updateMeterReading - updateMeterReading
|
|
689
|
-
*
|
|
690
|
-
* This operation updates a meter reading
|
|
691
|
-
*/
|
|
692
|
-
'updateMeterReading'(
|
|
693
|
-
parameters?: Parameters<Paths.UpdateMeterReading.PathParameters & Paths.UpdateMeterReading.QueryParameters> | null,
|
|
694
|
-
data?: Paths.UpdateMeterReading.RequestBody,
|
|
695
|
-
config?: AxiosRequestConfig
|
|
696
|
-
): OperationResponse<Paths.UpdateMeterReading.Responses.$200>
|
|
697
|
-
/**
|
|
698
|
-
* deleteMeterReading - deleteMeterReading
|
|
699
|
-
*
|
|
700
|
-
* This operation deletes a meter reading
|
|
701
|
-
*/
|
|
702
|
-
'deleteMeterReading'(
|
|
703
|
-
parameters?: Parameters<Paths.DeleteMeterReading.PathParameters & Paths.DeleteMeterReading.QueryParameters> | null,
|
|
704
|
-
data?: any,
|
|
705
|
-
config?: AxiosRequestConfig
|
|
706
|
-
): OperationResponse<Paths.DeleteMeterReading.Responses.$200>
|
|
707
|
-
/**
|
|
708
|
-
* getDownSampleReadingsByInterval - getDownSampleReadingsByInterval
|
|
709
|
-
*
|
|
710
|
-
* - Get the down sampled data of the entire readings specified in an interval
|
|
711
|
-
* - If the start_date & end_date are equal, then returns the readings of the specified date
|
|
712
|
-
* - start_date should <= end_date
|
|
713
|
-
*
|
|
714
|
-
*/
|
|
715
|
-
'getDownSampleReadingsByInterval'(
|
|
716
|
-
parameters?: Parameters<Paths.GetDownSampleReadingsByInterval.PathParameters & Paths.GetDownSampleReadingsByInterval.QueryParameters> | null,
|
|
717
|
-
data?: any,
|
|
718
|
-
config?: AxiosRequestConfig
|
|
719
|
-
): OperationResponse<Paths.GetDownSampleReadingsByInterval.Responses.$200>
|
|
720
|
-
}
|
|
721
|
-
|
|
722
|
-
export interface PathsDictionary {
|
|
723
|
-
['/v1/metering/meter']: {
|
|
724
|
-
/**
|
|
725
|
-
* getCustomerMeters - getCustomerMeters
|
|
726
|
-
*
|
|
727
|
-
* Get All meters related to a customer
|
|
728
|
-
*/
|
|
729
|
-
'get'(
|
|
730
|
-
parameters?: Parameters<UnknownParamsObject> | null,
|
|
731
|
-
data?: any,
|
|
732
|
-
config?: AxiosRequestConfig
|
|
733
|
-
): OperationResponse<Paths.GetCustomerMeters.Responses.$200>
|
|
734
|
-
}
|
|
735
|
-
['/v1/metering/counter']: {
|
|
736
|
-
/**
|
|
737
|
-
* getMeterCounters - getMeterCounters
|
|
738
|
-
*
|
|
739
|
-
* Get all counters for a given meter
|
|
740
|
-
*/
|
|
741
|
-
'get'(
|
|
742
|
-
parameters?: Parameters<Paths.GetMeterCounters.QueryParameters> | null,
|
|
743
|
-
data?: any,
|
|
744
|
-
config?: AxiosRequestConfig
|
|
745
|
-
): OperationResponse<Paths.GetMeterCounters.Responses.$200>
|
|
746
|
-
}
|
|
747
|
-
['/v1/metering/counter/{counter_id}']: {
|
|
748
|
-
/**
|
|
749
|
-
* getCounterDetails - getCounterDetails
|
|
750
|
-
*
|
|
751
|
-
* Get details for a meter counter
|
|
752
|
-
*/
|
|
753
|
-
'get'(
|
|
754
|
-
parameters?: Parameters<Paths.GetCounterDetails.PathParameters> | null,
|
|
755
|
-
data?: any,
|
|
756
|
-
config?: AxiosRequestConfig
|
|
757
|
-
): OperationResponse<Paths.GetCounterDetails.Responses.$200>
|
|
758
|
-
}
|
|
759
|
-
['/v1/metering/reading']: {
|
|
760
|
-
/**
|
|
761
|
-
* createMeterReading - createMeterReading
|
|
762
|
-
*
|
|
763
|
-
* This operation inserts a new meter reading
|
|
764
|
-
*/
|
|
765
|
-
'post'(
|
|
766
|
-
parameters?: Parameters<UnknownParamsObject> | null,
|
|
767
|
-
data?: Paths.CreateMeterReading.RequestBody,
|
|
768
|
-
config?: AxiosRequestConfig
|
|
769
|
-
): OperationResponse<Paths.CreateMeterReading.Responses.$200>
|
|
770
|
-
}
|
|
771
|
-
['/v1/metering/readings']: {
|
|
772
|
-
/**
|
|
773
|
-
* createMeterReadings - createMeterReadings
|
|
774
|
-
*
|
|
775
|
-
* This operation inserts a multiple meter readings at once, e.g; to submit bi-directional data (feed-in & feed-out) in a journey
|
|
776
|
-
*/
|
|
777
|
-
'post'(
|
|
778
|
-
parameters?: Parameters<UnknownParamsObject> | null,
|
|
779
|
-
data?: Paths.CreateMeterReadings.RequestBody,
|
|
780
|
-
config?: AxiosRequestConfig
|
|
781
|
-
): OperationResponse<Paths.CreateMeterReadings.Responses.$200>
|
|
782
|
-
}
|
|
783
|
-
['/v1/metering/reading/submission']: {
|
|
784
|
-
/**
|
|
785
|
-
* createMeterReadingFromSubmission - createMeterReadingFromSubmission
|
|
786
|
-
*
|
|
787
|
-
* This operation lets to create reading from a journey submission.
|
|
788
|
-
*/
|
|
789
|
-
'post'(
|
|
790
|
-
parameters?: Parameters<UnknownParamsObject> | null,
|
|
791
|
-
data?: Paths.CreateMeterReadingFromSubmission.RequestBody,
|
|
792
|
-
config?: AxiosRequestConfig
|
|
793
|
-
): OperationResponse<Paths.CreateMeterReadingFromSubmission.Responses.$200>
|
|
794
|
-
}
|
|
795
|
-
['/v1/metering/reading/with-meter']: {
|
|
796
|
-
/**
|
|
797
|
-
* createReadingWithMeter - createReadingWithMeter
|
|
798
|
-
*
|
|
799
|
-
* This operation lets to create reading along with a meter.
|
|
800
|
-
*/
|
|
801
|
-
'post'(
|
|
802
|
-
parameters?: Parameters<UnknownParamsObject> | null,
|
|
803
|
-
data?: Paths.CreateReadingWithMeter.RequestBody,
|
|
804
|
-
config?: AxiosRequestConfig
|
|
805
|
-
): OperationResponse<Paths.CreateReadingWithMeter.Responses.$200>
|
|
806
|
-
}
|
|
807
|
-
['/v1/metering/reading/{meter_id}/{counter_id}']: {
|
|
808
|
-
/**
|
|
809
|
-
* getReadingsByInterval - getReadingsByInterval
|
|
810
|
-
*
|
|
811
|
-
* - Get all readings specified in an interval
|
|
812
|
-
* - If the start_date & end_date are equal, then returns the readings of the specified date
|
|
813
|
-
* - start_date should <= end_date
|
|
814
|
-
*
|
|
815
|
-
*/
|
|
816
|
-
'get'(
|
|
817
|
-
parameters?: Parameters<Paths.GetReadingsByInterval.PathParameters & Paths.GetReadingsByInterval.QueryParameters> | null,
|
|
818
|
-
data?: any,
|
|
819
|
-
config?: AxiosRequestConfig
|
|
820
|
-
): OperationResponse<Paths.GetReadingsByInterval.Responses.$200>
|
|
821
|
-
/**
|
|
822
|
-
* updateMeterReading - updateMeterReading
|
|
823
|
-
*
|
|
824
|
-
* This operation updates a meter reading
|
|
825
|
-
*/
|
|
826
|
-
'put'(
|
|
827
|
-
parameters?: Parameters<Paths.UpdateMeterReading.PathParameters & Paths.UpdateMeterReading.QueryParameters> | null,
|
|
828
|
-
data?: Paths.UpdateMeterReading.RequestBody,
|
|
829
|
-
config?: AxiosRequestConfig
|
|
830
|
-
): OperationResponse<Paths.UpdateMeterReading.Responses.$200>
|
|
831
|
-
/**
|
|
832
|
-
* deleteMeterReading - deleteMeterReading
|
|
833
|
-
*
|
|
834
|
-
* This operation deletes a meter reading
|
|
835
|
-
*/
|
|
836
|
-
'delete'(
|
|
837
|
-
parameters?: Parameters<Paths.DeleteMeterReading.PathParameters & Paths.DeleteMeterReading.QueryParameters> | null,
|
|
838
|
-
data?: any,
|
|
839
|
-
config?: AxiosRequestConfig
|
|
840
|
-
): OperationResponse<Paths.DeleteMeterReading.Responses.$200>
|
|
841
|
-
}
|
|
842
|
-
['/v1/metering/down-sample/readings/{meter_id}/{counter_id}']: {
|
|
843
|
-
/**
|
|
844
|
-
* getDownSampleReadingsByInterval - getDownSampleReadingsByInterval
|
|
845
|
-
*
|
|
846
|
-
* - Get the down sampled data of the entire readings specified in an interval
|
|
847
|
-
* - If the start_date & end_date are equal, then returns the readings of the specified date
|
|
848
|
-
* - start_date should <= end_date
|
|
849
|
-
*
|
|
850
|
-
*/
|
|
851
|
-
'get'(
|
|
852
|
-
parameters?: Parameters<Paths.GetDownSampleReadingsByInterval.PathParameters & Paths.GetDownSampleReadingsByInterval.QueryParameters> | null,
|
|
853
|
-
data?: any,
|
|
854
|
-
config?: AxiosRequestConfig
|
|
855
|
-
): OperationResponse<Paths.GetDownSampleReadingsByInterval.Responses.$200>
|
|
856
|
-
}
|
|
857
|
-
}
|
|
858
|
-
|
|
859
|
-
export type Client = OpenAPIClient<OperationMethods, PathsDictionary>
|