-
Notifications
You must be signed in to change notification settings - Fork 6
Expand file tree
/
Copy pathschema.graphql
More file actions
executable file
·1105 lines (1053 loc) · 34.2 KB
/
schema.graphql
File metadata and controls
executable file
·1105 lines (1053 loc) · 34.2 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
706
707
708
709
710
711
712
713
714
715
716
717
718
719
720
721
722
723
724
725
726
727
728
729
730
731
732
733
734
735
736
737
738
739
740
741
742
743
744
745
746
747
748
749
750
751
752
753
754
755
756
757
758
759
760
761
762
763
764
765
766
767
768
769
770
771
772
773
774
775
776
777
778
779
780
781
782
783
784
785
786
787
788
789
790
791
792
793
794
795
796
797
798
799
800
801
802
803
804
805
806
807
808
809
810
811
812
813
814
815
816
817
818
819
820
821
822
823
824
825
826
827
828
829
830
831
832
833
834
835
836
837
838
839
840
841
842
843
844
845
846
847
848
849
850
851
852
853
854
855
856
857
858
859
860
861
862
863
864
865
866
867
868
869
870
871
872
873
874
875
876
877
878
879
880
881
882
883
884
885
886
887
888
889
890
891
892
893
894
895
896
897
898
899
900
901
902
903
904
905
906
907
908
909
910
911
912
913
914
915
916
917
918
919
920
921
922
923
924
925
926
927
928
929
930
931
932
933
934
935
936
937
938
939
940
941
942
943
944
945
946
947
948
949
950
951
952
953
954
955
956
957
958
959
960
961
962
963
964
965
966
967
968
969
970
971
972
973
974
975
976
977
978
979
980
981
982
983
984
985
986
987
988
989
990
991
992
993
994
995
996
997
998
999
1000
"""
Livepeer protocol global parameters
"""
type Protocol @entity {
"ID is set to 0"
id: ID!
"Per round inflation rate"
inflation: BigInt!
"Change in inflation rate per round until the target bonding rate is achieved"
inflationChange: BigInt!
"Limit of active transcoders"
numActiveTranscoders: BigInt!
"Total active transcoders (up to the limit)"
activeTranscoderCount: BigInt!
"True if the protocol is paused"
paused: Boolean!
"Target bonding rate (participation) that determines whether inflation should increase or decrease"
targetBondingRate: BigInt!
"Time in blocks needed to wait to unstake"
unbondingPeriod: BigInt!
"Time in blocks delegators have to review transcoder information without changes"
lockPeriod: BigInt!
"Lock period of a round as a % of round length"
roundLockAmount: BigInt!
"The total amount of active LPT staked"
totalActiveStake: BigDecimal!
"Total broadcaster fees transcoders have accumulated in ETH"
totalVolumeETH: BigDecimal!
"Total broadcaster fees transcoders have accumulated in USD"
totalVolumeUSD: BigDecimal!
"Ratio of total active stake to total supply"
participationRate: BigDecimal!
"Current round the protocol is in"
currentRound: Round!
"Round that was last initialized"
lastInitializedRound: Round!
"Round when round length was last updated"
lastRoundLengthUpdateRound: Round!
"Round length in blocks"
roundLength: BigInt!
"Block when round length was last updated"
lastRoundLengthUpdateStartBlock: BigInt!
"Livepeer Token supply"
totalSupply: BigDecimal!
"Livepeer Token price in ETH (not to be used for trading - updated only every round)"
lptPriceEth: BigDecimal!
"Total winning tickets"
winningTicketCount: Int!
"Total rounds"
roundCount: Int!
"Transcoders pending activation"
pendingActivation: [Transcoder!]!
"Transcoders pending deactivation"
pendingDeactivation: [Transcoder!]!
"Total number of delegators on the network"
delegatorsCount: BigInt!
"Broadcasters that paid tickets within the current 90 day fee window"
activeBroadcasters: [String!]!
}
"""
Perform transcoding work for the network. The transcoders with the most delegated stake are elected as active transcoders that process transcode jobs for the network.
"""
type Transcoder @entity {
"Transcoder's ETH address"
id: ID!
"Round in which the transcoder became active - 0 if inactive"
activationRound: BigInt!
"Round in which the transcoder will become inactive"
deactivationRound: BigInt!
"Round for which the stake was last updated while the transcoder is active"
lastActiveStakeUpdateRound: BigInt!
"Whether or not the transcoder is active"
active: Boolean!
"Status of the transcoder"
status: TranscoderStatus!
"The activation date beginning at 12:00am UTC"
activationTimestamp: Int!
"Last round that the transcoder called reward"
lastRewardRound: Round
"% of block reward cut paid to transcoder by a delegator"
rewardCut: BigInt!
"The last timestamped update to reward cut, beginning at 12:00am UTC"
rewardCutUpdateTimestamp: Int!
"% of fees paid to delegators by transcoder"
feeShare: BigInt!
"The last timestamped update to fee share, beginning at 12:00am UTC"
feeShareUpdateTimestamp: Int!
"Total tokens delegated toward a transcoder (including their own)"
totalStake: BigDecimal!
"Total fees generated by the transcoder in ETH (before distribution to delegators)"
totalVolumeETH: BigDecimal!
"Total fees generated by the transcoder in ETH (before distribution and in past 30 days)"
thirtyDayVolumeETH: BigDecimal!
"Total fees generated by the transcoder in ETH (before distribution and in past 60 days)"
sixtyDayVolumeETH: BigDecimal!
"Total fees generated by the transcoder in ETH (before distribution and in past 90 days)"
ninetyDayVolumeETH: BigDecimal!
"Total fees generated by the transcoder in USD (before distribution to delegators)"
totalVolumeUSD: BigDecimal!
"Pools associated with the transcoder"
pools: [Pool!] @derivedFrom(field: "delegate")
"Delegators bonded to the transcoder"
delegators: [Delegator!] @derivedFrom(field: "delegate")
"Delegator that registered this transcoder"
delegator: Delegator
"Service URI endpoint that can be used to send off-chain requests"
serviceURI: String
"Days which the transcoder earned fees"
transcoderDays: [TranscoderDay!]!
}
enum TranscoderStatus @entity {
NotRegistered
Registered
}
"""
Represents a transcoder's rewards and fees to be distributed to delegators
"""
type Pool @entity {
"Unique identifer for the pool (formed using the transcoder's address and round number)"
id: ID!
"Round associated with the pool"
round: Round!
"Transcoder associated with the pool"
delegate: Transcoder!
"Fees collected in the pool"
fees: BigDecimal!
"Total reward tokens collected in the pool"
rewardTokens: BigDecimal
"Transcoder's total stake during the earnings pool's round"
totalStake: BigDecimal!
"Transcoder's reward cut during the earnings pool's round"
rewardCut: BigInt!
"Transcoder's fee share during the earnings pool's round"
feeShare: BigInt!
}
"""
The Livepeer protocol is round based and each round is represented by some number of Ethereum blocks.
"""
type Round @entity {
"Round number"
id: ID!
"The start date beginning at 12:00am UTC"
startTimestamp: Int!
"Whether the round was initialized"
initialized: Boolean!
"Number of blocks this round lasts for"
length: BigInt!
"Start block for the round"
startBlock: BigInt!
"End block for the round"
endBlock: BigInt!
"Pools associated with the round"
pools: [Pool!] @derivedFrom(field: "round")
"Mintable tokens for the round"
mintableTokens: BigDecimal!
"Fees generated this round in ETH"
volumeETH: BigDecimal!
"Fees generated this round in USD"
volumeUSD: BigDecimal!
"Total active stake during the round"
totalActiveStake: BigDecimal!
"Total Livepeer token supply during the round"
totalSupply: BigDecimal!
"Participation rate during the round (totalActiveStake/totalSupply)"
participationRate: BigDecimal!
"Total stake moved from one delegate to another during the round"
movedStake: BigDecimal!
"Total amount of new stake introduced during the round"
newStake: BigDecimal!
"Per round inflation rate"
inflation: BigInt!
"Limit of active transcoders"
numActiveTranscoders: BigInt!
"Total active transcoders (up to the limit)"
activeTranscoderCount: BigInt!
"Total number of delegators at the start of the round"
delegatorsCount: BigInt!
}
"""
Bonded accounts who have delegated their stake towards a transcoder candidate
"""
type Delegator @entity {
"ETH address of a delegator"
id: ID!
"ETH address of the delegate (the one whom the delegator has bonded to)"
delegate: Transcoder
"Round the delegator becomes bonded and delegated to its delegate"
startRound: BigInt!
"Last round that the delegator claimed reward and fee pool shares"
lastClaimRound: Round
"Amount of Livepeer Token a delegator currently has bonded"
bondedAmount: BigDecimal!
"Amount of Livepeer Token a delegator has bonded over its lifetime separate from rewards"
principal: BigDecimal!
"Amount of Livepeer Token a delegator has unbonded over its lifetime"
unbonded: BigDecimal!
"Amount of fees a delegator has collected"
fees: BigDecimal!
"Amount of fees withdrawn"
withdrawnFees: BigDecimal!
"Amount of Livepeer Token the delegator has delegated"
delegatedAmount: BigDecimal!
"Unbonding locks associated with the delegator"
unbondingLocks: [UnbondingLock!] @derivedFrom(field: "delegator")
}
"""
Abstraction for accounts/delegators bonded with the protocol
"""
type LivepeerAccount @entity {
"ETH address of the bonded delegator"
id: ID!
"The date the account was last associated with an event, beginning at 12:00am UTC"
lastUpdatedTimestamp: Int!
"Delegator details for this account"
delegator: Delegator
"Reference to the Delegate this address is bonded to"
delegate: Transcoder
}
"""
Broadcasters pay transcoders to do the work of transcoding in exchange for fees
"""
type Broadcaster @entity {
"ETH address of a broadcaster"
id: ID!
"Amount of funds deposited"
deposit: BigDecimal!
"Amount of funds in reserve"
reserve: BigDecimal!
"Total fees paid out by this broadcaster in ETH"
totalVolumeETH: BigDecimal!
"Total fees paid out by this broadcaster in USD"
totalVolumeUSD: BigDecimal!
"Fees paid out by this broadcaster in ETH during the last 30 days"
thirtyDayVolumeETH: BigDecimal!
"Fees paid out by this broadcaster in ETH during the last 60 days"
sixtyDayVolumeETH: BigDecimal!
"Fees paid out by this broadcaster in ETH during the last 90 days"
ninetyDayVolumeETH: BigDecimal!
"The date this broadcaster first funded a deposit or reserve, beginning at 12:00am UTC"
firstFundedDay: Int!
"The date this broadcaster first funded a deposit or reserve, beginning at 12:00am UTC"
firstActiveDay: Int! @deprecated(reason: "Use firstFundedDay instead.")
"The date this broadcaster last paid fees, beginning at 12:00am UTC"
lastFundedDay: Int!
"The date this broadcaster last paid fees, beginning at 12:00am UTC"
lastActiveDay: Int! @deprecated(reason: "Use lastFundedDay instead.")
"Days in which this broadcaster paid out fees"
broadcasterDays: [BroadcasterDay!]!
}
"""
Get an unbonding lock for a delegator
"""
type UnbondingLock @entity {
"Unique unlock identifer"
id: ID!
"unbonding lock id"
unbondingLockId: Int!
"Delegator address this lock belongs to"
delegator: Delegator!
"Address of delegate unbonding from"
delegate: Transcoder!
"Amount being unbonded"
amount: BigDecimal!
"Round number when the unbonding amount will be available for withdrawal"
withdrawRound: BigInt!
"Account that initiates the transaction that creates the unbonding lock"
sender: String!
}
"""
Stake weighted poll
"""
type Poll @entity {
"Poll address"
id: ID!
"IPFS multihash for the proposal"
proposal: String!
"Block at which the poll ends and votes can no longer be submitted"
endBlock: BigInt!
"Minimum amount of participation (total stake including inactive stake) required for a poll to pass"
quorum: BigInt!
"Minimum amount of yes votes required for a poll to pass"
quota: BigInt!
"Poll tally"
tally: PollTally
"Votes belonging to a poll"
votes: [Vote!]!
}
"""
Stake weighted tally associated with a poll
"""
type PollTally @entity {
"Poll address"
id: ID!
"Stake voted yes"
yes: BigDecimal!
"Stake voted no"
no: BigDecimal!
}
"""
Vote data
"""
type Vote @entity {
"Voter address + poll address"
id: ID!
"Vote caster"
voter: String!
"Stake weighted vote"
voteStake: BigDecimal!
"This will be non-zero if voter is an transcoder and any of the its delegators voted"
nonVoteStake: BigDecimal!
"Vote choice"
choiceID: PollChoice
"Poll associated with this vote"
poll: Poll
"True if the voter was a registered transcoder during the poll period"
registeredTranscoder: Boolean
}
enum PollChoice @entity {
Yes
No
}
"""
Protocol data accumulated and condensed into day stats
"""
type Day @entity {
"Timestamp rounded to current day by dividing by 86400"
id: ID!
"The date beginning at 12:00am UTC"
date: Int!
"Fees generated this day in ETH"
volumeETH: BigDecimal!
"Fees generated this day in USD"
volumeUSD: BigDecimal!
"Total active stake during the day"
totalActiveStake: BigDecimal!
"Total Livepeer token supply during the day"
totalSupply: BigDecimal!
"Participation rate during the day (totalActiveStake/totalSupply)"
participationRate: BigDecimal!
"Per round inflation rate"
inflation: BigInt!
"Limit of active transcoders"
numActiveTranscoders: BigInt!
"Total active transcoders (up to the limit)"
activeTranscoderCount: BigInt!
"Total number of delegators at the start of the round"
delegatorsCount: BigInt!
}
"""
Transcoder data accumulated and condensed into day stats
"""
type TranscoderDay @entity {
"Concatenation of the transcoder address and the day timestamp (e.g. <ADDRESS>-<TIMESTAMP>)"
id: ID!
"The date beginning at 12:00am UTC"
date: Int!
"Fees generated this day in ETH"
volumeETH: BigDecimal!
"Fees generated this day in USD"
volumeUSD: BigDecimal!
"Transcoder associated with the day"
transcoder: Transcoder!
}
"""
Broadcaster data accumulated and condensed into day stats
"""
type BroadcasterDay @entity {
"Concatenation of the broadcaster address and the day timestamp (e.g. <ADDRESS>-<TIMESTAMP>)"
id: ID!
"The date beginning at 12:00am UTC"
date: Int!
"Fees paid this day in ETH"
volumeETH: BigDecimal!
"Fees paid this day in USD"
volumeUSD: BigDecimal!
"Broadcaster associated with the day"
broadcaster: Broadcaster!
}
"""
Stake weighted treasury proposal
"""
type TreasuryProposal @entity {
"Governor proposal ID formatted as a decimal number"
id: ID!
"Account that created the proposal"
proposer: LivepeerAccount!
"Targets to be called on proposal execution"
targets: [String!]!
"Values to be passed to the targets on proposal execution"
values: [BigInt!]!
"Functions to call on the targets on proposal execution"
calldatas: [Bytes!]!
"Round after which the proposal voting will begin"
voteStart: BigInt!
"Round after which the proposal voting will end and, if approved, execution will be allowed"
voteEnd: BigInt!
"Description of the proposal"
description: String!
"Votes cast for this proposal"
votes: [TreasuryVote!]! @derivedFrom(field: "proposal")
"Total weight of votes in favor"
forVotes: BigDecimal!
"Total weight of votes against"
againstVotes: BigDecimal!
"Total weight of abstaining votes"
abstainVotes: BigDecimal!
"Sum of all vote weights"
totalVotes: BigDecimal!
}
enum TreasuryVoteSupport{
Against
For
Abstain
}
"""
Stake weighted vote on a treasury proposal
"""
type TreasuryVote @entity {
"Proposal ID + voter address"
id: ID!
"The proposal that was voted on"
proposal: TreasuryProposal!
"Account that cast the vote"
voter: LivepeerAccount!
"The voter's position"
support: TreasuryVoteSupport!
"Stake-weighted voting power"
weight: BigDecimal!
"Optional reason string provided by the voter"
reason: String
}
###############################################################################
#
# Event types && transactions for historical records
#
###############################################################################
interface Event {
id: ID!
timestamp: Int!
transaction: Transaction!
round: Round!
}
"""
Transaction entities are created for each Ethereum transaction that contains an interaction within Livepeer contracts.
"""
type Transaction @entity {
"Ethereum transaction hash"
id: ID!
"Block transaction was mined in"
blockNumber: BigInt!
"Timestamp for transaction"
timestamp: Int!
"Actually is the limit of gas in the transaction, pending update in downstream projects"
gasUsed: BigInt!
"Cost per unit of gas specified for the transaction"
gasPrice: BigInt!
"The sending party of the transaction"
from: String!
"The receiving party of the transaction"
to: String!
"The events emitted within this transaction"
events: [Event!] @derivedFrom(field: "transaction")
}
"""
BondEvent entities are created for every emitted Bond event.
"""
type BondEvent implements Event @entity {
"Ethereum transaction hash + event log index"
id: ID!
"Reference to the transaction the event was included in"
transaction: Transaction!
"Timestamp of the transaction the event was included in, used to sort"
timestamp: Int!
"Reference to the round the event occured in"
round: Round!
"Delegator's current total bonded amount"
bondedAmount: BigDecimal!
"Additional amount added to bonded amount"
additionalAmount: BigDecimal!
"Reference to the Delegator's new delegate"
newDelegate: Transcoder!
"Reference to the Delegator's old delegate"
oldDelegate: Transcoder
"Reference to the Delegator that bonded"
delegator: Delegator!
}
"""
UnbondEvent entities are created for every emitted Unbond event.
"""
type UnbondEvent implements Event @entity {
"Ethereum transaction hash + event log index"
id: ID!
"Reference to the transaction the event was included in"
transaction: Transaction!
"Timestamp of the transaction the event was included in"
timestamp: Int!
"Reference to the round the event occured in"
round: Round!
"Amount unbonded in the transaction"
amount: BigDecimal!
"The future round in which the Delegator may withdraw its unbonded stake"
withdrawRound: BigInt!
"The unbonding lock ID associated with this transaction, used to optionally rebond the amount"
unbondingLockId: Int
"Reference to the delegate unbonded from"
delegate: Transcoder!
"Reference to the Delegator that unbonded"
delegator: Delegator!
}
"""
RebondEvent entities are created for every emitted Rebond event.
"""
type RebondEvent implements Event @entity {
"Ethereum transaction hash + event log index"
id: ID!
"Reference to the transaction the event was included in"
transaction: Transaction!
"Timestamp of the transaction the event was included in"
timestamp: Int!
"Reference to the round the event occured in"
round: Round!
"Reference to the delegator that rebonded"
delegator: Delegator!
delegate: Transcoder!
amount: BigDecimal!
unbondingLockId: Int!
}
"""
TransferBond entities are created for every emitted TransferBond event.
"""
type TransferBondEvent implements Event @entity {
"Ethereum transaction hash + event log index"
id: ID!
"Reference to the transaction the event was included in"
transaction: Transaction!
"Timestamp of the transaction the event was included in"
timestamp: Int!
"Reference to the round the event occured in"
round: Round!
amount: BigDecimal!
newDelegator: Delegator!
oldDelegator: Delegator!
newUnbondingLockId: Int!
oldUnbondingLockId: Int!
}
"""
RewardEvent entities are created for every emitted Reward event.
"""
type RewardEvent implements Event @entity {
"Ethereum transaction hash + event log index"
id: ID!
"Reference to the transaction the event was included in"
transaction: Transaction!
"Timestamp of the transaction the event was included in"
timestamp: Int!
"Reference to the round the event occured in"
round: Round!
"Amount of inflationary token rewards claimed"
rewardTokens: BigDecimal!
"Reference to the delegate that claimed its inflationary token reward"
delegate: Transcoder!
}
"""
TranscoderActivatedEvent entities are created for every emitted TranscoderActivated event.
"""
type TranscoderActivatedEvent implements Event @entity {
"Ethereum transaction hash + event log index"
id: ID!
"Reference to the transaction the event was included in"
transaction: Transaction!
"Timestamp of the transaction the event was included in"
timestamp: Int!
"Reference to the round the event occured in"
round: Round!
"Reference to the delegate that will be active"
delegate: Transcoder!
"Future round in which the delegate will become active"
activationRound: BigInt!
}
"""
TranscoderDeactivatedEvent entities are created for every emitted TranscoderDeactivated event.
"""
type TranscoderDeactivatedEvent implements Event @entity {
"Ethereum transaction hash + event log index"
id: ID!
"Reference to the transaction the event was included in"
transaction: Transaction!
"Timestamp of the transaction the event was included in"
timestamp: Int!
"Reference to the round the event occured in"
round: Round!
"Reference to the delegate that will become deactive"
delegate: Transcoder!
"Future round in which the delegate will become deactive"
deactivationRound: BigInt!
}
"""
EarningsClaimedEvent entities are created for every emitted EarningsClaimed event.
"""
type EarningsClaimedEvent implements Event @entity {
"Ethereum transaction hash + event log index"
id: ID!
"Reference to the transaction the event was included in"
transaction: Transaction!
"Timestamp of the transaction the event was included in"
timestamp: Int!
"Reference to the round the event occured in"
round: Round!
"Reference to the delegator that claimed its earnings"
delegator: Delegator!
"Reference to the delegator's delegate"
delegate: Transcoder!
"First round that the delegator's pending stake was computed from"
startRound: BigInt!
"Last round that the delegator's pending stake was computed from"
endRound: Round!
"Reward tokens claimed by the delegator"
rewardTokens: BigDecimal!
"Fees claimed by the delegator"
fees: BigDecimal!
}
"""
TranscoderUpdateEvent entities are created for every emitted TranscoderUpdate event.
"""
type TranscoderUpdateEvent implements Event @entity {
"Ethereum transaction hash + event log index"
id: ID!
"Reference to the transaction the event was included in"
transaction: Transaction!
"Timestamp of the transaction the event was included in"
timestamp: Int!
"Reference to the round the event occured in"
round: Round!
"Reference to the delegate that was updated"
delegate: Transcoder!
"Delegate's updated reward cut"
rewardCut: BigInt!
"Delegate's updated fee share"
feeShare: BigInt!
}
"""
TranscoderSlashedEvent entities are created for every emitted TranscoderSlashed event.
"""
type TranscoderSlashedEvent implements Event @entity {
"Ethereum transaction hash + event log index"
id: ID!
"Reference to the transaction the event was included in"
transaction: Transaction!
"Timestamp of the transaction the event was included in"
timestamp: Int!
"Reference to the round the event occured in"
round: Round!
"Reference to the delegate that was slashed"
delegate: Transcoder!
"Finder that proved a transcoder violated a slashing condition. Null address if there is no finder"
finder: Bytes!
"Percentage of transcoder bond to be slashed"
penalty: BigDecimal!
"Percentage of penalty awarded to finder. Zero if there is no finder"
finderReward: BigInt!
}
"""
TranscoderResignedEvent entities are created for every emitted TranscoderResigned event.
"""
type TranscoderResignedEvent implements Event @entity {
"Ethereum transaction hash + event log index"
id: ID!
"Reference to the transaction the event was included in"
transaction: Transaction!
"Timestamp of the transaction the event was included in"
timestamp: Int!
"Reference to the round the event occured in"
round: Round!
"Reference to the delegate that resigned"
delegate: Transcoder!
}
"""
TranscoderEvictedEvent entities are created for every emitted TranscoderEvicted event.
"""
type TranscoderEvictedEvent implements Event @entity {
"Ethereum transaction hash + event log index"
id: ID!
"Reference to the transaction the event was included in"
transaction: Transaction!
"Timestamp of the transaction the event was included in"
timestamp: Int!
"Reference to the round the event occured in"
round: Round!
"Reference to the delegate that was evicted"
delegate: Transcoder!
}
"""
WithdrawStakeEvent entities are created for every emitted WithdrawStake event.
"""
type WithdrawStakeEvent implements Event @entity {
"Ethereum transaction hash + event log index"
id: ID!
"Reference to the transaction the event was included in"
transaction: Transaction!
"Timestamp of the transaction the event was included in"
timestamp: Int!
"Reference to the round the event occured in"
round: Round!
"Reference to the delegator that withdraw its stake"
delegator: Delegator!
"Unbonding lock ID that was deleted upon withdrawal"
unbondingLockId: Int
"Amount of stake withdrawn"
amount: BigDecimal!
}
"""
WithdrawFeesEvent entities are created for every emitted WithdrawFees event.
"""
type WithdrawFeesEvent implements Event @entity {
"Ethereum transaction hash + event log index"
id: ID!
"Reference to the transaction the event was included in"
transaction: Transaction!
"Timestamp of the transaction the event was included in"
timestamp: Int!
"Reference to the round the event occured in"
round: Round!
"Reference to the delegator that withdraw its fees"
delegator: Delegator!
"Amount of fees withdrawn"
amount: BigDecimal!
"Address belonging to the receiver of fees"
recipient: String!
}
"""
NewRoundEvent entities are created for every emitted NewRound event.
"""
type NewRoundEvent implements Event @entity {
"Ethereum transaction hash + event log index"
id: ID!
"Reference to the transaction the event was included in"
transaction: Transaction!
"Timestamp of the transaction the event was included in"
timestamp: Int!
"Reference to the round the event occured in"
round: Round!
"Block hash for the round"
blockHash: String!
}
"""
WinningTicketRedeemedEvent entities are created for every emitted WinningTicketRedeemed event.
"""
type WinningTicketRedeemedEvent implements Event @entity {
"Ethereum transaction hash + event log index"
id: ID!
"Reference to the transaction the event was included in"
transaction: Transaction!
"Timestamp of the transaction the event was included in"
timestamp: Int!
"Reference to the round the event occured in"
round: Round!
"Reference to the broadcaster who sent the fees"
sender: Broadcaster!
"Reference to the recipient of the broadcaster fees"
recipient: Transcoder!
"Face value of ticket paid to recipient"
faceValue: BigDecimal!
"Amount of fees the winning ticket was redeemed for in in USD"
faceValueUSD: BigDecimal!
"The winning probability of the ticket"
winProb: BigInt!
"Sender's monotonically increasing counter for each ticket"
senderNonce: BigInt!
"keccak256 hash commitment to recipient's random value"
recipientRand: BigInt!
"Auxilary data included in ticket used for additional validation"
auxData: Bytes!
}
"""
DepositFundedEvent entities are created for every emitted DepositFunded event.
"""
type DepositFundedEvent implements Event @entity {
"Ethereum transaction hash + event log index"
id: ID!
"Reference to the transaction the event was included in"
transaction: Transaction!
"Timestamp of the transaction the event was included in"
timestamp: Int!
"Reference to the round the event occured in"
round: Round!
"Reference to the broadcaster that deposited the broadcasting fees"
sender: Broadcaster!
"Amount of broadcasting fees deposited"
amount: BigDecimal!
}
"""
ReserveFundedEvent entities are created for every emitted ReserveFunded event.
"""
type ReserveFundedEvent implements Event @entity {
"Ethereum transaction hash + event log index"
id: ID!
"Reference to the transaction the event was included in"
transaction: Transaction!
"Timestamp of the transaction the event was included in"
timestamp: Int!
"Reference to the round the event occured in"
round: Round!
"Reference to reserve holder"
reserveHolder: Broadcaster!
"Amount of funds added to reserve"
amount: BigDecimal!
}
"""
ReserveClaimedEvent entities are created for every emitted ReserveClaimed event.
"""
type ReserveClaimedEvent implements Event @entity {
"Ethereum transaction hash + event log index"
id: ID!
"Reference to the transaction the event was included in"
transaction: Transaction!
"Timestamp of the transaction the event was included in"
timestamp: Int!
"Reference to the round the event occured in"
round: Round!
"Reference to the reserve holder"
reserveHolder: Broadcaster!
"Reference to the claimant"
claimant: Transcoder!
"Amount of funds claimed by claimant from the reserve for the reserve holder"
amount: BigDecimal!
}
"""
WithdrawalEvent entities are created for every emitted Withdrawal event.
"""
type WithdrawalEvent implements Event @entity {
"Ethereum transaction hash + event log index"
id: ID!
"Reference to the transaction the event was included in"
transaction: Transaction!
"Timestamp of the transaction the event was included in"
timestamp: Int!
"Reference to the round the event occured in"
round: Round!
"Reference to the broadcaster withdrawing its deposit and reserve"
sender: Broadcaster!
"Deposit amount withdrawn"
deposit: BigDecimal!
"Reserve amount withdrawn"
reserve: BigDecimal!
}
"""
SetCurrentRewardTokensEvent entities are created for every emitted SetCurrentRewardTokens event.
"""
type SetCurrentRewardTokensEvent implements Event @entity {
"Ethereum transaction hash + event log index"
id: ID!
"Reference to the transaction the event was included in"
transaction: Transaction!
"Timestamp of the transaction the event was included in"
timestamp: Int!
"Reference to the round the event occured in"
round: Round!
"Number of mintable tokens for the round"
currentMintableTokens: BigDecimal!
"Current inflation during the round"
currentInflation: BigInt!
}
"""
PauseEvent entities are created for every emitted Pause event.
"""
type PauseEvent implements Event @entity {
"Ethereum transaction hash + event log index"
id: ID!
"Reference to the transaction the event was included in"
transaction: Transaction!
"Timestamp of the transaction the event was included in"
timestamp: Int!
"Reference to the round the event occured in"
round: Round!
}
"""
UnpauseEvent entities are created for every emitted Unpause event.
"""
type UnpauseEvent implements Event @entity {
"Ethereum transaction hash + event log index"
id: ID!
"Reference to the transaction the event was included in"
transaction: Transaction!
"Timestamp of the transaction the event was included in"
timestamp: Int!
"Reference to the round the event occured in"
round: Round!
}
"""
ParameterUpdateEvent entities are created for every emitted ParameterUpdate event.
"""
type ParameterUpdateEvent implements Event @entity {
"Ethereum transaction hash + event log index"
id: ID!
"Reference to the transaction the event was included in"
transaction: Transaction!
"Timestamp of the transaction the event was included in"
timestamp: Int!
"Reference to the round the event occured in"
round: Round!
"Parameter that was updated"
param: String!
}
"""
TreasuryVoteEvent entities are created for every emitted VoteCast/VoteCastWithParams event.
"""
type TreasuryVoteEvent implements Event @entity {
"Ethereum transaction hash + event log index"
id: ID!
"Reference to the transaction the event was included in"
transaction: Transaction!
"Timestamp of the transaction the event was included in"
timestamp: Int!
"Reference to the round the event occured in"
round: Round!
"Account that cast the vote"
voter: LivepeerAccount!
"Proposal that the vote was cast for"
proposal: TreasuryProposal!
"The voter's position"
support: TreasuryVoteSupport!
"Stake-weighted voting power"
weight: BigDecimal!
"Optional reason string provided by the voter"
reason: String
}
"""
VoteEvent entities are created for every emitted Vote event.
"""
type VoteEvent implements Event @entity {
"Ethereum transaction hash + event log index"
id: ID!
"Reference to the transaction the event was included in"
transaction: Transaction!
"Timestamp of the transaction the event was included in"
timestamp: Int!
"Reference to the round the event occured in"
round: Round!
"Address belonging to the voter"
voter: String!
"Voter choice. Zero means yes and one means no"
choiceID: BigInt!
"Reference to the poll this vote was casted in"
poll: Poll!
}
"""
PollCreatedEvent entities are created for every emitted PollCreated event.
"""
type PollCreatedEvent implements Event @entity {
"Ethereum transaction hash + event log index"
id: ID!
"Reference to the transaction the event was included in"
transaction: Transaction!