-
Notifications
You must be signed in to change notification settings - Fork 3
/
Copy pathsubgraph.template.yaml
211 lines (206 loc) · 7.11 KB
/
subgraph.template.yaml
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
specVersion: 0.0.4
features:
- ipfsOnEthereumContracts
description: TheBadge subgraph
repository: https://github.com/thebadge/thebadge-subgraph
schema:
file: ./schema.graphql
dataSources:
- kind: ethereum/contract
name: TheBadge
network: {{network}}
source:
address: "{{TheBadge.address}}"
startBlock: {{TheBadge.startBlock}}
abi: TheBadge
mapping:
kind: ethereum/events
apiVersion: 0.0.6
language: wasm/assemblyscript
entities:
- User
- BadgeModel
abis:
- name: TheBadge
file: ./abis/TheBadge.json
- name: TheBadgeStore
file: ./abis/TheBadgeStore.json
- name: TheBadgeUsers
file: ./abis/TheBadgeUsers.json
- name: TheBadgeModels
file: ./abis/TheBadgeModels.json
eventHandlers:
- event: Initialize(indexed address)
handler: handleContractInitialized
- event: ProtocolSettingsUpdated()
handler: handleProtocolSettingsUpdated
- event: PaymentMade(indexed address,address,uint256,indexed uint8,indexed uint256,string)
handler: handlePaymentMade
- event: BadgeRequested(indexed uint256,indexed uint256,indexed address,address,uint256)
handler: handleMint
- event: BadgeClaimed(indexed uint256,indexed address,indexed address)
handler: handleClaim
file: ./src/theBadge.ts
- kind: ethereum/contract
name: TheBadgeUsers
network: {{network}}
source:
address: "{{TheBadgeUsers.address}}"
startBlock: {{TheBadgeUsers.startBlock}}
abi: TheBadgeUsers
mapping:
kind: ethereum/events
apiVersion: 0.0.6
language: wasm/assemblyscript
entities:
- User
- BadgeModel
abis:
- name: TheBadgeUsers
file: ./abis/TheBadgeUsers.json
- name: TheBadgeStore
file: ./abis/TheBadgeStore.json
eventHandlers:
- event: UserRegistered(indexed address,string)
handler: handleUserRegistered
- event: UpdatedUser(indexed address,string,bool,bool,bool)
handler: handleUserUpdated
file: ./src/theBadge.ts
- kind: ethereum/contract
name: TheBadgeModels
network: {{network}}
source:
address: "{{TheBadgeModels.address}}"
startBlock: {{TheBadgeModels.startBlock}}
abi: TheBadgeModels
mapping:
kind: ethereum/events
apiVersion: 0.0.6
language: wasm/assemblyscript
entities:
- User
- BadgeModel
abis:
- name: TheBadgeModels
file: ./abis/TheBadgeModels.json
- name: TheBadge
file: ./abis/TheBadge.json
- name: TheBadgeStore
file: ./abis/TheBadgeStore.json
- name: TheBadgeUsers
file: ./abis/TheBadgeUsers.json
eventHandlers:
- event: BadgeModelCreated(indexed uint256)
handler: handleBadgeModelCreated
- event: BadgeModelUpdated(indexed uint256)
handler: handleBadgeModelUpdated
- event: BadgeModelSuspended(indexed uint256,bool)
handler: handleBadgeModelSuspended
file: ./src/theBadge.ts
- kind: ethereum/contract
name: KlerosBadgeModelController
network: {{network}}
source:
address: "{{KlerosBadgeModelController.address}}"
startBlock: {{KlerosBadgeModelController.startBlock}}
abi: KlerosBadgeModelController
mapping:
kind: ethereum/events
apiVersion: 0.0.6
language: wasm/assemblyscript
file: ./src/mappings/klerosBadgeModelController.ts
entities:
- BadgeModelKlerosMetaData
- BadgeKlerosMetaData
abis:
- name: KlerosBadgeModelController
file: ./abis/KlerosBadgeModelController.json
- name: KlerosBadgeModelControllerStore
file: ./abis/KlerosBadgeModelControllerStore.json
- name: LightGeneralizedTCR
file: ./abis/LightGeneralizedTCR.json
- name: TheBadge
file: ./abis/TheBadge.json
- name: TheBadgeModels
file: ./abis/TheBadgeModels.json
- name: TheBadgeStore
file: ./abis/TheBadgeStore.json
- name: TheBadgeUsers
file: ./abis/TheBadgeUsers.json
eventHandlers:
- event: Initialize(indexed address,indexed address)
handler: handleKlerosContractInitialized
- event: NewKlerosBadgeModel(indexed uint256,indexed address,string,string)
handler: handleNewKlerosBadgeModel
- event: MintKlerosBadge(indexed uint256,string)
handler: handleMintKlerosBadge
- kind: ethereum/contract
name: TpBadgeModelController
network: {{network}}
source:
address: "{{TpBadgeModelController.address}}"
startBlock: {{TpBadgeModelController.startBlock}}
abi: TpBadgeModelController
mapping:
kind: ethereum/events
apiVersion: 0.0.6
language: wasm/assemblyscript
file: ./src/mappings/thirdPartyBadgeModelController.ts
entities:
- BadgeModelThirdPartyMetaData
- BadgeThirdPartyMetaData
abis:
- name: TpBadgeModelController
file: ./abis/TpBadgeModelController.json
- name: LightGeneralizedTCR
file: ./abis/LightGeneralizedTCR.json
- name: TheBadge
file: ./abis/TheBadge.json
- name: TheBadgeModels
file: ./abis/TheBadgeModels.json
- name: TpBadgeModelControllerStore
file: ./abis/TpBadgeModelControllerStore.json
- name: TheBadgeUsers
file: ./abis/TheBadgeUsers.json
eventHandlers:
- event: Initialize(indexed address)
handler: handleThirdPartyContractInitialized
- event: NewThirdPartyBadgeModel(indexed uint256,indexed address)
handler: handleNewThirdPartyBadgeModel
- event: ThirdPartyBadgeMinted(indexed uint256,indexed bytes32)
handler: handleMintThirdPartyBadge
templates:
- kind: ethereum/contract
name: LightGeneralizedTCR
network: {{network}}
source:
abi: LightGeneralizedTCR
mapping:
kind: ethereum/events
apiVersion: 0.0.6
language: wasm/assemblyscript
entities:
- _EvidenceGroupIDToRequestIDToItemID
- Evidence
- BadgeModelKlerosMetaData
abis:
- name: KlerosBadgeModelController
file: ./abis/KlerosBadgeModelController.json
- name: LightGeneralizedTCR
file: ./abis/LightGeneralizedTCR.json
- name: TheBadgeModels
file: ./abis/TheBadgeModels.json
- name: TheBadgeStore
file: ./abis/TheBadgeStore.json
eventHandlers:
- event: RequestSubmitted(indexed bytes32,uint256)
handler: handleRequestSubmitted
- event: Dispute(indexed address,indexed uint256,uint256,uint256)
handler: handleRequestChallenged
- event: ItemStatusChange(indexed bytes32,bool)
handler: handleStatusUpdated
- event: Evidence(indexed address,indexed uint256,indexed address,string)
handler: handleEvidence
- event: Ruling(indexed address,indexed uint256,uint256)
handler: handleRuling
file: ./src/mappings/lightGeneralizedTCRMapping.ts