-
Notifications
You must be signed in to change notification settings - Fork 3
/
subgraph.yaml
54 lines (54 loc) · 1.73 KB
/
subgraph.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
specVersion: 0.0.2
schema:
file: ./schema.graphql
dataSources:
- kind: ethereum/contract
name: Contract
network: mainnet
source:
address: "0xBa37B002AbaFDd8E89a1995dA52740bbC013D992"
abi: Contract
startBlock: 10553531
mapping:
kind: ethereum/events
apiVersion: 0.0.4
language: wasm/assemblyscript
entities:
- NewProposal
- OwnershipTransferred
- ProposalFinished
- RegisterVoter
- RevokeVoter
- RewardAdded
- RewardPaid
- Staked
- Vote
- Withdrawn
abis:
- name: Contract
file: ./abis/Contract.json
eventHandlers:
- event: NewProposal(uint256,address,uint256,uint256,address)
handler: handleNewProposal
- event: OwnershipTransferred(indexed address,indexed address)
handler: handleOwnershipTransferred
- event: ProposalFinished(indexed uint256,uint256,uint256,bool)
handler: handleProposalFinished
- event: RegisterVoter(address,uint256,uint256)
handler: handleRegisterVoter
- event: RevokeVoter(address,uint256,uint256)
handler: handleRevokeVoter
- event: RewardAdded(uint256)
handler: handleRewardAdded
- event: RewardPaid(indexed address,uint256)
handler: handleRewardPaid
- event: Staked(indexed address,uint256)
handler: handleStaked
- event: Vote(indexed uint256,indexed address,bool,uint256)
handler: handleVote
- event: Withdrawn(indexed address,uint256)
handler: handleWithdrawn
callHandlers:
- function: propose(address,string)
handler: handleCreateProposal
file: ./src/mapping.ts