@agentxpay/sdk 0.1.0

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.
@@ -0,0 +1,748 @@
1
+ [
2
+ {
3
+ "type": "constructor",
4
+ "inputs": [],
5
+ "stateMutability": "nonpayable"
6
+ },
7
+ {
8
+ "type": "function",
9
+ "name": "activateService",
10
+ "inputs": [
11
+ {
12
+ "name": "serviceId",
13
+ "type": "uint256",
14
+ "internalType": "uint256"
15
+ }
16
+ ],
17
+ "outputs": [],
18
+ "stateMutability": "nonpayable"
19
+ },
20
+ {
21
+ "type": "function",
22
+ "name": "addSubscriptionPlan",
23
+ "inputs": [
24
+ {
25
+ "name": "serviceId",
26
+ "type": "uint256",
27
+ "internalType": "uint256"
28
+ },
29
+ {
30
+ "name": "name",
31
+ "type": "string",
32
+ "internalType": "string"
33
+ },
34
+ {
35
+ "name": "price",
36
+ "type": "uint256",
37
+ "internalType": "uint256"
38
+ },
39
+ {
40
+ "name": "duration",
41
+ "type": "uint256",
42
+ "internalType": "uint256"
43
+ }
44
+ ],
45
+ "outputs": [
46
+ {
47
+ "name": "planId",
48
+ "type": "uint256",
49
+ "internalType": "uint256"
50
+ }
51
+ ],
52
+ "stateMutability": "nonpayable"
53
+ },
54
+ {
55
+ "type": "function",
56
+ "name": "deactivateService",
57
+ "inputs": [
58
+ {
59
+ "name": "serviceId",
60
+ "type": "uint256",
61
+ "internalType": "uint256"
62
+ }
63
+ ],
64
+ "outputs": [],
65
+ "stateMutability": "nonpayable"
66
+ },
67
+ {
68
+ "type": "function",
69
+ "name": "getServiceCount",
70
+ "inputs": [],
71
+ "outputs": [
72
+ {
73
+ "name": "",
74
+ "type": "uint256",
75
+ "internalType": "uint256"
76
+ }
77
+ ],
78
+ "stateMutability": "view"
79
+ },
80
+ {
81
+ "type": "function",
82
+ "name": "getServiceDetails",
83
+ "inputs": [
84
+ {
85
+ "name": "serviceId",
86
+ "type": "uint256",
87
+ "internalType": "uint256"
88
+ }
89
+ ],
90
+ "outputs": [
91
+ {
92
+ "name": "",
93
+ "type": "tuple",
94
+ "internalType": "struct IServiceRegistry.Service",
95
+ "components": [
96
+ {
97
+ "name": "id",
98
+ "type": "uint256",
99
+ "internalType": "uint256"
100
+ },
101
+ {
102
+ "name": "provider",
103
+ "type": "address",
104
+ "internalType": "address"
105
+ },
106
+ {
107
+ "name": "name",
108
+ "type": "string",
109
+ "internalType": "string"
110
+ },
111
+ {
112
+ "name": "description",
113
+ "type": "string",
114
+ "internalType": "string"
115
+ },
116
+ {
117
+ "name": "endpoint",
118
+ "type": "string",
119
+ "internalType": "string"
120
+ },
121
+ {
122
+ "name": "category",
123
+ "type": "string",
124
+ "internalType": "string"
125
+ },
126
+ {
127
+ "name": "pricePerCall",
128
+ "type": "uint256",
129
+ "internalType": "uint256"
130
+ },
131
+ {
132
+ "name": "isActive",
133
+ "type": "bool",
134
+ "internalType": "bool"
135
+ },
136
+ {
137
+ "name": "createdAt",
138
+ "type": "uint256",
139
+ "internalType": "uint256"
140
+ }
141
+ ]
142
+ }
143
+ ],
144
+ "stateMutability": "view"
145
+ },
146
+ {
147
+ "type": "function",
148
+ "name": "getServicesByCategory",
149
+ "inputs": [
150
+ {
151
+ "name": "category",
152
+ "type": "string",
153
+ "internalType": "string"
154
+ }
155
+ ],
156
+ "outputs": [
157
+ {
158
+ "name": "",
159
+ "type": "tuple[]",
160
+ "internalType": "struct IServiceRegistry.Service[]",
161
+ "components": [
162
+ {
163
+ "name": "id",
164
+ "type": "uint256",
165
+ "internalType": "uint256"
166
+ },
167
+ {
168
+ "name": "provider",
169
+ "type": "address",
170
+ "internalType": "address"
171
+ },
172
+ {
173
+ "name": "name",
174
+ "type": "string",
175
+ "internalType": "string"
176
+ },
177
+ {
178
+ "name": "description",
179
+ "type": "string",
180
+ "internalType": "string"
181
+ },
182
+ {
183
+ "name": "endpoint",
184
+ "type": "string",
185
+ "internalType": "string"
186
+ },
187
+ {
188
+ "name": "category",
189
+ "type": "string",
190
+ "internalType": "string"
191
+ },
192
+ {
193
+ "name": "pricePerCall",
194
+ "type": "uint256",
195
+ "internalType": "uint256"
196
+ },
197
+ {
198
+ "name": "isActive",
199
+ "type": "bool",
200
+ "internalType": "bool"
201
+ },
202
+ {
203
+ "name": "createdAt",
204
+ "type": "uint256",
205
+ "internalType": "uint256"
206
+ }
207
+ ]
208
+ }
209
+ ],
210
+ "stateMutability": "view"
211
+ },
212
+ {
213
+ "type": "function",
214
+ "name": "getServicesByProvider",
215
+ "inputs": [
216
+ {
217
+ "name": "provider",
218
+ "type": "address",
219
+ "internalType": "address"
220
+ }
221
+ ],
222
+ "outputs": [
223
+ {
224
+ "name": "",
225
+ "type": "uint256[]",
226
+ "internalType": "uint256[]"
227
+ }
228
+ ],
229
+ "stateMutability": "view"
230
+ },
231
+ {
232
+ "type": "function",
233
+ "name": "getSubscriptionPlan",
234
+ "inputs": [
235
+ {
236
+ "name": "serviceId",
237
+ "type": "uint256",
238
+ "internalType": "uint256"
239
+ },
240
+ {
241
+ "name": "planId",
242
+ "type": "uint256",
243
+ "internalType": "uint256"
244
+ }
245
+ ],
246
+ "outputs": [
247
+ {
248
+ "name": "",
249
+ "type": "tuple",
250
+ "internalType": "struct IServiceRegistry.SubscriptionPlan",
251
+ "components": [
252
+ {
253
+ "name": "planId",
254
+ "type": "uint256",
255
+ "internalType": "uint256"
256
+ },
257
+ {
258
+ "name": "serviceId",
259
+ "type": "uint256",
260
+ "internalType": "uint256"
261
+ },
262
+ {
263
+ "name": "price",
264
+ "type": "uint256",
265
+ "internalType": "uint256"
266
+ },
267
+ {
268
+ "name": "duration",
269
+ "type": "uint256",
270
+ "internalType": "uint256"
271
+ },
272
+ {
273
+ "name": "name",
274
+ "type": "string",
275
+ "internalType": "string"
276
+ }
277
+ ]
278
+ }
279
+ ],
280
+ "stateMutability": "view"
281
+ },
282
+ {
283
+ "type": "function",
284
+ "name": "getSubscriptionPlans",
285
+ "inputs": [
286
+ {
287
+ "name": "serviceId",
288
+ "type": "uint256",
289
+ "internalType": "uint256"
290
+ }
291
+ ],
292
+ "outputs": [
293
+ {
294
+ "name": "",
295
+ "type": "tuple[]",
296
+ "internalType": "struct IServiceRegistry.SubscriptionPlan[]",
297
+ "components": [
298
+ {
299
+ "name": "planId",
300
+ "type": "uint256",
301
+ "internalType": "uint256"
302
+ },
303
+ {
304
+ "name": "serviceId",
305
+ "type": "uint256",
306
+ "internalType": "uint256"
307
+ },
308
+ {
309
+ "name": "price",
310
+ "type": "uint256",
311
+ "internalType": "uint256"
312
+ },
313
+ {
314
+ "name": "duration",
315
+ "type": "uint256",
316
+ "internalType": "uint256"
317
+ },
318
+ {
319
+ "name": "name",
320
+ "type": "string",
321
+ "internalType": "string"
322
+ }
323
+ ]
324
+ }
325
+ ],
326
+ "stateMutability": "view"
327
+ },
328
+ {
329
+ "type": "function",
330
+ "name": "isServiceActive",
331
+ "inputs": [
332
+ {
333
+ "name": "serviceId",
334
+ "type": "uint256",
335
+ "internalType": "uint256"
336
+ }
337
+ ],
338
+ "outputs": [
339
+ {
340
+ "name": "",
341
+ "type": "bool",
342
+ "internalType": "bool"
343
+ }
344
+ ],
345
+ "stateMutability": "view"
346
+ },
347
+ {
348
+ "type": "function",
349
+ "name": "owner",
350
+ "inputs": [],
351
+ "outputs": [
352
+ {
353
+ "name": "",
354
+ "type": "address",
355
+ "internalType": "address"
356
+ }
357
+ ],
358
+ "stateMutability": "view"
359
+ },
360
+ {
361
+ "type": "function",
362
+ "name": "pause",
363
+ "inputs": [],
364
+ "outputs": [],
365
+ "stateMutability": "nonpayable"
366
+ },
367
+ {
368
+ "type": "function",
369
+ "name": "paused",
370
+ "inputs": [],
371
+ "outputs": [
372
+ {
373
+ "name": "",
374
+ "type": "bool",
375
+ "internalType": "bool"
376
+ }
377
+ ],
378
+ "stateMutability": "view"
379
+ },
380
+ {
381
+ "type": "function",
382
+ "name": "registerService",
383
+ "inputs": [
384
+ {
385
+ "name": "name",
386
+ "type": "string",
387
+ "internalType": "string"
388
+ },
389
+ {
390
+ "name": "description",
391
+ "type": "string",
392
+ "internalType": "string"
393
+ },
394
+ {
395
+ "name": "endpoint",
396
+ "type": "string",
397
+ "internalType": "string"
398
+ },
399
+ {
400
+ "name": "category",
401
+ "type": "string",
402
+ "internalType": "string"
403
+ },
404
+ {
405
+ "name": "pricePerCall",
406
+ "type": "uint256",
407
+ "internalType": "uint256"
408
+ }
409
+ ],
410
+ "outputs": [
411
+ {
412
+ "name": "serviceId",
413
+ "type": "uint256",
414
+ "internalType": "uint256"
415
+ }
416
+ ],
417
+ "stateMutability": "nonpayable"
418
+ },
419
+ {
420
+ "type": "function",
421
+ "name": "renounceOwnership",
422
+ "inputs": [],
423
+ "outputs": [],
424
+ "stateMutability": "nonpayable"
425
+ },
426
+ {
427
+ "type": "function",
428
+ "name": "transferOwnership",
429
+ "inputs": [
430
+ {
431
+ "name": "newOwner",
432
+ "type": "address",
433
+ "internalType": "address"
434
+ }
435
+ ],
436
+ "outputs": [],
437
+ "stateMutability": "nonpayable"
438
+ },
439
+ {
440
+ "type": "function",
441
+ "name": "unpause",
442
+ "inputs": [],
443
+ "outputs": [],
444
+ "stateMutability": "nonpayable"
445
+ },
446
+ {
447
+ "type": "function",
448
+ "name": "updateService",
449
+ "inputs": [
450
+ {
451
+ "name": "serviceId",
452
+ "type": "uint256",
453
+ "internalType": "uint256"
454
+ },
455
+ {
456
+ "name": "name",
457
+ "type": "string",
458
+ "internalType": "string"
459
+ },
460
+ {
461
+ "name": "description",
462
+ "type": "string",
463
+ "internalType": "string"
464
+ },
465
+ {
466
+ "name": "endpoint",
467
+ "type": "string",
468
+ "internalType": "string"
469
+ },
470
+ {
471
+ "name": "pricePerCall",
472
+ "type": "uint256",
473
+ "internalType": "uint256"
474
+ }
475
+ ],
476
+ "outputs": [],
477
+ "stateMutability": "nonpayable"
478
+ },
479
+ {
480
+ "type": "event",
481
+ "name": "OwnershipTransferred",
482
+ "inputs": [
483
+ {
484
+ "name": "previousOwner",
485
+ "type": "address",
486
+ "indexed": true,
487
+ "internalType": "address"
488
+ },
489
+ {
490
+ "name": "newOwner",
491
+ "type": "address",
492
+ "indexed": true,
493
+ "internalType": "address"
494
+ }
495
+ ],
496
+ "anonymous": false
497
+ },
498
+ {
499
+ "type": "event",
500
+ "name": "Paused",
501
+ "inputs": [
502
+ {
503
+ "name": "account",
504
+ "type": "address",
505
+ "indexed": false,
506
+ "internalType": "address"
507
+ }
508
+ ],
509
+ "anonymous": false
510
+ },
511
+ {
512
+ "type": "event",
513
+ "name": "ServiceActivated",
514
+ "inputs": [
515
+ {
516
+ "name": "serviceId",
517
+ "type": "uint256",
518
+ "indexed": true,
519
+ "internalType": "uint256"
520
+ }
521
+ ],
522
+ "anonymous": false
523
+ },
524
+ {
525
+ "type": "event",
526
+ "name": "ServiceDeactivated",
527
+ "inputs": [
528
+ {
529
+ "name": "serviceId",
530
+ "type": "uint256",
531
+ "indexed": true,
532
+ "internalType": "uint256"
533
+ }
534
+ ],
535
+ "anonymous": false
536
+ },
537
+ {
538
+ "type": "event",
539
+ "name": "ServiceRegistered",
540
+ "inputs": [
541
+ {
542
+ "name": "serviceId",
543
+ "type": "uint256",
544
+ "indexed": true,
545
+ "internalType": "uint256"
546
+ },
547
+ {
548
+ "name": "provider",
549
+ "type": "address",
550
+ "indexed": true,
551
+ "internalType": "address"
552
+ },
553
+ {
554
+ "name": "name",
555
+ "type": "string",
556
+ "indexed": false,
557
+ "internalType": "string"
558
+ },
559
+ {
560
+ "name": "pricePerCall",
561
+ "type": "uint256",
562
+ "indexed": false,
563
+ "internalType": "uint256"
564
+ }
565
+ ],
566
+ "anonymous": false
567
+ },
568
+ {
569
+ "type": "event",
570
+ "name": "ServiceUpdated",
571
+ "inputs": [
572
+ {
573
+ "name": "serviceId",
574
+ "type": "uint256",
575
+ "indexed": true,
576
+ "internalType": "uint256"
577
+ }
578
+ ],
579
+ "anonymous": false
580
+ },
581
+ {
582
+ "type": "event",
583
+ "name": "SubscriptionPlanAdded",
584
+ "inputs": [
585
+ {
586
+ "name": "serviceId",
587
+ "type": "uint256",
588
+ "indexed": true,
589
+ "internalType": "uint256"
590
+ },
591
+ {
592
+ "name": "planId",
593
+ "type": "uint256",
594
+ "indexed": true,
595
+ "internalType": "uint256"
596
+ },
597
+ {
598
+ "name": "name",
599
+ "type": "string",
600
+ "indexed": false,
601
+ "internalType": "string"
602
+ },
603
+ {
604
+ "name": "price",
605
+ "type": "uint256",
606
+ "indexed": false,
607
+ "internalType": "uint256"
608
+ },
609
+ {
610
+ "name": "duration",
611
+ "type": "uint256",
612
+ "indexed": false,
613
+ "internalType": "uint256"
614
+ }
615
+ ],
616
+ "anonymous": false
617
+ },
618
+ {
619
+ "type": "event",
620
+ "name": "Unpaused",
621
+ "inputs": [
622
+ {
623
+ "name": "account",
624
+ "type": "address",
625
+ "indexed": false,
626
+ "internalType": "address"
627
+ }
628
+ ],
629
+ "anonymous": false
630
+ },
631
+ {
632
+ "type": "error",
633
+ "name": "EnforcedPause",
634
+ "inputs": []
635
+ },
636
+ {
637
+ "type": "error",
638
+ "name": "ExpectedPause",
639
+ "inputs": []
640
+ },
641
+ {
642
+ "type": "error",
643
+ "name": "InvalidEndpoint",
644
+ "inputs": []
645
+ },
646
+ {
647
+ "type": "error",
648
+ "name": "InvalidPrice",
649
+ "inputs": []
650
+ },
651
+ {
652
+ "type": "error",
653
+ "name": "InvalidServiceName",
654
+ "inputs": []
655
+ },
656
+ {
657
+ "type": "error",
658
+ "name": "NotServiceProvider",
659
+ "inputs": [
660
+ {
661
+ "name": "serviceId",
662
+ "type": "uint256",
663
+ "internalType": "uint256"
664
+ },
665
+ {
666
+ "name": "caller",
667
+ "type": "address",
668
+ "internalType": "address"
669
+ }
670
+ ]
671
+ },
672
+ {
673
+ "type": "error",
674
+ "name": "OwnableInvalidOwner",
675
+ "inputs": [
676
+ {
677
+ "name": "owner",
678
+ "type": "address",
679
+ "internalType": "address"
680
+ }
681
+ ]
682
+ },
683
+ {
684
+ "type": "error",
685
+ "name": "OwnableUnauthorizedAccount",
686
+ "inputs": [
687
+ {
688
+ "name": "account",
689
+ "type": "address",
690
+ "internalType": "address"
691
+ }
692
+ ]
693
+ },
694
+ {
695
+ "type": "error",
696
+ "name": "PlanNotFound",
697
+ "inputs": [
698
+ {
699
+ "name": "serviceId",
700
+ "type": "uint256",
701
+ "internalType": "uint256"
702
+ },
703
+ {
704
+ "name": "planId",
705
+ "type": "uint256",
706
+ "internalType": "uint256"
707
+ }
708
+ ]
709
+ },
710
+ {
711
+ "type": "error",
712
+ "name": "ReentrancyGuardReentrantCall",
713
+ "inputs": []
714
+ },
715
+ {
716
+ "type": "error",
717
+ "name": "ServiceAlreadyActive",
718
+ "inputs": [
719
+ {
720
+ "name": "serviceId",
721
+ "type": "uint256",
722
+ "internalType": "uint256"
723
+ }
724
+ ]
725
+ },
726
+ {
727
+ "type": "error",
728
+ "name": "ServiceAlreadyInactive",
729
+ "inputs": [
730
+ {
731
+ "name": "serviceId",
732
+ "type": "uint256",
733
+ "internalType": "uint256"
734
+ }
735
+ ]
736
+ },
737
+ {
738
+ "type": "error",
739
+ "name": "ServiceNotFound",
740
+ "inputs": [
741
+ {
742
+ "name": "serviceId",
743
+ "type": "uint256",
744
+ "internalType": "uint256"
745
+ }
746
+ ]
747
+ }
748
+ ]