@alephium/web3 1.0.2-rc.2 → 1.0.2

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.
@@ -9,57 +9,40 @@
9
9
  * ---------------------------------------------------------------
10
10
  */
11
11
 
12
- /** Val */
13
- export type Val = ValAddress | ValArray | ValBool | ValByteVec | ValI256 | ValU256
14
-
15
- /** ContractOutput */
16
- export interface ContractOutput {
17
- /** @format address */
18
- address: string
19
- /** @format int32 */
20
- hint: number
12
+ export interface AcceptedTransaction {
21
13
  /** @format 32-byte-hash */
22
- spent?: string
14
+ hash: string
15
+ /** @format block-hash */
16
+ blockHash: string
17
+ /** @format int64 */
18
+ timestamp: number
19
+ inputs?: Input[]
20
+ outputs?: Output[]
21
+ /** @format int32 */
22
+ gasAmount: number
23
23
  /** @format uint256 */
24
- attoAlphAmount: string
25
- tokens?: Token[]
26
- fixedOutput: boolean
24
+ gasPrice: string
25
+ scriptExecutionOk: boolean
26
+ coinbase: boolean
27
27
  type: string
28
- /** @format 32-byte-hash */
29
- key: string
30
- }
31
-
32
- /** IntervalType */
33
- export enum IntervalType {
34
- Daily = 'daily',
35
- Hourly = 'hourly',
36
- Weekly = 'weekly'
37
28
  }
38
29
 
39
- /** Token */
40
- export interface Token {
30
+ export interface AddressBalance {
41
31
  /** @format uint256 */
42
- amount: string
43
- /** @format 32-byte-hash */
44
- id: string
45
- }
46
-
47
- /** ContractLivenessLocation */
48
- export interface ContractLivenessLocation {
49
- /** @format block-hash */
50
- blockHash: string
51
- /** @format 32-byte-hash */
52
- txHash: string
53
- /** @format int64 */
54
- timestamp: number
32
+ balance: string
33
+ /** @format uint256 */
34
+ lockedBalance: string
55
35
  }
56
36
 
57
- /** NonStandard */
58
- export interface NonStandard {
59
- type: string
37
+ export interface AddressInfo {
38
+ /** @format uint256 */
39
+ balance: string
40
+ /** @format uint256 */
41
+ lockedBalance: string
42
+ /** @format int32 */
43
+ txNumber: number
60
44
  }
61
45
 
62
- /** AddressTokenBalance */
63
46
  export interface AddressTokenBalance {
64
47
  /** @format 32-byte-hash */
65
48
  tokenId: string
@@ -69,532 +52,421 @@ export interface AddressTokenBalance {
69
52
  lockedBalance: string
70
53
  }
71
54
 
72
- /** OutputRef */
73
- export interface OutputRef {
55
+ export interface AmountHistory {
56
+ amountHistory?: TimedAmount[]
57
+ }
58
+
59
+ export interface AssetOutput {
74
60
  /** @format int32 */
75
61
  hint: number
76
62
  /** @format 32-byte-hash */
77
63
  key: string
78
- }
79
-
80
- /** Input */
81
- export interface Input {
82
- /** @format address */
83
- address?: string
84
- contractInput: boolean
85
- /** @format hex-string */
86
- unlockScript?: string
87
64
  /** @format uint256 */
88
- attoAlphAmount?: string
65
+ attoAlphAmount: string
66
+ /** @format address */
67
+ address: string
89
68
  tokens?: Token[]
90
- /** @format 32-byte-hash */
91
- txHashRef?: string
92
- outputRef: OutputRef
93
- }
94
-
95
- /** PerChainCount */
96
- export interface PerChainCount {
97
- /** @format int32 */
98
- chainFrom: number
99
- /** @format int32 */
100
- chainTo: number
101
69
  /** @format int64 */
102
- count: number
70
+ lockTime?: number
71
+ /** @format hex-string */
72
+ message?: string
73
+ /** @format 32-byte-hash */
74
+ spent?: string
75
+ type: string
103
76
  }
104
77
 
105
- /** Unknown */
106
- export interface Unknown {
107
- id: string
108
- type: string
78
+ export interface BadRequest {
79
+ detail: string
109
80
  }
110
81
 
111
- /** BlockEntry */
112
- export interface BlockEntry {
82
+ export interface BlockEntryLite {
113
83
  /** @format block-hash */
114
- parent?: string
84
+ hash: string
85
+ /** @format int64 */
86
+ timestamp: number
115
87
  /** @format group-index */
116
88
  chainFrom: number
117
- /** @format 32-byte-hash */
118
- depStateHash: string
119
- deps?: string[]
120
- /** @format hex-string */
121
- nonce: string
122
- version: number
123
- /** @format hex-string */
124
- target: string
125
- mainChain: boolean
126
- /** @format 32-byte-hash */
127
- txsHash: string
128
89
  /** @format group-index */
129
90
  chainTo: number
130
- ghostUncles?: GhostUncle[]
131
- /** @format bigint */
132
- hashRate: string
133
- /** @format int32 */
134
- txNumber: number
135
- /** @format block-hash */
136
- hash: string
137
91
  /** @format int32 */
138
92
  height: number
139
- /** @format int64 */
140
- timestamp: number
141
- }
142
-
143
- /** ContractParent */
144
- export interface ContractParent {
145
- /** @format address */
146
- parent?: string
147
- }
148
-
149
- /** ServiceUnavailable */
150
- export interface ServiceUnavailable {
151
- detail: string
152
- }
153
-
154
- /** ValI256 */
155
- export interface ValI256 {
156
- type: string
93
+ /** @format int32 */
94
+ txNumber: number
95
+ mainChain: boolean
157
96
  /** @format bigint */
158
- value: string
97
+ hashRate: string
159
98
  }
160
99
 
161
- /** ContractLiveness */
162
100
  export interface ContractLiveness {
163
101
  /** @format address */
164
102
  parent?: string
165
- interfaceId?: StdInterfaceId
166
- destruction?: ContractLivenessLocation
167
103
  creation: ContractLivenessLocation
104
+ destruction?: ContractLivenessLocation
105
+ interfaceId?: StdInterfaceId
168
106
  }
169
107
 
170
- /** AssetOutput */
171
- export interface AssetOutput {
172
- /** @format address */
173
- address: string
108
+ export interface ContractLivenessLocation {
109
+ /** @format block-hash */
110
+ blockHash: string
111
+ /** @format 32-byte-hash */
112
+ txHash: string
174
113
  /** @format int64 */
175
- lockTime?: number
114
+ timestamp: number
115
+ }
116
+
117
+ export interface ContractOutput {
176
118
  /** @format int32 */
177
119
  hint: number
178
120
  /** @format 32-byte-hash */
179
- spent?: string
121
+ key: string
180
122
  /** @format uint256 */
181
123
  attoAlphAmount: string
124
+ /** @format address */
125
+ address: string
182
126
  tokens?: Token[]
183
- fixedOutput: boolean
184
- type: string
185
- /** @format hex-string */
186
- message?: string
187
127
  /** @format 32-byte-hash */
188
- key: string
128
+ spent?: string
129
+ type: string
189
130
  }
190
131
 
191
- /** NFT */
192
- export interface NFT {
193
- type: string
132
+ export interface ContractParent {
133
+ /** @format address */
134
+ parent?: string
194
135
  }
195
136
 
196
- /** AcceptedTransaction */
197
- export interface AcceptedTransaction {
198
- outputs?: Output[]
137
+ export interface Event {
199
138
  /** @format block-hash */
200
139
  blockHash: string
201
- scriptSignatures?: string[]
202
- inputs?: Input[]
203
- scriptExecutionOk: boolean
204
- type: string
205
- scriptOpt?: string
206
- version: number
207
- coinbase: boolean
208
- inputSignatures?: string[]
209
- /** @format int32 */
210
- gasAmount: number
211
- networkId: number
212
140
  /** @format 32-byte-hash */
213
- hash: string
214
- /** @format uint256 */
215
- gasPrice: string
141
+ txHash: string
142
+ /** @format address */
143
+ contractAddress: string
144
+ /** @format address */
145
+ inputAddress?: string
146
+ /** @format int32 */
147
+ eventIndex: number
148
+ fields?: Val[]
149
+ }
150
+
151
+ export interface ExplorerInfo {
152
+ releaseVersion: string
153
+ commit: string
154
+ /** @format int32 */
155
+ migrationsVersion: number
216
156
  /** @format int64 */
217
- timestamp: number
157
+ lastFinalizedInputTime: number
218
158
  }
219
159
 
220
- /** TokenSupply */
221
- export interface TokenSupply {
222
- /** @format uint256 */
223
- circulating: string
224
- /** @format uint256 */
225
- total: string
226
- /** @format uint256 */
227
- reserved: string
228
- /** @format uint256 */
229
- maximum: string
160
+ export interface FungibleToken {
161
+ type: string
162
+ }
163
+
164
+ export interface FungibleTokenMetadata {
165
+ /** @format 32-byte-hash */
166
+ id: string
167
+ symbol: string
168
+ name: string
230
169
  /** @format uint256 */
231
- locked: string
170
+ decimals: string
171
+ }
172
+
173
+ export interface Hashrate {
232
174
  /** @format int64 */
233
175
  timestamp: number
176
+ hashrate: number
177
+ value: number
234
178
  }
235
179
 
236
- /** PendingTransaction */
237
- export interface PendingTransaction {
238
- outputs?: Output[]
239
- /** @format group-index */
240
- chainFrom: number
241
- /** @format int64 */
242
- lastSeen: number
243
- /** @format group-index */
244
- chainTo: number
245
- inputs?: Input[]
246
- /** @format int32 */
247
- gasAmount: number
248
- type: string
180
+ export interface Input {
181
+ outputRef: OutputRef
182
+ /** @format hex-string */
183
+ unlockScript?: string
249
184
  /** @format 32-byte-hash */
250
- hash: string
185
+ txHashRef?: string
186
+ /** @format address */
187
+ address?: string
251
188
  /** @format uint256 */
252
- gasPrice: string
189
+ attoAlphAmount?: string
190
+ tokens?: Token[]
253
191
  }
254
192
 
255
- /** TransactionLike */
256
- export type TransactionLike = AcceptedTransaction | PendingTransaction
193
+ export interface InternalServerError {
194
+ detail: string
195
+ }
257
196
 
258
- /** LogbackValue */
259
- export interface LogbackValue {
260
- level: string
261
- name: string
197
+ export enum IntervalType {
198
+ Daily = 'daily',
199
+ Hourly = 'hourly',
200
+ Weekly = 'weekly'
262
201
  }
263
202
 
264
- /** ValU256 */
265
- export interface ValU256 {
266
- type: string
267
- /** @format uint256 */
268
- value: string
203
+ export interface ListBlocks {
204
+ /** @format int32 */
205
+ total: number
206
+ blocks?: BlockEntryLite[]
269
207
  }
270
208
 
271
- /** BlockEntryLite */
272
- export interface BlockEntryLite {
273
- mainChain: boolean
209
+ export interface LogbackValue {
210
+ name: string
211
+ level: string
212
+ }
213
+
214
+ export interface MempoolTransaction {
215
+ /** @format 32-byte-hash */
216
+ hash: string
274
217
  /** @format group-index */
275
218
  chainFrom: number
276
219
  /** @format group-index */
277
220
  chainTo: number
278
- /** @format bigint */
279
- hashRate: string
280
- /** @format int32 */
281
- txNumber: number
282
- /** @format block-hash */
283
- hash: string
221
+ inputs?: Input[]
222
+ outputs?: Output[]
284
223
  /** @format int32 */
285
- height: number
224
+ gasAmount: number
225
+ /** @format uint256 */
226
+ gasPrice: string
286
227
  /** @format int64 */
287
- timestamp: number
228
+ lastSeen: number
288
229
  }
289
230
 
290
- /** PerChainHeight */
291
- export interface PerChainHeight {
292
- /** @format int32 */
293
- chainFrom: number
294
- /** @format int32 */
295
- chainTo: number
296
- /** @format int64 */
297
- value: number
298
- /** @format int64 */
299
- height: number
231
+ export interface NFT {
232
+ type: string
300
233
  }
301
234
 
302
- /** ValByteVec */
303
- export interface ValByteVec {
235
+ export interface NFTCollection {
304
236
  type: string
305
- /** @format hex-string */
306
- value: string
307
237
  }
308
238
 
309
- /** TokenStdInterfaceId */
310
- export enum TokenStdInterfaceId {
311
- Fungible = 'fungible',
312
- NonFungible = 'non-fungible',
313
- NonStandard = 'non-standard'
239
+ export interface NFTCollectionMetadata {
240
+ /** @format address */
241
+ address: string
242
+ collectionUri: string
314
243
  }
315
244
 
316
- /** ExplorerInfo */
317
- export interface ExplorerInfo {
318
- releaseVersion: string
319
- commit: string
320
- /** @format int32 */
321
- migrationsVersion: number
322
- /** @format int64 */
323
- lastFinalizedInputTime: number
245
+ export interface NFTCollectionWithRoyalty {
246
+ type: string
324
247
  }
325
248
 
326
- /** ValArray */
327
- export interface ValArray {
249
+ export interface NFTMetadata {
250
+ /** @format 32-byte-hash */
251
+ id: string
252
+ tokenUri: string
253
+ /** @format 32-byte-hash */
254
+ collectionId: string
255
+ /** @format uint256 */
256
+ nftIndex: string
257
+ }
258
+
259
+ export interface NonStandard {
328
260
  type: string
329
- value: Val[]
330
261
  }
331
262
 
332
- /** BadRequest */
333
- export interface BadRequest {
263
+ export interface NotFound {
334
264
  detail: string
265
+ resource: string
335
266
  }
336
267
 
337
- /** Hashrate */
338
- export interface Hashrate {
339
- hashrate: number
340
- value: number
341
- /** @format int64 */
342
- timestamp: number
268
+ export type Output = AssetOutput | ContractOutput
269
+
270
+ export interface OutputRef {
271
+ /** @format int32 */
272
+ hint: number
273
+ /** @format 32-byte-hash */
274
+ key: string
343
275
  }
344
276
 
345
- /** Transaction */
346
- export interface Transaction {
347
- outputs?: Output[]
348
- /** @format block-hash */
349
- blockHash: string
350
- scriptSignatures?: string[]
277
+ export interface PendingTransaction {
278
+ /** @format 32-byte-hash */
279
+ hash: string
280
+ /** @format group-index */
281
+ chainFrom: number
282
+ /** @format group-index */
283
+ chainTo: number
351
284
  inputs?: Input[]
352
- scriptExecutionOk: boolean
353
- scriptOpt?: string
354
- version: number
355
- coinbase: boolean
356
- inputSignatures?: string[]
285
+ outputs?: Output[]
357
286
  /** @format int32 */
358
287
  gasAmount: number
359
- networkId: number
360
- /** @format 32-byte-hash */
361
- hash: string
362
288
  /** @format uint256 */
363
289
  gasPrice: string
364
290
  /** @format int64 */
365
- timestamp: number
291
+ lastSeen: number
292
+ type: string
366
293
  }
367
294
 
368
- /** FungibleToken */
369
- export interface FungibleToken {
370
- type: string
295
+ export interface PerChainCount {
296
+ /** @format int32 */
297
+ chainFrom: number
298
+ /** @format int32 */
299
+ chainTo: number
300
+ /** @format int64 */
301
+ count: number
371
302
  }
372
303
 
373
- /** GhostUncle */
374
- export interface GhostUncle {
375
- /** @format block-hash */
376
- blockHash: string
377
- /** @format address */
378
- miner: string
304
+ export interface PerChainDuration {
305
+ /** @format int32 */
306
+ chainFrom: number
307
+ /** @format int32 */
308
+ chainTo: number
309
+ /** @format int64 */
310
+ duration: number
311
+ /** @format int64 */
312
+ value: number
379
313
  }
380
314
 
381
- /** NFTCollectionWithRoyalty */
382
- export interface NFTCollectionWithRoyalty {
383
- type: string
315
+ export interface PerChainHeight {
316
+ /** @format int32 */
317
+ chainFrom: number
318
+ /** @format int32 */
319
+ chainTo: number
320
+ /** @format int64 */
321
+ height: number
322
+ /** @format int64 */
323
+ value: number
384
324
  }
385
325
 
386
- /** PerChainTimedCount */
387
326
  export interface PerChainTimedCount {
388
- totalCountPerChain?: PerChainCount[]
389
327
  /** @format int64 */
390
328
  timestamp: number
329
+ totalCountPerChain?: PerChainCount[]
391
330
  }
392
331
 
393
- /** MempoolTransaction */
394
- export interface MempoolTransaction {
395
- outputs?: Output[]
396
- /** @format group-index */
397
- chainFrom: number
398
- /** @format int64 */
399
- lastSeen: number
400
- /** @format group-index */
401
- chainTo: number
402
- inputs?: Input[]
403
- /** @format int32 */
404
- gasAmount: number
405
- /** @format 32-byte-hash */
406
- hash: string
407
- /** @format uint256 */
408
- gasPrice: string
332
+ export interface ServiceUnavailable {
333
+ detail: string
409
334
  }
410
335
 
411
- export enum TokensWithPrice {
412
- WETH = 'WETH',
413
- ALPH = 'ALPH',
414
- USDT = 'USDT',
415
- AYIN = 'AYIN',
416
- DAI = 'DAI',
417
- USDC = 'USDC',
418
- WBTC = 'WBTC'
336
+ export type StdInterfaceId = FungibleToken | NFT | NFTCollection | NFTCollectionWithRoyalty | NonStandard | Unknown
337
+
338
+ export interface SubContracts {
339
+ subContracts?: string[]
419
340
  }
420
341
 
421
- export enum MaxSizeTokens {
422
- Value80 = 80
342
+ export interface TimedAmount {
343
+ /** @format int64 */
344
+ timestamp: number
345
+ /** @format bigint */
346
+ amount: string
423
347
  }
424
348
 
425
- /** NFTCollection */
426
- export interface NFTCollection {
427
- type: string
349
+ export interface TimedCount {
350
+ /** @format int64 */
351
+ timestamp: number
352
+ /** @format int64 */
353
+ totalCountAllChains: number
428
354
  }
429
355
 
430
- export enum MaxSizeAddressesForTokens {
431
- Value80 = 80
356
+ export interface TimedPrices {
357
+ timestamps?: number[]
358
+ prices?: number[]
432
359
  }
433
360
 
434
- /** InternalServerError */
435
- export interface InternalServerError {
436
- detail: string
361
+ export interface Token {
362
+ /** @format 32-byte-hash */
363
+ id: string
364
+ /** @format uint256 */
365
+ amount: string
366
+ }
367
+
368
+ export interface TokenInfo {
369
+ /** @format 32-byte-hash */
370
+ token: string
371
+ /** Raw interface id, e.g. 0001 */
372
+ stdInterfaceId?: TokenStdInterfaceId | string
437
373
  }
438
374
 
439
- /** TimedPrices */
440
- export interface TimedPrices {
441
- timestamps?: number[]
442
- prices?: number[]
375
+ export enum TokenStdInterfaceId {
376
+ Fungible = 'fungible',
377
+ NonFungible = 'non-fungible',
378
+ NonStandard = 'non-standard'
443
379
  }
444
380
 
445
- /** TimedCount */
446
- export interface TimedCount {
447
- /** @format int64 */
448
- totalCountAllChains: number
381
+ export interface TokenSupply {
449
382
  /** @format int64 */
450
383
  timestamp: number
451
- }
452
-
453
- /** NFTMetadata */
454
- export interface NFTMetadata {
455
384
  /** @format uint256 */
456
- nftIndex: string
457
- tokenUri: string
458
- /** @format 32-byte-hash */
459
- id: string
460
- /** @format 32-byte-hash */
461
- collectionId: string
385
+ total: string
386
+ /** @format uint256 */
387
+ circulating: string
388
+ /** @format uint256 */
389
+ reserved: string
390
+ /** @format uint256 */
391
+ locked: string
392
+ /** @format uint256 */
393
+ maximum: string
462
394
  }
463
395
 
464
- /** PerChainDuration */
465
- export interface PerChainDuration {
396
+ export interface Transaction {
397
+ /** @format 32-byte-hash */
398
+ hash: string
399
+ /** @format block-hash */
400
+ blockHash: string
466
401
  /** @format int64 */
467
- duration: number
468
- /** @format int32 */
469
- chainFrom: number
402
+ timestamp: number
403
+ inputs?: Input[]
404
+ outputs?: Output[]
470
405
  /** @format int32 */
471
- chainTo: number
472
- /** @format int64 */
473
- value: number
406
+ gasAmount: number
407
+ /** @format uint256 */
408
+ gasPrice: string
409
+ scriptExecutionOk: boolean
410
+ coinbase: boolean
474
411
  }
475
412
 
476
- /** StdInterfaceId */
477
- export type StdInterfaceId = FungibleToken | NFT | NFTCollection | NFTCollectionWithRoyalty | NonStandard | Unknown
478
-
479
- /** Output */
480
- export type Output = AssetOutput | ContractOutput
413
+ export type TransactionLike = AcceptedTransaction | PendingTransaction
481
414
 
482
- /** Unauthorized */
483
415
  export interface Unauthorized {
484
416
  detail: string
485
417
  }
486
418
 
487
- /** NFTCollectionMetadata */
488
- export interface NFTCollectionMetadata {
489
- collectionUri: string
490
- /** @format address */
491
- address: string
419
+ export interface Unknown {
420
+ id: string
421
+ type: string
492
422
  }
493
423
 
494
- /** ValAddress */
424
+ export type Val = ValAddress | ValArray | ValBool | ValByteVec | ValI256 | ValU256
425
+
495
426
  export interface ValAddress {
496
- type: string
497
427
  /** @format address */
498
428
  value: string
499
- }
500
-
501
- /** ValBool */
502
- export interface ValBool {
503
429
  type: string
504
- value: boolean
505
430
  }
506
431
 
507
- /** FungibleTokenMetadata */
508
- export interface FungibleTokenMetadata {
509
- symbol: string
510
- /** @format uint256 */
511
- decimals: string
512
- name: string
513
- /** @format 32-byte-hash */
514
- id: string
432
+ export interface ValArray {
433
+ value: Val[]
434
+ type: string
515
435
  }
516
436
 
517
- export enum MaxSizeAddresses {
518
- Value80 = 80
437
+ export interface ValBool {
438
+ value: boolean
439
+ type: string
519
440
  }
520
441
 
521
- export enum Currencies {
522
- Btc = 'btc',
523
- Eth = 'eth',
524
- Usd = 'usd',
525
- Eur = 'eur',
526
- Chf = 'chf',
527
- Gbp = 'gbp',
528
- Idr = 'idr',
529
- Vnd = 'vnd',
530
- Rub = 'rub',
531
- Try = 'try',
532
- Cad = 'cad',
533
- Aud = 'aud'
442
+ export interface ValByteVec {
443
+ /** @format hex-string */
444
+ value: string
445
+ type: string
534
446
  }
535
447
 
536
- /** AddressInfo */
537
- export interface AddressInfo {
538
- /** @format uint256 */
539
- balance: string
540
- /** @format uint256 */
541
- lockedBalance: string
542
- /** @format int32 */
543
- txNumber: number
448
+ export interface ValI256 {
449
+ /** @format bigint */
450
+ value: string
451
+ type: string
544
452
  }
545
453
 
546
- /** AddressBalance */
547
- export interface AddressBalance {
548
- /** @format uint256 */
549
- balance: string
454
+ export interface ValU256 {
550
455
  /** @format uint256 */
551
- lockedBalance: string
552
- }
553
-
554
- /** AmountHistory */
555
- export interface AmountHistory {
556
- amountHistory?: string[][]
557
- }
558
-
559
- /** Event */
560
- export interface Event {
561
- /** @format block-hash */
562
- blockHash: string
563
- /** @format address */
564
- inputAddress?: string
565
- /** @format address */
566
- contractAddress: string
567
- /** @format int32 */
568
- eventIndex: number
569
- fields?: Val[]
570
- /** @format 32-byte-hash */
571
- txHash: string
572
- }
573
-
574
- /** ListBlocks */
575
- export interface ListBlocks {
576
- /** @format int32 */
577
- total: number
578
- blocks?: BlockEntryLite[]
456
+ value: string
457
+ type: string
579
458
  }
580
459
 
581
- /** SubContracts */
582
- export interface SubContracts {
583
- subContracts?: string[]
460
+ export enum MaxSizeTokens {
461
+ Value80 = 80
584
462
  }
585
463
 
586
- /** TokenInfo */
587
- export interface TokenInfo {
588
- /** Raw interface id, e.g. 0001 */
589
- stdInterfaceId?: TokenStdInterfaceId | string
590
- /** @format 32-byte-hash */
591
- token: string
464
+ export enum MaxSizeAddressesForTokens {
465
+ Value80 = 80
592
466
  }
593
467
 
594
- /** NotFound */
595
- export interface NotFound {
596
- resource: string
597
- detail: string
468
+ export enum MaxSizeAddresses {
469
+ Value80 = 80
598
470
  }
599
471
 
600
472
  import 'cross-fetch/polyfill'
@@ -814,35 +686,142 @@ export class HttpClient<SecurityDataType = unknown> {
814
686
  * @version 1.0
815
687
  */
816
688
  export class Api<SecurityDataType extends unknown> extends HttpClient<SecurityDataType> {
817
- contracts = {
689
+ blocks = {
690
+ /**
691
+ * @description List latest blocks
692
+ *
693
+ * @tags Blocks
694
+ * @name GetBlocks
695
+ * @request GET:/blocks
696
+ */
697
+ getBlocks: (
698
+ query?: {
699
+ /**
700
+ * Page number
701
+ * @format int32
702
+ */
703
+ page?: number
704
+ /**
705
+ * Number of items per page
706
+ * @format int32
707
+ */
708
+ limit?: number
709
+ /** Reverse pagination */
710
+ reverse?: boolean
711
+ },
712
+ params: RequestParams = {}
713
+ ) =>
714
+ this.request<ListBlocks, BadRequest | Unauthorized | NotFound | InternalServerError | ServiceUnavailable>({
715
+ path: `/blocks`,
716
+ method: 'GET',
717
+ query: query,
718
+ format: 'json',
719
+ ...params
720
+ }).then(convertHttpResponse),
721
+
722
+ /**
723
+ * @description Get a block with hash
724
+ *
725
+ * @tags Blocks
726
+ * @name GetBlocksBlockHash
727
+ * @request GET:/blocks/{block_hash}
728
+ */
729
+ getBlocksBlockHash: (blockHash: string, params: RequestParams = {}) =>
730
+ this.request<BlockEntryLite, BadRequest | Unauthorized | NotFound | InternalServerError | ServiceUnavailable>({
731
+ path: `/blocks/${blockHash}`,
732
+ method: 'GET',
733
+ format: 'json',
734
+ ...params
735
+ }).then(convertHttpResponse),
736
+
737
+ /**
738
+ * @description Get block's transactions
739
+ *
740
+ * @tags Blocks
741
+ * @name GetBlocksBlockHashTransactions
742
+ * @request GET:/blocks/{block_hash}/transactions
743
+ */
744
+ getBlocksBlockHashTransactions: (
745
+ blockHash: string,
746
+ query?: {
747
+ /**
748
+ * Page number
749
+ * @format int32
750
+ */
751
+ page?: number
752
+ /**
753
+ * Number of items per page
754
+ * @format int32
755
+ */
756
+ limit?: number
757
+ },
758
+ params: RequestParams = {}
759
+ ) =>
760
+ this.request<Transaction[], BadRequest | Unauthorized | NotFound | InternalServerError | ServiceUnavailable>({
761
+ path: `/blocks/${blockHash}/transactions`,
762
+ method: 'GET',
763
+ query: query,
764
+ format: 'json',
765
+ ...params
766
+ }).then(convertHttpResponse)
767
+ }
768
+ transactions = {
769
+ /**
770
+ * @description Get a transaction with hash
771
+ *
772
+ * @tags Transactions
773
+ * @name GetTransactionsTransactionHash
774
+ * @request GET:/transactions/{transaction_hash}
775
+ */
776
+ getTransactionsTransactionHash: (transactionHash: string, params: RequestParams = {}) =>
777
+ this.request<TransactionLike, BadRequest | Unauthorized | NotFound | InternalServerError | ServiceUnavailable>({
778
+ path: `/transactions/${transactionHash}`,
779
+ method: 'GET',
780
+ format: 'json',
781
+ ...params
782
+ }).then(convertHttpResponse)
783
+ }
784
+ addresses = {
785
+ /**
786
+ * @description Get address information
787
+ *
788
+ * @tags Addresses
789
+ * @name GetAddressesAddress
790
+ * @request GET:/addresses/{address}
791
+ */
792
+ getAddressesAddress: (address: string, params: RequestParams = {}) =>
793
+ this.request<AddressInfo, BadRequest | Unauthorized | NotFound | InternalServerError | ServiceUnavailable>({
794
+ path: `/addresses/${address}`,
795
+ method: 'GET',
796
+ format: 'json',
797
+ ...params
798
+ }).then(convertHttpResponse),
799
+
818
800
  /**
819
- * @description Get sub contract addresses
801
+ * @description List transactions of a given address
820
802
  *
821
- * @tags Contracts
822
- * @name GetContractsContractAddressSubContracts
823
- * @request GET:/contracts/{contract_address}/sub-contracts
803
+ * @tags Addresses
804
+ * @name GetAddressesAddressTransactions
805
+ * @request GET:/addresses/{address}/transactions
824
806
  */
825
- getContractsContractAddressSubContracts: (
826
- contractAddress: string,
807
+ getAddressesAddressTransactions: (
808
+ address: string,
827
809
  query?: {
828
810
  /**
829
811
  * Page number
830
812
  * @format int32
831
- * @min 1
832
813
  */
833
814
  page?: number
834
815
  /**
835
816
  * Number of items per page
836
817
  * @format int32
837
- * @min 0
838
- * @max 100
839
818
  */
840
819
  limit?: number
841
820
  },
842
821
  params: RequestParams = {}
843
822
  ) =>
844
- this.request<SubContracts, BadRequest | Unauthorized | NotFound | InternalServerError | ServiceUnavailable>({
845
- path: `/contracts/${contractAddress}/sub-contracts`,
823
+ this.request<Transaction[], BadRequest | Unauthorized | NotFound | InternalServerError | ServiceUnavailable>({
824
+ path: `/addresses/${address}/transactions`,
846
825
  method: 'GET',
847
826
  query: query,
848
827
  format: 'json',
@@ -850,47 +829,32 @@ export class Api<SecurityDataType extends unknown> extends HttpClient<SecurityDa
850
829
  }).then(convertHttpResponse),
851
830
 
852
831
  /**
853
- * @description Get contract liveness
854
- *
855
- * @tags Contracts
856
- * @name GetContractsContractAddressCurrentLiveness
857
- * @request GET:/contracts/{contract_address}/current-liveness
858
- */
859
- getContractsContractAddressCurrentLiveness: (contractAddress: string, params: RequestParams = {}) =>
860
- this.request<ContractLiveness, BadRequest | Unauthorized | NotFound | InternalServerError | ServiceUnavailable>({
861
- path: `/contracts/${contractAddress}/current-liveness`,
862
- method: 'GET',
863
- format: 'json',
864
- ...params
865
- }).then(convertHttpResponse),
866
-
867
- /**
868
- * @description Get contract parent address if exist
869
- *
870
- * @tags Contracts
871
- * @name GetContractsContractAddressParent
872
- * @request GET:/contracts/{contract_address}/parent
873
- */
874
- getContractsContractAddressParent: (contractAddress: string, params: RequestParams = {}) =>
875
- this.request<ContractParent, BadRequest | Unauthorized | NotFound | InternalServerError | ServiceUnavailable>({
876
- path: `/contracts/${contractAddress}/parent`,
877
- method: 'GET',
878
- format: 'json',
879
- ...params
880
- }).then(convertHttpResponse)
881
- }
882
- addresses = {
883
- /**
884
- * @description Are the addresses used (at least 1 transaction)
832
+ * @description List transactions for given addresses
885
833
  *
886
- * @tags Addresses, Addresses
887
- * @name PostAddressesUsed
888
- * @request POST:/addresses/used
834
+ * @tags Addresses
835
+ * @name PostAddressesTransactions
836
+ * @request POST:/addresses/transactions
889
837
  */
890
- postAddressesUsed: (data?: string[], params: RequestParams = {}) =>
891
- this.request<boolean[], BadRequest | Unauthorized | NotFound | InternalServerError | ServiceUnavailable>({
892
- path: `/addresses/used`,
838
+ postAddressesTransactions: (
839
+ query?: {
840
+ /**
841
+ * Page number
842
+ * @format int32
843
+ */
844
+ page?: number
845
+ /**
846
+ * Number of items per page
847
+ * @format int32
848
+ */
849
+ limit?: number
850
+ },
851
+ data?: string[],
852
+ params: RequestParams = {}
853
+ ) =>
854
+ this.request<Transaction[], BadRequest | Unauthorized | NotFound | InternalServerError | ServiceUnavailable>({
855
+ path: `/addresses/transactions`,
893
856
  method: 'POST',
857
+ query: query,
894
858
  body: data,
895
859
  type: ContentType.Json,
896
860
  format: 'json',
@@ -898,13 +862,13 @@ export class Api<SecurityDataType extends unknown> extends HttpClient<SecurityDa
898
862
  }).then(convertHttpResponse),
899
863
 
900
864
  /**
901
- * No description
865
+ * @description List transactions of a given address within a time-range
902
866
  *
903
867
  * @tags Addresses
904
- * @name GetAddressesAddressExportTransactionsCsv
905
- * @request GET:/addresses/{address}/export-transactions/csv
868
+ * @name GetAddressesAddressTimerangedTransactions
869
+ * @request GET:/addresses/{address}/timeranged-transactions
906
870
  */
907
- getAddressesAddressExportTransactionsCsv: (
871
+ getAddressesAddressTimerangedTransactions: (
908
872
  address: string,
909
873
  query: {
910
874
  /**
@@ -917,27 +881,37 @@ export class Api<SecurityDataType extends unknown> extends HttpClient<SecurityDa
917
881
  * @min 0
918
882
  */
919
883
  toTs: number
884
+ /**
885
+ * Page number
886
+ * @format int32
887
+ */
888
+ page?: number
889
+ /**
890
+ * Number of items per page
891
+ * @format int32
892
+ */
893
+ limit?: number
920
894
  },
921
895
  params: RequestParams = {}
922
896
  ) =>
923
- this.request<string, BadRequest | Unauthorized | NotFound | InternalServerError | ServiceUnavailable>({
924
- path: `/addresses/${address}/export-transactions/csv`,
897
+ this.request<Transaction[], BadRequest | Unauthorized | NotFound | InternalServerError | ServiceUnavailable>({
898
+ path: `/addresses/${address}/timeranged-transactions`,
925
899
  method: 'GET',
926
900
  query: query,
927
- format: 'text',
901
+ format: 'json',
928
902
  ...params
929
903
  }).then(convertHttpResponse),
930
904
 
931
905
  /**
932
- * @description Get address balance
906
+ * @description Get total transactions of a given address
933
907
  *
934
908
  * @tags Addresses
935
- * @name GetAddressesAddressBalance
936
- * @request GET:/addresses/{address}/balance
909
+ * @name GetAddressesAddressTotalTransactions
910
+ * @request GET:/addresses/{address}/total-transactions
937
911
  */
938
- getAddressesAddressBalance: (address: string, params: RequestParams = {}) =>
939
- this.request<AddressBalance, BadRequest | Unauthorized | NotFound | InternalServerError | ServiceUnavailable>({
940
- path: `/addresses/${address}/balance`,
912
+ getAddressesAddressTotalTransactions: (address: string, params: RequestParams = {}) =>
913
+ this.request<number, BadRequest | Unauthorized | NotFound | InternalServerError | ServiceUnavailable>({
914
+ path: `/addresses/${address}/total-transactions`,
941
915
  method: 'GET',
942
916
  format: 'json',
943
917
  ...params
@@ -961,35 +935,47 @@ export class Api<SecurityDataType extends unknown> extends HttpClient<SecurityDa
961
935
  ...params
962
936
  }).then(convertHttpResponse),
963
937
 
938
+ /**
939
+ * @description Get address balance
940
+ *
941
+ * @tags Addresses
942
+ * @name GetAddressesAddressBalance
943
+ * @request GET:/addresses/{address}/balance
944
+ */
945
+ getAddressesAddressBalance: (address: string, params: RequestParams = {}) =>
946
+ this.request<AddressBalance, BadRequest | Unauthorized | NotFound | InternalServerError | ServiceUnavailable>({
947
+ path: `/addresses/${address}/balance`,
948
+ method: 'GET',
949
+ format: 'json',
950
+ ...params
951
+ }).then(convertHttpResponse),
952
+
964
953
  /**
965
954
  * @description List address tokens
966
955
  *
967
956
  * @tags Addresses
968
- * @name GetAddressesAddressTokensTokenIdTransactions
969
- * @request GET:/addresses/{address}/tokens/{token_id}/transactions
957
+ * @name GetAddressesAddressTokens
958
+ * @request GET:/addresses/{address}/tokens
959
+ * @deprecated
970
960
  */
971
- getAddressesAddressTokensTokenIdTransactions: (
961
+ getAddressesAddressTokens: (
972
962
  address: string,
973
- tokenId: string,
974
963
  query?: {
975
964
  /**
976
965
  * Page number
977
966
  * @format int32
978
- * @min 1
979
967
  */
980
968
  page?: number
981
969
  /**
982
970
  * Number of items per page
983
971
  * @format int32
984
- * @min 0
985
- * @max 100
986
972
  */
987
973
  limit?: number
988
974
  },
989
975
  params: RequestParams = {}
990
976
  ) =>
991
- this.request<Transaction[], BadRequest | Unauthorized | NotFound | InternalServerError | ServiceUnavailable>({
992
- path: `/addresses/${address}/tokens/${tokenId}/transactions`,
977
+ this.request<string[], BadRequest | Unauthorized | NotFound | InternalServerError | ServiceUnavailable>({
978
+ path: `/addresses/${address}/tokens`,
993
979
  method: 'GET',
994
980
  query: query,
995
981
  format: 'json',
@@ -997,58 +983,31 @@ export class Api<SecurityDataType extends unknown> extends HttpClient<SecurityDa
997
983
  }).then(convertHttpResponse),
998
984
 
999
985
  /**
1000
- * @description Get total transactions of a given address
1001
- *
1002
- * @tags Addresses
1003
- * @name GetAddressesAddressTotalTransactions
1004
- * @request GET:/addresses/{address}/total-transactions
1005
- */
1006
- getAddressesAddressTotalTransactions: (address: string, params: RequestParams = {}) =>
1007
- this.request<number, BadRequest | Unauthorized | NotFound | InternalServerError | ServiceUnavailable>({
1008
- path: `/addresses/${address}/total-transactions`,
1009
- method: 'GET',
1010
- format: 'json',
1011
- ...params
1012
- }).then(convertHttpResponse),
1013
-
1014
- /**
1015
- * @description List transactions of a given address within a time-range
986
+ * @description List address tokens
1016
987
  *
1017
988
  * @tags Addresses
1018
- * @name GetAddressesAddressTimerangedTransactions
1019
- * @request GET:/addresses/{address}/timeranged-transactions
989
+ * @name GetAddressesAddressTokensTokenIdTransactions
990
+ * @request GET:/addresses/{address}/tokens/{token_id}/transactions
1020
991
  */
1021
- getAddressesAddressTimerangedTransactions: (
992
+ getAddressesAddressTokensTokenIdTransactions: (
1022
993
  address: string,
1023
- query: {
1024
- /**
1025
- * @format int64
1026
- * @min 0
1027
- */
1028
- fromTs: number
1029
- /**
1030
- * @format int64
1031
- * @min 0
1032
- */
1033
- toTs: number
994
+ tokenId: string,
995
+ query?: {
1034
996
  /**
1035
997
  * Page number
1036
998
  * @format int32
1037
- * @min 1
1038
999
  */
1039
1000
  page?: number
1040
1001
  /**
1041
1002
  * Number of items per page
1042
1003
  * @format int32
1043
- * @min 0
1044
- * @max 1000
1045
1004
  */
1046
1005
  limit?: number
1047
1006
  },
1048
1007
  params: RequestParams = {}
1049
1008
  ) =>
1050
1009
  this.request<Transaction[], BadRequest | Unauthorized | NotFound | InternalServerError | ServiceUnavailable>({
1051
- path: `/addresses/${address}/timeranged-transactions`,
1010
+ path: `/addresses/${address}/tokens/${tokenId}/transactions`,
1052
1011
  method: 'GET',
1053
1012
  query: query,
1054
1013
  format: 'json',
@@ -1056,101 +1015,83 @@ export class Api<SecurityDataType extends unknown> extends HttpClient<SecurityDa
1056
1015
  }).then(convertHttpResponse),
1057
1016
 
1058
1017
  /**
1059
- * @description List transactions of a given address
1018
+ * @description Get address balance of given token
1060
1019
  *
1061
1020
  * @tags Addresses
1062
- * @name GetAddressesAddressTransactions
1063
- * @request GET:/addresses/{address}/transactions
1021
+ * @name GetAddressesAddressTokensTokenIdBalance
1022
+ * @request GET:/addresses/{address}/tokens/{token_id}/balance
1064
1023
  */
1065
- getAddressesAddressTransactions: (
1066
- address: string,
1067
- query?: {
1068
- /**
1069
- * Page number
1070
- * @format int32
1071
- * @min 1
1072
- */
1073
- page?: number
1074
- /**
1075
- * Number of items per page
1076
- * @format int32
1077
- * @min 0
1078
- * @max 100
1079
- */
1080
- limit?: number
1081
- },
1082
- params: RequestParams = {}
1083
- ) =>
1084
- this.request<Transaction[], BadRequest | Unauthorized | NotFound | InternalServerError | ServiceUnavailable>({
1085
- path: `/addresses/${address}/transactions`,
1024
+ getAddressesAddressTokensTokenIdBalance: (address: string, tokenId: string, params: RequestParams = {}) =>
1025
+ this.request<
1026
+ AddressTokenBalance,
1027
+ BadRequest | Unauthorized | NotFound | InternalServerError | ServiceUnavailable
1028
+ >({
1029
+ path: `/addresses/${address}/tokens/${tokenId}/balance`,
1086
1030
  method: 'GET',
1087
- query: query,
1088
1031
  format: 'json',
1089
1032
  ...params
1090
1033
  }).then(convertHttpResponse),
1091
1034
 
1092
1035
  /**
1093
- * No description
1036
+ * @description Get public key of p2pkh addresses, the address needs to have at least one input.
1094
1037
  *
1095
1038
  * @tags Addresses
1096
- * @name GetAddressesAddressAmountHistory
1097
- * @request GET:/addresses/{address}/amount-history
1039
+ * @name GetAddressesAddressPublicKey
1040
+ * @request GET:/addresses/{address}/public-key
1098
1041
  */
1099
- getAddressesAddressAmountHistory: (
1100
- address: string,
1101
- query: {
1102
- /**
1103
- * @format int64
1104
- * @min 0
1105
- */
1106
- fromTs: number
1107
- /**
1108
- * @format int64
1109
- * @min 0
1110
- */
1111
- toTs: number
1112
- 'interval-type': IntervalType
1113
- },
1114
- params: RequestParams = {}
1115
- ) =>
1116
- this.request<AmountHistory, BadRequest | Unauthorized | NotFound | InternalServerError | ServiceUnavailable>({
1117
- path: `/addresses/${address}/amount-history`,
1042
+ getAddressesAddressPublicKey: (address: string, params: RequestParams = {}) =>
1043
+ this.request<string, BadRequest | Unauthorized | NotFound | InternalServerError | ServiceUnavailable>({
1044
+ path: `/addresses/${address}/public-key`,
1118
1045
  method: 'GET',
1119
- query: query,
1120
1046
  format: 'json',
1121
1047
  ...params
1122
1048
  }).then(convertHttpResponse),
1123
1049
 
1124
1050
  /**
1125
- * @description List transactions for given addresses
1051
+ * @description Get address tokens with balance
1126
1052
  *
1127
1053
  * @tags Addresses
1128
- * @name PostAddressesTransactions
1129
- * @request POST:/addresses/transactions
1054
+ * @name GetAddressesAddressTokensBalance
1055
+ * @request GET:/addresses/{address}/tokens-balance
1130
1056
  */
1131
- postAddressesTransactions: (
1057
+ getAddressesAddressTokensBalance: (
1058
+ address: string,
1132
1059
  query?: {
1133
1060
  /**
1134
1061
  * Page number
1135
1062
  * @format int32
1136
- * @min 1
1137
1063
  */
1138
1064
  page?: number
1139
1065
  /**
1140
1066
  * Number of items per page
1141
1067
  * @format int32
1142
- * @min 0
1143
- * @max 100
1144
1068
  */
1145
1069
  limit?: number
1146
1070
  },
1147
- data?: string[],
1148
1071
  params: RequestParams = {}
1149
1072
  ) =>
1150
- this.request<Transaction[], BadRequest | Unauthorized | NotFound | InternalServerError | ServiceUnavailable>({
1151
- path: `/addresses/transactions`,
1152
- method: 'POST',
1073
+ this.request<
1074
+ AddressTokenBalance[],
1075
+ BadRequest | Unauthorized | NotFound | InternalServerError | ServiceUnavailable
1076
+ >({
1077
+ path: `/addresses/${address}/tokens-balance`,
1078
+ method: 'GET',
1153
1079
  query: query,
1080
+ format: 'json',
1081
+ ...params
1082
+ }).then(convertHttpResponse),
1083
+
1084
+ /**
1085
+ * @description Are the addresses used (at least 1 transaction)
1086
+ *
1087
+ * @tags Addresses, Addresses
1088
+ * @name PostAddressesUsed
1089
+ * @request POST:/addresses/used
1090
+ */
1091
+ postAddressesUsed: (data?: string[], params: RequestParams = {}) =>
1092
+ this.request<boolean[], BadRequest | Unauthorized | NotFound | InternalServerError | ServiceUnavailable>({
1093
+ path: `/addresses/used`,
1094
+ method: 'POST',
1154
1095
  body: data,
1155
1096
  type: ContentType.Json,
1156
1097
  format: 'json',
@@ -1161,11 +1102,10 @@ export class Api<SecurityDataType extends unknown> extends HttpClient<SecurityDa
1161
1102
  * No description
1162
1103
  *
1163
1104
  * @tags Addresses
1164
- * @name GetAddressesAddressAmountHistoryDeprecated
1165
- * @request GET:/addresses/{address}/amount-history-DEPRECATED
1166
- * @deprecated
1105
+ * @name GetAddressesAddressExportTransactionsCsv
1106
+ * @request GET:/addresses/{address}/export-transactions/csv
1167
1107
  */
1168
- getAddressesAddressAmountHistoryDeprecated: (
1108
+ getAddressesAddressExportTransactionsCsv: (
1169
1109
  address: string,
1170
1110
  query: {
1171
1111
  /**
@@ -1178,47 +1118,44 @@ export class Api<SecurityDataType extends unknown> extends HttpClient<SecurityDa
1178
1118
  * @min 0
1179
1119
  */
1180
1120
  toTs: number
1181
- 'interval-type': IntervalType
1182
1121
  },
1183
1122
  params: RequestParams = {}
1184
1123
  ) =>
1185
1124
  this.request<string, BadRequest | Unauthorized | NotFound | InternalServerError | ServiceUnavailable>({
1186
- path: `/addresses/${address}/amount-history-DEPRECATED`,
1125
+ path: `/addresses/${address}/export-transactions/csv`,
1187
1126
  method: 'GET',
1188
1127
  query: query,
1189
- format: 'json',
1128
+ format: 'text',
1190
1129
  ...params
1191
1130
  }).then(convertHttpResponse),
1192
1131
 
1193
1132
  /**
1194
- * @description List address tokens
1133
+ * No description
1195
1134
  *
1196
1135
  * @tags Addresses
1197
- * @name GetAddressesAddressTokens
1198
- * @request GET:/addresses/{address}/tokens
1136
+ * @name GetAddressesAddressAmountHistoryDeprecated
1137
+ * @request GET:/addresses/{address}/amount-history-DEPRECATED
1199
1138
  * @deprecated
1200
1139
  */
1201
- getAddressesAddressTokens: (
1140
+ getAddressesAddressAmountHistoryDeprecated: (
1202
1141
  address: string,
1203
- query?: {
1142
+ query: {
1204
1143
  /**
1205
- * Page number
1206
- * @format int32
1207
- * @min 1
1144
+ * @format int64
1145
+ * @min 0
1208
1146
  */
1209
- page?: number
1147
+ fromTs: number
1210
1148
  /**
1211
- * Number of items per page
1212
- * @format int32
1149
+ * @format int64
1213
1150
  * @min 0
1214
- * @max 100
1215
1151
  */
1216
- limit?: number
1152
+ toTs: number
1153
+ 'interval-type': IntervalType
1217
1154
  },
1218
1155
  params: RequestParams = {}
1219
1156
  ) =>
1220
- this.request<string[], BadRequest | Unauthorized | NotFound | InternalServerError | ServiceUnavailable>({
1221
- path: `/addresses/${address}/tokens`,
1157
+ this.request<string, BadRequest | Unauthorized | NotFound | InternalServerError | ServiceUnavailable>({
1158
+ path: `/addresses/${address}/amount-history-DEPRECATED`,
1222
1159
  method: 'GET',
1223
1160
  query: query,
1224
1161
  format: 'json',
@@ -1226,91 +1163,68 @@ export class Api<SecurityDataType extends unknown> extends HttpClient<SecurityDa
1226
1163
  }).then(convertHttpResponse),
1227
1164
 
1228
1165
  /**
1229
- * @description Get address tokens with balance
1166
+ * No description
1230
1167
  *
1231
1168
  * @tags Addresses
1232
- * @name GetAddressesAddressTokensBalance
1233
- * @request GET:/addresses/{address}/tokens-balance
1169
+ * @name GetAddressesAddressAmountHistory
1170
+ * @request GET:/addresses/{address}/amount-history
1234
1171
  */
1235
- getAddressesAddressTokensBalance: (
1172
+ getAddressesAddressAmountHistory: (
1236
1173
  address: string,
1237
- query?: {
1174
+ query: {
1238
1175
  /**
1239
- * Page number
1240
- * @format int32
1241
- * @min 1
1176
+ * @format int64
1177
+ * @min 0
1242
1178
  */
1243
- page?: number
1179
+ fromTs: number
1244
1180
  /**
1245
- * Number of items per page
1246
- * @format int32
1181
+ * @format int64
1247
1182
  * @min 0
1248
- * @max 100
1249
1183
  */
1250
- limit?: number
1184
+ toTs: number
1185
+ 'interval-type': IntervalType
1251
1186
  },
1252
1187
  params: RequestParams = {}
1253
1188
  ) =>
1254
- this.request<
1255
- AddressTokenBalance[],
1256
- BadRequest | Unauthorized | NotFound | InternalServerError | ServiceUnavailable
1257
- >({
1258
- path: `/addresses/${address}/tokens-balance`,
1189
+ this.request<AmountHistory, BadRequest | Unauthorized | NotFound | InternalServerError | ServiceUnavailable>({
1190
+ path: `/addresses/${address}/amount-history`,
1259
1191
  method: 'GET',
1260
1192
  query: query,
1261
1193
  format: 'json',
1262
1194
  ...params
1263
- }).then(convertHttpResponse),
1264
-
1195
+ }).then(convertHttpResponse)
1196
+ }
1197
+ infos = {
1265
1198
  /**
1266
- * @description Get address balance of given token
1199
+ * @description Get explorer informations
1267
1200
  *
1268
- * @tags Addresses
1269
- * @name GetAddressesAddressTokensTokenIdBalance
1270
- * @request GET:/addresses/{address}/tokens/{token_id}/balance
1201
+ * @tags Infos
1202
+ * @name GetInfos
1203
+ * @request GET:/infos
1271
1204
  */
1272
- getAddressesAddressTokensTokenIdBalance: (address: string, tokenId: string, params: RequestParams = {}) =>
1273
- this.request<
1274
- AddressTokenBalance,
1275
- BadRequest | Unauthorized | NotFound | InternalServerError | ServiceUnavailable
1276
- >({
1277
- path: `/addresses/${address}/tokens/${tokenId}/balance`,
1205
+ getInfos: (params: RequestParams = {}) =>
1206
+ this.request<ExplorerInfo, BadRequest | Unauthorized | NotFound | InternalServerError | ServiceUnavailable>({
1207
+ path: `/infos`,
1278
1208
  method: 'GET',
1279
1209
  format: 'json',
1280
1210
  ...params
1281
1211
  }).then(convertHttpResponse),
1282
1212
 
1283
1213
  /**
1284
- * @description Get address information
1214
+ * @description List latest height for each chain
1285
1215
  *
1286
- * @tags Addresses
1287
- * @name GetAddressesAddress
1288
- * @request GET:/addresses/{address}
1216
+ * @tags Infos
1217
+ * @name GetInfosHeights
1218
+ * @request GET:/infos/heights
1289
1219
  */
1290
- getAddressesAddress: (address: string, params: RequestParams = {}) =>
1291
- this.request<AddressInfo, BadRequest | Unauthorized | NotFound | InternalServerError | ServiceUnavailable>({
1292
- path: `/addresses/${address}`,
1220
+ getInfosHeights: (params: RequestParams = {}) =>
1221
+ this.request<PerChainHeight[], BadRequest | Unauthorized | NotFound | InternalServerError | ServiceUnavailable>({
1222
+ path: `/infos/heights`,
1293
1223
  method: 'GET',
1294
1224
  format: 'json',
1295
1225
  ...params
1296
1226
  }).then(convertHttpResponse),
1297
1227
 
1298
- /**
1299
- * @description Get public key of p2pkh addresses, the address needs to have at least one input.
1300
- *
1301
- * @tags Addresses
1302
- * @name GetAddressesAddressPublicKey
1303
- * @request GET:/addresses/{address}/public-key
1304
- */
1305
- getAddressesAddressPublicKey: (address: string, params: RequestParams = {}) =>
1306
- this.request<string, BadRequest | Unauthorized | NotFound | InternalServerError | ServiceUnavailable>({
1307
- path: `/addresses/${address}/public-key`,
1308
- method: 'GET',
1309
- format: 'json',
1310
- ...params
1311
- }).then(convertHttpResponse)
1312
- }
1313
- infos = {
1314
1228
  /**
1315
1229
  * @description Get token supply list
1316
1230
  *
@@ -1323,14 +1237,11 @@ export class Api<SecurityDataType extends unknown> extends HttpClient<SecurityDa
1323
1237
  /**
1324
1238
  * Page number
1325
1239
  * @format int32
1326
- * @min 1
1327
1240
  */
1328
1241
  page?: number
1329
1242
  /**
1330
1243
  * Number of items per page
1331
1244
  * @format int32
1332
- * @min 0
1333
- * @max 100
1334
1245
  */
1335
1246
  limit?: number
1336
1247
  },
@@ -1344,51 +1255,6 @@ export class Api<SecurityDataType extends unknown> extends HttpClient<SecurityDa
1344
1255
  ...params
1345
1256
  }).then(convertHttpResponse),
1346
1257
 
1347
- /**
1348
- * @description Get the ALPH locked supply
1349
- *
1350
- * @tags Infos
1351
- * @name GetInfosSupplyLockedAlph
1352
- * @request GET:/infos/supply/locked-alph
1353
- */
1354
- getInfosSupplyLockedAlph: (params: RequestParams = {}) =>
1355
- this.request<number, BadRequest | Unauthorized | NotFound | InternalServerError | ServiceUnavailable>({
1356
- path: `/infos/supply/locked-alph`,
1357
- method: 'GET',
1358
- format: 'text',
1359
- ...params
1360
- }).then(convertHttpResponse),
1361
-
1362
- /**
1363
- * @description Get explorer informations
1364
- *
1365
- * @tags Infos
1366
- * @name GetInfos
1367
- * @request GET:/infos
1368
- */
1369
- getInfos: (params: RequestParams = {}) =>
1370
- this.request<ExplorerInfo, BadRequest | Unauthorized | NotFound | InternalServerError | ServiceUnavailable>({
1371
- path: `/infos`,
1372
- method: 'GET',
1373
- format: 'json',
1374
- ...params
1375
- }).then(convertHttpResponse),
1376
-
1377
- /**
1378
- * @description Get the ALPH circulating supply
1379
- *
1380
- * @tags Infos
1381
- * @name GetInfosSupplyCirculatingAlph
1382
- * @request GET:/infos/supply/circulating-alph
1383
- */
1384
- getInfosSupplyCirculatingAlph: (params: RequestParams = {}) =>
1385
- this.request<number, BadRequest | Unauthorized | NotFound | InternalServerError | ServiceUnavailable>({
1386
- path: `/infos/supply/circulating-alph`,
1387
- method: 'GET',
1388
- format: 'text',
1389
- ...params
1390
- }).then(convertHttpResponse),
1391
-
1392
1258
  /**
1393
1259
  * @description Get the ALPH total supply
1394
1260
  *
@@ -1405,15 +1271,15 @@ export class Api<SecurityDataType extends unknown> extends HttpClient<SecurityDa
1405
1271
  }).then(convertHttpResponse),
1406
1272
 
1407
1273
  /**
1408
- * @description Get the total number of transactions
1274
+ * @description Get the ALPH circulating supply
1409
1275
  *
1410
1276
  * @tags Infos
1411
- * @name GetInfosTotalTransactions
1412
- * @request GET:/infos/total-transactions
1277
+ * @name GetInfosSupplyCirculatingAlph
1278
+ * @request GET:/infos/supply/circulating-alph
1413
1279
  */
1414
- getInfosTotalTransactions: (params: RequestParams = {}) =>
1280
+ getInfosSupplyCirculatingAlph: (params: RequestParams = {}) =>
1415
1281
  this.request<number, BadRequest | Unauthorized | NotFound | InternalServerError | ServiceUnavailable>({
1416
- path: `/infos/total-transactions`,
1282
+ path: `/infos/supply/circulating-alph`,
1417
1283
  method: 'GET',
1418
1284
  format: 'text',
1419
1285
  ...params
@@ -1435,121 +1301,87 @@ export class Api<SecurityDataType extends unknown> extends HttpClient<SecurityDa
1435
1301
  }).then(convertHttpResponse),
1436
1302
 
1437
1303
  /**
1438
- * @description List latest height for each chain
1304
+ * @description Get the ALPH locked supply
1439
1305
  *
1440
1306
  * @tags Infos
1441
- * @name GetInfosHeights
1442
- * @request GET:/infos/heights
1307
+ * @name GetInfosSupplyLockedAlph
1308
+ * @request GET:/infos/supply/locked-alph
1443
1309
  */
1444
- getInfosHeights: (params: RequestParams = {}) =>
1445
- this.request<PerChainHeight[], BadRequest | Unauthorized | NotFound | InternalServerError | ServiceUnavailable>({
1446
- path: `/infos/heights`,
1310
+ getInfosSupplyLockedAlph: (params: RequestParams = {}) =>
1311
+ this.request<number, BadRequest | Unauthorized | NotFound | InternalServerError | ServiceUnavailable>({
1312
+ path: `/infos/supply/locked-alph`,
1447
1313
  method: 'GET',
1448
- format: 'json',
1314
+ format: 'text',
1449
1315
  ...params
1450
1316
  }).then(convertHttpResponse),
1451
1317
 
1452
1318
  /**
1453
- * @description Get the average block time for each chain
1319
+ * @description Get the total number of transactions
1454
1320
  *
1455
1321
  * @tags Infos
1456
- * @name GetInfosAverageBlockTimes
1457
- * @request GET:/infos/average-block-times
1458
- */
1459
- getInfosAverageBlockTimes: (params: RequestParams = {}) =>
1460
- this.request<PerChainDuration[], BadRequest | Unauthorized | NotFound | InternalServerError | ServiceUnavailable>(
1461
- {
1462
- path: `/infos/average-block-times`,
1463
- method: 'GET',
1464
- format: 'json',
1465
- ...params
1466
- }
1467
- ).then(convertHttpResponse)
1468
- }
1469
- utils = {
1470
- /**
1471
- * @description Perform a sanity check
1472
- *
1473
- * @tags Utils
1474
- * @name PutUtilsSanityCheck
1475
- * @request PUT:/utils/sanity-check
1476
- */
1477
- putUtilsSanityCheck: (params: RequestParams = {}) =>
1478
- this.request<void, BadRequest | Unauthorized | NotFound | InternalServerError | ServiceUnavailable>({
1479
- path: `/utils/sanity-check`,
1480
- method: 'PUT',
1481
- ...params
1482
- }).then(convertHttpResponse),
1483
-
1484
- /**
1485
- * @description Update global log level, accepted: TRACE, DEBUG, INFO, WARN, ERROR
1486
- *
1487
- * @tags Utils
1488
- * @name PutUtilsUpdateGlobalLoglevel
1489
- * @request PUT:/utils/update-global-loglevel
1490
- */
1491
- putUtilsUpdateGlobalLoglevel: (data: 'TRACE' | 'DEBUG' | 'INFO' | 'WARN' | 'ERROR', params: RequestParams = {}) =>
1492
- this.request<void, BadRequest | Unauthorized | NotFound | InternalServerError | ServiceUnavailable>({
1493
- path: `/utils/update-global-loglevel`,
1494
- method: 'PUT',
1495
- body: data,
1322
+ * @name GetInfosTotalTransactions
1323
+ * @request GET:/infos/total-transactions
1324
+ */
1325
+ getInfosTotalTransactions: (params: RequestParams = {}) =>
1326
+ this.request<number, BadRequest | Unauthorized | NotFound | InternalServerError | ServiceUnavailable>({
1327
+ path: `/infos/total-transactions`,
1328
+ method: 'GET',
1329
+ format: 'text',
1496
1330
  ...params
1497
1331
  }).then(convertHttpResponse),
1498
1332
 
1499
1333
  /**
1500
- * @description Update logback values
1334
+ * @description Get the average block time for each chain
1501
1335
  *
1502
- * @tags Utils
1503
- * @name PutUtilsUpdateLogConfig
1504
- * @request PUT:/utils/update-log-config
1336
+ * @tags Infos
1337
+ * @name GetInfosAverageBlockTimes
1338
+ * @request GET:/infos/average-block-times
1505
1339
  */
1506
- putUtilsUpdateLogConfig: (data?: LogbackValue[], params: RequestParams = {}) =>
1507
- this.request<void, BadRequest | Unauthorized | NotFound | InternalServerError | ServiceUnavailable>({
1508
- path: `/utils/update-log-config`,
1509
- method: 'PUT',
1510
- body: data,
1511
- type: ContentType.Json,
1512
- ...params
1513
- }).then(convertHttpResponse)
1340
+ getInfosAverageBlockTimes: (params: RequestParams = {}) =>
1341
+ this.request<PerChainDuration[], BadRequest | Unauthorized | NotFound | InternalServerError | ServiceUnavailable>(
1342
+ {
1343
+ path: `/infos/average-block-times`,
1344
+ method: 'GET',
1345
+ format: 'json',
1346
+ ...params
1347
+ }
1348
+ ).then(convertHttpResponse)
1514
1349
  }
1515
- tokens = {
1350
+ mempool = {
1516
1351
  /**
1517
- * @description Return metadata for the given fungible tokens, if metadata doesn't exist or token isn't a fungible, it won't be in the output list
1352
+ * @description list mempool transactions
1518
1353
  *
1519
- * @tags Tokens
1520
- * @name PostTokensFungibleMetadata
1521
- * @request POST:/tokens/fungible-metadata
1354
+ * @tags Mempool
1355
+ * @name GetMempoolTransactions
1356
+ * @request GET:/mempool/transactions
1522
1357
  */
1523
- postTokensFungibleMetadata: (data?: string[], params: RequestParams = {}) =>
1358
+ getMempoolTransactions: (
1359
+ query?: {
1360
+ /**
1361
+ * Page number
1362
+ * @format int32
1363
+ */
1364
+ page?: number
1365
+ /**
1366
+ * Number of items per page
1367
+ * @format int32
1368
+ */
1369
+ limit?: number
1370
+ },
1371
+ params: RequestParams = {}
1372
+ ) =>
1524
1373
  this.request<
1525
- FungibleTokenMetadata[],
1374
+ MempoolTransaction[],
1526
1375
  BadRequest | Unauthorized | NotFound | InternalServerError | ServiceUnavailable
1527
1376
  >({
1528
- path: `/tokens/fungible-metadata`,
1529
- method: 'POST',
1530
- body: data,
1531
- type: ContentType.Json,
1532
- format: 'json',
1533
- ...params
1534
- }).then(convertHttpResponse),
1535
-
1536
- /**
1537
- * @description List given tokens information
1538
- *
1539
- * @tags Tokens
1540
- * @name PostTokens
1541
- * @request POST:/tokens
1542
- */
1543
- postTokens: (data?: string[], params: RequestParams = {}) =>
1544
- this.request<TokenInfo[], BadRequest | Unauthorized | NotFound | InternalServerError | ServiceUnavailable>({
1545
- path: `/tokens`,
1546
- method: 'POST',
1547
- body: data,
1548
- type: ContentType.Json,
1377
+ path: `/mempool/transactions`,
1378
+ method: 'GET',
1379
+ query: query,
1549
1380
  format: 'json',
1550
1381
  ...params
1551
- }).then(convertHttpResponse),
1552
-
1382
+ }).then(convertHttpResponse)
1383
+ }
1384
+ tokens = {
1553
1385
  /**
1554
1386
  * @description List token information
1555
1387
  *
@@ -1562,14 +1394,11 @@ export class Api<SecurityDataType extends unknown> extends HttpClient<SecurityDa
1562
1394
  /**
1563
1395
  * Page number
1564
1396
  * @format int32
1565
- * @min 1
1566
1397
  */
1567
1398
  page?: number
1568
1399
  /**
1569
1400
  * Number of items per page
1570
1401
  * @format int32
1571
- * @min 0
1572
- * @max 100
1573
1402
  */
1574
1403
  limit?: number
1575
1404
  /**
@@ -1588,6 +1417,23 @@ export class Api<SecurityDataType extends unknown> extends HttpClient<SecurityDa
1588
1417
  ...params
1589
1418
  }).then(convertHttpResponse),
1590
1419
 
1420
+ /**
1421
+ * @description List given tokens information
1422
+ *
1423
+ * @tags Tokens
1424
+ * @name PostTokens
1425
+ * @request POST:/tokens
1426
+ */
1427
+ postTokens: (data?: string[], params: RequestParams = {}) =>
1428
+ this.request<TokenInfo[], BadRequest | Unauthorized | NotFound | InternalServerError | ServiceUnavailable>({
1429
+ path: `/tokens`,
1430
+ method: 'POST',
1431
+ body: data,
1432
+ type: ContentType.Json,
1433
+ format: 'json',
1434
+ ...params
1435
+ }).then(convertHttpResponse),
1436
+
1591
1437
  /**
1592
1438
  * @description List token transactions
1593
1439
  *
@@ -1601,14 +1447,11 @@ export class Api<SecurityDataType extends unknown> extends HttpClient<SecurityDa
1601
1447
  /**
1602
1448
  * Page number
1603
1449
  * @format int32
1604
- * @min 1
1605
1450
  */
1606
1451
  page?: number
1607
1452
  /**
1608
1453
  * Number of items per page
1609
1454
  * @format int32
1610
- * @min 0
1611
- * @max 100
1612
1455
  */
1613
1456
  limit?: number
1614
1457
  },
@@ -1622,26 +1465,6 @@ export class Api<SecurityDataType extends unknown> extends HttpClient<SecurityDa
1622
1465
  ...params
1623
1466
  }).then(convertHttpResponse),
1624
1467
 
1625
- /**
1626
- * @description Return metadata for the given nft collection addresses, if metadata doesn't exist or address isn't a nft collection, it won't be in the output list
1627
- *
1628
- * @tags Tokens
1629
- * @name PostTokensNftCollectionMetadata
1630
- * @request POST:/tokens/nft-collection-metadata
1631
- */
1632
- postTokensNftCollectionMetadata: (data?: string[], params: RequestParams = {}) =>
1633
- this.request<
1634
- NFTCollectionMetadata[],
1635
- BadRequest | Unauthorized | NotFound | InternalServerError | ServiceUnavailable
1636
- >({
1637
- path: `/tokens/nft-collection-metadata`,
1638
- method: 'POST',
1639
- body: data,
1640
- type: ContentType.Json,
1641
- format: 'json',
1642
- ...params
1643
- }).then(convertHttpResponse),
1644
-
1645
1468
  /**
1646
1469
  * @description List token addresses
1647
1470
  *
@@ -1655,14 +1478,11 @@ export class Api<SecurityDataType extends unknown> extends HttpClient<SecurityDa
1655
1478
  /**
1656
1479
  * Page number
1657
1480
  * @format int32
1658
- * @min 1
1659
1481
  */
1660
1482
  page?: number
1661
1483
  /**
1662
1484
  * Number of items per page
1663
1485
  * @format int32
1664
- * @min 0
1665
- * @max 100
1666
1486
  */
1667
1487
  limit?: number
1668
1488
  },
@@ -1677,41 +1497,36 @@ export class Api<SecurityDataType extends unknown> extends HttpClient<SecurityDa
1677
1497
  }).then(convertHttpResponse),
1678
1498
 
1679
1499
  /**
1680
- * @description Return metadata for the given nft tokens, if metadata doesn't exist or token isn't a nft, it won't be in the output list
1500
+ * @description Return metadata for the given fungible tokens, if metadata doesn't exist or token isn't a fungible, it won't be in the output list
1681
1501
  *
1682
1502
  * @tags Tokens
1683
- * @name PostTokensNftMetadata
1684
- * @request POST:/tokens/nft-metadata
1503
+ * @name PostTokensFungibleMetadata
1504
+ * @request POST:/tokens/fungible-metadata
1685
1505
  */
1686
- postTokensNftMetadata: (data?: string[], params: RequestParams = {}) =>
1687
- this.request<NFTMetadata[], BadRequest | Unauthorized | NotFound | InternalServerError | ServiceUnavailable>({
1688
- path: `/tokens/nft-metadata`,
1506
+ postTokensFungibleMetadata: (data?: string[], params: RequestParams = {}) =>
1507
+ this.request<
1508
+ FungibleTokenMetadata[],
1509
+ BadRequest | Unauthorized | NotFound | InternalServerError | ServiceUnavailable
1510
+ >({
1511
+ path: `/tokens/fungible-metadata`,
1689
1512
  method: 'POST',
1690
1513
  body: data,
1691
1514
  type: ContentType.Json,
1692
1515
  format: 'json',
1693
1516
  ...params
1694
- }).then(convertHttpResponse)
1695
- }
1696
- market = {
1517
+ }).then(convertHttpResponse),
1518
+
1697
1519
  /**
1698
- * No description
1520
+ * @description Return metadata for the given nft tokens, if metadata doesn't exist or token isn't a nft, it won't be in the output list
1699
1521
  *
1700
- * @tags Market
1701
- * @name PostMarketPrices
1702
- * @request POST:/market/prices
1522
+ * @tags Tokens
1523
+ * @name PostTokensNftMetadata
1524
+ * @request POST:/tokens/nft-metadata
1703
1525
  */
1704
- postMarketPrices: (
1705
- query: {
1706
- currency: string
1707
- },
1708
- data?: string[],
1709
- params: RequestParams = {}
1710
- ) =>
1711
- this.request<number[], BadRequest | Unauthorized | NotFound | InternalServerError | ServiceUnavailable>({
1712
- path: `/market/prices`,
1526
+ postTokensNftMetadata: (data?: string[], params: RequestParams = {}) =>
1527
+ this.request<NFTMetadata[], BadRequest | Unauthorized | NotFound | InternalServerError | ServiceUnavailable>({
1528
+ path: `/tokens/nft-metadata`,
1713
1529
  method: 'POST',
1714
- query: query,
1715
1530
  body: data,
1716
1531
  type: ContentType.Json,
1717
1532
  format: 'json',
@@ -1719,56 +1534,52 @@ export class Api<SecurityDataType extends unknown> extends HttpClient<SecurityDa
1719
1534
  }).then(convertHttpResponse),
1720
1535
 
1721
1536
  /**
1722
- * No description
1537
+ * @description Return metadata for the given nft collection addresses, if metadata doesn't exist or address isn't a nft collection, it won't be in the output list
1723
1538
  *
1724
- * @tags Market
1725
- * @name GetMarketPricesSymbolCharts
1726
- * @request GET:/market/prices/{symbol}/charts
1539
+ * @tags Tokens
1540
+ * @name PostTokensNftCollectionMetadata
1541
+ * @request POST:/tokens/nft-collection-metadata
1727
1542
  */
1728
- getMarketPricesSymbolCharts: (
1729
- symbol: string,
1730
- query: {
1731
- currency: string
1732
- },
1733
- params: RequestParams = {}
1734
- ) =>
1735
- this.request<TimedPrices, BadRequest | Unauthorized | NotFound | InternalServerError | ServiceUnavailable>({
1736
- path: `/market/prices/${symbol}/charts`,
1737
- method: 'GET',
1738
- query: query,
1543
+ postTokensNftCollectionMetadata: (data?: string[], params: RequestParams = {}) =>
1544
+ this.request<
1545
+ NFTCollectionMetadata[],
1546
+ BadRequest | Unauthorized | NotFound | InternalServerError | ServiceUnavailable
1547
+ >({
1548
+ path: `/tokens/nft-collection-metadata`,
1549
+ method: 'POST',
1550
+ body: data,
1551
+ type: ContentType.Json,
1739
1552
  format: 'json',
1740
1553
  ...params
1741
1554
  }).then(convertHttpResponse)
1742
1555
  }
1743
- blocks = {
1556
+ charts = {
1744
1557
  /**
1745
- * @description Get block's transactions
1558
+ * @description `interval-type` query param: hourly, daily
1746
1559
  *
1747
- * @tags Blocks
1748
- * @name GetBlocksBlockHashTransactions
1749
- * @request GET:/blocks/{block_hash}/transactions
1560
+ * @tags Charts
1561
+ * @name GetChartsHashrates
1562
+ * @summary Get hashrate chart in H/s
1563
+ * @request GET:/charts/hashrates
1750
1564
  */
1751
- getBlocksBlockHashTransactions: (
1752
- blockHash: string,
1753
- query?: {
1565
+ getChartsHashrates: (
1566
+ query: {
1754
1567
  /**
1755
- * Page number
1756
- * @format int32
1757
- * @min 1
1568
+ * @format int64
1569
+ * @min 0
1758
1570
  */
1759
- page?: number
1571
+ fromTs: number
1760
1572
  /**
1761
- * Number of items per page
1762
- * @format int32
1573
+ * @format int64
1763
1574
  * @min 0
1764
- * @max 100
1765
1575
  */
1766
- limit?: number
1576
+ toTs: number
1577
+ 'interval-type': IntervalType
1767
1578
  },
1768
1579
  params: RequestParams = {}
1769
1580
  ) =>
1770
- this.request<Transaction[], BadRequest | Unauthorized | NotFound | InternalServerError | ServiceUnavailable>({
1771
- path: `/blocks/${blockHash}/transactions`,
1581
+ this.request<Hashrate[], BadRequest | Unauthorized | NotFound | InternalServerError | ServiceUnavailable>({
1582
+ path: `/charts/hashrates`,
1772
1583
  method: 'GET',
1773
1584
  query: query,
1774
1585
  format: 'json',
@@ -1776,71 +1587,72 @@ export class Api<SecurityDataType extends unknown> extends HttpClient<SecurityDa
1776
1587
  }).then(convertHttpResponse),
1777
1588
 
1778
1589
  /**
1779
- * @description Get a block with hash
1590
+ * @description `interval-type` query param: hourly, daily
1780
1591
  *
1781
- * @tags Blocks
1782
- * @name GetBlocksBlockHash
1783
- * @request GET:/blocks/{block_hash}
1592
+ * @tags Charts
1593
+ * @name GetChartsTransactionsCount
1594
+ * @summary Get transaction count history
1595
+ * @request GET:/charts/transactions-count
1784
1596
  */
1785
- getBlocksBlockHash: (blockHash: string, params: RequestParams = {}) =>
1786
- this.request<BlockEntry, BadRequest | Unauthorized | NotFound | InternalServerError | ServiceUnavailable>({
1787
- path: `/blocks/${blockHash}`,
1597
+ getChartsTransactionsCount: (
1598
+ query: {
1599
+ /**
1600
+ * @format int64
1601
+ * @min 0
1602
+ */
1603
+ fromTs: number
1604
+ /**
1605
+ * @format int64
1606
+ * @min 0
1607
+ */
1608
+ toTs: number
1609
+ 'interval-type': IntervalType
1610
+ },
1611
+ params: RequestParams = {}
1612
+ ) =>
1613
+ this.request<TimedCount[], BadRequest | Unauthorized | NotFound | InternalServerError | ServiceUnavailable>({
1614
+ path: `/charts/transactions-count`,
1788
1615
  method: 'GET',
1616
+ query: query,
1789
1617
  format: 'json',
1790
1618
  ...params
1791
1619
  }).then(convertHttpResponse),
1792
1620
 
1793
1621
  /**
1794
- * @description List latest blocks
1622
+ * @description `interval-type` query param: hourly, daily
1795
1623
  *
1796
- * @tags Blocks
1797
- * @name GetBlocks
1798
- * @request GET:/blocks
1624
+ * @tags Charts
1625
+ * @name GetChartsTransactionsCountPerChain
1626
+ * @summary Get transaction count history per chain
1627
+ * @request GET:/charts/transactions-count-per-chain
1799
1628
  */
1800
- getBlocks: (
1801
- query?: {
1629
+ getChartsTransactionsCountPerChain: (
1630
+ query: {
1802
1631
  /**
1803
- * Page number
1804
- * @format int32
1805
- * @min 1
1632
+ * @format int64
1633
+ * @min 0
1806
1634
  */
1807
- page?: number
1635
+ fromTs: number
1808
1636
  /**
1809
- * Number of items per page
1810
- * @format int32
1637
+ * @format int64
1811
1638
  * @min 0
1812
- * @max 100
1813
1639
  */
1814
- limit?: number
1815
- /** Reverse pagination */
1816
- reverse?: boolean
1640
+ toTs: number
1641
+ 'interval-type': IntervalType
1817
1642
  },
1818
1643
  params: RequestParams = {}
1819
1644
  ) =>
1820
- this.request<ListBlocks, BadRequest | Unauthorized | NotFound | InternalServerError | ServiceUnavailable>({
1821
- path: `/blocks`,
1645
+ this.request<
1646
+ PerChainTimedCount[],
1647
+ BadRequest | Unauthorized | NotFound | InternalServerError | ServiceUnavailable
1648
+ >({
1649
+ path: `/charts/transactions-count-per-chain`,
1822
1650
  method: 'GET',
1823
1651
  query: query,
1824
1652
  format: 'json',
1825
1653
  ...params
1826
1654
  }).then(convertHttpResponse)
1827
1655
  }
1828
- transactions = {
1829
- /**
1830
- * @description Get a transaction with hash
1831
- *
1832
- * @tags Transactions
1833
- * @name GetTransactionsTransactionHash
1834
- * @request GET:/transactions/{transaction_hash}
1835
- */
1836
- getTransactionsTransactionHash: (transactionHash: string, params: RequestParams = {}) =>
1837
- this.request<TransactionLike, BadRequest | Unauthorized | NotFound | InternalServerError | ServiceUnavailable>({
1838
- path: `/transactions/${transactionHash}`,
1839
- method: 'GET',
1840
- format: 'json',
1841
- ...params
1842
- }).then(convertHttpResponse)
1843
- }
1844
1656
  contractEvents = {
1845
1657
  /**
1846
1658
  * @description Get contract events by transaction id
@@ -1870,14 +1682,11 @@ export class Api<SecurityDataType extends unknown> extends HttpClient<SecurityDa
1870
1682
  /**
1871
1683
  * Page number
1872
1684
  * @format int32
1873
- * @min 1
1874
1685
  */
1875
1686
  page?: number
1876
1687
  /**
1877
1688
  * Number of items per page
1878
1689
  * @format int32
1879
- * @min 0
1880
- * @max 100
1881
1690
  */
1882
1691
  limit?: number
1883
1692
  },
@@ -1905,14 +1714,11 @@ export class Api<SecurityDataType extends unknown> extends HttpClient<SecurityDa
1905
1714
  /**
1906
1715
  * Page number
1907
1716
  * @format int32
1908
- * @min 1
1909
1717
  */
1910
1718
  page?: number
1911
1719
  /**
1912
1720
  * Number of items per page
1913
1721
  * @format int32
1914
- * @min 0
1915
- * @max 100
1916
1722
  */
1917
1723
  limit?: number
1918
1724
  },
@@ -1926,140 +1732,158 @@ export class Api<SecurityDataType extends unknown> extends HttpClient<SecurityDa
1926
1732
  ...params
1927
1733
  }).then(convertHttpResponse)
1928
1734
  }
1929
- charts = {
1735
+ contracts = {
1930
1736
  /**
1931
- * @description `interval-type` query param: hourly, daily
1737
+ * @description Get contract liveness
1932
1738
  *
1933
- * @tags Charts
1934
- * @name GetChartsTransactionsCountPerChain
1935
- * @summary Get transaction count history per chain
1936
- * @request GET:/charts/transactions-count-per-chain
1739
+ * @tags Contracts
1740
+ * @name GetContractsContractAddressCurrentLiveness
1741
+ * @request GET:/contracts/{contract_address}/current-liveness
1937
1742
  */
1938
- getChartsTransactionsCountPerChain: (
1939
- query: {
1743
+ getContractsContractAddressCurrentLiveness: (contractAddress: string, params: RequestParams = {}) =>
1744
+ this.request<ContractLiveness, BadRequest | Unauthorized | NotFound | InternalServerError | ServiceUnavailable>({
1745
+ path: `/contracts/${contractAddress}/current-liveness`,
1746
+ method: 'GET',
1747
+ format: 'json',
1748
+ ...params
1749
+ }).then(convertHttpResponse),
1750
+
1751
+ /**
1752
+ * @description Get contract parent address if exist
1753
+ *
1754
+ * @tags Contracts
1755
+ * @name GetContractsContractAddressParent
1756
+ * @request GET:/contracts/{contract_address}/parent
1757
+ */
1758
+ getContractsContractAddressParent: (contractAddress: string, params: RequestParams = {}) =>
1759
+ this.request<ContractParent, BadRequest | Unauthorized | NotFound | InternalServerError | ServiceUnavailable>({
1760
+ path: `/contracts/${contractAddress}/parent`,
1761
+ method: 'GET',
1762
+ format: 'json',
1763
+ ...params
1764
+ }).then(convertHttpResponse),
1765
+
1766
+ /**
1767
+ * @description Get sub contract addresses
1768
+ *
1769
+ * @tags Contracts
1770
+ * @name GetContractsContractAddressSubContracts
1771
+ * @request GET:/contracts/{contract_address}/sub-contracts
1772
+ */
1773
+ getContractsContractAddressSubContracts: (
1774
+ contractAddress: string,
1775
+ query?: {
1940
1776
  /**
1941
- * @format int64
1942
- * @min 0
1777
+ * Page number
1778
+ * @format int32
1943
1779
  */
1944
- fromTs: number
1780
+ page?: number
1945
1781
  /**
1946
- * @format int64
1947
- * @min 0
1782
+ * Number of items per page
1783
+ * @format int32
1948
1784
  */
1949
- toTs: number
1950
- 'interval-type': IntervalType
1785
+ limit?: number
1951
1786
  },
1952
1787
  params: RequestParams = {}
1953
1788
  ) =>
1954
- this.request<
1955
- PerChainTimedCount[],
1956
- BadRequest | Unauthorized | NotFound | InternalServerError | ServiceUnavailable
1957
- >({
1958
- path: `/charts/transactions-count-per-chain`,
1789
+ this.request<SubContracts, BadRequest | Unauthorized | NotFound | InternalServerError | ServiceUnavailable>({
1790
+ path: `/contracts/${contractAddress}/sub-contracts`,
1959
1791
  method: 'GET',
1960
1792
  query: query,
1961
1793
  format: 'json',
1962
1794
  ...params
1963
- }).then(convertHttpResponse),
1964
-
1795
+ }).then(convertHttpResponse)
1796
+ }
1797
+ market = {
1965
1798
  /**
1966
- * @description `interval-type` query param: hourly, daily
1799
+ * No description
1967
1800
  *
1968
- * @tags Charts
1969
- * @name GetChartsTransactionsCount
1970
- * @summary Get transaction count history
1971
- * @request GET:/charts/transactions-count
1801
+ * @tags Market
1802
+ * @name PostMarketPrices
1803
+ * @request POST:/market/prices
1972
1804
  */
1973
- getChartsTransactionsCount: (
1805
+ postMarketPrices: (
1974
1806
  query: {
1975
- /**
1976
- * @format int64
1977
- * @min 0
1978
- */
1979
- fromTs: number
1980
- /**
1981
- * @format int64
1982
- * @min 0
1983
- */
1984
- toTs: number
1985
- 'interval-type': IntervalType
1807
+ currency: string
1986
1808
  },
1809
+ data?: string[],
1987
1810
  params: RequestParams = {}
1988
1811
  ) =>
1989
- this.request<TimedCount[], BadRequest | Unauthorized | NotFound | InternalServerError | ServiceUnavailable>({
1990
- path: `/charts/transactions-count`,
1991
- method: 'GET',
1812
+ this.request<number[], BadRequest | Unauthorized | NotFound | InternalServerError | ServiceUnavailable>({
1813
+ path: `/market/prices`,
1814
+ method: 'POST',
1992
1815
  query: query,
1816
+ body: data,
1817
+ type: ContentType.Json,
1993
1818
  format: 'json',
1994
1819
  ...params
1995
1820
  }).then(convertHttpResponse),
1996
1821
 
1997
1822
  /**
1998
- * @description `interval-type` query param: hourly, daily
1823
+ * No description
1999
1824
  *
2000
- * @tags Charts
2001
- * @name GetChartsHashrates
2002
- * @summary Get hashrate chart in H/s
2003
- * @request GET:/charts/hashrates
1825
+ * @tags Market
1826
+ * @name GetMarketPricesSymbolCharts
1827
+ * @request GET:/market/prices/{symbol}/charts
2004
1828
  */
2005
- getChartsHashrates: (
1829
+ getMarketPricesSymbolCharts: (
1830
+ symbol: string,
2006
1831
  query: {
2007
- /**
2008
- * @format int64
2009
- * @min 0
2010
- */
2011
- fromTs: number
2012
- /**
2013
- * @format int64
2014
- * @min 0
2015
- */
2016
- toTs: number
2017
- 'interval-type': IntervalType
1832
+ currency: string
2018
1833
  },
2019
1834
  params: RequestParams = {}
2020
1835
  ) =>
2021
- this.request<Hashrate[], BadRequest | Unauthorized | NotFound | InternalServerError | ServiceUnavailable>({
2022
- path: `/charts/hashrates`,
1836
+ this.request<TimedPrices, BadRequest | Unauthorized | NotFound | InternalServerError | ServiceUnavailable>({
1837
+ path: `/market/prices/${symbol}/charts`,
2023
1838
  method: 'GET',
2024
1839
  query: query,
2025
1840
  format: 'json',
2026
1841
  ...params
2027
1842
  }).then(convertHttpResponse)
2028
1843
  }
2029
- mempool = {
1844
+ utils = {
2030
1845
  /**
2031
- * @description list mempool transactions
1846
+ * @description Perform a sanity check
2032
1847
  *
2033
- * @tags Mempool
2034
- * @name GetMempoolTransactions
2035
- * @request GET:/mempool/transactions
1848
+ * @tags Utils
1849
+ * @name PutUtilsSanityCheck
1850
+ * @request PUT:/utils/sanity-check
2036
1851
  */
2037
- getMempoolTransactions: (
2038
- query?: {
2039
- /**
2040
- * Page number
2041
- * @format int32
2042
- * @min 1
2043
- */
2044
- page?: number
2045
- /**
2046
- * Number of items per page
2047
- * @format int32
2048
- * @min 0
2049
- * @max 100
2050
- */
2051
- limit?: number
2052
- },
2053
- params: RequestParams = {}
2054
- ) =>
2055
- this.request<
2056
- MempoolTransaction[],
2057
- BadRequest | Unauthorized | NotFound | InternalServerError | ServiceUnavailable
2058
- >({
2059
- path: `/mempool/transactions`,
2060
- method: 'GET',
2061
- query: query,
2062
- format: 'json',
1852
+ putUtilsSanityCheck: (params: RequestParams = {}) =>
1853
+ this.request<void, BadRequest | Unauthorized | NotFound | InternalServerError | ServiceUnavailable>({
1854
+ path: `/utils/sanity-check`,
1855
+ method: 'PUT',
1856
+ ...params
1857
+ }).then(convertHttpResponse),
1858
+
1859
+ /**
1860
+ * @description Update global log level, accepted: TRACE, DEBUG, INFO, WARN, ERROR
1861
+ *
1862
+ * @tags Utils
1863
+ * @name PutUtilsUpdateGlobalLoglevel
1864
+ * @request PUT:/utils/update-global-loglevel
1865
+ */
1866
+ putUtilsUpdateGlobalLoglevel: (data: 'TRACE' | 'DEBUG' | 'INFO' | 'WARN' | 'ERROR', params: RequestParams = {}) =>
1867
+ this.request<void, BadRequest | Unauthorized | NotFound | InternalServerError | ServiceUnavailable>({
1868
+ path: `/utils/update-global-loglevel`,
1869
+ method: 'PUT',
1870
+ body: data,
1871
+ ...params
1872
+ }).then(convertHttpResponse),
1873
+
1874
+ /**
1875
+ * @description Update logback values
1876
+ *
1877
+ * @tags Utils
1878
+ * @name PutUtilsUpdateLogConfig
1879
+ * @request PUT:/utils/update-log-config
1880
+ */
1881
+ putUtilsUpdateLogConfig: (data?: LogbackValue[], params: RequestParams = {}) =>
1882
+ this.request<void, BadRequest | Unauthorized | NotFound | InternalServerError | ServiceUnavailable>({
1883
+ path: `/utils/update-log-config`,
1884
+ method: 'PUT',
1885
+ body: data,
1886
+ type: ContentType.Json,
2063
1887
  ...params
2064
1888
  }).then(convertHttpResponse)
2065
1889
  }