Skip to content

Commit

Permalink
chore: Add treasure Mainnet and treasureTopaz Testnet (#3110)
Browse files Browse the repository at this point in the history
* chore: Add `treasure` Mainnet and `treasureTopaz` Testnet

* Create gentle-moles-search.md

---------

Co-authored-by: jxom <7336481+jxom@users.noreply.github.com>
  • Loading branch information
karelvuong and jxom authored Dec 11, 2024
1 parent 0c41e94 commit 915c6c2
Show file tree
Hide file tree
Showing 4 changed files with 71 additions and 0 deletions.
5 changes: 5 additions & 0 deletions .changeset/gentle-moles-search.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
"viem": patch
---

Added `treasure` Mainnet and `treasureTopaz` Testnet.
32 changes: 32 additions & 0 deletions src/chains/definitions/treasure.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,32 @@
import { defineChain } from '../../utils/chain/defineChain.js'
import { chainConfig } from '../../zksync/chainConfig.js'

export const treasure = /*#__PURE__*/ defineChain({
...chainConfig,
id: 61_166,
name: 'Treasure',
nativeCurrency: {
decimals: 18,
name: 'MAGIC',
symbol: 'MAGIC',
},
rpcUrls: {
default: {
http: ['https://rpc.treasure.lol'],
webSocket: ['wss://rpc.treasure.lol/ws'],
},
},
blockExplorers: {
default: {
name: 'Treasure Block Explorer',
url: 'https://treasurescan.io',
},
},
contracts: {
multicall3: {
address: '0x2e29fe39496a56856D8698bD43e1dF4D0CE6266a',
blockCreated: 101,
},
},
testnet: false,
})
32 changes: 32 additions & 0 deletions src/chains/definitions/treasureTopaz.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,32 @@
import { defineChain } from '../../utils/chain/defineChain.js'
import { chainConfig } from '../../zksync/chainConfig.js'

export const treasureTopaz = /*#__PURE__*/ defineChain({
...chainConfig,
id: 978_658,
name: 'Treasure Topaz Testnet',
nativeCurrency: {
decimals: 18,
name: 'MAGIC',
symbol: 'MAGIC',
},
rpcUrls: {
default: {
http: ['https://rpc.topaz.treasure.lol'],
webSocket: ['wss://rpc.topaz.treasure.lol/ws'],
},
},
blockExplorers: {
default: {
name: 'Treasure Topaz Block Explorer',
url: 'https://topaz.treasurescan.io',
},
},
contracts: {
multicall3: {
address: '0xF9cda624FBC7e059355ce98a31693d299FACd963',
blockCreated: 108112,
},
},
testnet: true,
})
2 changes: 2 additions & 0 deletions src/chains/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -426,6 +426,8 @@ export { thunderCore } from './definitions/thunderCore.js'
export { thunderTestnet } from './definitions/thunderTestnet.js'
export { tiktrixTestnet } from './definitions/tiktrixTestnet.js'
export { tomb } from './definitions/tomb.js'
export { treasure } from './definitions/treasure.js'
export { treasureTopaz } from './definitions/treasureTopaz.js'
export { tron } from './definitions/tron.js'
export { ubiq } from './definitions/ubiq.js'
export { ultron } from './definitions/ultron.js'
Expand Down

0 comments on commit 915c6c2

Please sign in to comment.