Skip to content

Commit 47d2d06

Browse files
committed
chore: new chains support
1 parent 5b1129b commit 47d2d06

File tree

3 files changed

+23
-2
lines changed

3 files changed

+23
-2
lines changed

generated/types.ts

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -26,8 +26,11 @@ export interface RegistryChain<N extends number, C extends string> {
2626
chainId: N;
2727
centrifugeId: number;
2828
catapultaNetwork?: string;
29+
protocolAdmin?: string;
30+
opsAdmin?: string;
2931
etherscanUrl?: string;
3032
network?: string;
33+
batchLimit?: number;
3134
safeAdmin?: string;
3235
};
3336
adapters: unknown;

src/chains.ts

Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -32,6 +32,9 @@ export const networkNames = {
3232
"98866": "plume",
3333
"56": "binance",
3434
"998": "hyperliquid",
35+
"10": "optimism",
36+
"143": "monad",
37+
"999": "hyperliquid",
3538
} as const;
3639

3740
type ExtractNetworkNamesFromKeys<K> = K extends keyof typeof networkNames
@@ -119,6 +122,18 @@ export const endpoints = {
119122
`https://hyperliquid-testnet.g.alchemy.com/v2/${process.env.ALCHEMY_API_KEY}`,
120123
`https://${process.env.QUICKNODE_API_NAME}.hype-testnet.quiknode.pro/${process.env.QUICKNODE_API_KEY}/evm`,
121124
],
125+
10: [
126+
`https://opt-mainnet.g.alchemy.com/v2/${process.env.ALCHEMY_API_KEY}`,
127+
`https://${process.env.QUICKNODE_API_NAME}.optimism-mainnet.quiknode.pro/${process.env.QUICKNODE_API_KEY}`,
128+
],
129+
143: [
130+
`https://monad-mainnet.g.alchemy.com/v2/${process.env.ALCHEMY_API_KEY}`,
131+
`https://${process.env.QUICKNODE_API_NAME}.monad-mainnet.quiknode.pro/${process.env.QUICKNODE_API_KEY}`,
132+
],
133+
999: [
134+
`https://hyperliquid-mainnet.g.alchemy.com/v2/${process.env.ALCHEMY_API_KEY}`,
135+
`https://${process.env.QUICKNODE_API_NAME}.hyperliquid-mainnet.quiknode.pro/${process.env.QUICKNODE_API_KEY}`,
136+
],
122137
};
123138

124139
// Package loadedChains into a ChainConfig object for ponder to consume
@@ -158,6 +173,9 @@ export const skipBlocks = {
158173
"1": 300,
159174
"98866": 9000,
160175
"56": 4800,
176+
"10": 1800,
177+
"143": 9000,
178+
"999": 18000,
161179
};
162180

163181
const blocks = Object.fromEntries(

src/handlers/setupHandlers.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@ multiMapper("multiAdapter:setup", async ({ context }) => {
2020
serviceLog(
2121
`Initialising adapter ${adapterName} with address ${adapterAddress} on chain ${chainId}`
2222
);
23-
const adapter = await AdapterService.insert(
23+
const adapter = await AdapterService.upsert(
2424
context,
2525
{
2626
name: adapterName,
@@ -64,7 +64,7 @@ multiMapper("hubRegistry:setup", async ({ context }) => {
6464
}
6565

6666
const contracts = Object.fromEntries(contractsMap);
67-
const _deployment = await DeploymentService.insert(
67+
const _deployment = await DeploymentService.upsert(
6868
context,
6969
{
7070
chainId: currentChain.network.chainId.toString(),

0 commit comments

Comments
 (0)