-
Notifications
You must be signed in to change notification settings - Fork 2
/
subgraph.xdai.yaml
138 lines (138 loc) · 4.28 KB
/
subgraph.xdai.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
specVersion: 0.0.2
description: Swapr is a decentralized protocol for automated token exchange on Ethereum.
repository: https://github.com/nicoelzer/swapr-subgraph
schema:
file: ./schema.graphql
dataSources:
- kind: ethereum/contract
name: Factory
network: xdai
source:
address: '0x5D48C95AdfFD4B40c1AAADc4e08fc44117E02179'
abi: Factory
startBlock: 14913783
mapping:
kind: ethereum/events
apiVersion: 0.0.4
language: wasm/assemblyscript
file: ./src/mappings/factory.ts
entities:
- Pair
- Token
abis:
- name: Factory
file: ./abis/factory.json
- name: ERC20
file: ./abis/ERC20.json
- name: ERC20SymbolBytes
file: ./abis/ERC20SymbolBytes.json
- name: ERC20NameBytes
file: ./abis/ERC20NameBytes.json
eventHandlers:
- event: PairCreated(indexed address,indexed address,address,uint256)
handler: handleNewPair
- kind: ethereum/contract
name: StakingRewardsFactory
network: xdai
source:
address: '0xa039793Af0bb060c597362E8155a0327d9b8BEE8'
abi: StakingRewardsFactory
startBlock: 16517765
mapping:
kind: ethereum/events
apiVersion: 0.0.4
language: wasm/assemblyscript
file: ./src/mappings/staking-rewards.ts
entities:
- Distribution
abis:
- name: Factory
file: ./abis/factory.json
- name: StakingRewardsFactory
file: ./abis/staking-rewards-factory.json
- name: ERC20
file: ./abis/ERC20.json
- name: ERC20SymbolBytes
file: ./abis/ERC20SymbolBytes.json
- name: ERC20NameBytes
file: ./abis/ERC20NameBytes.json
eventHandlers:
- event: DistributionCreated(address,address)
handler: handleDistributionCreation
templates:
- kind: ethereum/contract
name: Pair
network: xdai
source:
abi: Pair
mapping:
kind: ethereum/events
apiVersion: 0.0.4
language: wasm/assemblyscript
file: ./src/mappings/core.ts
entities:
- Pair
- Token
abis:
- name: Pair
file: ./abis/pair.json
- name: Factory
file: ./abis/factory.json
- name: ERC20
file: ./abis/ERC20.json
- name: ERC20SymbolBytes
file: ./abis/ERC20SymbolBytes.json
- name: ERC20NameBytes
file: ./abis/ERC20NameBytes.json
eventHandlers:
- event: Mint(indexed address,uint256,uint256)
handler: handleMint
- event: Burn(indexed address,uint256,uint256,indexed address)
handler: handleBurn
- event: Swap(indexed address,uint256,uint256,uint256,uint256,indexed address)
handler: handleSwap
- event: Transfer(indexed address,indexed address,uint256)
handler: handleTransfer
- event: Sync(uint112,uint112)
handler: handleSync
- kind: ethereum/contract
name: Distribution
network: xdai
source:
abi: StakingRewardsDistribution
mapping:
kind: ethereum/events
apiVersion: 0.0.4
language: wasm/assemblyscript
file: ./src/mappings/staking-rewards.ts
entities:
- Deposit
- Withdrawal
- Claim
- Recovery
abis:
- name: Factory
file: ./abis/factory.json
- name: StakingRewardsDistribution
file: ./abis/staking-rewards-distribution.json
- name: ERC20
file: ./abis/ERC20.json
- name: ERC20SymbolBytes
file: ./abis/ERC20SymbolBytes.json
- name: ERC20NameBytes
file: ./abis/ERC20NameBytes.json
eventHandlers:
- event: Initialized(address[],address,uint256[],uint64,uint64,bool,uint256)
handler: handleDistributionInitialization
- event: Canceled()
handler: handleCancelation
- event: Staked(indexed address,uint256)
handler: handleDeposit
- event: Withdrawn(indexed address,uint256)
handler: handleWithdrawal
- event: Claimed(indexed address,uint256[])
handler: handleClaim
- event: Recovered(uint256[])
handler: handleRecovery
- event: OwnershipTransferred(indexed address,indexed address)
handler: handleOwnershipTransfer