feat: add Uniswap V2 config for Unichain (#187)

* feat: add Uniswap V2 config for Unichain

* refactor: add URLs for Uniswap V2 config

---------

Co-authored-by: zizou <111426680+flopell@users.noreply.github.com>
This commit is contained in:
Zizou
2025-03-27 10:38:29 +01:00
committed by GitHub
parent 0313c9b498
commit 002d42d100
6 changed files with 55 additions and 0 deletions

View File

@@ -2,6 +2,7 @@ specVersion: v0.1.0
package:
name: "arbitrum_uniswap_v2"
version: v0.3.2
url: "https://github.com/propeller-heads/tycho-protocol-sdk/tree/main/substreams/ethereum-uniswap-v2"
protobuf:
files:

View File

@@ -2,6 +2,7 @@ specVersion: v0.1.0
package:
name: "base_uniswap_v2"
version: v0.3.2
url: "https://github.com/propeller-heads/tycho-protocol-sdk/tree/main/substreams/ethereum-uniswap-v2"
protobuf:
files:

View File

@@ -2,6 +2,7 @@ specVersion: v0.1.0
package:
name: "ethereum_pancakeswap_v2"
version: v0.3.2
url: "https://github.com/propeller-heads/tycho-protocol-sdk/tree/main/substreams/ethereum-uniswap-v2"
protobuf:
files:

View File

@@ -2,6 +2,7 @@ specVersion: v0.1.0
package:
name: "ethereum_sushiswap_v2"
version: v0.3.2
url: "https://github.com/propeller-heads/tycho-protocol-sdk/tree/main/substreams/ethereum-uniswap-v2"
protobuf:
files:

View File

@@ -2,6 +2,7 @@ specVersion: v0.1.0
package:
name: "ethereum_uniswap_v2"
version: v0.3.2
url: "https://github.com/propeller-heads/tycho-protocol-sdk/tree/main/substreams/ethereum-uniswap-v2"
protobuf:
files:

View File

@@ -0,0 +1,50 @@
specVersion: v0.1.0
package:
name: "unichain_uniswap_v2"
version: v0.3.2
url: "https://github.com/propeller-heads/tycho-protocol-sdk/tree/main/substreams/ethereum-uniswap-v2"
protobuf:
files:
- tycho/evm/v1/common.proto
- tycho/evm/v1/entity.proto
- uniswap.proto
importPaths:
- ./proto/v1
- ../../proto/
binaries:
default:
type: wasm/rust-v1
file: ../target/wasm32-unknown-unknown/release/ethereum_uniswap_v2.wasm
modules:
- name: map_pools_created
kind: map
initialBlock: 0
inputs:
- params: string
- source: sf.ethereum.type.v2.Block
output:
type: proto:tycho.evm.v1.BlockChanges
- name: store_pools
kind: store
initialBlock: 0
updatePolicy: set_if_not_exists
valueType: proto:tycho.evm.uniswap.v2.Pool
inputs:
- map: map_pools_created
- name: map_pool_events
kind: map
initialBlock: 0
inputs:
- source: sf.ethereum.type.v2.Block
- map: map_pools_created
- store: store_pools
output:
type: proto:tycho.evm.v1.BlockChanges
params:
map_pools_created: factory_address=1F98400000000000000000000000000000000002&protocol_type_name=uniswap_v2_pool