-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathsubgraph-template.yaml
138 lines (134 loc) · 4.59 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
specVersion: 0.0.4
schema:
file: ./schema.graphql
features:
- grafting
dataSources:
- kind: ethereum/contract
name: Otto
network: ${SUBGRAPH_NETWORK}
source:
address: '${SUBGRAPH_OTTO_ADDRESS}'
abi: OttoV4Contract
startBlock: ${SUBGRAPH_OTTO_STARTBLOCK}
mapping:
kind: ethereum/events
apiVersion: 0.0.5
language: wasm/assemblyscript
entities:
- Otto
abis:
- name: OttoContract
file: ./abis/Otto.json
- name: OttoV2Contract
file: ./abis/OttoV2.json
- name: OttoV3Contract
file: ./abis/OttoV3.json
- name: OttoV4Contract
file: ./abis/OttoV4.json
- name: OttoItemContract
file: ./abis/OttoItem.json
# --------------------
eventHandlers:
- event: Transfer(indexed address,indexed address,indexed uint256)
handler: handleTransfer
- event: OpenPortal(indexed address,indexed uint256,bool)
handler: handleOpen
- event: SummonOtto(indexed address,indexed uint256,bool)
handler: handleSummon
- event: CandidatesCorrected(indexed uint256,uint256[])
handler: handleCandidatesCorrected
- event: TraitsChanged(indexed uint256,uint16[16])
handler: handleTraitsChanged
- event: ItemEquipped(indexed uint256,indexed uint256)
handler: handleItemEquipped
- event: ItemTookOff(indexed uint256,indexed uint256)
handler: handleItemTookOff
- event: EpochBoostsChanged(indexed uint256,indexed uint32,int16[9])
handler: handleEpochBoostChanged
- event: BaseAttributesChanged(indexed uint256,int16[8])
handler: handleBaseAttributesChanged
- event: ExpIncreased(indexed uint256,uint32,uint32)
handler: handleExpIncreased
- event: LevelUp(indexed uint256,uint32,uint32,uint32,uint32,uint32,uint32,uint32)
handler: handleLevelUp
- event: ApIncreased(indexed uint256,uint32,uint32)
handler: handleApIncreased
file: ./src/Otto.ts
- kind: ethereum/contract
name: OttoItem
network: ${SUBGRAPH_NETWORK}
source:
address: '${SUBGRAPH_OTTO_ITEM_ADDRESS}'
abi: OttoItemContract
startBlock: ${SUBGRAPH_ITEM_START_BLOCK}
mapping:
kind: ethereum/events
apiVersion: 0.0.5
language: wasm/assemblyscript
entities:
- Item
abis:
- name: OttoItemContract
file: ./abis/OttoItem.json
# --------------------
eventHandlers:
- event: TransferSingle(indexed address,indexed address,indexed address,uint256,uint256)
handler: handleTransfer
- event: TransferBatch(indexed address,indexed address,indexed address,uint256[],uint256[])
handler: handleTransferBatch
file: ./src/OttoItem.ts
- kind: ethereum/contract
name: OttopiaStore
network: ${SUBGRAPH_NETWORK}
source:
address: '${SUBGRAPH_OTTOPIA_STORE_ADDRESS}'
abi: OttopiaStoreContract
startBlock: ${SUBGRAPH_OTTOPIA_STORE_START_BLOCK}
mapping:
kind: ethereum/events
apiVersion: 0.0.5
language: wasm/assemblyscript
entities:
- OttoProduct
abis:
- name: OttopiaStoreContract
file: ./abis/OttopiaStore.json
# --------------------
eventHandlers:
- event: CreateProduct(indexed uint256)
handler: handleCreate
- event: UpdateProduct(indexed uint256)
handler: handleUpdate
- event: DeleteProduct(indexed uint256)
handler: handleDelete
file: ./src/OttopiaStore.ts
- kind: ethereum/contract
name: Adventure
network: ${SUBGRAPH_NETWORK}
source:
address: '${SUBGRAPH_ADVENTURE_ADDRESS}'
abi: AdventureContract
startBlock: ${SUBGRAPH_ADVENTURE_START_BLOCK}
mapping:
kind: ethereum/events
apiVersion: 0.0.5
language: wasm/assemblyscript
entities:
- AdventurePass
abis:
- name: AdventureContract
file: ./abis/Adventure.json
# --------------------
eventHandlers:
- event: Departure(indexed uint256,indexed uint256)
handler: handleDeparture
- event: Finish(indexed uint256,indexed uint256,bool)
handler: handleFinish
- event: Revive(indexed uint256,indexed uint256)
handler: handleRevive
- event: PassUpdated(indexed uint256,indexed uint256)
handler: handlePassUpdated
- event: RestingUntilUpdated(indexed uint256,uint256,uint256)
handler: handleRestingUntilUpdated
file: ./src/Adventure.ts