This repository was archived by the owner on Nov 24, 2025. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathsubgraph.yaml
More file actions
218 lines (214 loc) · 7.26 KB
/
subgraph.yaml
File metadata and controls
218 lines (214 loc) · 7.26 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
specVersion: 0.0.2
schema:
file: ./schema.graphql
dataSources:
- name: Core
kind: ethereum/contract
network: mainnet
source:
abi: Core
address: '0xf55186cc537e7067ea616f2aae007b4427a120c8'
startBlock: 7536585
mapping:
kind: ethereum/events
apiVersion: 0.0.4
language: wasm/assemblyscript
file: ./src/core/index.ts
abis:
- name: Core
file: ./abis/Core.json
- name: SetToken
file: ./abis/SetToken.json
entities:
- Exchange
- Factory
- Module
- PriceLibrary
- Set
eventHandlers:
- event: SetTokenCreated(indexed address,address,address[],uint256[],uint256,bytes32,bytes32)
handler: handleSetTokenCreated
- event: SetIssued(address,uint256)
handler: handleSetIssued
- event: SetRedeemed(address,uint256)
handler: handleSetRedeemed
- event: SetDisabled(address)
handler: handleSetDisabled
- event: SetReenabled(address)
handler: handleSetReenabled
- event: ExchangeAdded(uint8,address)
handler: handleExchangeAdded
- event: ExchangeRemoved(uint8)
handler: handleExchangeRemoved
- event: FactoryAdded(address)
handler: handleFactoryAdded
- event: FactoryRemoved(address)
handler: handleFactoryRemoved
- event: ModuleAdded(address)
handler: handleModuleAdded
- event: ModuleRemoved(address)
handler: handleModuleRemoved
- event: PriceLibraryAdded(address)
handler: handlePriceLibraryAdded
- event: PriceLibraryRemoved(address)
handler: handlePriceLibraryRemoved
- name: RebalancingSetIssuanceModule
kind: ethereum/contract
network: mainnet
source:
abi: RebalancingSetIssuanceModule
address: '0xceda8318522d348f1d1aca48b24629b8fbf09020'
startBlock: 8112412
mapping:
kind: ethereum/events
apiVersion: 0.0.4
language: wasm/assemblyscript
file: ./src/core/modules/rebalancing-set-issuance.ts
abis:
- name: RebalancingSetIssuanceModule
file: ./abis/RebalancingSetIssuanceModule.json
entities:
- RebalancingSetIssue
- RebalancingSetRedeem
eventHandlers:
- event: LogRebalancingSetIssue(indexed address,indexed address,uint256)
handler: handleLogRebalancingSetIssue
- event: LogRebalancingSetRedeem(indexed address,indexed address,uint256)
handler: handleLogRebalancingSetRedeem
- name: RebalanceAuctionModule
kind: ethereum/contract
network: mainnet
source:
abi: RebalanceAuctionModule
address: '0xe23fb31dd2edacebf7d92720358bb92445f47fdb'
startBlock: 8358158
mapping:
kind: ethereum/events
apiVersion: 0.0.4
language: wasm/assemblyscript
file: ./src/core/modules/rebalance-auction.ts
abis:
- name: RebalanceAuctionModule
file: ./abis/RebalanceAuctionModule.json
entities:
- Bid
eventHandlers:
- event: BidPlaced(indexed address,indexed address,uint256,address[],uint256[],uint256[])
handler: handleBidPlaced
- name: RebalancingSetExchangeIssuanceModule
kind: ethereum/contract
network: mainnet
source:
abi: RebalancingSetExchangeIssuanceModule
address: '0xd4240987d6f92b06c8b5068b1e4006a97c47392b'
startBlock: 8442613
mapping:
kind: ethereum/events
apiVersion: 0.0.4
language: wasm/assemblyscript
file: ./src/core/modules/rebalancing-set-exchange-issuance.ts
abis:
- name: RebalancingSetExchangeIssuanceModule
file: ./abis/RebalancingSetExchangeIssuanceModule.json
entities:
- PayableExchangeIssue
- PayableExchangeRedeem
eventHandlers:
- event: LogPayableExchangeIssue(indexed address,indexed address,address,uint256,uint256)
handler: handleLogPayableExchangeIssue
- event: LogPayableExchangeRedeem(indexed address,indexed address,address,uint256,uint256)
handler: handleLogPayableExchangeRedeem
templates:
# Handle fixed Set tokens
- name: SetToken
kind: ethereum/contract
network: mainnet
source:
abi: SetToken
mapping:
kind: ethereum/events
apiVersion: 0.0.4
language: wasm/assemblyscript
file: ./src/core/tokens/set-token.ts
entities:
- Set
- SetToken
- TransferEvent
abis:
- name: SetToken
file: ./abis/SetToken.json
eventHandlers:
- event: Transfer(indexed address,indexed address,uint256)
handler: handleTransfer
# Handle legacy version of Rebalancing Set tokens (V1)
- name: RebalancingSetTokenV1
kind: ethereum/contract
network: mainnet
source:
abi: RebalancingSetToken
mapping:
kind: ethereum/events
apiVersion: 0.0.4
language: wasm/assemblyscript
file: ./src/core/tokens/rebalancing-set-token-legacy.ts
entities:
- RebalanceProposalEvent
- RebalanceSettlementEvent
- RebalanceStartEvent
- Set
abis:
- name: RebalancingSetToken
file: ./abis/RebalancingSetToken.json
- name: SetToken
file: ./abis/SetToken.json
eventHandlers:
- event: RebalanceProposed(address,indexed address,indexed uint256)
handler: handleRebalanceProposal
- event: RebalanceStarted(address,address)
handler: handleRebalanceStart
- event: Transfer(indexed address,indexed address,uint256)
handler: handleTransfer
callHandlers:
- function: settleRebalance()
handler: handleRebalanceSettle
# Supports RebalancingSetTokenV2 and RebalancingSetTokenV3 contracts
- name: RebalancingSetToken
kind: ethereum/contract
network: mainnet
source:
abi: RebalancingSetTokenV3
mapping:
kind: ethereum/events
apiVersion: 0.0.4
language: wasm/assemblyscript
file: ./src/core/tokens/rebalancing-set-token.ts
entities:
- RebalanceSettlementEvent
- RebalanceStartEvent
- Set
abis:
- name: RebalancingSetToken
file: ./abis/RebalancingSetTokenV2.json
- name: RebalancingSetTokenV3
file: ./abis/RebalancingSetTokenV3.json
- name: SetToken
file: ./abis/SetToken.json
eventHandlers:
- event: EntryFeePaid(indexed address,uint256)
handler: handleEntryFeePaid
- event: IncentiveFeePaid(indexed address,uint256,uint256,uint256)
handler: handleIncentiveFeePaid
- event: NewEntryFee(uint256,uint256)
handler: handleNewEntryFee
- event: NewFeeRecipient(address,address)
handler: handleNewFeeRecipient
- event: NewLiquidatorAdded(address,address)
handler: handleNewLiquidatorAdded
- event: NewManagerAdded(address,address)
handler: handleNewManagerAdded
- event: RebalanceSettled(indexed address,uint256,uint256,uint256,uint256,uint256)
handler: handleRebalanceSettle
- event: RebalanceStarted(address,address,uint256,uint256)
handler: handleRebalanceStart
- event: Transfer(indexed address,indexed address,uint256)
handler: handleTransfer