Quickstart

Add Network (MetaMask)

await window.ethereum.request({
  method: 'wallet_addEthereumChain',
  params: [{
    chainId: '0xf765',
    chainName: 'tiger-chain-testnet',
    nativeCurrency: { name: 'Ether', symbol: 'ETH', decimals: 18 },
    rpcUrls: ['https://testnet-rpc.tigerchain.app'], 
    blockExplorerUrls: ['https://testnet-explorer.tigerchain.app']
  }]
})

viem

import { createPublicClient, http } from 'viem'
export const client = createPublicClient({
  transport: http('https://testnet-rpc.tigerchain.app'), 
})

ethers v6

import { JsonRpcProvider } from 'ethers'
export const provider = new JsonRpcProvider('https://testnet-rpc.tigerchain.app') 

wagmi (custom chain)

import { http, createConfig } from 'wagmi'
import { defineChain } from 'viem'

export const tigerTestnet = defineChain({
  id: 63333, 
  name: 'TigerChain Testnet',
  nativeCurrency: { name: 'Ether', symbol: 'ETH', decimals: 18 },
  rpcUrls: { default: { http: ['https://testnet-rpc.tigerchain.app'] } }, 
  blockExplorers: { default: { name: 'Blockscout', url: 'https://testnet-explorer.tigerchain.app' } },
})

export const config = createConfig({
  chains: [tigerTestnet],
  transports: { [tigerTestnet.id]: http() },
})

Last updated