erpc-sdk 0.6.0 → 0.7.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/README.md +125 -0
- data/lib/erpc_sdk/client.rb +5 -1
- data/lib/erpc_sdk/dex_catalog.rb +207 -0
- data/lib/erpc_sdk/generated/dex_catalog.rb +28 -0
- data/lib/erpc_sdk/generated/token_catalog.rb +216 -0
- data/lib/erpc_sdk/generated/token_rankings.rb +25 -0
- data/lib/erpc_sdk/swap.rb +688 -0
- data/lib/erpc_sdk/token_catalog.rb +170 -0
- data/lib/erpc_sdk/token_rankings.rb +50 -0
- data/lib/erpc_sdk/version.rb +1 -1
- data/lib/erpc_sdk.rb +4 -0
- metadata +9 -2
checksums.yaml
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
SHA256:
|
|
3
|
-
metadata.gz:
|
|
4
|
-
data.tar.gz:
|
|
3
|
+
metadata.gz: 317ffd5217863e2d5915a992ef7d997b268ecaaac07f7f34129441d40cbd2521
|
|
4
|
+
data.tar.gz: 06751bca8e281bf143d2dc80f043d91d8b806c167eebfce826460eeffe5eaf57
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: ca330578c4e0c8c2055cd7a2dad65b500eec1bcae41d737ba81d570df40cbc6b2fe0245f2db10c48cffa2162fc96fd104c0ae8a733c12aa4dfd4457fa009c110
|
|
7
|
+
data.tar.gz: 426d7d68e2d89a6d2fca5e5ff3fbf8b84df4988c6324230f6aae19841ab165803f3a5634cbf8139de93f34b189473912e3c8ec7ba0148621fce11dffb5b68681
|
data/README.md
CHANGED
|
@@ -28,11 +28,136 @@ ensure
|
|
|
28
28
|
end
|
|
29
29
|
```
|
|
30
30
|
|
|
31
|
+
## Offline token catalog
|
|
32
|
+
|
|
33
|
+
The gem bundles a generated token catalog for Ethereum, Solana, and Avalanche
|
|
34
|
+
C-Chain. Lookups are synchronous and offline: they do not need a client, API
|
|
35
|
+
key, registry checkout, JSON parsing, or network access.
|
|
36
|
+
|
|
37
|
+
```ruby
|
|
38
|
+
require "erpc_sdk"
|
|
39
|
+
|
|
40
|
+
ethereum_usdc = ERPC::TokenCatalog.find_token_deployments_by_symbol(
|
|
41
|
+
ERPC::TokenChainIDs::ETHEREUM_MAINNET,
|
|
42
|
+
"USDC"
|
|
43
|
+
).first
|
|
44
|
+
native_sol = ERPC::TokenCatalog.get_native_token_deployment(
|
|
45
|
+
ERPC::TokenChainIDs::SOLANA_MAINNET
|
|
46
|
+
)
|
|
47
|
+
|
|
48
|
+
puts ethereum_usdc.fetch(:decimals) # 6
|
|
49
|
+
puts native_sol.fetch(:symbol) # SOL
|
|
50
|
+
puts ERPC::Tokens::Ethereum.fetch(:USDC) # opaque deployment ID
|
|
51
|
+
```
|
|
52
|
+
|
|
53
|
+
Deployment records include their flattened asset identity, chain ID, symbol,
|
|
54
|
+
decimals, standard, address, lifecycle status, and replacement reference. Use
|
|
55
|
+
`list_token_deployments(chain_id: ..., stable_currency: ...)` to filter while
|
|
56
|
+
keeping legacy, winding-down, and retired records visible. The canonical
|
|
57
|
+
registry and its evidence are documented in the [token catalog registry
|
|
58
|
+
README](https://github.com/elsoul/erpc-sdk/blob/main/registry/README.md).
|
|
59
|
+
|
|
60
|
+
## Offline token rankings
|
|
61
|
+
|
|
62
|
+
The gem also bundles the generated token-ranking snapshot. Ranking metadata
|
|
63
|
+
uses the exact `schema_version`, `metric`, `as_of`, `content_digest`,
|
|
64
|
+
`status`, `coverage`, and `source_ids` fields from the registry, and all
|
|
65
|
+
nested values are frozen. The current snapshot is intentionally
|
|
66
|
+
`unconfigured`, so its metric and `as_of` are `nil` and each chain lookup is
|
|
67
|
+
empty until a reviewed snapshot is published.
|
|
68
|
+
|
|
69
|
+
```ruby
|
|
70
|
+
rankings = ERPC::TokenRankings.list_token_rankings(
|
|
71
|
+
ERPC::TokenChainIDs::ETHEREUM_MAINNET
|
|
72
|
+
)
|
|
73
|
+
puts ERPC::TokenRankings::TOKEN_RANKINGS_METADATA.fetch(:status)
|
|
74
|
+
puts rankings.length
|
|
75
|
+
```
|
|
76
|
+
|
|
77
|
+
`list_token_rankings` matches the complete chain ID exactly. Empty, unknown,
|
|
78
|
+
and special strings return the same frozen empty array. It never performs
|
|
79
|
+
network I/O, reads the current clock, or filters by observation time.
|
|
80
|
+
|
|
81
|
+
When a reviewed snapshot is populated, the approved native metric represents
|
|
82
|
+
total supply multiplied by the direct native-pool price. It does not represent
|
|
83
|
+
circulating market capitalization. Coverage remains explicit in metadata and
|
|
84
|
+
may be `partial`; unavailable observations stay out of ranked rows rather than
|
|
85
|
+
being treated as zero.
|
|
86
|
+
|
|
87
|
+
## Offline DEX and pool catalog
|
|
88
|
+
|
|
89
|
+
The source tree bundles the generated DEX deployment, pool, and native/wrapped
|
|
90
|
+
token catalog. These lookups are synchronous and offline, and the returned
|
|
91
|
+
records are frozen. The published `0.6.0` gem predates these exports; this
|
|
92
|
+
source-tree feature is planned for unreleased `0.7.0`.
|
|
93
|
+
|
|
94
|
+
```ruby
|
|
95
|
+
pool = ERPC::DexCatalog.get_pool_definition("pool-0001")
|
|
96
|
+
puts pool.fetch(:address)
|
|
97
|
+
puts ERPC::Dexes::Ethereum.fetch(:UNISWAP_V2)
|
|
98
|
+
puts ERPC::Pools::AvalancheC.fetch(:LFJ_LEGACY_WAVAX_USDC)
|
|
99
|
+
|
|
100
|
+
matches = ERPC::DexCatalog.find_pool_definitions_by_pair(
|
|
101
|
+
ERPC::DexChainIDs::SOLANA_MAINNET,
|
|
102
|
+
"deployment-0013",
|
|
103
|
+
"deployment-0006"
|
|
104
|
+
)
|
|
105
|
+
```
|
|
106
|
+
|
|
107
|
+
The catalog currently contains Uniswap V2 on Ethereum and LFJ legacy
|
|
108
|
+
constant-product on Avalanche C-Chain, plus lookup-only Orca Whirlpools and
|
|
109
|
+
Raydium CLMM records on Solana. Pair lookup is unordered and returns stable
|
|
110
|
+
pool-ID order. `get_native_wrap_definition` accepts a native token deployment
|
|
111
|
+
ID and returns its chain-bound wrapped deployment.
|
|
112
|
+
|
|
113
|
+
## RPC-only swap quotes
|
|
114
|
+
|
|
115
|
+
`erpc.swap.quote_exact_input` performs an exact-input quote for the two EVM
|
|
116
|
+
constant-product pools through the client's configured RPC transports. It
|
|
117
|
+
reads the factory, pool, reserves, and block snapshot using the EIP-1898 block
|
|
118
|
+
hash selector, validates the final headers, and computes the result locally.
|
|
119
|
+
Amounts and block quantities are decimal strings; no hosted aggregator or
|
|
120
|
+
additional API is required.
|
|
121
|
+
|
|
122
|
+
```ruby
|
|
123
|
+
quote = erpc.swap.quote_exact_input(
|
|
124
|
+
chainId: ERPC::DexChainIDs::ETHEREUM_MAINNET,
|
|
125
|
+
poolDefinitionId: ERPC::Pools::Ethereum.fetch(:UNISWAP_V2_USDC_WETH),
|
|
126
|
+
inputTokenDeploymentId: ERPC::Tokens::Ethereum.fetch(:WETH),
|
|
127
|
+
outputTokenDeploymentId: ERPC::Tokens::Ethereum.fetch(:USDC),
|
|
128
|
+
amountIn: "1000000000000000000"
|
|
129
|
+
)
|
|
130
|
+
|
|
131
|
+
puts quote.fetch("amountOut")
|
|
132
|
+
```
|
|
133
|
+
|
|
134
|
+
`SwapQuoteError#code` exposes deterministic validation codes such as
|
|
135
|
+
`SWAP_STATE_STALE` and `SWAP_UNSUPPORTED_ADAPTER`. Existing transport,
|
|
136
|
+
timeout, and JSON-RPC errors retain their native class. Solana pool records
|
|
137
|
+
are available for lookup; their CLMM adapters are not yet quote-enabled.
|
|
138
|
+
Quote eligibility is a reviewed handwritten boundary for the exact WETH/USDC
|
|
139
|
+
Uniswap V2 tuple on Ethereum and WAVAX/USDC LFJ legacy tuple on Avalanche,
|
|
140
|
+
including chain, pool, factory, token addresses, decimals, ERC-20 standards,
|
|
141
|
+
adapter, and fee fields. New catalog records do not automatically become
|
|
142
|
+
quote-enabled; an otherwise valid request outside those tuples returns
|
|
143
|
+
`SWAP_UNSUPPORTED_TOKEN` before RPC.
|
|
144
|
+
Transaction building, signing, sending, route search, native wrapping, and
|
|
145
|
+
cross-chain bridging are outside this quote API.
|
|
146
|
+
|
|
31
147
|
Both exact wire names (`getSlot`, `eth_chainId`) and idiomatic snake-case
|
|
32
148
|
aliases (`get_slot`, `eth_chain_id`) create inert requests. Network I/O starts
|
|
33
149
|
only when `send` is called. `request` restricts calls to the namespace catalog;
|
|
34
150
|
`raw` is the forward-compatible escape hatch.
|
|
35
151
|
|
|
152
|
+
For Solana v1 transactions, pass numeric `maxSupportedTransactionVersion` in
|
|
153
|
+
the request options for `get_transaction` and `get_block`. Responses remain
|
|
154
|
+
opaque Ruby hashes: v1 values include `transaction.message.transactionConfig`,
|
|
155
|
+
legacy and v0 values omit that field, and unrelated response fields are
|
|
156
|
+
preserved. For serialized transactions larger than 1232 bytes, pass the exact
|
|
157
|
+
base64 payload with `"encoding" => "base64"` to `send_transaction` or
|
|
158
|
+
`simulate_transaction`; the SDK forwards the request and response unchanged.
|
|
159
|
+
See the [Solana v1 guide](https://github.com/elsoul/erpc-sdk/blob/main/packages/typescript/docs/solana-v1.md).
|
|
160
|
+
|
|
36
161
|
## Namespaces
|
|
37
162
|
|
|
38
163
|
| Namespace | Purpose |
|
data/lib/erpc_sdk/client.rb
CHANGED
|
@@ -23,7 +23,7 @@ module ERPC
|
|
|
23
23
|
)
|
|
24
24
|
|
|
25
25
|
class Client
|
|
26
|
-
attr_reader :solana, :ethereum, :avalanche, :price, :account, :usage
|
|
26
|
+
attr_reader :solana, :ethereum, :avalanche, :price, :account, :usage, :swap
|
|
27
27
|
|
|
28
28
|
def initialize(config, http_adapter: nil, websocket_factory: nil)
|
|
29
29
|
adapter = http_adapter || NetHttpAdapter.new
|
|
@@ -137,6 +137,10 @@ module ERPC
|
|
|
137
137
|
),
|
|
138
138
|
subscriptions: EthereumSubscriptions.new(avalanche_ws)
|
|
139
139
|
)
|
|
140
|
+
@swap = SwapClient.new(
|
|
141
|
+
ethereum_transport: ethereum_transport,
|
|
142
|
+
avalanche_transport: avalanche_transport
|
|
143
|
+
)
|
|
140
144
|
@price = PriceClient.new(
|
|
141
145
|
RestTransport.new(
|
|
142
146
|
credential: config.api_key,
|
|
@@ -0,0 +1,207 @@
|
|
|
1
|
+
# frozen_string_literal: true
|
|
2
|
+
|
|
3
|
+
require_relative "generated/dex_catalog"
|
|
4
|
+
require_relative "token_catalog"
|
|
5
|
+
|
|
6
|
+
module ERPC
|
|
7
|
+
# Canonical CAIP-2 chain identifiers used by the bundled DEX catalog.
|
|
8
|
+
module DexChainIDs
|
|
9
|
+
ETHEREUM_MAINNET = DexCatalogData::DEX_CHAIN_IDS.fetch(:ethereum)
|
|
10
|
+
SOLANA_MAINNET = DexCatalogData::DEX_CHAIN_IDS.fetch(:solana)
|
|
11
|
+
AVALANCHE_C_MAINNET = DexCatalogData::DEX_CHAIN_IDS.fetch(:avalanche_c)
|
|
12
|
+
end
|
|
13
|
+
|
|
14
|
+
# Offline access to the generated DEX, pool, and native-wrap catalog.
|
|
15
|
+
#
|
|
16
|
+
# The generated records are deeply frozen scalar/hash values. Lookups return
|
|
17
|
+
# those immutable records directly, so a caller cannot alter a later lookup
|
|
18
|
+
# or quote by mutating a previous result.
|
|
19
|
+
module DexCatalog
|
|
20
|
+
DEX_CATALOG_VERSION = DexCatalogData::DEX_CATALOG_VERSION
|
|
21
|
+
DEX_CATALOG_AS_OF_DATE = DexCatalogData::DEX_CATALOG_AS_OF_DATE
|
|
22
|
+
DEX_CATALOG_CONTENT_DIGEST = DexCatalogData::DEX_CATALOG_CONTENT_DIGEST
|
|
23
|
+
AS_OF_DATE = DEX_CATALOG_AS_OF_DATE
|
|
24
|
+
CONTENT_DIGEST = DEX_CATALOG_CONTENT_DIGEST
|
|
25
|
+
|
|
26
|
+
DEX_CHAIN_IDS = DexCatalogData::DEX_CHAIN_IDS
|
|
27
|
+
DEX_DEPLOYMENTS = DexCatalogData::DEX_DEPLOYMENTS
|
|
28
|
+
POOL_DEFINITIONS = DexCatalogData::POOL_DEFINITIONS
|
|
29
|
+
NATIVE_WRAP_DEFINITIONS = DexCatalogData::NATIVE_WRAP_DEFINITIONS
|
|
30
|
+
DEX_ALIASES = DexCatalogData::DEX_ALIASES
|
|
31
|
+
|
|
32
|
+
# Generated namespace modules contain the opaque IDs used by callers.
|
|
33
|
+
DEXES = Dexes
|
|
34
|
+
POOLS = Pools
|
|
35
|
+
|
|
36
|
+
EMPTY_POOLS = [].freeze
|
|
37
|
+
|
|
38
|
+
DEXES_BY_ID = DEX_DEPLOYMENTS.each_with_object({}) do |deployment, index|
|
|
39
|
+
index[deployment.fetch(:dex_deployment_id)] = deployment
|
|
40
|
+
end.freeze
|
|
41
|
+
|
|
42
|
+
POOLS_BY_ID = POOL_DEFINITIONS.each_with_object({}) do |pool, index|
|
|
43
|
+
index[pool.fetch(:pool_definition_id)] = pool
|
|
44
|
+
end.freeze
|
|
45
|
+
|
|
46
|
+
WRAPS_BY_NATIVE_ID = NATIVE_WRAP_DEFINITIONS.each_with_object({}) do |definition, index|
|
|
47
|
+
index[definition.fetch(:native_token_deployment_id)] = definition
|
|
48
|
+
end.freeze
|
|
49
|
+
|
|
50
|
+
KNOWN_CHAIN_IDS = [
|
|
51
|
+
DexChainIDs::ETHEREUM_MAINNET,
|
|
52
|
+
DexChainIDs::SOLANA_MAINNET,
|
|
53
|
+
DexChainIDs::AVALANCHE_C_MAINNET
|
|
54
|
+
].freeze
|
|
55
|
+
|
|
56
|
+
EVM_CHAIN_IDS = [
|
|
57
|
+
DexChainIDs::ETHEREUM_MAINNET,
|
|
58
|
+
DexChainIDs::AVALANCHE_C_MAINNET
|
|
59
|
+
].freeze
|
|
60
|
+
|
|
61
|
+
class << self
|
|
62
|
+
# Return the generated DEX namespace module for ergonomic alias access.
|
|
63
|
+
def dexes
|
|
64
|
+
Dexes
|
|
65
|
+
end
|
|
66
|
+
|
|
67
|
+
# Return the generated pool namespace module for ergonomic alias access.
|
|
68
|
+
def pools
|
|
69
|
+
Pools
|
|
70
|
+
end
|
|
71
|
+
|
|
72
|
+
# Return a DEX deployment by its exact opaque ID.
|
|
73
|
+
def get_dex_deployment(dex_deployment_id)
|
|
74
|
+
return nil unless dex_deployment_id.is_a?(String) && !dex_deployment_id.empty?
|
|
75
|
+
|
|
76
|
+
DEXES_BY_ID[dex_deployment_id]
|
|
77
|
+
end
|
|
78
|
+
|
|
79
|
+
# Return a pool definition by its exact opaque ID.
|
|
80
|
+
def get_pool_definition(pool_definition_id)
|
|
81
|
+
return nil unless pool_definition_id.is_a?(String) && !pool_definition_id.empty?
|
|
82
|
+
|
|
83
|
+
POOLS_BY_ID[pool_definition_id]
|
|
84
|
+
end
|
|
85
|
+
|
|
86
|
+
# Find a pool by chain-qualified address.
|
|
87
|
+
# EVM addresses are strict hexadecimal and matched case-insensitively;
|
|
88
|
+
# Solana addresses are matched exactly as their canonical base58 text.
|
|
89
|
+
def find_pool_definition_by_address(chain_id, address)
|
|
90
|
+
return nil unless known_chain_id?(chain_id)
|
|
91
|
+
return nil unless address.is_a?(String) && !address.empty?
|
|
92
|
+
|
|
93
|
+
normalized = address
|
|
94
|
+
if evm_chain_id?(chain_id)
|
|
95
|
+
return nil unless valid_evm_address?(address)
|
|
96
|
+
|
|
97
|
+
normalized = address.downcase
|
|
98
|
+
return nil if zero_evm_address?(normalized)
|
|
99
|
+
end
|
|
100
|
+
|
|
101
|
+
POOL_DEFINITIONS.find do |pool|
|
|
102
|
+
pool.fetch(:chain_id) == chain_id && pool.fetch(:address) == normalized
|
|
103
|
+
end
|
|
104
|
+
end
|
|
105
|
+
|
|
106
|
+
# Find all pools for an unordered token pair in stable pool-ID order.
|
|
107
|
+
def find_pool_definitions_by_pair(chain_id, token_a_deployment_id, token_b_deployment_id)
|
|
108
|
+
return EMPTY_POOLS unless known_chain_id?(chain_id)
|
|
109
|
+
return EMPTY_POOLS unless token_a_deployment_id.is_a?(String) && token_b_deployment_id.is_a?(String)
|
|
110
|
+
return EMPTY_POOLS if token_a_deployment_id.empty? || token_b_deployment_id.empty?
|
|
111
|
+
return EMPTY_POOLS if token_a_deployment_id == token_b_deployment_id
|
|
112
|
+
|
|
113
|
+
wanted = [token_a_deployment_id, token_b_deployment_id].sort
|
|
114
|
+
matches = POOL_DEFINITIONS.select do |pool|
|
|
115
|
+
actual = [pool.fetch(:token0_deployment_id), pool.fetch(:token1_deployment_id)].sort
|
|
116
|
+
pool.fetch(:chain_id) == chain_id && actual == wanted
|
|
117
|
+
end.sort_by { |pool| pool.fetch(:pool_definition_id) }
|
|
118
|
+
matches.empty? ? EMPTY_POOLS : matches.freeze
|
|
119
|
+
end
|
|
120
|
+
|
|
121
|
+
# List pools using the optional chainId/tokenDeploymentId/adapterKind
|
|
122
|
+
# filters. Ruby callers may use either the contract's camelCase keys or
|
|
123
|
+
# idiomatic snake_case keyword keys.
|
|
124
|
+
def list_pool_definitions(options = nil, **keyword_options)
|
|
125
|
+
if options.nil?
|
|
126
|
+
options = keyword_options
|
|
127
|
+
elsif !keyword_options.empty?
|
|
128
|
+
return EMPTY_POOLS
|
|
129
|
+
end
|
|
130
|
+
return EMPTY_POOLS unless options.is_a?(Hash)
|
|
131
|
+
|
|
132
|
+
normalized = normalize_filter_keys(options)
|
|
133
|
+
return EMPTY_POOLS unless normalized
|
|
134
|
+
|
|
135
|
+
chain_id = normalized[:chain_id]
|
|
136
|
+
token_deployment_id = normalized[:token_deployment_id]
|
|
137
|
+
adapter_kind = normalized[:adapter_kind]
|
|
138
|
+
return EMPTY_POOLS if chain_id && !known_chain_id?(chain_id)
|
|
139
|
+
return EMPTY_POOLS if token_deployment_id &&
|
|
140
|
+
(!token_deployment_id.is_a?(String) || token_deployment_id.empty?)
|
|
141
|
+
return EMPTY_POOLS if adapter_kind &&
|
|
142
|
+
(!adapter_kind.is_a?(String) || adapter_kind.empty?)
|
|
143
|
+
|
|
144
|
+
matches = POOL_DEFINITIONS.select do |pool|
|
|
145
|
+
(chain_id.nil? || pool.fetch(:chain_id) == chain_id) &&
|
|
146
|
+
(token_deployment_id.nil? ||
|
|
147
|
+
pool.fetch(:token0_deployment_id) == token_deployment_id ||
|
|
148
|
+
pool.fetch(:token1_deployment_id) == token_deployment_id) &&
|
|
149
|
+
(adapter_kind.nil? || pool.fetch(:adapter).fetch(:kind) == adapter_kind)
|
|
150
|
+
end.sort_by { |pool| pool.fetch(:pool_definition_id) }
|
|
151
|
+
matches.empty? ? EMPTY_POOLS : matches.freeze
|
|
152
|
+
end
|
|
153
|
+
|
|
154
|
+
# Return the chain-bound native-to-wrapped relationship for an opaque
|
|
155
|
+
# native token deployment ID. A wrap definition ID is not accepted.
|
|
156
|
+
def get_native_wrap_definition(native_token_deployment_id)
|
|
157
|
+
return nil unless native_token_deployment_id.is_a?(String) && !native_token_deployment_id.empty?
|
|
158
|
+
|
|
159
|
+
WRAPS_BY_NATIVE_ID[native_token_deployment_id]
|
|
160
|
+
end
|
|
161
|
+
|
|
162
|
+
private
|
|
163
|
+
|
|
164
|
+
def normalize_filter_keys(options)
|
|
165
|
+
aliases = {
|
|
166
|
+
"chainId" => :chain_id,
|
|
167
|
+
:chainId => :chain_id,
|
|
168
|
+
"chain_id" => :chain_id,
|
|
169
|
+
:chain_id => :chain_id,
|
|
170
|
+
"tokenDeploymentId" => :token_deployment_id,
|
|
171
|
+
:tokenDeploymentId => :token_deployment_id,
|
|
172
|
+
"token_deployment_id" => :token_deployment_id,
|
|
173
|
+
:token_deployment_id => :token_deployment_id,
|
|
174
|
+
"adapterKind" => :adapter_kind,
|
|
175
|
+
:adapterKind => :adapter_kind,
|
|
176
|
+
"adapter_kind" => :adapter_kind,
|
|
177
|
+
:adapter_kind => :adapter_kind
|
|
178
|
+
}
|
|
179
|
+
result = {}
|
|
180
|
+
options.each do |key, value|
|
|
181
|
+
target = aliases[key]
|
|
182
|
+
return nil unless target
|
|
183
|
+
return nil if result.key?(target)
|
|
184
|
+
|
|
185
|
+
result[target] = value
|
|
186
|
+
end
|
|
187
|
+
result
|
|
188
|
+
end
|
|
189
|
+
|
|
190
|
+
def known_chain_id?(chain_id)
|
|
191
|
+
chain_id.is_a?(String) && KNOWN_CHAIN_IDS.include?(chain_id)
|
|
192
|
+
end
|
|
193
|
+
|
|
194
|
+
def evm_chain_id?(chain_id)
|
|
195
|
+
EVM_CHAIN_IDS.include?(chain_id)
|
|
196
|
+
end
|
|
197
|
+
|
|
198
|
+
def valid_evm_address?(address)
|
|
199
|
+
address.match?(/\A0x[0-9A-Fa-f]{40}\z/)
|
|
200
|
+
end
|
|
201
|
+
|
|
202
|
+
def zero_evm_address?(address)
|
|
203
|
+
address == "0x#{'0' * 40}"
|
|
204
|
+
end
|
|
205
|
+
end
|
|
206
|
+
end
|
|
207
|
+
end
|
|
@@ -0,0 +1,28 @@
|
|
|
1
|
+
# frozen_string_literal: true
|
|
2
|
+
|
|
3
|
+
# Generated by registry/generate-dex-catalog.mjs. Do not edit.
|
|
4
|
+
|
|
5
|
+
module ERPC
|
|
6
|
+
module Dexes
|
|
7
|
+
Ethereum = { :UNISWAP_V2 => 'dex-deployment-0001' }.freeze
|
|
8
|
+
Solana = { :ORCA_WHIRLPOOLS => 'dex-deployment-0003', :RAYDIUM_CLMM => 'dex-deployment-0004' }.freeze
|
|
9
|
+
AvalancheC = { :LFJ_LEGACY => 'dex-deployment-0002' }.freeze
|
|
10
|
+
end
|
|
11
|
+
|
|
12
|
+
module Pools
|
|
13
|
+
Ethereum = { :DISCOVERED_POOL_1B98A5F24A364E05 => 'discovered-pool-1b98a5f24a364e05b3d56a9702c3560fc3a71f84b2195c486cfc5f8a956cc0b7', :DISCOVERED_POOL_6428A1E5DA293B2E => 'discovered-pool-6428a1e5da293b2ef62027ec823ba27532219a40784def3930feee56a623b809', :DISCOVERED_POOL_866F890448D13C07 => 'discovered-pool-866f890448d13c078e217a894ebd47430da5941fe5bff7e382fc095916b4614d', :DISCOVERED_POOL_90805F8995C1D0B8 => 'discovered-pool-90805f8995c1d0b85a45fcd4587928a00066b1f14407baee4e8ed1b634c07804', :DISCOVERED_POOL_A7F9E600A86951F4 => 'discovered-pool-a7f9e600a86951f40472ff779fae467db8a6bbbc6076356058f427e97d4ae429', :DISCOVERED_POOL_B8F972F8BAE36C82 => 'discovered-pool-b8f972f8bae36c82b51ed2aeed070d3ef3e7642e2a708c7d3c0c134e6e1946ed', :DISCOVERED_POOL_E702B0CB56528418 => 'discovered-pool-e702b0cb56528418b4ce089dfc001c6241c94e92aabde72f1a340c4601541780', :UNISWAP_V2_USDC_WETH => 'pool-0001' }.freeze
|
|
14
|
+
Solana = { :ORCA_WHIRLPOOLS_WSOL_EURC => 'pool-0003', :RAYDIUM_CLMM_WSOL_EURC => 'pool-0004' }.freeze
|
|
15
|
+
AvalancheC = { :DISCOVERED_POOL_1568E761C62F7DC5 => 'discovered-pool-1568e761c62f7dc58207a77f2dc32153805efe03a8d9cce9366ce68efdf276c4', :DISCOVERED_POOL_3C1E38D02092D16E => 'discovered-pool-3c1e38d02092d16e396d2f3a22b2bfae55246a1c566831d31f211670e45bd562', :DISCOVERED_POOL_3F840A40991E755E => 'discovered-pool-3f840a40991e755e42d242188bd8deb85cd5b9655308269b00c220f5237710cf', :DISCOVERED_POOL_5D7AA6A767A0C6EA => 'discovered-pool-5d7aa6a767a0c6ea9ddeb06d1289bd12d85018935d5b25724b165dc8b9832252', :DISCOVERED_POOL_9E4ED76F76904A4A => 'discovered-pool-9e4ed76f76904a4ae271946bb1a4b2dc7428e343040b05a42707071bbfac9462', :DISCOVERED_POOL_A2480F3D4EA5CE12 => 'discovered-pool-a2480f3d4ea5ce12252126acf64b174b9fe678b0f0fda8936a12fef180ae08cd', :DISCOVERED_POOL_ECE9088CF3894443 => 'discovered-pool-ece9088cf38944438897ff9fb2a1abc6855a687b5a3f0d6ab98dfe06c1a6dfef', :DISCOVERED_POOL_FB02E85806CD9079 => 'discovered-pool-fb02e85806cd907920126af935137b0775a858ddf04a28d7ca144f761fd7579e', :LFJ_LEGACY_WAVAX_USDC => 'pool-0002' }.freeze
|
|
16
|
+
end
|
|
17
|
+
|
|
18
|
+
module DexCatalogData
|
|
19
|
+
DEX_CATALOG_VERSION = '1.0.0'
|
|
20
|
+
DEX_CATALOG_AS_OF_DATE = '2026-09-15'
|
|
21
|
+
DEX_CATALOG_CONTENT_DIGEST = 'caccde1f997648dfa045af41d4f8b7f93a051c59d098cc770bd3a2757185aac1'
|
|
22
|
+
DEX_CHAIN_IDS = { ethereum: 'eip155:1', solana: 'solana:5eykt4UsFv8P8NJdTREpY1vzqKqZKvdp', avalanche_c: 'eip155:43114' }.freeze
|
|
23
|
+
DEX_DEPLOYMENTS = [{ dex_deployment_id: 'dex-deployment-0001', protocol_id: 'uniswap-v2', name: 'Uniswap V2', chain_id: 'eip155:1', program_address: '0x5c69bee701ef814a2b6a3edd4b1652cb9cc5aa6f', adapter_kind: 'evm-constant-product-v2', status: 'active', replaced_by_dex_deployment_id: nil }.freeze, { dex_deployment_id: 'dex-deployment-0002', protocol_id: 'lfj-legacy-constant-product', name: 'LFJ legacy constant-product (Joe V1)', chain_id: 'eip155:43114', program_address: '0x9ad6c38be94206ca50bb0d90783181662f0cfa10', adapter_kind: 'evm-constant-product-v2', status: 'active', replaced_by_dex_deployment_id: nil }.freeze, { dex_deployment_id: 'dex-deployment-0003', protocol_id: 'orca-whirlpools', name: 'Orca Whirlpools', chain_id: 'solana:5eykt4UsFv8P8NJdTREpY1vzqKqZKvdp', program_address: 'whirLbMiicVdio4qvUfM5KAg6Ct8VwpYzGff3uctyCc', adapter_kind: 'solana-orca-whirlpool', status: 'active', replaced_by_dex_deployment_id: nil }.freeze, { dex_deployment_id: 'dex-deployment-0004', protocol_id: 'raydium-clmm', name: 'Raydium CLMM', chain_id: 'solana:5eykt4UsFv8P8NJdTREpY1vzqKqZKvdp', program_address: 'CAMMCzo5YL8w4VFF8KVHrK22GGUsp5VTaW7grrKgrWqK', adapter_kind: 'solana-raydium-clmm', status: 'active', replaced_by_dex_deployment_id: nil }.freeze].freeze
|
|
24
|
+
POOL_DEFINITIONS = [{ pool_definition_id: 'discovered-pool-1568e761c62f7dc58207a77f2dc32153805efe03a8d9cce9366ce68efdf276c4', dex_deployment_id: 'dex-deployment-0002', chain_id: 'eip155:43114', address: '0xd5a37dc5c9a396a03dd1136fc76a1a02b1c88ffa', token0_deployment_id: 'discovered-token-9f9965cc065c9becf8d2cb58071524baafea37d27fda9bf683a93ea85f2e653d', token1_deployment_id: 'deployment-0004', adapter: { kind: 'evm-constant-product-v2', fee_numerator: '3', fee_denominator: '1000' }.freeze, status: 'active', replaced_by_pool_definition_id: nil }.freeze, { pool_definition_id: 'discovered-pool-1b98a5f24a364e05b3d56a9702c3560fc3a71f84b2195c486cfc5f8a956cc0b7', dex_deployment_id: 'dex-deployment-0001', chain_id: 'eip155:1', address: '0xc2adda861f89bbb333c90c492cb837741916a225', token0_deployment_id: 'discovered-token-b475569f6a15e97ac04e531dd813e9dcc902521c098d60d6ae4d21d53baf1395', token1_deployment_id: 'deployment-0002', adapter: { kind: 'evm-constant-product-v2', fee_numerator: '3', fee_denominator: '1000' }.freeze, status: 'active', replaced_by_pool_definition_id: nil }.freeze, { pool_definition_id: 'discovered-pool-3c1e38d02092d16e396d2f3a22b2bfae55246a1c566831d31f211670e45bd562', dex_deployment_id: 'dex-deployment-0002', chain_id: 'eip155:43114', address: '0xed8cbd9f0ce3c6986b22002f03c6475ceb7a6256', token0_deployment_id: 'deployment-0004', token1_deployment_id: 'discovered-token-288036a90ee0fa72a2751a78a6934cc6ced9e16de91c97ae8e109e2ee6189bc5', adapter: { kind: 'evm-constant-product-v2', fee_numerator: '3', fee_denominator: '1000' }.freeze, status: 'active', replaced_by_pool_definition_id: nil }.freeze, { pool_definition_id: 'discovered-pool-3f840a40991e755e42d242188bd8deb85cd5b9655308269b00c220f5237710cf', dex_deployment_id: 'dex-deployment-0002', chain_id: 'eip155:43114', address: '0xfe15c2695f1f920da45c30aae47d11de51007af9', token0_deployment_id: 'discovered-token-0a7f98c8752f15ee02ce0d801f25df8ff78864a1d70aff7e204f7bdb3f8a0692', token1_deployment_id: 'deployment-0004', adapter: { kind: 'evm-constant-product-v2', fee_numerator: '3', fee_denominator: '1000' }.freeze, status: 'active', replaced_by_pool_definition_id: nil }.freeze, { pool_definition_id: 'discovered-pool-5d7aa6a767a0c6ea9ddeb06d1289bd12d85018935d5b25724b165dc8b9832252', dex_deployment_id: 'dex-deployment-0002', chain_id: 'eip155:43114', address: '0x48f7c83c29e5ecea926d8169864d8cd022deaf3c', token0_deployment_id: 'discovered-token-323d07c442f0d089197ae7eea9b3ebb829910177c5b780161a7623aaed5e4371', token1_deployment_id: 'deployment-0004', adapter: { kind: 'evm-constant-product-v2', fee_numerator: '3', fee_denominator: '1000' }.freeze, status: 'active', replaced_by_pool_definition_id: nil }.freeze, { pool_definition_id: 'discovered-pool-6428a1e5da293b2ef62027ec823ba27532219a40784def3930feee56a623b809', dex_deployment_id: 'dex-deployment-0001', chain_id: 'eip155:1', address: '0xa2107fa5b38d9bbd2c461d6edf11b11a50f6b974', token0_deployment_id: 'deployment-0057', token1_deployment_id: 'deployment-0002', adapter: { kind: 'evm-constant-product-v2', fee_numerator: '3', fee_denominator: '1000' }.freeze, status: 'active', replaced_by_pool_definition_id: nil }.freeze, { pool_definition_id: 'discovered-pool-866f890448d13c078e217a894ebd47430da5941fe5bff7e382fc095916b4614d', dex_deployment_id: 'dex-deployment-0001', chain_id: 'eip155:1', address: '0xb6909b960dbbe7392d405429eb2b3649752b4838', token0_deployment_id: 'discovered-token-69519fd08e31445cad84b0c17a5346b7ee9c5692e270602af9308ca6d8943bb6', token1_deployment_id: 'deployment-0002', adapter: { kind: 'evm-constant-product-v2', fee_numerator: '3', fee_denominator: '1000' }.freeze, status: 'active', replaced_by_pool_definition_id: nil }.freeze, { pool_definition_id: 'discovered-pool-90805f8995c1d0b85a45fcd4587928a00066b1f14407baee4e8ed1b634c07804', dex_deployment_id: 'dex-deployment-0001', chain_id: 'eip155:1', address: '0x55d5c232d921b9eaa6b37b5845e439acd04b4dba', token0_deployment_id: 'discovered-token-611597bd13daa43d01a23caa9cca6a98797c64be7fb5b2677370ddbcdeaf01ec', token1_deployment_id: 'deployment-0002', adapter: { kind: 'evm-constant-product-v2', fee_numerator: '3', fee_denominator: '1000' }.freeze, status: 'active', replaced_by_pool_definition_id: nil }.freeze, { pool_definition_id: 'discovered-pool-9e4ed76f76904a4ae271946bb1a4b2dc7428e343040b05a42707071bbfac9462', dex_deployment_id: 'dex-deployment-0002', chain_id: 'eip155:43114', address: '0x6f3a0c89f611ef5dc9d96650324ac633d02265d3', token0_deployment_id: 'deployment-0058', token1_deployment_id: 'deployment-0004', adapter: { kind: 'evm-constant-product-v2', fee_numerator: '3', fee_denominator: '1000' }.freeze, status: 'active', replaced_by_pool_definition_id: nil }.freeze, { pool_definition_id: 'discovered-pool-a2480f3d4ea5ce12252126acf64b174b9fe678b0f0fda8936a12fef180ae08cd', dex_deployment_id: 'dex-deployment-0002', chain_id: 'eip155:43114', address: '0xa389f9430876455c36478deea9769b7ca4e3ddb1', token0_deployment_id: 'deployment-0018', token1_deployment_id: 'deployment-0004', adapter: { kind: 'evm-constant-product-v2', fee_numerator: '3', fee_denominator: '1000' }.freeze, status: 'active', replaced_by_pool_definition_id: nil }.freeze, { pool_definition_id: 'discovered-pool-a7f9e600a86951f40472ff779fae467db8a6bbbc6076356058f427e97d4ae429', dex_deployment_id: 'dex-deployment-0001', chain_id: 'eip155:1', address: '0xa478c2975ab1ea89e8196811f51a7b7ade33eb11', token0_deployment_id: 'deployment-0019', token1_deployment_id: 'deployment-0002', adapter: { kind: 'evm-constant-product-v2', fee_numerator: '3', fee_denominator: '1000' }.freeze, status: 'active', replaced_by_pool_definition_id: nil }.freeze, { pool_definition_id: 'discovered-pool-b8f972f8bae36c82b51ed2aeed070d3ef3e7642e2a708c7d3c0c134e6e1946ed', dex_deployment_id: 'dex-deployment-0001', chain_id: 'eip155:1', address: '0x11b1f53204d03e5529f09eb3091939e4fd8c9cf3', token0_deployment_id: 'discovered-token-054d80a64e1f36a756129763ca2f1e7a140b50b04c83876ff01dd5fd497a74c5', token1_deployment_id: 'deployment-0002', adapter: { kind: 'evm-constant-product-v2', fee_numerator: '3', fee_denominator: '1000' }.freeze, status: 'active', replaced_by_pool_definition_id: nil }.freeze, { pool_definition_id: 'discovered-pool-e702b0cb56528418b4ce089dfc001c6241c94e92aabde72f1a340c4601541780', dex_deployment_id: 'dex-deployment-0001', chain_id: 'eip155:1', address: '0xbb2b8038a1640196fbe3e38816f3e67cba72d940', token0_deployment_id: 'discovered-token-e375086901067fe3de023bcdc70f1bafca798e1719ed7e676a98f57de3350a07', token1_deployment_id: 'deployment-0002', adapter: { kind: 'evm-constant-product-v2', fee_numerator: '3', fee_denominator: '1000' }.freeze, status: 'active', replaced_by_pool_definition_id: nil }.freeze, { pool_definition_id: 'discovered-pool-ece9088cf38944438897ff9fb2a1abc6855a687b5a3f0d6ab98dfe06c1a6dfef', dex_deployment_id: 'dex-deployment-0002', chain_id: 'eip155:43114', address: '0x454e67025631c065d3cfad6d71e6892f74487a15', token0_deployment_id: 'deployment-0059', token1_deployment_id: 'deployment-0004', adapter: { kind: 'evm-constant-product-v2', fee_numerator: '3', fee_denominator: '1000' }.freeze, status: 'active', replaced_by_pool_definition_id: nil }.freeze, { pool_definition_id: 'discovered-pool-fb02e85806cd907920126af935137b0775a858ddf04a28d7ca144f761fd7579e', dex_deployment_id: 'dex-deployment-0002', chain_id: 'eip155:43114', address: '0xb6a00cead355d1ec492fd72e1d79199c347a74b5', token0_deployment_id: 'discovered-token-1847342426b765add3c8b4feb724c6b15121f25097cb7917c967c285ca77e804', token1_deployment_id: 'deployment-0004', adapter: { kind: 'evm-constant-product-v2', fee_numerator: '3', fee_denominator: '1000' }.freeze, status: 'active', replaced_by_pool_definition_id: nil }.freeze, { pool_definition_id: 'pool-0001', dex_deployment_id: 'dex-deployment-0001', chain_id: 'eip155:1', address: '0xb4e16d0168e52d35cacd2c6185b44281ec28c9dc', token0_deployment_id: 'deployment-0008', token1_deployment_id: 'deployment-0002', adapter: { kind: 'evm-constant-product-v2', fee_numerator: '3', fee_denominator: '1000' }.freeze, status: 'active', replaced_by_pool_definition_id: nil }.freeze, { pool_definition_id: 'pool-0002', dex_deployment_id: 'dex-deployment-0002', chain_id: 'eip155:43114', address: '0xf4003f4efbe8691b60249e6afbd307abe7758adb', token0_deployment_id: 'deployment-0004', token1_deployment_id: 'deployment-0009', adapter: { kind: 'evm-constant-product-v2', fee_numerator: '3', fee_denominator: '1000' }.freeze, status: 'active', replaced_by_pool_definition_id: nil }.freeze, { pool_definition_id: 'pool-0003', dex_deployment_id: 'dex-deployment-0003', chain_id: 'solana:5eykt4UsFv8P8NJdTREpY1vzqKqZKvdp', address: 'FgH1dEvyRQoAqJjbUzzKVoM1HYdxTqPwjEF82kDH1kVe', token0_deployment_id: 'deployment-0006', token1_deployment_id: 'deployment-0013', adapter: { kind: 'solana-orca-whirlpool', fee_numerator: nil, fee_denominator: nil }.freeze, status: 'active', replaced_by_pool_definition_id: nil }.freeze, { pool_definition_id: 'pool-0004', dex_deployment_id: 'dex-deployment-0004', chain_id: 'solana:5eykt4UsFv8P8NJdTREpY1vzqKqZKvdp', address: 'AwaVyGAF3N6K4YRUJk55Ui1GquKhKdD6vTCmVvCzXpKf', token0_deployment_id: 'deployment-0006', token1_deployment_id: 'deployment-0013', adapter: { kind: 'solana-raydium-clmm', fee_numerator: nil, fee_denominator: nil }.freeze, status: 'active', replaced_by_pool_definition_id: nil }.freeze].freeze
|
|
25
|
+
NATIVE_WRAP_DEFINITIONS = [{ native_wrap_definition_id: 'native-wrap-0001', chain_id: 'eip155:1', native_token_deployment_id: 'deployment-0001', wrapped_token_deployment_id: 'deployment-0002', status: 'active' }.freeze, { native_wrap_definition_id: 'native-wrap-0002', chain_id: 'eip155:43114', native_token_deployment_id: 'deployment-0003', wrapped_token_deployment_id: 'deployment-0004', status: 'active' }.freeze, { native_wrap_definition_id: 'native-wrap-0003', chain_id: 'solana:5eykt4UsFv8P8NJdTREpY1vzqKqZKvdp', native_token_deployment_id: 'deployment-0005', wrapped_token_deployment_id: 'deployment-0006', status: 'active' }.freeze].freeze
|
|
26
|
+
DEX_ALIASES = [{ namespace: 'avalancheC', name: 'DISCOVERED_POOL_1568E761C62F7DC5', dex_deployment_id: nil, pool_definition_id: ERPC::Pools::AvalancheC[:DISCOVERED_POOL_1568E761C62F7DC5] }.freeze, { namespace: 'avalancheC', name: 'DISCOVERED_POOL_3C1E38D02092D16E', dex_deployment_id: nil, pool_definition_id: ERPC::Pools::AvalancheC[:DISCOVERED_POOL_3C1E38D02092D16E] }.freeze, { namespace: 'avalancheC', name: 'DISCOVERED_POOL_3F840A40991E755E', dex_deployment_id: nil, pool_definition_id: ERPC::Pools::AvalancheC[:DISCOVERED_POOL_3F840A40991E755E] }.freeze, { namespace: 'avalancheC', name: 'DISCOVERED_POOL_5D7AA6A767A0C6EA', dex_deployment_id: nil, pool_definition_id: ERPC::Pools::AvalancheC[:DISCOVERED_POOL_5D7AA6A767A0C6EA] }.freeze, { namespace: 'avalancheC', name: 'DISCOVERED_POOL_9E4ED76F76904A4A', dex_deployment_id: nil, pool_definition_id: ERPC::Pools::AvalancheC[:DISCOVERED_POOL_9E4ED76F76904A4A] }.freeze, { namespace: 'avalancheC', name: 'DISCOVERED_POOL_A2480F3D4EA5CE12', dex_deployment_id: nil, pool_definition_id: ERPC::Pools::AvalancheC[:DISCOVERED_POOL_A2480F3D4EA5CE12] }.freeze, { namespace: 'avalancheC', name: 'DISCOVERED_POOL_ECE9088CF3894443', dex_deployment_id: nil, pool_definition_id: ERPC::Pools::AvalancheC[:DISCOVERED_POOL_ECE9088CF3894443] }.freeze, { namespace: 'avalancheC', name: 'DISCOVERED_POOL_FB02E85806CD9079', dex_deployment_id: nil, pool_definition_id: ERPC::Pools::AvalancheC[:DISCOVERED_POOL_FB02E85806CD9079] }.freeze, { namespace: 'avalancheC', name: 'LFJ_LEGACY', dex_deployment_id: ERPC::Dexes::AvalancheC[:LFJ_LEGACY], pool_definition_id: nil }.freeze, { namespace: 'avalancheC', name: 'LFJ_LEGACY_WAVAX_USDC', dex_deployment_id: nil, pool_definition_id: ERPC::Pools::AvalancheC[:LFJ_LEGACY_WAVAX_USDC] }.freeze, { namespace: 'ethereum', name: 'DISCOVERED_POOL_1B98A5F24A364E05', dex_deployment_id: nil, pool_definition_id: ERPC::Pools::Ethereum[:DISCOVERED_POOL_1B98A5F24A364E05] }.freeze, { namespace: 'ethereum', name: 'DISCOVERED_POOL_6428A1E5DA293B2E', dex_deployment_id: nil, pool_definition_id: ERPC::Pools::Ethereum[:DISCOVERED_POOL_6428A1E5DA293B2E] }.freeze, { namespace: 'ethereum', name: 'DISCOVERED_POOL_866F890448D13C07', dex_deployment_id: nil, pool_definition_id: ERPC::Pools::Ethereum[:DISCOVERED_POOL_866F890448D13C07] }.freeze, { namespace: 'ethereum', name: 'DISCOVERED_POOL_90805F8995C1D0B8', dex_deployment_id: nil, pool_definition_id: ERPC::Pools::Ethereum[:DISCOVERED_POOL_90805F8995C1D0B8] }.freeze, { namespace: 'ethereum', name: 'DISCOVERED_POOL_A7F9E600A86951F4', dex_deployment_id: nil, pool_definition_id: ERPC::Pools::Ethereum[:DISCOVERED_POOL_A7F9E600A86951F4] }.freeze, { namespace: 'ethereum', name: 'DISCOVERED_POOL_B8F972F8BAE36C82', dex_deployment_id: nil, pool_definition_id: ERPC::Pools::Ethereum[:DISCOVERED_POOL_B8F972F8BAE36C82] }.freeze, { namespace: 'ethereum', name: 'DISCOVERED_POOL_E702B0CB56528418', dex_deployment_id: nil, pool_definition_id: ERPC::Pools::Ethereum[:DISCOVERED_POOL_E702B0CB56528418] }.freeze, { namespace: 'ethereum', name: 'UNISWAP_V2', dex_deployment_id: ERPC::Dexes::Ethereum[:UNISWAP_V2], pool_definition_id: nil }.freeze, { namespace: 'ethereum', name: 'UNISWAP_V2_USDC_WETH', dex_deployment_id: nil, pool_definition_id: ERPC::Pools::Ethereum[:UNISWAP_V2_USDC_WETH] }.freeze, { namespace: 'solana', name: 'ORCA_WHIRLPOOLS', dex_deployment_id: ERPC::Dexes::Solana[:ORCA_WHIRLPOOLS], pool_definition_id: nil }.freeze, { namespace: 'solana', name: 'ORCA_WHIRLPOOLS_WSOL_EURC', dex_deployment_id: nil, pool_definition_id: ERPC::Pools::Solana[:ORCA_WHIRLPOOLS_WSOL_EURC] }.freeze, { namespace: 'solana', name: 'RAYDIUM_CLMM', dex_deployment_id: ERPC::Dexes::Solana[:RAYDIUM_CLMM], pool_definition_id: nil }.freeze, { namespace: 'solana', name: 'RAYDIUM_CLMM_WSOL_EURC', dex_deployment_id: nil, pool_definition_id: ERPC::Pools::Solana[:RAYDIUM_CLMM_WSOL_EURC] }.freeze].freeze
|
|
27
|
+
end
|
|
28
|
+
end
|