-
Notifications
You must be signed in to change notification settings - Fork 8
/
apiary.apib
795 lines (574 loc) · 27.7 KB
/
apiary.apib
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
FORMAT: 1A
HOST: https://rss.store.lab.fiware.org/
TITLE: FIWARE Revenue Settlement and Sharing System Open API Specification
DATE: 30 September 2015
VERSION: v4.4.3
PREVIOUS_VERSION: v3.5.2
APIARY_PROJECT: fiwarerss
# FIWARE RSS
The Revenue Settlement and Sharing System (RSS) GE is in charge of distributing the revenues originated by the usage of a given service among the involved stakeholders. In particular, it focuses on distributing part of the revenue generated by a service between the Store Provider and the Service Provider(s) responsible for the service. With the term "service" we refer to both final applications and backend application services (typically exposed through an API). Note that, in the case of composite services, more than one service provider may have to receive a share of the revenues.
Additionally, as a supplementary functionality, expenditure limits functionality is offered in this GE. The expenditure limit API provides a mechanism through which an application provider can limit the amount of money spent by a customer using the services, along a specific time interval.
This document describes the RSS Rest API, including the Stores API, Providers API, Revenue Sharing Models API, CDRs API, and Expenditure Limits API.
## Editors
* Francisco de la Vega, Universidad Politénica de Madrid
## Status
This is a work in progress and is changing on a daily basis. You can check the latest
available version on: <https://github.com/conwetlab/wstore/tree/develop>.
Please send your comments to <[email protected]>.
This specification is licensed under the [FIWARE Open Specification License](https://forge.fiware.org/plugins/mediawiki/wiki/fiware/index.php/FI-WARE_Open_Specification_Legal_Notice_%28implicit_patents_license%29)
## Acknowledgements
The editors would like to express their gratitude to the following people who actively contributed to this specification:
Aitor Magán and Álvaro Arranz García.
## Copyright
* Copyright © 2015 by Universidad Politénica de Madrid
## Specification
### Authentication
Each HTTP request against the RSS API requires the inclusion of specific authentication credentials. The specific implementation of this API may support multiple authentication schemes (OAuth, Basic Auth, Token) and will be determined by the specific provider that implements the GE. Please contact the provider to determine the best way to authenticate against this API. Remember that some authentication schemes may require that the API operates using SSL over HTTP (HTTPS).
The RSS provides support for Cookie and OAuth2 authentication being OAuth2 the default in FIWARE Lab.
### Used HTTP Codes
| HTTP Code | Type | Description |
|-----------|------|------------ |
| 200 | OK | Your request has been completed properly |
| 201 | Created | Your resource has been created.|
| 202 | Accepted | Your request has been accepted for processing.|
| 204 | No content | Your request has been processed, but a response is not available. Generally used when deleting entities|
| 400 | Bad Request | The content of your request is not correct (e.g. There is a missing field) |
| 409 | Conflict | The resource you are tring to create already exists |
| 404 | Not Found | The resource you are looking for does not exists |
| 403 | Forbidden | You have no rights to perform the request |
| 401 | Unauthorized | You are not logged in or the Authorization token you are providing is not valid |
| 500 | Internal server error | There was an internal error in the system so your request cannot be completed |
# Group Aggregators Management
API for the management of aggregators that play the role of charging information sources. This API allows to register and retrieve aggregators information.
This API uses the following fields:
* **aggregatorName** - Display name of the given aggregator
* **aggragtorId** - Email used to identify the user that is authorized to send changing information (typically an admin of a Store instance)
## Aggregators Collection [/fiware-rss/rss/aggregator]
### List all Aggregators [GET]
+ Request
+ Headers
Authorization: Bearer YOUR_OAUTH2_TOKEN
+ Response 200 (application/json)
[
{
"aggregatorName": "WStore",
"aggregatorId": "[email protected]"
}
]
### Register an Aggregator [POST]
+ Request (application/json)
+ Headers
Authorization: Bearer YOUR_OAUTH2_TOKEN
+ Body
{
"aggregatorName": "WStore",
"aggregatorId": "[email protected]"
}
+ Response 201
# Group Providers Management
API for the management of providers. Providers are registered in the context of an aggregator, and are the owners of the applications and services that generate the charging information. This API allows to retrieve and register providers.
This API manages the following fields:
* **aggregatorId** - Aggregator email that identifies the charging information source (Store instance)
* **providerId** - Id of the given provider. Note that this id only needs to be unique in the context of an aggregator, so the same providerId can be used for different providers if the aggregator is different
* **providerName** - Display name of the given provider
## Providers Collection [/fiware-rss/rss/providers{?aggregatorId}]
### List all providers [GET]
+ Parameters
+ aggregatorId: [email protected] (optional) - Optional parameter used to retrieve only those providers registered for a given aggregator
+ Request
+ Headers
Authorization: Bearer YOUR_OAUTH2_TOKEN
+ Response 200 (application/json)
[
{
"aggregatorId": "[email protected]",
"providerId": "conwet",
"providerName": "CoNWeT"
}
]
### Register a provider [POST]
+ Request (application/json)
+ Headers
Authorization: Bearer YOUR_OAUTH2_TOKEN
+ Body
{
"aggregatorId": "[email protected]",
"providerId": "conwet",
"providerName": "CoNWeT"
}
+ Response 201
# Group Algorithms Management
API for the management of supported Algorithms. Supported algorithms are those that can be used to perform the revenue sharing. This API allows to retrieve supported algorithms
This API manages the following fields:
* **algorithmId** - ID of the given algorithm
* **description** - A textual description that explains how the algorithm works
## Algorithms Collection [/fiware-rss/rss/algorithms]
### List Supported Algorithms [GET]
+ Request
+ Headers
Authorization: Bearer YOUR_OAUTH2_TOKEN
+ Response 200 (application/json)
[
{
"algorithmId": "FIXED_PERCENTAGE",
"description": "Fixed percentage distribution of revenues"
}
]
# Group Revenue Sharing Models Management
API for the management of revenue sharing models. A Revenue Sharing Model specifies how the revenues must be distributed between the involved stakeholders. This API allows to retrieve, create, update, and delete revenue sharing models.
This API manages the following fields:
* **ownerProviderId** - Provider Id of the owner of the model. This provider is the owner of the application and services whose revenues will be distributed using the Revenue Sharing Model
* **ownerValue** - Value of the owner provider in the Revenue Sharing Model. The semantics of this field depends on the algorithm specified, for example if the algorithm is a fixed precentage, this field will contain the percetage of the revenue that belongs to the owner provider.
* **productClass** - Id of the Revenue Sharing Model. This field represents a group of services or applications whose revenues are distributed in the same way
* **algorithmType** - ID of the algorithm that is used in this model
* **aggregatorId** - Id of the aggregator that represents the Store instance where the applications and services are offered, and thus, must receive part of the revenues
* **aggregatorValue** - Value of the aggregator in the Revenue Sharing Model
* **stakeholders** - List of providers that are stakeholders of the applications and services included in a given product class, and thus, must receive part of the revenues. For each stakeholder the following fields are included:
* stakeholderId - provider Id of the Stakeholder
* modelValue - Value of the stakeholder in the Revenue Sharing Model
## Revenue Sharing Models Collection [/fiware-rss/rss/models{?aggregatorId}{?appProviderId}{?productClass}]
### List Revenue Sharing models [GET]
+ Parameters
+ aggregatorId: [email protected] (optional) - Optional parameter used to filter by aggragtor Id
+ appProviderId: aarranz (optional) - Optional parameter used to filter by provider Id
+ productClass: orionServices (optional) - Optional parameter used to filter by product class
+ Request
+ Headers
Authorization: Bearer YOUR_OAUTH2_TOKEN
+ Response 200 (application/json)
[
{
"ownerProviderId": "fdelavega",
"ownerValue": 60,
"productClass": "orionServices",
"algorithmType": "FIXED_PERCENTAGE",
"aggregatorId": "[email protected]",
"aggregatorValue": 20,
"stakeholders": [
{
"stakeholderId": "aarranz",
"modelValue": 20
}
]
}
]
### Create Revenue Sharing Model [POST]
+ Request (application/json)
+ Headers
Authorization: Bearer YOUR_OAUTH2_TOKEN
+ Body
{
"ownerProviderId": "fdelavega",
"ownerValue": 60,
"productClass": "orionServices",
"algorithmType": "FIXED_PERCENTAGE",
"aggregatorId": "[email protected]",
"aggregatorValue": 20,
"stakeholders": [
{
"stakeholderId": "aarranz",
"modelValue": 20
}
]
}
+ Response 201
# Group CDRs - Transactions - Management
API for the management of CDR documents describing transactions. This API allows to register and retrieve transactions. Additionally, this API allows to launch the settlement process that aggregates the transactions and calculates the distribution of revenues.
This API manages the following fields:
* **cdrSource** - Id of the aggregator that represent the Store instance that is generating the charging information
* **productClass** - Product Class used to identify the revenue sharing model that will be used to distribute the revenues generated in the current transaction
* **correlationNumber** - Correlation number of the transaction
* **timestamp** - Timestamp of the transaction
* **application** - Textual field with the id of the application or service that generates the transaction
* **transactionType** - Type of transaction. This field can contain "C" for charges and "R" for refunds
* **event** - Textual field that describes the event that generated the transaction (e.g pay-per-use)
* **referenceCode** - Reference code that identifies the purchase in the Store instance that generates the transaction
* **description** - Textual description of the transaction
* **chargedAmount** - Part of the total charged amount to be distributed. The total amount charged to the customer includes also the field chargedTaxAmount
* **chargedTaxAmount** - Part of the total charged amount that are taxes. The total amount charged to the customer includes also the field chargedAmount
* **currency** - Currency of the transaction
* **customerId** - Id of the customer that acquires the given service or application
* **appProvider** - provider Id of the owner of the charged applications or services
## Transactions Collection [/fiware-rss/rss/cdrs{?aggregatorId}{?providerId}]
### List Transactions [GET]
+ Parameters
+ aggregatorId: [email protected] (optional) - Optional parameter used to filter transactions by aggregatorId
+ providerId: aarranz (optional) - Optional parameter used to filter transactions by providerId
+ Request
+ Headers
Authorization: Bearer YOUR_OAUTH2_TOKEN
+ Response 201 (application/json)
[
{
"cdrSource": "[email protected]",
"productClass": "orionServices",
"correlationNumber": 112,
"timestamp": "2015-07-15T19:00:01.000Z",
"application": "OrionStarterKit",
"transactionType": "C",
"event": "use",
"referenceCode": "555b079d8e05ac213ff15827",
"description": "Usage of OrionStarterKit Offering",
"chargedAmount": 10,
"chargedTaxAmount": 3,
"currency": "EUR",
"customerId": "amagan",
"appProvider": "fdelavega"
}
]
### Create Transaction [POST]
+ Request (application/json)
+ Headers
Authorization: Bearer YOUR_OAUTH2_TOKEN
+ Body
{
"cdrSource": "[email protected]",
"productClass": "orionServices",
"correlationNumber": 112,
"timestamp": "2015-07-15T19:00:01.000Z",
"application": "OrionStarterKit",
"transactionType": "C",
"event": "use",
"referenceCode": "555b079d8e05ac213ff15827",
"description": "Usage of OrionStarterKit Offering",
"chargedAmount": 10,
"chargedTaxAmount": 3,
"currency": "EUR",
"customerId": "amagan",
"appProvider": "fdelavega"
}
+ Response 201
## Settlement Collection [/fiware-rss/rss/settlement{?aggregatorId}{?providerId}{?productClass}]
### Launch Settlement [GET]
+ Parameters
+ aggregatorId: [email protected] (optional) - Optional parameter used to aggregate only transactions with a given aggregator
+ providerId: aarranz (optional) - Optional parameter used to aggregate only transactions with a given provider
+ productClass: orionServices (optional) - Optional parameter used to aggregate only transactions with a given product class
+ Request
+ Headers
Authorization: Bearer YOUR_OAUTH2_TOKEN
+ Response 202
## Reports Collection [/fiware-rss/rss/settlement/reports{?aggregatorId}{?providerId}{?productClass}]
API for the management of RS Reports generated during the settlement process. This API allows to retrieve RS Reports.
This API manages the following fields:
* **ownerProviderId** - Provider Id of the owner of the model. This provider is the owner of the application and services whose revenues has been aggregated.
* **ownerValue** - Amount that has to be paid to the provider.
* **productClass** - Id of the Revenue Sharing Model that have been applied. This field represents a group of services or applications whose revenues are distributed in the same way
* **algorithmType** - ID of the algorithm that have been used.
* **aggregatorId** - Id of the aggregator that represents the Store instance where the applications and services are offered, and thus, must receive part of the revenues
* **aggregatorValue** - Amount that has to be paid to the store owners.
* **currency**: Currency of the different amounts.
* **timestamp**: Timestamp of the reports.
* **stakeholders** - List of providers that are stakeholders of the applications and services included in a given product class, and thus, must receive part of the revenues. For each stakeholder the following fields are included:
* **stakeholderId** - provider Id of the Stakeholder
* **modelValue** - Amount that has to be paid to the concrete stakeholder
### Get Reports [GET]
+ Parameters
+ aggregatorId: [email protected] (optional) - Optional parameter used to get only reports with a given aggregator
+ providerId: aarranz (optional) - Optional parameter used to get only reports with a given provider
+ productClass: orionServices (optional) - Optional parameter used to get only reports with a given product class
+ Request
+ Headers
Authorization: Bearer YOUR_OAUTH2_TOKEN
+ Response 200 (application/json)
[
{
"ownerProviderId": "fdelavega",
"ownerValue": 4578,
"productClass": "orionServices",
"algorithmType": "FIXED_PERCENTAGE",
"aggregatorId": "[email protected]",
"aggregatorValue": 3000,
"currency": EUR,
"timestamp": "2015-07-15T19:00:01",
"stakeholders": [
{
"stakeholderId": "aarranz",
"modelValue": 2500
}
]
}
]
# Group Expenditure Limit Management
API for the management of expenditure limits. This API allows to define a couple of limits that allow to control the maximun expenses of customers in different periods of time. This API allows to list, create, modify, and delete expenditure limits.
This API manages the following fields:
* **service** - Service where the limits are applied
* **limits** - List of expenditure limits. Each limit has the following fields:
* **type** - Period of time of the limit. This field can contain perTransaction, daily, weekly, and monthly
* **currency** - Currency of the limit
* **maxAmount** - Maximum amount that can be expensed in the defined period.
Note that only a limit can be defined for a given type and a given currency.
This API allows to manage limits for both providers and users. It is important to remark that provider limits are used as the default limits applied, if the user has not defined its own limits.
## Provider Limits Entry [/expenditureLimits/limits/{aggregator}/{provider}{?service}{?currency}{?type}]
### Get Provider Limits [GET]
+ Parameters
+ aggregator: [email protected] - Store where the provider belongs
+ provider: conwet - Provider whose limits are defined
+ service: fiware - Id of the service where the limits are created
+ currency: EUR (optional) - Optional parameter used to filter by currency
+ type: weekly (optional) - Optional parameter used to filter by type
+ Request
+ Headers
Authorization: Bearer YOUR_OAUTH2_TOKEN
+ Response 200 (application/json)
{
"service": "fiware",
"limits": [
{
"type": "perTransaction",
"currency": "EUR",
"maxAmount": 100,
},
{
"type": "weekly",
"currency": "GBP",
"maxAmount": 500
},
{
"type":"daily",
"currency": "EUR",
"maxAmount": 200
},
{
"type":"monthly",
"currency": "EUR",
"maxAmount": 5000
},
{
"type":"monthly",
"currency": "GBP",
"maxAmount": 3000
}
]
}
### Create/Update provider Limit [POST]
+ Parameters
+ aggregator: [email protected] - Store where the provider belongs
+ provider: conwet - Provider whose limits are defined
+ Request (application/json)
+ Headers
Authorization: Bearer YOUR_OAUTH2_TOKEN
+ Body
{
"service": "fiware",
"limits": [
{
"type": "perTransaction",
"currency": "EUR",
"maxAmount": 100,
},
{
"type": "weekly",
"currency": "GBP",
"maxAmount": 500
},
{
"type":"daily",
"currency": "EUR",
"maxAmount": 200
},
{
"type":"monthly",
"currency": "EUR",
"maxAmount": 5000
},
{
"type":"monthly",
"currency": "GBP",
"maxAmount": 3000
}
]
}
+ Response 201
### Delete Provider Limits [DELETE]
+ Parameters
+ aggregator: [email protected] - Store where the provider belongs
+ provider: conwet - Provider whose limits are defined
+ Request (application/json)
+ Headers
Authorization: Bearer YOUR_OAUTH2_TOKEN
+ Response 204
## User Limits Entry [/expenditureLimits/limits/{aggregator}/{provider}/{user}{?service}{?currency}{?type}]
### Get User Limits [GET]
+ Parameters
+ aggregator: [email protected] - Store where the provider belongs
+ provider: conwet - Provider where limits are applied
+ user: fdelavega - User whose limits are defined
+ service: fiware (optional) - Optional parameter used to filter by service
+ currency: EUR (optional) - Optional parameter used to filter by currency
+ type: weekly (optional) - Optional parameter used to filter by type
+ Request
+ Headers
Authorization: Bearer YOUR_OAUTH2_TOKEN
+ Response 200 (application/json)
{
"service": "fiware",
"limits": [
{
"type": "perTransaction",
"currency": "EUR",
"maxAmount": 100,
},
{
"type": "weekly",
"currency": "GBP",
"maxAmount": 500
},
{
"type":"daily",
"currency": "EUR",
"maxAmount": 200
},
{
"type":"monthly",
"currency": "EUR",
"maxAmount": 5000
},
{
"type":"monthly",
"currency": "GBP",
"maxAmount": 3000
}
]
}
### Create/Update User Limits [POST]
+ Parameters
+ aggregator: [email protected] - Store where the provider belongs
+ provider: conwet - Provider where limits are applied
+ user: fdelavega - User whose limits are defined
+ Request (application/json)
+ Headers
Authorization: Bearer YOUR_OAUTH2_TOKEN
+ Body
{
"service": "fiware",
"limits": [
{
"type": "perTransaction",
"currency": "EUR",
"maxAmount": 100,
},
{
"type": "weekly",
"currency": "GBP",
"maxAmount": 500
},
{
"type":"daily",
"currency": "EUR",
"maxAmount": 200
},
{
"type":"monthly",
"currency": "EUR",
"maxAmount": 5000
},
{
"type":"monthly",
"currency": "GBP",
"maxAmount": 3000
}
]
}
+ Response 201
### Delete User Limits [DELETE]
+ Parameters
+ aggregator: [email protected] - Store where the provider belongs
+ provider: conwet - Provider where limits are applied
+ user: fdelavega - User whose limits are defined
+ Request (application/json)
+ Headers
Authorization: Bearer YOUR_OAUTH2_TOKEN
+ Response 204
# Group Balance Accumulated Management
API for the management of accumulated balances. Accumulated balances are the total expenses used to check the expenditure limits. This API allows to retrieve, check and update balances.
This API manages the following fields:
* **service** - Service where the limits are applied
* **aggregator** - Store where the provider belongs
* **appProvider** - Provider where limits are applied
* **accums** - List of accumulated balances for the existing expenditure limits
* **type** - Period of time of the balance. This field can contain perTransaction, daily, weekly, and monthly
* **currency** - Currency of the balance
* **nextPeriodStartDate** - Start time of the next period for the given accumulated balance
* **expensedAmount** - Total amount accumulated
* **chargeType** - Type of transaction. This value can contain "C" for charges and "R" for refunds
* **amount** - Amount charged in a transaction
## User balance Entry [/expenditureLimits/balance/{user}{?service}{?appProvider}{?currency}{?type}]
### Get User Balance [GET]
+ Parameters
+ user: fdelavega - User owner of the accumulated balance
+ service: fiware - (optional) Optional parameter used to filter by service
+ appProvider: conwet (optional) - Optional parameter used to filter by provider
+ currency: EUR (optional) - Optional parameter used to filter by currency
+ type: weekly (optional) - Optional parameter used to filter by type
+ Request
+ Headers
Authorization: Bearer YOUR_OAUTH2_TOKEN
+ Response 200 (application/json)
{
"service": "fiware",
"aggregator": "[email protected]",
"appProvider": "conwet",
"accums": [
{
"type": "weekly",
"currency": "EUR",
"nextPeriodStartDate": "2015-07-15T19:00:01.000Z",
"expensedAmount": 140
},
{
"type": "weekly",
"currency": "GBP",
"nextPeriodStartDate": "2015-07-15T19:00:01.000Z",
"expensedAmount": 100
}
]
}
### Check User Balance [POST]
+ Parameters
+ user: fdelavega - User whose limits are defined
+ Request (application/json)
+ Headers
Authorization: Bearer YOUR_OAUTH2_TOKEN
+ Body
{
"service": "fiware",
"aggregator": "[email protected]",
"appProvider": "conwet",
"chargeType": "C",
"currency": "EUR",
"amount": 50
}
+ Response 200
### Update User Balance [PUT]
+ Parameters
+ user: fdelavega - User whose limits are defined
+ Request (application/json)
+ Headers
Authorization: Bearer YOUR_OAUTH2_TOKEN
+ Body
{
"service": "fiware",
"aggregator": "[email protected]",
"appProvider": "conwet",
"chargeType": "C",
"currency": "EUR",
"amount": 50
}
+ Response 200
## Reset User Balance Entry [/expenditureLimits/balance/{user}/reset]
### Reset User Balance [PUT]
+ Parameters
+ user: fdelavega - User owner of the accumulated balance
+ Request (application/json)
+ Headers
Authorization: Bearer YOUR_OAUTH2_TOKEN
+ Body
{
"service": "fiware",
"aggregator": "[email protected]",
"appProvider": "conwet",
"currency": "EUR",
"type": "weekly"
}
+ Response 200