-
Notifications
You must be signed in to change notification settings - Fork 1
/
open_api_spec.yaml
4018 lines (3893 loc) · 109 KB
/
open_api_spec.yaml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
706
707
708
709
710
711
712
713
714
715
716
717
718
719
720
721
722
723
724
725
726
727
728
729
730
731
732
733
734
735
736
737
738
739
740
741
742
743
744
745
746
747
748
749
750
751
752
753
754
755
756
757
758
759
760
761
762
763
764
765
766
767
768
769
770
771
772
773
774
775
776
777
778
779
780
781
782
783
784
785
786
787
788
789
790
791
792
793
794
795
796
797
798
799
800
801
802
803
804
805
806
807
808
809
810
811
812
813
814
815
816
817
818
819
820
821
822
823
824
825
826
827
828
829
830
831
832
833
834
835
836
837
838
839
840
841
842
843
844
845
846
847
848
849
850
851
852
853
854
855
856
857
858
859
860
861
862
863
864
865
866
867
868
869
870
871
872
873
874
875
876
877
878
879
880
881
882
883
884
885
886
887
888
889
890
891
892
893
894
895
896
897
898
899
900
901
902
903
904
905
906
907
908
909
910
911
912
913
914
915
916
917
918
919
920
921
922
923
924
925
926
927
928
929
930
931
932
933
934
935
936
937
938
939
940
941
942
943
944
945
946
947
948
949
950
951
952
953
954
955
956
957
958
959
960
961
962
963
964
965
966
967
968
969
970
971
972
973
974
975
976
977
978
979
980
981
982
983
984
985
986
987
988
989
990
991
992
993
994
995
996
997
998
999
1000
swagger: '2.0'
info:
title: Utilitarian API
termsOfService: https://www.pwit.se
x-logo:
url: "https://docs.utilitarian.io/images/utilitarian_logo_on_light.svg"
backgroundColor: "#FFFFFF"
altText: "Utilitarian logo"
contact:
name: Dev Team
url: https://www.utilitarian.io
email: info@pwit.se
version: 1.3.0
license:
name: BSD-3-Clause
url: https://opensource.org/licenses/BSD-3-Clause
description: |
Utilitarian API is a software for Multi Utility AMR (Automatic Meter
Reading) built by Palmlund Wahlgren Innovative Technology AB and
is targeted to utility organisations that require a more open solution for
their AMR Operations.
The source for this documentation can be found on
[github.com](https://www.github.com/pwitab/utilitarian-api-docs). If you
find any errors in the documentation or you have suggestions on how to make
it better please create an issue on Github.
# Introduction
Utilitarian API is a RESTful API that exposes endpoint for AMR Operations.
host: localhost
schemes:
- https
basePath: /v1/metering # Maybe this should be changed??
consumes:
- application/json
produces:
- application/json
securityDefinitions:
api_key:
name: API Key
description: >
Each User is given an API Key.
type: apiKey
in: header
basic:
description: >
All users are allowed to use basic auth but it is not recommended.
type: basic
name: basic
in: header
tags:
# Metering
- name: meter-devices
description: |
Operations on Meter Devices
### Meter Devices
Meter Devices are the entity that represents a physical (or logical)
meter deployed in the field. They handle all information about how to
communicate with the meter and how to interpret the data from the
meter.
x-displayName: Meter Devices
- name: meter-device-configs
description: |
Operations on Meter Device Configs
### Meter Device Configs
A Meter Device Config stores the configurations of a Meter Device Type.
As of now this stores mainly what MeteringSeries it has.
The metering series list is used to validate if a meter reading from a
meter device is allowed to be saved.
The plan later on is have information about what, for example COSEM
objects a meter has, or what MBus Vifes etc the meter has. For example can
an IDIS complient meter share configuration with other meters of different
make. An OMS compliant Mbus meter can also share configuration between
different manufacturers.
x-displayName: Meter Device Configs
- name: meter-device-types
description: |
Operations on Meter Device Types
### Meter Device Types
It is possible to have a meter that is of same make and model but
differently configured. By adding a different meter type we can have a
several different setups of the same manufacturer model.
x-displayName: Meter Device Types
- name: sim-cards
description: |
Operations on SIM Cards
### SIM Cards
Utilitarian is focused on IP communication with meters. Many meter have
internal or external modems that are used for cellular communications.
This require a SIM-card. Many SIM-cards in IoT data plans will give a
fixed IP. It is possible to store all your SIM cards in Utiltarian and
link them to your meter devices for an easy way of finding the IP for a
meter device. If you switch a SIM cards in the field you need to switch
it in Utilitarian so that the system can find the meter device.
> Tips: It is possible to save a link to the managing software, for
> example Jasper, of the SIM cards. In future Utilitarian UI this will be
> rendered as an external link to quickly get access to logs and other SIM
> cards operations that are not in the scope of Utilitarian.
x-displayName: SIM Cards
- name: new-meter-readings
description: |
Operation on new meter readings
### New Meter Readings
This enpoint is used by the different distributed AMR services that send
data.
It is not always knows by the external service what the database ID is
for meter device or meter readings series. This endpoint will do lookups
based on the names of the meter device and meter reading series.
x-displayName: New Meter Readings
- name: meter-security-keys
description: |
Operations on Meter Security Key Collection
### Meter Security Key Collection
A Meter Security Key Collection holds all passwords, secrets and
encryption keys for a meter device.
The `dlms_master_key` will never be returned in any of the responses for security reasons.
> Note: DLMS Keys are stored in hexadecimal strings. 128 bit key = 32 hex
> characters, 256 bit key = 64 hex characters.
x-displayName: Meter Security Key Collections
- name: meter-readings
description: |
Operations on Meter Readings
### Meter Readings
Meter Readings are the raw data we receive from meter devices.
They are limited to numerical data.
Meter Readings table is designed for short term storage of meter values.
x-displayName: Meter Readings
- name: meter-reading-series
description: |
Operations on Meter Reading Series
### Meter Reading Series
A MeterReadingSeries is used for grouping all meter values that should be
viewed as a time series of values. It also adds "metadata" about the series
so that it is possible to know more about the values contained in it.
In Utilitarian we aim to use OBIS codes as series identifier but there is
nothing preventing the use of any identifier for a series. Simple string
values like "energy" and "power" could be used or more complex identifiers
like from the CIM standard.
Since we might have electricity meters that have current and voltage
transformers in their measurement loops we need to specify if the series
is affected by either the current transformer and/or the voltage
transformer ratio.
x-displayName: Meter Reading Series
- name: staged-meter-readings
description: |
Operations on Staged Meter Readings
### Staged Meter Readings
Staged Meter Readings are meter readings that when they where received by
Utilitarian API did not have a corresponding meter. This might be due to
that the meter was set up in the field but was not yet set up in Utilitarian
API. To avoid loosing values we save the meter readings for a while and
whenever a new meter device is created we will save all staged meter
readings as normal meter readings. We also clear the staging table of old
values after a set amount of time to make sure the list doesn't grow to
large.
x-displayName: Staged Meter Readings
- name: meter-system-events
description: |
Operations on Meter System Events
### Meter System Events
A MeterSystemEvent is some form of event occurring in a MeterDevice. It
could be an indication that something is wrong (Alarm) or an just a log
entry that the meter switched to summer time.
x-displayName: Meter System Events
- name: network-interfaces
description: |
Operations on Network Interfaces.
### Network Interfaces
A NetworkInterface is an object holding information needed for
communication to a meter device. You can connect SIM cards to a network
interface. Several meter devices can share the same network interface,
for example an MBus gateway. It is also possbile for several network
interfaces to share the same SIM Card, for example if using the same
IP/SIM-card but different devices are under different ports. Then each
meter device would have its own network interface specifiying the port
but they would all share the same SIM Card to get the IP address.
Some network interfaces only allows for one open connection and when the
network interface is used by communication software we want to make sure
that no other job is trying to communicate with the meter devcice. This
is done by blocking the network interface. When the communication is done
the network interface should be unblocked so that other jobs can connect
to it.
> Tips: The `host` parameter is only returned in responses and will contain
> the following data:
>
> 1. FQDN. If a meter has a DNS compliant name attached to it we assume
> we want to use that firstly
> 2. Static IP Address. If no FQDN is set on the meter it will return the
> static ip address associated with it.
> 3. IP of SIM Card. If no static ip address or FQDN is set the meter
> will return the IP of the SIM Card attached to it.
x-displayName: Network Interfaces
- name: amr-task-groups
description: |
Operations on Amr Task Groups.
### Amr Task Groups
Amr Task Groups are used for managing AMR Task that should be set on Meter
Devices together.
One good use is to have certain "AMR Profiles" as Amr Task Groups. For example if
you have a group of meter that should be collected hourly and another daily you
could set up two groups: 'Hourly' and 'Daily' then set the Amr Task Group on
specified meter devices. If you then need to make adjustments in the daily jobs
you can do this in one place, the Amr Task Group, and not on every individual
meter device.
x-displayName: Amr Task Groups
- name: amr-tasks
description: |
Operations on Amr Tasks.
### Amr Tasks
Amr Task are object containing information on how and when to run a AMR job.
Amr Tasks are added to meter or Amr Task Groups. If added to a meter the task
will run for that particular meter. If you need to manage a collection of tasks
used for several meter, use an AmrTask Group.
x-displayName: Amr Tasks
- name: amr-tasks-invoke
description: |
Direct invocation of task on demand
### Invoke Amr Task
It is possible to invoke the an AMR Task on demand by using this endpoint.
It takes a meter device id and task info and will send the task directly to the
async workerk.
x-displayName: Invoke Amr Task
- name: organizations-main
description: |
Operations on an Organization
### Organizations
Organizationas are used to group entites to a single customer / organization.
x-displayName: Organizations
- name: organizations-memberships
description: |
Managing users membership in an organization.
### Organizations Membershitp
Organizationas are used to group entites to a single customer / organization.
x-displayName: Organizations Memebership
# Common
- name: Pagination
x-traitTag: true
description: |
The Pagination scheme used for Utiltiarian API is a Limit/Offset scheme.
By using a limit indicates the maximum number of items to return and the
offset indicates the starting position of the query in relation to the
complete set of unpaginated items. This makes for a very extensible
pagination scheme where the client have better control of the returned
values. In all responses the total count of items in the compleate set of
unpaginated items are returned to be able to know where in the set a
pagination response is located.
The limit and offset is applied in query parameters like:
```
GET https://api.example.org/accounts/?limit=100&offset=400
```
The following example shows a common result set.
``` json
{
"count": 1023
"next": "https://api.example.org/accounts/?limit=100&offset=500",
"previous": "https://api.example.org/accounts/?limit=100&offset=300",
"results": [
…
]
}
```
> Note: Having very large result sets can lead to significant performance
> issues.
- name: Authentication
x-traitTag: true
description: |
# Token Authentication
Each user with `is_staff=True` is given a unique API Key Token to interact with
the API.
Token Authentication is made for programatical high level access of the API.
To make other services use the API via a Token make a sepatate user for them and
use the token in all authentications.
Users with Token Authentication access to all actions in the API.
For clients to authenticate, the token key should be included in the
`Authorization` HTTP header. The key should be prefixed by the string
literal "Token", with whitespace separating the two strings. For example:
```
Authorization: Token 9944b09199c62bcf9418ad846dd0e4bbdfc6ee4b
```
Unauthenticated responses that are denied permission will result in an
`HTTP 401 Unauthorized` response with an appropriate
WWW-Authenticate header. For example:
```
WWW-Authenticate: Token
```
> Note: If you are running an instance of Utilitarian API that is
> accessable over the Internet you need to make sure that the API is
> only served under `https`.
# User JWT Auth
Users with `is_staff=False` are able to request a JSON Web Token (JWT) via the
`/auth/jwt` endpoints.
The JWT endpoint issues a JWT with only read access to the API and will filter all
results to the entites the users organization has access to. When using User JWT Auth
the `organization` field of all request bodys an be omittted and if you add it in
the request body it will be cleaned and the correct organization ID will be added.
For users that are part of several organizations it is possible to switch
organization by requesting a new JWT for another organization.
User JWT Auth is used for client applications using the API. Mobile apps,
single page application etc.
For clients to authenticate, the JWT key should be included in the
`Authorization` HTTP header. The key should be prefixed by the string
literal "JWT", with whitespace separating the two strings. For example:
```
Authorization: JWT eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJzdWIiOiIxMjM0NTY3ODkwIiwibmFtZSI6IkpvaG4gRG9lIiwiaWF0IjoxNTE2MjM5MDIyfQ.SflKxwRJSMeKKF2QT4fwpMeJf36POk6yJV_adQssw5c
```
Unauthenticated responses that are denied permission will result in an
`HTTP 401 Unauthorized` response with an appropriate
WWW-Authenticate header. For example:
```
WWW-Authenticate: JWT
```
> Note: If you are running an instance of Utilitarian API that is
> accessable over the Internet you need to make sure that the API is
> only served under `https`.
# Structuring the tags in the x-tagGroup also controls their order, so generated
# API specs doesn't scramble the order.
x-tagGroups:
- name: Common
tags:
- Authentication
- Pagination
- name: Metering
tags:
- meter-devices
- network-interfaces
- sim-cards
- meter-device-types
- meter-device-configs
- meter-reading-series
- meter-readings
- staged-meter-readings
- new-meter-readings
- meter-system-events
- meter-security-keys
- amr-task-groups
- amr-tasks
- amr-tasks-invoke
- name: Organizations
tags:
- organizations-main
- organizations-memberships
- name: Auth
tags:
- auth
paths:
/auth/jwt/change-organization/:
post:
operationId: auth_jwt_change-organization_create
description: "Will issue a new token to an already \"logged in\" UserJwt User\
\ for another\norganization"
parameters:
- name: data
in: body
required: true
schema:
$ref: '#/definitions/TokenChangeOrg'
responses:
'201':
description: ''
schema:
$ref: '#/definitions/TokenChangeOrg'
tags:
- auth
- auth-jwt
- auth-jwt-change-organization
- jwt
- change-organization
parameters: []
/auth/jwt/renew/:
get:
operationId: auth_jwt_renew_list
description: Will issue a new JWT if the user has a valid JWT.
parameters:
- name: limit
in: query
description: Number of results to return per page.
required: false
type: integer
- name: offset
in: query
description: The initial index from which to return the results.
required: false
type: integer
responses:
'200':
description: ''
tags:
- auth
- auth-jwt
- auth-jwt-renew
- jwt
- renew
parameters: []
/auth/jwt/token/:
post:
operationId: auth_jwt_token_create
description: "Providing username, password return token with access to first\n\
available organization.\nIf an organization_id is provided return that organization\
\ id if the user has\naccess to it.\n\n:param request:\n:param args:\n:param\
\ kwargs:\n:return:"
parameters:
- name: data
in: body
required: true
schema:
$ref: '#/definitions/GetTokenAuth'
responses:
'201':
description: ''
schema:
$ref: '#/definitions/GetTokenAuth'
tags:
- auth
- auth-jwt
- auth-jwt-token
- jwt
- token
parameters: []
/metering/amr-task-groups/:
get:
operationId: metering_amr-task-groups_list
description: Returns list of Amr Task Groups
parameters:
- name: limit
in: query
description: Number of results to return per page.
required: false
type: integer
- name: offset
in: query
description: The initial index from which to return the results.
required: false
type: integer
responses:
'200':
description: ''
schema:
required:
- count
- results
type: object
properties:
count:
type: integer
next:
type: string
format: uri
x-nullable: true
previous:
type: string
format: uri
x-nullable: true
results:
type: array
items:
$ref: '#/definitions/AmrTaskGroup'
tags:
- metering
- metering-amr-task-groups
- amr-task-groups
post:
operationId: metering_amr-task-groups_create
description: Create a new Amr Task Groups
parameters:
- name: data
in: body
required: true
schema:
$ref: '#/definitions/AmrTaskGroup'
responses:
'201':
description: ''
schema:
$ref: '#/definitions/AmrTaskGroup'
tags:
- metering
- metering-amr-task-groups
- amr-task-groups
parameters: []
/metering/amr-task-groups/{id}:
get:
operationId: metering_amr-task-groups_read
description: Returns a single Amr Task Group
parameters: []
responses:
'200':
description: ''
schema:
$ref: '#/definitions/AmrTaskGroup'
tags:
- metering
- metering-amr-task-groups
- amr-task-groups
put:
operationId: metering_amr-task-groups_update
description: Updates a single Amr Task Group
parameters:
- name: data
in: body
required: true
schema:
$ref: '#/definitions/AmrTaskGroup'
responses:
'200':
description: ''
schema:
$ref: '#/definitions/AmrTaskGroup'
tags:
- metering
- metering-amr-task-groups
- amr-task-groups
patch:
operationId: metering_amr-task-groups_partial_update
description: Partially updates a single Amr Task Group
parameters:
- name: data
in: body
required: true
schema:
$ref: '#/definitions/AmrTaskGroup'
responses:
'200':
description: ''
schema:
$ref: '#/definitions/AmrTaskGroup'
tags:
- metering
- metering-amr-task-groups
- amr-task-groups
delete:
operationId: metering_amr-task-groups_delete
description: Deletes a single Amr Task Group
parameters: []
responses:
'204':
description: ''
tags:
- metering
- metering-amr-task-groups
- amr-task-groups
parameters:
- name: id
in: path
description: A UUID string identifying this amr task group.
required: true
type: string
format: uuid
/metering/amr-tasks/:
get:
operationId: metering_amr-tasks_list
description: Returns list of Amr Task
parameters:
- name: limit
in: query
description: Number of results to return per page.
required: false
type: integer
- name: offset
in: query
description: The initial index from which to return the results.
required: false
type: integer
responses:
'200':
description: ''
schema:
required:
- count
- results
type: object
properties:
count:
type: integer
next:
type: string
format: uri
x-nullable: true
previous:
type: string
format: uri
x-nullable: true
results:
type: array
items:
$ref: '#/definitions/AmrTask'
tags:
- metering
- metering-amr-tasks
- amr-tasks
post:
operationId: metering_amr-tasks_create
description: Create a new Amr Task
parameters:
- name: data
in: body
required: true
schema:
$ref: '#/definitions/AmrTask'
responses:
'201':
description: ''
schema:
$ref: '#/definitions/AmrTask'
tags:
- metering
- metering-amr-tasks
- amr-tasks
parameters: []
/metering/amr-tasks/invoke:
post:
operationId: metering_amr-tasks_invoke_create
description: Invokes a task.
parameters: []
responses:
'201':
description: ''
tags:
- metering
- metering-amr-tasks
- metering-amr-tasks-invoke
- amr-tasks
- invoke
parameters: []
/metering/amr-tasks/{id}:
get:
operationId: metering_amr-tasks_read
description: Returns a single Amr Task
parameters: []
responses:
'200':
description: ''
schema:
$ref: '#/definitions/AmrTask'
tags:
- metering
- metering-amr-tasks
- amr-tasks
put:
operationId: metering_amr-tasks_update
description: Updates a single Amr Task
parameters:
- name: data
in: body
required: true
schema:
$ref: '#/definitions/AmrTask'
responses:
'200':
description: ''
schema:
$ref: '#/definitions/AmrTask'
tags:
- metering
- metering-amr-tasks
- amr-tasks
patch:
operationId: metering_amr-tasks_partial_update
description: Partially updates a single Amr Task
parameters:
- name: data
in: body
required: true
schema:
$ref: '#/definitions/AmrTask'
responses:
'200':
description: ''
schema:
$ref: '#/definitions/AmrTask'
tags:
- metering
- metering-amr-tasks
- amr-tasks
delete:
operationId: metering_amr-tasks_delete
description: Deletes a single Amr Task
parameters: []
responses:
'204':
description: ''
tags:
- metering
- metering-amr-tasks
- amr-tasks
parameters:
- name: id
in: path
description: A UUID string identifying this amr task.
required: true
type: string
format: uuid
/metering/meter-device-configs:
get:
operationId: metering_meter-device-configs_list
description: Returns a list of MeterDeviceConfigs
parameters:
- name: limit
in: query
description: Number of results to return per page.
required: false
type: integer
- name: offset
in: query
description: The initial index from which to return the results.
required: false
type: integer
responses:
'200':
description: ''
schema:
required:
- count
- results
type: object
properties:
count:
type: integer
next:
type: string
format: uri
x-nullable: true
previous:
type: string
format: uri
x-nullable: true
results:
type: array
items:
$ref: '#/definitions/MeterDeviceConfig'
tags:
- metering
- metering-meter-device-configs
- meter-device-configs
post:
operationId: metering_meter-device-configs_create
description: Creates a MeterDeviceConfig
parameters:
- name: data
in: body
required: true
schema:
$ref: '#/definitions/MeterDeviceConfig'
responses:
'201':
description: ''
schema:
$ref: '#/definitions/MeterDeviceConfig'
tags:
- metering
- metering-meter-device-configs
- meter-device-configs
parameters: []
/metering/meter-device-configs/{id}:
get:
operationId: metering_meter-device-configs_read
description: Returns a single MeterDeviceConfig
parameters: []
responses:
'200':
description: ''
schema:
$ref: '#/definitions/MeterDeviceConfig'
tags:
- metering
- metering-meter-device-configs
- meter-device-configs
put:
operationId: metering_meter-device-configs_update
description: Updates a single MeterDeviceConfig
parameters:
- name: data
in: body
required: true
schema:
$ref: '#/definitions/MeterDeviceConfig'
responses:
'200':
description: ''
schema:
$ref: '#/definitions/MeterDeviceConfig'
tags:
- metering
- metering-meter-device-configs
- meter-device-configs
patch:
operationId: metering_meter-device-configs_partial_update
description: Partially updates a single MeterDeviceConfig
parameters:
- name: data
in: body
required: true
schema:
$ref: '#/definitions/MeterDeviceConfig'
responses:
'200':
description: ''
schema:
$ref: '#/definitions/MeterDeviceConfig'
tags:
- metering
- metering-meter-device-configs
- meter-device-configs
delete:
operationId: metering_meter-device-configs_delete
description: Deletes a single MeterDeviceConfig
parameters: []
responses:
'204':
description: ''
tags:
- metering
- metering-meter-device-configs
- meter-device-configs
parameters:
- name: id
in: path
description: A UUID string identifying this meter device config.
required: true
type: string
format: uuid
/metering/meter-device-types:
get:
operationId: metering_meter-device-types_list
description: Returns a list of MeterDeviceTypess
parameters:
- name: limit
in: query
description: Number of results to return per page.
required: false
type: integer
- name: offset
in: query
description: The initial index from which to return the results.
required: false
type: integer
responses:
'200':
description: ''
schema:
required:
- count
- results
type: object
properties:
count:
type: integer
next:
type: string
format: uri
x-nullable: true
previous:
type: string
format: uri
x-nullable: true
results:
type: array
items:
$ref: '#/definitions/MeterDeviceType'
tags:
- metering
- metering-meter-device-types
- meter-device-types
post:
operationId: metering_meter-device-types_create
description: Creates a MeterDeviceType
parameters:
- name: data
in: body
required: true
schema:
$ref: '#/definitions/MeterDeviceType'
responses:
'201':
description: ''
schema:
$ref: '#/definitions/MeterDeviceType'
tags: