@@ -5,27 +5,31 @@ import { ChainId } from '@uniswap/sdk-core'
55export const v4SubgraphUrlOverride = ( chainId : ChainId ) => {
66 switch ( chainId ) {
77 case ChainId . SEPOLIA :
8- return `https://subgraph.satsuma-prod.com/${ process . env . ALCHEMY_QUERY_KEY } /bransfer/uniswap-v4- sepolia-test /api`
8+ return `https://subgraph.satsuma-prod.com/${ process . env . ALCHEMY_QUERY_KEY } /bransfer/sepolia-v4 /api`
99 case ChainId . ARBITRUM_ONE :
1010 return `https://subgraph.satsuma-prod.com/${ process . env . ALCHEMY_QUERY_KEY } /bransfer/arbitrum-v4/api`
1111 case ChainId . BASE :
12- return `https://subgraph.satsuma-prod.com/${ process . env . ALCHEMY_QUERY_KEY } /bransfer/uniswap -v4-base /api`
12+ return `https://subgraph.satsuma-prod.com/${ process . env . ALCHEMY_QUERY_KEY } /bransfer/base -v4/api`
1313 case ChainId . POLYGON :
14- return `https://subgraph.satsuma-prod.com/${ process . env . ALCHEMY_QUERY_KEY } /bransfer/uniswap -v4-polygon /api`
14+ return `https://subgraph.satsuma-prod.com/${ process . env . ALCHEMY_QUERY_KEY } /bransfer/polygon -v4/api`
1515 case ChainId . WORLDCHAIN :
16- return `https://subgraph.satsuma-prod.com/${ process . env . ALCHEMY_QUERY_KEY } /bransfer/uniswap -v4-worldchain /api`
16+ return `https://subgraph.satsuma-prod.com/${ process . env . ALCHEMY_QUERY_KEY } /bransfer/worldchain -v4/api`
1717 case ChainId . ZORA :
18- return `https://subgraph.satsuma-prod.com/${ process . env . ALCHEMY_QUERY_KEY } /bransfer/uniswap -v4-zora /api`
18+ return `https://subgraph.satsuma-prod.com/${ process . env . ALCHEMY_QUERY_KEY } /bransfer/zora -v4/api`
1919 case ChainId . UNICHAIN :
20- return `https://subgraph.satsuma-prod.com/${ process . env . ALCHEMY_QUERY_KEY } /bransfer/uniswap-v4- unichain-mainnet /api`
20+ return `https://subgraph.satsuma-prod.com/${ process . env . ALCHEMY_QUERY_KEY } /bransfer/unichain-v4 /api`
2121 case ChainId . BNB :
22- return `https://subgraph.satsuma-prod.com/${ process . env . ALCHEMY_QUERY_KEY } /bransfer/uniswap -v4-bsc /api`
22+ return `https://subgraph.satsuma-prod.com/${ process . env . ALCHEMY_QUERY_KEY } /bransfer/bsc -v4/api`
2323 case ChainId . BLAST :
24- return `https://subgraph.satsuma-prod.com/${ process . env . ALCHEMY_QUERY_KEY } /bransfer/uniswap -v4-blast /api`
24+ return `https://subgraph.satsuma-prod.com/${ process . env . ALCHEMY_QUERY_KEY } /bransfer/blast -v4/api`
2525 case ChainId . MAINNET :
2626 return `https://subgraph.satsuma-prod.com/${ process . env . ALCHEMY_QUERY_KEY } /bransfer/ethereum-v4/api`
2727 case ChainId . SONEIUM :
28- return `https://subgraph.satsuma-prod.com/${ process . env . ALCHEMY_QUERY_KEY } /bransfer/uniswap-v4-soneium-mainnet/api`
28+ return `https://subgraph.satsuma-prod.com/${ process . env . ALCHEMY_QUERY_KEY } /bransfer/soneium-v4/api`
29+ case ChainId . AVALANCHE :
30+ return `https://subgraph.satsuma-prod.com/${ process . env . ALCHEMY_QUERY_KEY } /bransfer/avalanche-v4/api`
31+ case ChainId . OPTIMISM :
32+ return `https://subgraph.satsuma-prod.com/${ process . env . ALCHEMY_QUERY_KEY } /bransfer/optimism-v4/api`
2933 default :
3034 return undefined
3135 }
@@ -109,95 +113,95 @@ const v2UntrackedUsdThreshold = Number.MAX_VALUE // Pairs need at least 1K USD (
109113
110114export const chainProtocols = [
111115 // V3.
116+
117+
118+ // V2.
119+
120+
121+ // V4
122+
112123 {
113- protocol : Protocol . V3 ,
124+ protocol : Protocol . V4 ,
114125 chainId : ChainId . MAINNET ,
115126 timeout : 90000 ,
116- provider : new V3SubgraphProvider (
127+ provider : new V4SubgraphProvider (
117128 ChainId . MAINNET ,
118129 3 ,
119130 90000 ,
120131 true ,
121- v3TrackedEthThreshold ,
122- v3UntrackedUsdThreshold ,
123- v3SubgraphUrlOverride ( ChainId . MAINNET )
132+ v4TrackedEthThreshold ,
133+ v4UntrackedUsdThreshold ,
134+ v4SubgraphUrlOverride ( ChainId . MAINNET )
124135 ) ,
125136 } ,
126137 {
127- protocol : Protocol . V3 ,
138+ protocol : Protocol . V4 ,
128139 chainId : ChainId . ARBITRUM_ONE ,
129140 timeout : 90000 ,
130- provider : new V3SubgraphProvider (
141+ provider : new V4SubgraphProvider (
131142 ChainId . ARBITRUM_ONE ,
132- 5 ,
143+ 3 ,
133144 90000 ,
134145 true ,
135- v3TrackedEthThreshold ,
136- v3UntrackedUsdThreshold ,
137- v3SubgraphUrlOverride ( ChainId . ARBITRUM_ONE )
146+ v4TrackedEthThreshold ,
147+ v4UntrackedUsdThreshold ,
148+ v4SubgraphUrlOverride ( ChainId . ARBITRUM_ONE )
138149 ) ,
139150 } ,
140-
141- // V2.
142151 {
143- protocol : Protocol . V2 ,
144- chainId : ChainId . MAINNET ,
145- timeout : 840000 ,
146- provider : new V2SubgraphProvider (
147- ChainId . MAINNET ,
148- 5 ,
149- 900000 ,
152+ protocol : Protocol . V4 ,
153+ chainId : ChainId . BASE ,
154+ timeout : 90000 ,
155+ provider : new V4SubgraphProvider (
156+ ChainId . BASE ,
157+ 3 ,
158+ 90000 ,
150159 true ,
151- 1000 ,
152- v2TrackedEthThreshold ,
153- v2UntrackedUsdThreshold ,
154- v2SubgraphUrlOverride ( ChainId . MAINNET )
155- ) , // 1000 is the largest page size supported by thegraph
160+ v4TrackedEthThreshold ,
161+ v4UntrackedUsdThreshold ,
162+ v4SubgraphUrlOverride ( ChainId . BASE )
163+ ) ,
156164 } ,
157165 {
158- protocol : Protocol . V2 ,
159- chainId : ChainId . ARBITRUM_ONE ,
166+ protocol : Protocol . V4 ,
167+ chainId : ChainId . BNB ,
160168 timeout : 90000 ,
161- provider : new V2SubgraphProvider (
162- ChainId . ARBITRUM_ONE ,
169+ provider : new V4SubgraphProvider (
170+ ChainId . BNB ,
163171 3 ,
164172 90000 ,
165173 true ,
166- 1000 ,
167- v2TrackedEthThreshold ,
168- v2UntrackedUsdThreshold ,
169- v2SubgraphUrlOverride ( ChainId . ARBITRUM_ONE )
174+ v4TrackedEthThreshold ,
175+ v4UntrackedUsdThreshold ,
176+ v4SubgraphUrlOverride ( ChainId . BNB )
170177 ) ,
171178 } ,
172-
173- // V4
174-
175179 {
176180 protocol : Protocol . V4 ,
177- chainId : ChainId . MAINNET ,
181+ chainId : ChainId . OPTIMISM ,
178182 timeout : 90000 ,
179183 provider : new V4SubgraphProvider (
180- ChainId . MAINNET ,
184+ ChainId . OPTIMISM ,
181185 3 ,
182186 90000 ,
183187 true ,
184188 v4TrackedEthThreshold ,
185189 v4UntrackedUsdThreshold ,
186- v4SubgraphUrlOverride ( ChainId . MAINNET )
190+ v4SubgraphUrlOverride ( ChainId . OPTIMISM )
187191 ) ,
188192 } ,
189193 {
190194 protocol : Protocol . V4 ,
191- chainId : ChainId . ARBITRUM_ONE ,
195+ chainId : ChainId . AVALANCHE ,
192196 timeout : 90000 ,
193197 provider : new V4SubgraphProvider (
194- ChainId . ARBITRUM_ONE ,
198+ ChainId . AVALANCHE ,
195199 3 ,
196200 90000 ,
197201 true ,
198202 v4TrackedEthThreshold ,
199203 v4UntrackedUsdThreshold ,
200- v4SubgraphUrlOverride ( ChainId . ARBITRUM_ONE )
204+ v4SubgraphUrlOverride ( ChainId . AVALANCHE )
201205 ) ,
202206 } ,
203207]
0 commit comments