Skip to main content

πŸ“„ Document steps of Add new chains to api3dao/contracts for Csur

Merge into chain-integration-process.md

Process Description: This issue documents the detailed steps required to complete the Add new chains to api3dao/contracts for Csur issues for delegation purpose.

Steps to add new chains to api3dao/contracts for Csur​

The detailed steps required to complete the Add new chains to api3dao/contracts for Csur issues are documented below:

1. Extract key infrastructure details about the chain​

  • Acquire chains documentation and link them to the issue.
  • Chain ID.
  • Block Explorer URL.
  • Bridge information (if applicable).
  • Faucet details (for testnets).

2. Add the new chains details to api3dao/contracts/data/chains​

  • Checkout to the Csur-YYYY-MM-DD branch from main.
  • Create the relevant chain’s JSON files under api3dao/contracts/data/chains.
  • Identify the key-value pairs for the chains objects and populate the related chains JSON files accordingly:
    • alias
    • blockExplorerUrl
    • decimals
    • id
    • name
    • providers
      • default rpcUrl
      • private1 homepageUrl
      • private2 homepageUrl
      • private3 homepageUrl
      • Etc…
    • symbol
    • testnet
    • verificationApi

3. Execute scripts to generate and validate chain data​

4. Obtain funds for the chains​

  • For Mainnets: Obtain approximately $350 per chain for the contracts deployment. Consider the following methods:
    • Use a bridge if applicable.
    • Transact through exchanges (DEX or CEX).
    • Acquire funds through existing partnerships or grants (coordinate with the Business Development team).
  • For Testnets: Acquire equivalent funds through bridges, faucets, or existing partnerships.

5. Fund the deployer wallet​

  • Send the funds on all chains to the deployer wallet address: 0xBED0d9914B3901c6a4C4F33ECDf6068dB53a491e.

6. Deploy contracts on testnet and mainnet​

Deploy the following contracts in a deterministic way (using deployment scripts from the api3dao/contracts repository) to ensure everything is working as expected:

  • Run NETWORK=<CHAIN_ALIAS> pnpm deploy:deterministic to execute hardhat deploy
    • GnosisSafeWithoutProxy
    • OwnableCallForwarder
    • AccessControlRegistry
    • Api3ServerV1
    • Api3ServerV1OevExtension
    • Api3ReaderProxyV1Factory
    • Api3ReaderProxyV1
    • Api3MarketV2
    • AirseekerRegistry

In case deterministic deployment fails, deploy the contracts using undeterministic deployment method;

  • Run NETWORK=<CHAIN_ALIAS> pnpm deploy:undeterministic to execute hardhat deploy

Owner: Hayrettin