forked from HcashOrg/hcd
-
Notifications
You must be signed in to change notification settings - Fork 0
/
ominiresults.go
902 lines (822 loc) · 36.1 KB
/
ominiresults.go
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
706
707
708
709
710
711
712
713
714
715
716
717
718
719
720
721
722
723
724
725
726
727
728
729
730
731
732
733
734
735
736
737
738
739
740
741
742
743
744
745
746
747
748
749
750
751
752
753
754
755
756
757
758
759
760
761
762
763
764
765
766
767
768
769
770
771
772
773
774
775
776
777
778
779
780
781
782
783
784
785
786
787
788
789
790
791
792
793
794
795
796
797
798
799
800
801
802
803
804
805
806
807
808
809
810
811
812
813
814
815
816
817
818
819
820
821
822
823
824
825
826
827
828
829
830
831
832
833
834
835
836
837
838
839
840
841
842
843
844
845
846
847
848
849
850
851
852
853
854
855
856
857
858
859
860
861
862
863
864
865
866
867
868
869
870
871
872
873
874
875
876
877
878
879
880
881
882
883
884
885
886
887
888
889
890
891
892
893
894
895
896
897
898
899
900
901
902
package hcjson
type OmniSendResult struct {
/*
"hash" // (string) the hex-encoded transaction hash
*/
}
type OmniSenddexsellResult struct {
/*
"hash" // (string) the hex-encoded transaction hash
*/
}
type OmniSenddexacceptResult struct {
/*
"hash" // (string) the hex-encoded transaction hash
*/
}
type OmniSendissuancecrowdsaleResult struct {
/*
"hash" // (string) the hex-encoded transaction hash
*/
}
type OmniSendissuancefixedResult struct {
/*
"hash" // (string) the hex-encoded transaction hash
*/
}
type OmniSendissuancemanagedResult struct {
/*
"hash" // (string) the hex-encoded transaction hash
*/
}
type OmniSendstoResult struct {
/*
"hash" // (string) the hex-encoded transaction hash
*/
}
type OmniSendgrantResult struct {
/*
"hash" // (string) the hex-encoded transaction hash
*/
}
type OmniSendrevokeResult struct {
/*
"hash" // (string) the hex-encoded transaction hash
*/
}
type OmniSendclosecrowdsaleResult struct {
/*
"hash" // (string) the hex-encoded transaction hash
*/
}
type OmniSendtradeResult struct {
/*
"hash" // (string) the hex-encoded transaction hash
*/
}
type OmniSendcanceltradesbypriceResult struct {
/*
"hash" // (string) the hex-encoded transaction hash
*/
}
type OmniSendcanceltradesbypairResult struct {
/*
"hash" // (string) the hex-encoded transaction hash
*/
}
type OmniSendcancelalltradesResult struct {
/*
"hash" // (string) the hex-encoded transaction hash
*/
}
type OmniSendchangeissuerResult struct {
/*
"hash" // (string) the hex-encoded transaction hash
*/
}
type OmniSendallResult struct {
/*
"hash" // (string) the hex-encoded transaction hash
*/
}
type OmniSendenablefreezingResult struct {
/*
"hash" // (string) the hex-encoded transaction hash
*/
}
type OmniSenddisablefreezingResult struct {
/*
"hash" // (string) the hex-encoded transaction hash
*/
}
type OmniSendfreezeResult struct {
/*
"hash" // (string) the hex-encoded transaction hash
*/
}
type OmniSendunfreezeResult struct {
/*
"hash" // (string) the hex-encoded transaction hash
*/
}
type OmniSendrawtxResult struct {
/*
"hash" // (string) the hex-encoded transaction hash
*/
}
type OmniFundedSendResult struct {
/*
"hash" // (string) the hex-encoded transaction hash
*/
}
type OmniFundedSendallResult struct {
/*
"hash" // (string) the hex-encoded transaction hash
*/
}
type OmniGetinfoResult struct {
/*
{
"omnicoreversion_int" : xxxxxxx, // (number) client version as integer
"omnicoreversion" : "x.x.x.x-xxx", // (string) client version
"mastercoreversion" : "x.x.x.x-xxx", // (string) client version (DEPRECIATED)
"bitcoincoreversion" : "x.x.x", // (string) Bitcoin Core version
"commitinfo" : "xxxxxxx", // (string) build commit identifier
"block" : nnnnnn, // (number) index of the last processed block
"blocktime" : nnnnnnnnnn, // (number) timestamp of the last processed block
"blocktransactions" : nnnn, // (number) Omni transactions found in the last processed block
"totaltransactions" : nnnnnnnn, // (number) Omni transactions processed in total
"alerts" : [ // (array of JSON objects) active protocol alert (if any)
{
"alerttype" : n // (number) alert type as integer
"alerttype" : "xxx" // (string) alert type (can be "alertexpiringbyblock", "alertexpiringbyblocktime", "alertexpiringbyclientversion" or "error")
"alertexpiry" : "nnnnnnnnnn" // (string) expiration criteria (can refer to block height, timestamp or client verion)
"alertmessage" : "xxx" // (string) information about the alert
},
...
]
}
*/
}
type OmniGetbalanceResult struct {
/*
{
"balance" : "n.nnnnnnnn", // (string) the available balance of the address
"reserved" : "n.nnnnnnnn", // (string) the amount reserved by sell offers and accepts
"frozen" : "n.nnnnnnnn" // (string) the amount frozen by the issuer (applies to managed properties only)
}
*/
}
type OmniGetallbalancesforidResult struct {
/*
[ // (array of JSON objects)
{
"address" : "address", // (string) the address
"balance" : "n.nnnnnnnn", // (string) the available balance of the address
"reserved" : "n.nnnnnnnn", // (string) the amount reserved by sell offers and accepts
"frozen" : "n.nnnnnnnn" // (string) the amount frozen by the issuer (applies to managed properties only)
},
...
]
*/
}
type OmniGetallbalancesforaddressResult struct {
/*
[ // (array of JSON objects)
{
"propertyid" : n, // (number) the property identifier
"name" : "name", // (string) the name of the property
"balance" : "n.nnnnnnnn", // (string) the available balance of the address
"reserved" : "n.nnnnnnnn", // (string) the amount reserved by sell offers and accepts
"frozen" : "n.nnnnnnnn" // (string) the amount frozen by the issuer (applies to managed properties only)
},
...
]
*/
}
type OmniGetwalletbalancesResult struct {
/*
[ // (array of JSON objects)
{
"propertyid" : n, // (number) the property identifier
"name" : "name", // (string) the name of the token
"balance" : "n.nnnnnnnn", // (string) the total available balance for the token
"reserved" : "n.nnnnnnnn" // (string) the total amount reserved by sell offers and accepts
"frozen" : "n.nnnnnnnn" // (string) the total amount frozen by the issuer (applies to managed properties only)
},
...
]
*/
}
type OmniGetwalletaddressbalancesResult struct {
/*
[ // (array of JSON objects)
{
"address" : "address", // (string) the address linked to the following balances
"balances" :
[
{
"propertyid" : n, // (number) the property identifier
"name" : "name", // (string) the name of the token
"balance" : "n.nnnnnnnn", // (string) the available balance for the token
"reserved" : "n.nnnnnnnn" // (string) the amount reserved by sell offers and accepts
"frozen" : "n.nnnnnnnn" // (string) the amount frozen by the issuer (applies to managed properties only)
},
...
]
},
...
]
*/
}
type OmniGettransactionResult struct {
/*
{
"txid" : "hash", // (string) the hex-encoded hash of the transaction
"sendingaddress" : "address", // (string) the Bitcoin address of the sender
"referenceaddress" : "address", // (string) a Bitcoin address used as reference (if any)
"ismine" : true|false, // (boolean) whether the transaction involes an address in the wallet
"confirmations" : nnnnnnnnnn, // (number) the number of transaction confirmations
"fee" : "n.nnnnnnnn", // (string) the transaction fee in bitcoins
"blocktime" : nnnnnnnnnn, // (number) the timestamp of the block that contains the transaction
"valid" : true|false, // (boolean) whether the transaction is valid
"positioninblock" : n, // (number) the position (index) of the transaction within the block
"version" : n, // (number) the transaction version
"type_int" : n, // (number) the transaction type as number
"type" : "type", // (string) the transaction type as string
[...] // (mixed) other transaction type specific properties
}
*/
}
type OmniListtransactionsResult struct {
/*
[ // (array of JSON objects)
{
"txid" : "hash", // (string) the hex-encoded hash of the transaction
"sendingaddress" : "address", // (string) the Bitcoin address of the sender
"referenceaddress" : "address", // (string) a Bitcoin address used as reference (if any)
"ismine" : true|false, // (boolean) whether the transaction involves an address in the wallet
"confirmations" : nnnnnnnnnn, // (number) the number of transaction confirmations
"fee" : "n.nnnnnnnn", // (string) the transaction fee in bitcoins
"blocktime" : nnnnnnnnnn, // (number) the timestamp of the block that contains the transaction
"valid" : true|false, // (boolean) whether the transaction is valid
"positioninblock" : n, // (number) the position (index) of the transaction within the block
"version" : n, // (number) the transaction version
"type_int" : n, // (number) the transaction type as number
"type" : "type", // (string) the transaction type as string
[...] // (mixed) other transaction type specific properties
},
...
]
*/
}
type OmniListblocktransactionsResult struct {
/*
[ // (array of string)
"hash", // (string) the hash of the transaction
...
]
*/
}
type OmniListpendingtransactionsResult struct {
/*
[ // (array of JSON objects)
{
"txid" : "hash", // (string) the hex-encoded hash of the transaction
"sendingaddress" : "address", // (string) the Bitcoin address of the sender
"referenceaddress" : "address", // (string) a Bitcoin address used as reference (if any)
"ismine" : true|false, // (boolean) whether the transaction involes an address in the wallet
"fee" : "n.nnnnnnnn", // (string) the transaction fee in bitcoins
"version" : n, // (number) the transaction version
"type_int" : n, // (number) the transaction type as number
"type" : "type", // (string) the transaction type as string
[...] // (mixed) other transaction type specific properties
},
...
]
*/
}
type OmniGetactivedexsellsResult struct {
/*
[ // (array of JSON objects)
{
"txid" : "hash", // (string) the hash of the transaction of this offer
"propertyid" : n, // (number) the identifier of the tokens for sale
"seller" : "address", // (string) the Bitcoin address of the seller
"amountavailable" : "n.nnnnnnnn", // (string) the number of tokens still listed for sale and currently available
"bitcoindesired" : "n.nnnnnnnn", // (string) the number of bitcoins desired in exchange
"unitprice" : "n.nnnnnnnn" , // (string) the unit price (BTC/token)
"timelimit" : nn, // (number) the time limit in blocks a buyer has to pay following a successful accept
"minimumfee" : "n.nnnnnnnn", // (string) the minimum mining fee a buyer has to pay to accept this offer
"amountaccepted" : "n.nnnnnnnn", // (string) the number of tokens currently reserved for pending "accept" orders
"accepts": [ // (array of JSON objects) a list of pending "accept" orders
{
"buyer" : "address", // (string) the Bitcoin address of the buyer
"block" : nnnnnn, // (number) the index of the block that contains the "accept" order
"blocksleft" : nn, // (number) the number of blocks left to pay
"amount" : "n.nnnnnnnn" // (string) the amount of tokens accepted and reserved
"amounttopay" : "n.nnnnnnnn" // (string) the amount in bitcoins needed finalize the trade
},
...
]
},
...
]
*/
}
type OmniListpropertiesResult struct {
/*
[ // (array of JSON objects)
{
"propertyid" : n, // (number) the identifier of the tokens
"name" : "name", // (string) the name of the tokens
"category" : "category", // (string) the category used for the tokens
"subcategory" : "subcategory", // (string) the subcategory used for the tokens
"data" : "information", // (string) additional information or a description
"url" : "uri", // (string) an URI, for example pointing to a website
"divisible" : true|false // (boolean) whether the tokens are divisible
},
...
]
*/
}
type OmniGetpropertyResult struct {
/*
{
"propertyid" : n, // (number) the identifier
"name" : "name", // (string) the name of the tokens
"category" : "category", // (string) the category used for the tokens
"subcategory" : "subcategory", // (string) the subcategory used for the tokens
"data" : "information", // (string) additional information or a description
"url" : "uri", // (string) an URI, for example pointing to a website
"divisible" : true|false, // (boolean) whether the tokens are divisible
"issuer" : "address", // (string) the Bitcoin address of the issuer on record
"creationtxid" : "hash", // (string) the hex-encoded creation transaction hash
"fixedissuance" : true|false, // (boolean) whether the token supply is fixed
"managedissuance" : true|false, // (boolean) whether the token supply is managed by the issuer
"freezingenabled" : true|false, // (boolean) whether freezing is enabled for the property (managed properties only)
"totaltokens" : "n.nnnnnnnn" // (string) the total number of tokens in existence
}
*/
}
type OmniGetactivecrowdsalesResult struct {
/*
[ // (array of JSON objects)
{
"propertyid" : n, // (number) the identifier of the crowdsale
"name" : "name", // (string) the name of the tokens issued via the crowdsale
"issuer" : "address", // (string) the Bitcoin address of the issuer on record
"propertyiddesired" : n, // (number) the identifier of the tokens eligible to participate in the crowdsale
"tokensperunit" : "n.nnnnnnnn", // (string) the amount of tokens granted per unit invested in the crowdsale
"earlybonus" : n, // (number) an early bird bonus for participants in percent per week
"percenttoissuer" : n, // (number) a percentage of tokens that will be granted to the issuer
"starttime" : nnnnnnnnnn, // (number) the start time of the of the crowdsale as Unix timestamp
"deadline" : nnnnnnnnnn // (number) the deadline of the crowdsale as Unix timestamp
},
...
]
*/
}
type OmniGetcrowdsaleResult struct {
/*
{
"propertyid" : n, // (number) the identifier of the crowdsale
"name" : "name", // (string) the name of the tokens issued via the crowdsale
"active" : true|false, // (boolean) whether the crowdsale is still active
"issuer" : "address", // (string) the Bitcoin address of the issuer on record
"propertyiddesired" : n, // (number) the identifier of the tokens eligible to participate in the crowdsale
"tokensperunit" : "n.nnnnnnnn", // (string) the amount of tokens granted per unit invested in the crowdsale
"earlybonus" : n, // (number) an early bird bonus for participants in percent per week
"percenttoissuer" : n, // (number) a percentage of tokens that will be granted to the issuer
"starttime" : nnnnnnnnnn, // (number) the start time of the of the crowdsale as Unix timestamp
"deadline" : nnnnnnnnnn, // (number) the deadline of the crowdsale as Unix timestamp
"amountraised" : "n.nnnnnnnn", // (string) the amount of tokens invested by participants
"tokensissued" : "n.nnnnnnnn", // (string) the total number of tokens issued via the crowdsale
"issuerbonustokens" : "n.nnnnnnnn", // (string) the amount of tokens granted to the issuer as bonus
"addedissuertokens" : "n.nnnnnnnn", // (string) the amount of issuer bonus tokens not yet emitted
"closedearly" : true|false, // (boolean) whether the crowdsale ended early (if not active)
"maxtokens" : true|false, // (boolean) whether the crowdsale ended early due to reaching the limit of max. issuable tokens (if not active)
"endedtime" : nnnnnnnnnn, // (number) the time when the crowdsale ended (if closed early)
"closetx" : "hash", // (string) the hex-encoded hash of the transaction that closed the crowdsale (if closed manually)
"participanttransactions": [ // (array of JSON objects) a list of crowdsale participations (if verbose=true)
{
"txid" : "hash", // (string) the hex-encoded hash of participation transaction
"amountsent" : "n.nnnnnnnn", // (string) the amount of tokens invested by the participant
"participanttokens" : "n.nnnnnnnn", // (string) the tokens granted to the participant
"issuertokens" : "n.nnnnnnnn" // (string) the tokens granted to the issuer as bonus
},
...
]
}
*/
}
type OmniGetgrantsResult struct {
/*
{
"propertyid" : n, // (number) the identifier of the managed tokens
"name" : "name", // (string) the name of the tokens
"issuer" : "address", // (string) the Bitcoin address of the issuer on record
"creationtxid" : "hash", // (string) the hex-encoded creation transaction hash
"totaltokens" : "n.nnnnnnnn", // (string) the total number of tokens in existence
"issuances": [ // (array of JSON objects) a list of the granted and revoked tokens
{
"txid" : "hash", // (string) the hash of the transaction that granted tokens
"grant" : "n.nnnnnnnn" // (string) the number of tokens granted by this transaction
},
{
"txid" : "hash", // (string) the hash of the transaction that revoked tokens
"grant" : "n.nnnnnnnn" // (string) the number of tokens revoked by this transaction
},
...
]
}
*/
}
type OmniGetstoResult struct {
/*
{
"txid" : "hash", // (string) the hex-encoded hash of the transaction
"sendingaddress" : "address", // (string) the Bitcoin address of the sender
"ismine" : true|false, // (boolean) whether the transaction involes an address in the wallet
"confirmations" : nnnnnnnnnn, // (number) the number of transaction confirmations
"fee" : "n.nnnnnnnn", // (string) the transaction fee in bitcoins
"blocktime" : nnnnnnnnnn, // (number) the timestamp of the block that contains the transaction
"valid" : true|false, // (boolean) whether the transaction is valid
"positioninblock" : n, // (number) the position (index) of the transaction within the block
"version" : n, // (number) the transaction version
"type_int" : n, // (number) the transaction type as number
"type" : "type", // (string) the transaction type as string
"propertyid" : n, // (number) the identifier of sent tokens
"divisible" : true|false, // (boolean) whether the sent tokens are divisible
"amount" : "n.nnnnnnnn", // (string) the number of tokens sent to owners
"totalstofee" : "n.nnnnnnnn", // (string) the fee paid by the sender, nominated in OMNI or TOMNI
"recipients": [ // (array of JSON objects) a list of recipients
{
"address" : "address", // (string) the Bitcoin address of the recipient
"amount" : "n.nnnnnnnn" // (string) the number of tokens sent to this recipient
},
...
]
}
*/
}
type OmniGettradeResult struct {
/*
{
"txid" : "hash", // (string) the hex-encoded hash of the transaction of the order
"sendingaddress" : "address", // (string) the Bitcoin address of the trader
"ismine" : true|false, // (boolean) whether the order involes an address in the wallet
"confirmations" : nnnnnnnnnn, // (number) the number of transaction confirmations
"fee" : "n.nnnnnnnn", // (string) the transaction fee in bitcoins
"blocktime" : nnnnnnnnnn, // (number) the timestamp of the block that contains the transaction
"valid" : true|false, // (boolean) whether the transaction is valid
"positioninblock" : n, // (number) the position (index) of the transaction within the block
"version" : n, // (number) the transaction version
"type_int" : n, // (number) the transaction type as number
"type" : "type", // (string) the transaction type as string
"propertyidforsale" : n, // (number) the identifier of the tokens put up for sale
"propertyidforsaleisdivisible" : true|false, // (boolean) whether the tokens for sale are divisible
"amountforsale" : "n.nnnnnnnn", // (string) the amount of tokens initially offered
"propertyiddesired" : n, // (number) the identifier of the tokens desired in exchange
"propertyiddesiredisdivisible" : true|false, // (boolean) whether the desired tokens are divisible
"amountdesired" : "n.nnnnnnnn", // (string) the amount of tokens initially desired
"unitprice" : "n.nnnnnnnnnnn..." // (string) the unit price (shown in the property desired)
"status" : "status" // (string) the status of the order ("open", "cancelled", "filled", ...)
"canceltxid" : "hash", // (string) the hash of the transaction that cancelled the order (if cancelled)
"matches": [ // (array of JSON objects) a list of matched orders and executed trades
{
"txid" : "hash", // (string) the hash of the transaction that was matched against
"block" : nnnnnn, // (number) the index of the block that contains this transaction
"address" : "address", // (string) the Bitcoin address of the other trader
"amountsold" : "n.nnnnnnnn", // (string) the number of tokens sold in this trade
"amountreceived" : "n.nnnnnnnn" // (string) the number of tokens traded in exchange
},
...
]
}
*/
}
type OmniGetorderbookResult struct {
/*
[ // (array of JSON objects)
{
"address" : "address", // (string) the Bitcoin address of the trader
"txid" : "hash", // (string) the hex-encoded hash of the transaction of the order
"ecosystem" : "main"|"test", // (string) the ecosytem in which the order was made (if "cancel-ecosystem")
"propertyidforsale" : n, // (number) the identifier of the tokens put up for sale
"propertyidforsaleisdivisible" : true|false, // (boolean) whether the tokens for sale are divisible
"amountforsale" : "n.nnnnnnnn", // (string) the amount of tokens initially offered
"amountremaining" : "n.nnnnnnnn", // (string) the amount of tokens still up for sale
"propertyiddesired" : n, // (number) the identifier of the tokens desired in exchange
"propertyiddesiredisdivisible" : true|false, // (boolean) whether the desired tokens are divisible
"amountdesired" : "n.nnnnnnnn", // (string) the amount of tokens initially desired
"amounttofill" : "n.nnnnnnnn", // (string) the amount of tokens still needed to fill the offer completely
"action" : n, // (number) the action of the transaction: (1) "trade", (2) "cancel-price", (3) "cancel-pair", (4) "cancel-ecosystem"
"block" : nnnnnn, // (number) the index of the block that contains the transaction
"blocktime" : nnnnnnnnnn // (number) the timestamp of the block that contains the transaction
},
...
]
*/
}
type OmniGettradehistoryforpairResult struct {
/*
[ // (array of JSON objects)
{
"block" : nnnnnn, // (number) the index of the block that contains the trade match
"unitprice" : "n.nnnnnnnnnnn..." , // (string) the unit price used to execute this trade (received/sold)
"inverseprice" : "n.nnnnnnnnnnn...", // (string) the inverse unit price (sold/received)
"sellertxid" : "hash", // (string) the hash of the transaction of the seller
"address" : "address", // (string) the Bitcoin address of the seller
"amountsold" : "n.nnnnnnnn", // (string) the number of tokens sold in this trade
"amountreceived" : "n.nnnnnnnn", // (string) the number of tokens traded in exchange
"matchingtxid" : "hash", // (string) the hash of the transaction that was matched against
"matchingaddress" : "address" // (string) the Bitcoin address of the other party of this trade
},
...
]
*/
}
type OmniGettradehistoryforaddressResult struct {
/*
[ // (array of JSON objects)
{
"txid" : "hash", // (string) the hex-encoded hash of the transaction of the order
"sendingaddress" : "address", // (string) the Bitcoin address of the trader
"ismine" : true|false, // (boolean) whether the order involes an address in the wallet
"confirmations" : nnnnnnnnnn, // (number) the number of transaction confirmations
"fee" : "n.nnnnnnnn", // (string) the transaction fee in bitcoins
"blocktime" : nnnnnnnnnn, // (number) the timestamp of the block that contains the transaction
"valid" : true|false, // (boolean) whether the transaction is valid
"positioninblock" : n, // (number) the position (index) of the transaction within the block
"version" : n, // (number) the transaction version
"type_int" : n, // (number) the transaction type as number
"type" : "type", // (string) the transaction type as string
"propertyidforsale" : n, // (number) the identifier of the tokens put up for sale
"propertyidforsaleisdivisible" : true|false, // (boolean) whether the tokens for sale are divisible
"amountforsale" : "n.nnnnnnnn", // (string) the amount of tokens initially offered
"propertyiddesired" : n, // (number) the identifier of the tokens desired in exchange
"propertyiddesiredisdivisible" : true|false, // (boolean) whether the desired tokens are divisible
"amountdesired" : "n.nnnnnnnn", // (string) the amount of tokens initially desired
"unitprice" : "n.nnnnnnnnnnn..." // (string) the unit price (shown in the property desired)
"status" : "status" // (string) the status of the order ("open", "cancelled", "filled", ...)
"canceltxid" : "hash", // (string) the hash of the transaction that cancelled the order (if cancelled)
"matches": [ // (array of JSON objects) a list of matched orders and executed trades
{
"txid" : "hash", // (string) the hash of the transaction that was matched against
"block" : nnnnnn, // (number) the index of the block that contains this transaction
"address" : "address", // (string) the Bitcoin address of the other trader
"amountsold" : "n.nnnnnnnn", // (string) the number of tokens sold in this trade
"amountreceived" : "n.nnnnnnnn" // (string) the number of tokens traded in exchange
},
...
]
},
...
]
*/
}
type OmniGetactivationsResult struct {
/*
{
"pendingactivations": [ // (array of JSON objects) a list of pending feature activations
{
"featureid" : n, // (number) the id of the feature
"featurename" : "xxxxxxxx", // (string) the name of the feature
"activationblock" : n, // (number) the block the feature will be activated
"minimumversion" : n // (number) the minimum client version needed to support this feature
},
...
]
"completedactivations": [ // (array of JSON objects) a list of completed feature activations
{
"featureid" : n, // (number) the id of the feature
"featurename" : "xxxxxxxx", // (string) the name of the feature
"activationblock" : n, // (number) the block the feature will be activated
"minimumversion" : n // (number) the minimum client version needed to support this feature
},
...
]
}
*/
}
type OmniGetpayloadResult struct {
/*
{
"payload" : "payloadmessage", // (string) the decoded Omni payload message
"payloadsize" : n // (number) the size of the payload
}
*/
}
type OmniGetseedblocksResult struct {
/*
[ // (array of numbers) a list of seed blocks
nnnnnnn, // the block height of the seed block
...
]
*/
}
type OmniGetcurrentconsensushashResult struct {
/*
{
"block" : nnnnnn, // (number) the index of the block this consensus hash applies to
"blockhash" : "hash", // (string) the hash of the corresponding block
"consensushash" : "hash" // (string) the consensus hash for the block
}
*/
}
type OmniDecodetransactionResult struct {
/*
{
"txid" : "hash", // (string) the hex-encoded hash of the transaction
"fee" : "n.nnnnnnnn", // (string) the transaction fee in bitcoins
"sendingaddress" : "address", // (string) the Bitcoin address of the sender
"referenceaddress" : "address", // (string) a Bitcoin address used as reference (if any)
"ismine" : true|false, // (boolean) whether the transaction involes an address in the wallet
"version" : n, // (number) the transaction version
"type_int" : n, // (number) the transaction type as number
"type" : "type", // (string) the transaction type as string
[...] // (mixed) other transaction type specific properties
}
*/
}
type OmniCreaterawtxOpreturnResult struct {
/*
"rawtx" // (string) the hex-encoded modified raw transaction
*/
}
type OmniCreaterawtxMultisigResult struct {
/*
"rawtx" // (string) the hex-encoded modified raw transaction
*/
}
type OmniCreaterawtxInputResult struct {
/*
"rawtx" // (string) the hex-encoded modified raw transaction
*/
}
type OmniCreaterawtxReferenceResult struct {
/*
"rawtx" // (string) the hex-encoded modified raw transaction
*/
}
type OmniCreaterawtxChangeResult struct {
/*
"rawtx" // (string) the hex-encoded modified raw transaction
*/
}
type OmniCreatepayloadSimplesendResult struct {
/*
"payload" // (string) the hex-encoded payload
*/
}
type OmniCreatepayloadSendallResult struct {
/*
"payload" // (string) the hex-encoded payload
*/
}
type OmniCreatepayloadDexsellResult struct {
/*
"payload" // (string) the hex-encoded payload
*/
}
type OmniCreatepayloadDexacceptResult struct {
/*
"payload" // (string) the hex-encoded payload
*/
}
type OmniCreatepayloadStoResult struct {
/*
"payload" // (string) the hex-encoded payload
*/
}
type OmniCreatepayloadIssuancefixedResult struct {
/*
"payload" // (string) the hex-encoded payload
*/
}
type OmniCreatepayloadIssuancecrowdsaleResult struct {
/*
"payload" // (string) the hex-encoded payload
*/
}
type OmniCreatepayloadIssuancemanagedResult struct {
/*
"payload" // (string) the hex-encoded payload
*/
}
type OmniCreatepayloadClosecrowdsaleResult struct {
/*
"payload" // (string) the hex-encoded payload
*/
}
type OmniCreatepayloadGrantResult struct {
/*
"payload" // (string) the hex-encoded payload
*/
}
type OmniCreatepayloadRevokeResult struct {
/*
"payload" // (string) the hex-encoded payload
*/
}
type OmniCreatepayloadChangeissuerResult struct {
/*
"payload" // (string) the hex-encoded payload
*/
}
type OmniCreatepayloadTradeResult struct {
/*
"payload" // (string) the hex-encoded payload
*/
}
type OmniCreatepayloadCanceltradesbypriceResult struct {
/*
"payload" // (string) the hex-encoded payload
*/
}
type OmniCreatepayloadCanceltradesbypairResult struct {
/*
"payload" // (string) the hex-encoded payload
*/
}
type OmniCreatepayloadCancelalltradesResult struct {
/*
"payload" // (string) the hex-encoded payload
*/
}
type OmniCreatepayloadEnablefreezingResult struct {
/*
"payload" // (string) the hex-encoded payload
*/
}
type OmniCreatepayloadDisablefreezingResult struct {
/*
"payload" // (string) the hex-encoded payload
*/
}
type OmniCreatepayloadFreezeResult struct {
/*
"payload" // (string) the hex-encoded payload
*/
}
type OmniCreatepayloadUnfreezeResult struct {
/*
"payload" // (string) the hex-encoded payload
*/
}
type OmniGetfeecacheResult struct {
/*
[ // (array of JSON objects)
{
"propertyid" : nnnnnnn, // (number) the property id
"cachedfees" : "n.nnnnnnnn", // (string) the amount of fees cached for this property
},
...
]
*/
}
type OmniGetfeetriggerResult struct {
/*
[ // (array of JSON objects)
{
"propertyid" : nnnnnnn, // (number) the property id
"feetrigger" : "n.nnnnnnnn", // (string) the amount of fees required to trigger distribution
},
...
]
*/
}
type OmniGetfeeshareResult struct {
/*
[ // (array of JSON objects)
{
"address" : "address" // (string) the adress that would receive a share of fees
"feeshare" : "n.nnnn%", // (string) the percentage of fees this address will receive based on the current state
},
...
]
*/
}
type OmniGetfeedistributionResult struct {
/*
{
"distributionid" : n, // (number) the distribution id
"propertyid" : n, // (number) the property id of the distributed tokens
"block" : n, // (number) the block the distribution occurred
"amount" : "n.nnnnnnnn", // (string) the amount that was distributed
"recipients": [ // (array of JSON objects) a list of recipients
{
"address" : "address", // (string) the address of the recipient
"amount" : "n.nnnnnnnn" // (string) the amount of fees received by the recipient
},
...
]
}
*/
}
type OmniGetfeedistributionsResult struct {
/*
[ // (array of JSON objects)
{
"distributionid" : n, // (number) the distribution id
"propertyid" : n, // (number) the property id of the distributed tokens
"block" : n, // (number) the block the distribution occurred
"amount" : "n.nnnnnnnn", // (string) the amount that was distributed
"recipients": [ // (array of JSON objects) a list of recipients
{
"address" : "address", // (string) the address of the recipient
"amount" : "n.nnnnnnnn" // (string) the amount of fees received by the recipient
},
...
]
},
...
]
*/
}
type OmniSetautocommitResult struct {
/*
true|false // (boolean) the updated flag status
*/
}