-
Notifications
You must be signed in to change notification settings - Fork 3
/
subgraph.template.yaml
162 lines (162 loc) · 5.31 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
specVersion: 0.0.2
description: Explore all NFTX Vault tokens
schema:
file: ./schema.graphql
dataSources:
- kind: ethereum/contract
name: NFTXVaultFactoryUpgradeable
network: {{network}}
source:
address: '{{addressVaultFactory}}'
abi: NFTXVaultFactoryUpgradeable
startBlock: {{startBlockNFTXFactory}}
mapping:
file: ./src/mappings/vault.ts
kind: ethereum/events
apiVersion: 0.0.6
language: wasm/assemblyscript
entities:
- Vault
abis:
- name: NFTXVaultFactoryUpgradeable
file: ./abis/NFTXVaultFactoryUpgradeable.json
- name: NFTXFeeDistributor
file: ./abis/NFTXFeeDistributor.json
- name: IERC20
file: ./node_modules/@openzeppelin/contracts/build/contracts/IERC20Metadata.json
eventHandlers:
- event: NewVault(indexed uint256,address,address)
handler: handleNewVault
- event: NewFeeDistributor(address,address)
handler: handleNewFeeDistributor
- kind: ethereum/contract
name: NFTXInventoryStaking
network: {{network}}
source:
abi: NFTXInventoryStaking
address: '{{addressInventoryStaking}}'
startBlock: {{startBlockInventoryStaking}}
mapping:
file: ./src/mappings/inventoryStaking.ts
kind: ethereum/events
apiVersion: 0.0.6
language: wasm/assemblyscript
entities:
- Vault
abis:
- name: NFTXInventoryStaking
file: ./abis/NFTXInventoryStaking.json
- name: NFTXVaultFactoryUpgradeable
file: ./abis/NFTXVaultFactoryUpgradeable.json
eventHandlers:
- event: XTokenCreated(uint256,address,address)
handler: handleXTokenCreated
- event: Deposit(uint256,uint256,uint256,uint256,address)
handler: handleXTokenDeposited
- event: Withdraw(uint256,uint256,uint256,address)
handler: handleXTokenWithdrawn
- kind: ethereum/contract
name: NFTXStakingZap
network: {{network}}
source:
address: '{{addressStakingZap}}'
abi: NFTXStakingZap
startBlock: {{startBlockZaps}}
mapping:
file: ./src/mappings/pairs.ts
kind: ethereum/events
apiVersion: 0.0.6
language: wasm/assemblyscript
entities:
- Zap
abis:
- name: NFTXStakingZap
file: ./abis/NFTXStakingZap.json
- name: Factory
file: ./node_modules/@sushiswap/core/build/abi/UniswapV2Factory.json
- name: NFTXVaultFactoryUpgradeable
file: ./abis/NFTXVaultFactoryUpgradeable.json
- name: StakingTokenProvider
file: ./abis/StakingTokenProvider.json
eventHandlers:
- event: UserStaked(uint256,uint256,uint256,uint256,address)
handler: handleVaultTokenWETHPairCreation
- kind: ethereum/contract
name: NFTXStakingZapV2
network: {{network}}
source:
address: '{{addressStakingZapV2}}'
abi: NFTXStakingZap
startBlock: {{startBlockZapsV2}}
mapping:
file: ./src/mappings/pairs.ts
kind: ethereum/events
apiVersion: 0.0.6
language: wasm/assemblyscript
entities:
- Zap
abis:
- name: NFTXStakingZap
file: ./abis/NFTXStakingZap.json
- name: Factory
file: ./node_modules/@sushiswap/core/build/abi/UniswapV2Factory.json
- name: StakingTokenProvider
file: ./abis/StakingTokenProvider.json
- name: NFTXVaultFactoryUpgradeable
file: ./abis/NFTXVaultFactoryUpgradeable.json
eventHandlers:
- event: UserStaked(uint256,uint256,uint256,uint256,address)
handler: handleVaultTokenWETHPairCreation
templates:
- kind: ethereum/contract
name: NFTXLPStaking
network: {{network}}
source:
abi: NFTXLPStaking
mapping:
file: ./src/mappings/pairs.ts
kind: ethereum/events
apiVersion: 0.0.6
language: wasm/assemblyscript
entities:
- Vault
abis:
- name: NFTXLPStaking
file: ./abis/NFTXLPStaking.json
- name: NFTXVaultFactoryUpgradeable
file: ./abis/NFTXVaultFactoryUpgradeable.json
- name: StakingTokenProvider
file: ./abis/StakingTokenProvider.json
eventHandlers:
- event: PoolCreated(uint256,address)
handler: handlePoolCreated
- event: PoolUpdated(uint256,address)
handler: handlePoolUpdated
- kind: ethereum/contract
name: Token
network: {{network}}
source:
abi: IERC20
mapping:
file: ./src/mappings/erc20/datasource.ts
kind: ethereum/events
apiVersion: 0.0.6
language: wasm/assemblyscript
entities:
- ERC20Contract
abis:
- name: NFTXVaultFactoryUpgradeable
file: ./abis/NFTXVaultFactoryUpgradeable.json
- name: NFTXVaultUpgradeable
file: ./abis/NFTXVaultUpgradeable.json
- name: XTokenUpgradeable
file: ./abis/XTokenUpgradeable.json
- name: StakingTokenProvider
file: ./abis/StakingTokenProvider.json
- name: IERC20
file: ./node_modules/@openzeppelin/contracts/build/contracts/IERC20Metadata.json
eventHandlers:
- event: Approval(indexed address,indexed address,uint256)
handler: handleApproval
- event: Transfer(indexed address,indexed address,uint256)
handler: handleTransfer