├── .github └── workflows │ └── main.yml ├── .gitignore ├── LICENSE ├── README.md ├── abis ├── CP.json ├── CPV2.json ├── Controller.json ├── CrowdPoolingFactory.json ├── CrowdPoolingFactoryV2.json ├── DODO.json ├── DODOAvatarERC1155.json ├── DODOAvatarERC721.json ├── DODOEthProxy.json ├── DODOFeeRouteProxy.json ├── DODOIncentive.json ├── DODOLpToken.json ├── DODOMine.json ├── DODOMineV3Proxy.json ├── DODOMineV3ProxyV2.json ├── DODOMineV3Registry.json ├── DODONFT.json ├── DODONFT1155.json ├── DODONFTPoolProxy.json ├── DODONFTProxy.json ├── DODONFTRegistry.json ├── DODORouteProxy.json ├── DODOStarterFactory.json ├── DODOStarterFactoryV2.json ├── DODOSwap.json ├── DODOV1Proxy01.json ├── DODOV1Proxy02.json ├── DODOV1Proxy03.json ├── DODOV1Proxy04.json ├── DODOV2Adapter.json ├── DODOV2Proxy01.json ├── DODOV2Proxy02.json ├── DODOV2RouteHelper.json ├── DODOZoo.json ├── DPP.json ├── DPPFactory.json ├── DPPOracleAdmin.json ├── DSP.json ├── DSPFactory.json ├── DVM.json ├── DVMFactory.json ├── ERC20.json ├── ERC20Factory.json ├── ERC20MineV3.json ├── ERC20NameBytes.json ├── ERC20SymbolBytes.json ├── ERC20V2Factory.json ├── ERC20V3Factory.json ├── FairFunding.json ├── FeeDistributor.json ├── FeeRateModel.json ├── FilterAdmin.json ├── FilterERC1155V1.json ├── FilterERC721V1.json ├── Fragment.json ├── GSP.json ├── GSPFactory.json ├── InitializableERC1155.json ├── InitializableERC721.json ├── InstantFunding.json ├── LockedTokenVault.json ├── LockedTokenVaultFactory.json ├── MerkleDistributor.json ├── MintableERC20.json ├── NFTCollateralVault.json ├── NFTTokenFactory.json ├── UpCrowdPoolingFactory.json └── vDODOToken.json ├── bin ├── config.js ├── index-cmd.js ├── index-create.js ├── index-deploy.js └── index.js ├── build ├── DODOMine │ └── DODOMine.wasm ├── DODOZoo │ └── DODOZoo.wasm ├── DVMFactory │ └── DVMFactory.wasm ├── subgraph.yaml └── templates │ ├── CP │ └── CP.wasm │ ├── DODOLpToken │ └── DODOLpToken.wasm │ └── DVM │ └── DVM.wasm ├── package.json ├── src └── mappings │ ├── avatar │ ├── helper.ts │ └── index.ts │ ├── constant-arb-sep.ts │ ├── constant-arbitrum.ts │ ├── constant-aurora.ts │ ├── constant-avax.ts │ ├── constant-base-mainnet.ts │ ├── constant-basegor.ts │ ├── constant-bitlayer.ts │ ├── constant-boba.ts │ ├── constant-bsc.ts │ ├── constant-cfx.ts │ ├── constant-cronos.ts │ ├── constant-dodochain-testnet.ts │ ├── constant-goerli.ts │ ├── constant-heco.ts │ ├── constant-kcc.ts │ ├── constant-kovan.ts │ ├── constant-linea.ts │ ├── constant-mainnet.ts │ ├── constant-manta.ts │ ├── constant-mantle.ts │ ├── constant-moonriver.ts │ ├── constant-okb.ts │ ├── constant-okchain.ts │ ├── constant-optimism.ts │ ├── constant-polygon.ts │ ├── constant-rinkeby.ts │ ├── constant-scroll-alpha.ts │ ├── constant-scroll-sepolia.ts │ ├── constant-scroll.ts │ ├── constant-sepolia.ts │ ├── constant-tokb.ts │ ├── constant-zircuit-testnet.ts │ ├── constant-zircuit.ts │ ├── constant.ts │ ├── dodoex │ ├── classicPoolFromV1.ts │ ├── classicalPoolAurora.ts │ ├── crowdPooling.ts │ ├── dayUpdates.ts │ ├── helpers.ts │ ├── incentive.ts │ ├── lpToken.ts │ ├── mine.ts │ ├── pool.ts │ ├── poolFactory.ts │ ├── pricing.ts │ ├── smartRoute.ts │ └── transaction.ts │ ├── dpoint │ ├── factory.ts │ └── index.ts │ ├── merkle-airdrop │ └── index.ts │ ├── mine │ ├── helper.ts │ ├── mine.ts │ ├── mineProxy.ts │ └── registry.ts │ ├── nft │ ├── buyout │ │ ├── erc1155.ts │ │ ├── erc721.ts │ │ ├── fragment.ts │ │ ├── proxy.ts │ │ └── vault.ts │ ├── helpers.ts │ └── pool │ │ ├── baseFilterV1.ts │ │ ├── filterAdmin.ts │ │ ├── filterERC1155V1.ts │ │ ├── filterERC721V1.ts │ │ ├── helper.ts │ │ └── poolProxy.ts │ ├── starter │ ├── factory.ts │ ├── fair.ts │ ├── helper.ts │ └── instant.ts │ ├── token │ ├── factory.ts │ ├── factoryv2.ts │ ├── helpers.ts │ └── mintableERC20.ts │ ├── tools │ └── dodoNftBalance │ │ ├── erc1155.ts │ │ ├── erc721.ts │ │ └── helpers.ts │ ├── utils │ └── helper.ts │ └── vdodo │ ├── constants.ts │ ├── core.ts │ └── helpers.ts └── subgraphs ├── avatar ├── avatar.graphql ├── avatar_bsc.yaml └── avatar_rinkeby.yaml ├── dodoex ├── abis │ ├── CP.json │ ├── CPV2.json │ ├── Controller.json │ ├── CrowdPoolingFactory.json │ ├── CrowdPoolingFactoryV2.json │ ├── DODO.json │ ├── DODOAvatarERC1155.json │ ├── DODOAvatarERC721.json │ ├── DODOEthProxy.json │ ├── DODOIncentive.json │ ├── DODOLpToken.json │ ├── DODOMine.json │ ├── DODOMineV3Proxy.json │ ├── DODOMineV3ProxyV2.json │ ├── DODOMineV3Registry.json │ ├── DODONFT.json │ ├── DODONFT1155.json │ ├── DODONFTPoolProxy.json │ ├── DODONFTProxy.json │ ├── DODONFTRegistry.json │ ├── DODORouteProxy.json │ ├── DODOStarterFactory.json │ ├── DODOSwap.json │ ├── DODOV1Proxy01.json │ ├── DODOV1Proxy02.json │ ├── DODOV1Proxy03.json │ ├── DODOV1Proxy04.json │ ├── DODOV2Adapter.json │ ├── DODOV2Proxy01.json │ ├── DODOV2Proxy02.json │ ├── DODOV2RouteHelper.json │ ├── DODOZoo.json │ ├── DPP.json │ ├── DPPFactory.json │ ├── DSP.json │ ├── DSPFactory.json │ ├── DVM.json │ ├── DVMFactory.json │ ├── ERC20.json │ ├── ERC20Factory.json │ ├── ERC20MineV3.json │ ├── ERC20NameBytes.json │ ├── ERC20SymbolBytes.json │ ├── ERC20V2Factory.json │ ├── ERC20V3Factory.json │ ├── FairFunding.json │ ├── FeeDistributor.json │ ├── FeeRateModel.json │ ├── FilterAdmin.json │ ├── FilterERC1155V1.json │ ├── FilterERC721V1.json │ ├── Fragment.json │ ├── InitializableERC1155.json │ ├── InitializableERC721.json │ ├── InstantFunding.json │ ├── MintableERC20.json │ ├── NFTCollateralVault.json │ ├── NFTTokenFactory.json │ ├── UpCrowdPoolingFactory.json │ └── vDODOToken.json ├── dodoex.graphql ├── dodoex_arb-sep.yaml ├── dodoex_arbitrum-graft.yaml ├── dodoex_arbitrum.yaml ├── dodoex_arbitrum_rinkeby.yaml ├── dodoex_aurora.yaml ├── dodoex_avax-graft.yaml ├── dodoex_avax.yaml ├── dodoex_base_mainnet.yaml ├── dodoex_basegor.yaml ├── dodoex_bitlayer.yaml ├── dodoex_boba-graft.yaml ├── dodoex_boba.yaml ├── dodoex_bsc-graft.yaml ├── dodoex_bsc.yaml ├── dodoex_cfx.yaml ├── dodoex_cronos.yaml ├── dodoex_dodochain-testnet.yaml ├── dodoex_goerli.yaml ├── dodoex_heco.yaml ├── dodoex_kcc.yaml ├── dodoex_kovan.yaml ├── dodoex_linea.yaml ├── dodoex_mainnet.yaml ├── dodoex_manta.yaml ├── dodoex_mantle.yaml ├── dodoex_moonriver-graft.yaml ├── dodoex_moonriver.yaml ├── dodoex_okb.yaml ├── dodoex_okchain.yaml ├── dodoex_optimism.yaml ├── dodoex_polygon-graft.yaml ├── dodoex_polygon.yaml ├── dodoex_rinkeby.yaml ├── dodoex_scroll-alpha.yaml ├── dodoex_scroll-sepolia.yaml ├── dodoex_scroll.yaml ├── dodoex_sepolia.yaml ├── dodoex_tokb.yaml ├── dodoex_zircuit-testnet.yaml └── dodoex_zircuit.yaml ├── dpoint ├── dpoint.graphql ├── dpoint_goerli.yaml └── dpoint_scroll.yaml ├── merkle-airdrop ├── merkle.graphql ├── merkle_base_mainnet.yaml └── merkle_goerli.yaml ├── mine ├── abis │ ├── DODOMineV3Proxy.json │ ├── DODOMineV3Registry.json │ ├── ERC20.json │ ├── ERC20MineV3.json │ ├── ERC20NameBytes.json │ └── ERC20SymbolBytes.json ├── mine.graphql ├── mine_arb-sep.yaml ├── mine_arbitrum.yaml ├── mine_arbitrum_rinkeby.yaml ├── mine_aurora.yaml ├── mine_avax.yaml ├── mine_base_mainnet.yaml ├── mine_basegor.yaml ├── mine_bitlayer.yaml ├── mine_boba.yaml ├── mine_bsc.yaml ├── mine_cfx.yaml ├── mine_cronos.yaml ├── mine_dodochain-testnet.yaml ├── mine_goerli.yaml ├── mine_heco.yaml ├── mine_kcc.yaml ├── mine_linea.yaml ├── mine_mainnet.yaml ├── mine_manta.yaml ├── mine_mantle.yaml ├── mine_moonriver.yaml ├── mine_okb.yaml ├── mine_okchain.yaml ├── mine_optimism.yaml ├── mine_polygon.yaml ├── mine_rinkeby.yaml ├── mine_scroll-alpha.yaml ├── mine_scroll-sepolia.yaml ├── mine_scroll.yaml ├── mine_sepolia.yaml ├── mine_tokb.yaml ├── mine_zircuit-testnet.yaml └── mine_zircuit.yaml ├── nft ├── abis │ ├── DODONFT.json │ ├── DODONFT1155.json │ ├── DODONFTPoolProxy.json │ ├── DODONFTProxy.json │ ├── ERC20.json │ ├── ERC20NameBytes.json │ ├── ERC20SymbolBytes.json │ ├── FilterAdmin.json │ ├── FilterERC1155V1.json │ ├── FilterERC721V1.json │ ├── Fragment.json │ ├── InitializableERC1155.json │ ├── InitializableERC721.json │ └── NFTCollateralVault.json ├── dodo_topia_goerli.yaml ├── dodo_topia_mainnet.yaml ├── nft.graphql ├── nft_bsc-graft.yaml ├── nft_bsc.yaml ├── nft_kovan.yaml ├── nft_mainnet.yaml └── nft_rinkeby.yaml ├── starter ├── starter.graphql ├── starter_arbitrum.yaml ├── starter_bsc.yaml ├── starter_goerli.yaml ├── starter_polygon.yaml └── starter_rinkeby.yaml ├── token ├── token.graphql ├── token_arb-sep.yaml ├── token_arbitrum.yaml ├── token_arbitrum_rinkeby.yaml ├── token_aurora.yaml ├── token_avax.yaml ├── token_base_mainnet.yaml ├── token_basegor.yaml ├── token_bitlayer.yaml ├── token_boba.yaml ├── token_bsc.yaml ├── token_cfx.yaml ├── token_cronos.yaml ├── token_dodochain-testnet.yaml ├── token_goerli.yaml ├── token_heco.yaml ├── token_kcc.yaml ├── token_kovan.yaml ├── token_linea.yaml ├── token_mainnet.yaml ├── token_manta.yaml ├── token_mantle.yaml ├── token_moonbeam.yaml ├── token_moonriver.yaml ├── token_okb.yaml ├── token_okchain.yaml ├── token_optimism.yaml ├── token_polygon.yaml ├── token_rinkeby.yaml ├── token_scroll-alpha.yaml ├── token_scroll-sepolia.yaml ├── token_scroll.yaml ├── token_sepolia.yaml ├── token_tokb.yaml ├── token_zircuit-testnet.yaml └── token_zircuit.yaml ├── tools └── dodoNftBalance │ ├── nft.graphql │ └── nft_bsc.yaml └── vdodo ├── abis ├── ERC20.json ├── ERC20NameBytes.json ├── ERC20SymbolBytes.json └── vDODOToken.json ├── vdodo.graphql ├── vdodo_kovan.yaml ├── vdodo_mainnet.yaml └── vdodo_rinkeby.yaml /.github/workflows/main.yml: -------------------------------------------------------------------------------- 1 | # This is a basic workflow to help you get started with Actions 2 | 3 | name: CI 4 | 5 | # Controls when the action will run. 6 | on: 7 | # Triggers the workflow on push or pull request events but only for the master branch 8 | push: 9 | branches: [ master ] 10 | pull_request: 11 | branches: [ master ] 12 | 13 | # Allows you to run this workflow manually from the Actions tab 14 | workflow_dispatch: 15 | 16 | # A workflow run is made up of one or more jobs that can run sequentially or in parallel 17 | jobs: 18 | # This workflow contains a single job called "build" 19 | security-scan: 20 | # The type of runner that the job will run on 21 | runs-on: ubuntu-latest 22 | 23 | # Steps represent a sequence of tasks that will be executed as part of the job 24 | steps: 25 | # Checks-out your repository under $GITHUB_WORKSPACE, so your job can access it 26 | - uses: actions/checkout@v2 27 | 28 | - name: Security and Licence Scan 29 | uses: ShiftLeftSecurity/scan-action@v1.3.0 30 | -------------------------------------------------------------------------------- /.gitignore: -------------------------------------------------------------------------------- 1 | logs/ 2 | npm-debug.log 3 | yarn-error.log 4 | node_modules/ 5 | bak.node_modules/ 6 | package-lock.json 7 | yarn.lock 8 | .idea/ 9 | .DS_Store 10 | *.sw* 11 | *.un~ 12 | .tsbuildinfo 13 | .tsbuildinfo.* 14 | .docker 15 | .docker.* 16 | build/ 17 | src/types/ 18 | -------------------------------------------------------------------------------- /LICENSE: -------------------------------------------------------------------------------- 1 | MIT License 2 | 3 | Copyright (c) 2019 The Graph 4 | 5 | Permission is hereby granted, free of charge, to any person obtaining a copy 6 | of this software and associated documentation files (the "Software"), to deal 7 | in the Software without restriction, including without limitation the rights 8 | to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 9 | copies of the Software, and to permit persons to whom the Software is 10 | furnished to do so, subject to the following conditions: 11 | 12 | The above copyright notice and this permission notice shall be included in all 13 | copies or substantial portions of the Software. 14 | 15 | THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 16 | IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 17 | FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 18 | AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 19 | LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 20 | OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE 21 | SOFTWARE. 22 | -------------------------------------------------------------------------------- /abis/ERC20NameBytes.json: -------------------------------------------------------------------------------- 1 | [ 2 | { 3 | "constant": true, 4 | "inputs": [], 5 | "name": "name", 6 | "outputs": [ 7 | { 8 | "internalType": "bytes32", 9 | "name": "", 10 | "type": "bytes32" 11 | } 12 | ], 13 | "payable": false, 14 | "stateMutability": "view", 15 | "type": "function" 16 | } 17 | ] -------------------------------------------------------------------------------- /abis/ERC20SymbolBytes.json: -------------------------------------------------------------------------------- 1 | [ 2 | { 3 | "constant": true, 4 | "inputs": [], 5 | "name": "symbol", 6 | "outputs": [ 7 | { 8 | "internalType": "bytes32", 9 | "name": "", 10 | "type": "bytes32" 11 | } 12 | ], 13 | "payable": false, 14 | "stateMutability": "view", 15 | "type": "function" 16 | } 17 | ] -------------------------------------------------------------------------------- /abis/MerkleDistributor.json: -------------------------------------------------------------------------------- 1 | [ 2 | { 3 | "inputs": [ 4 | { 5 | "internalType": "address", 6 | "name": "token_", 7 | "type": "address" 8 | }, 9 | { 10 | "internalType": "bytes32", 11 | "name": "merkleRoot_", 12 | "type": "bytes32" 13 | } 14 | ], 15 | "stateMutability": "nonpayable", 16 | "type": "constructor" 17 | }, 18 | { 19 | "anonymous": false, 20 | "inputs": [ 21 | { 22 | "indexed": false, 23 | "internalType": "uint256", 24 | "name": "index", 25 | "type": "uint256" 26 | }, 27 | { 28 | "indexed": false, 29 | "internalType": "address", 30 | "name": "account", 31 | "type": "address" 32 | }, 33 | { 34 | "indexed": false, 35 | "internalType": "uint256", 36 | "name": "amount", 37 | "type": "uint256" 38 | } 39 | ], 40 | "name": "Claimed", 41 | "type": "event" 42 | }, 43 | { 44 | "inputs": [ 45 | { 46 | "internalType": "uint256", 47 | "name": "index", 48 | "type": "uint256" 49 | }, 50 | { 51 | "internalType": "address", 52 | "name": "account", 53 | "type": "address" 54 | }, 55 | { 56 | "internalType": "uint256", 57 | "name": "amount", 58 | "type": "uint256" 59 | }, 60 | { 61 | "internalType": "bytes32[]", 62 | "name": "merkleProof", 63 | "type": "bytes32[]" 64 | } 65 | ], 66 | "name": "claim", 67 | "outputs": [], 68 | "stateMutability": "nonpayable", 69 | "type": "function" 70 | }, 71 | { 72 | "inputs": [ 73 | { 74 | "internalType": "uint256", 75 | "name": "index", 76 | "type": "uint256" 77 | } 78 | ], 79 | "name": "isClaimed", 80 | "outputs": [ 81 | { 82 | "internalType": "bool", 83 | "name": "", 84 | "type": "bool" 85 | } 86 | ], 87 | "stateMutability": "view", 88 | "type": "function" 89 | }, 90 | { 91 | "inputs": [], 92 | "name": "merkleRoot", 93 | "outputs": [ 94 | { 95 | "internalType": "bytes32", 96 | "name": "", 97 | "type": "bytes32" 98 | } 99 | ], 100 | "stateMutability": "view", 101 | "type": "function" 102 | }, 103 | { 104 | "inputs": [], 105 | "name": "token", 106 | "outputs": [ 107 | { 108 | "internalType": "address", 109 | "name": "", 110 | "type": "address" 111 | } 112 | ], 113 | "stateMutability": "view", 114 | "type": "function" 115 | } 116 | ] -------------------------------------------------------------------------------- /bin/config.js: -------------------------------------------------------------------------------- 1 | const studioNodeUrl = "https://api.studio.thegraph.com/deploy/"; 2 | const theGraphNodeUrl = "https://api.thegraph.com/deploy/"; 3 | const theGraphIpfsUrl = "https://api.thegraph.com/ipfs/"; 4 | const localNodeUrl = "http://127.0.0.1:8020"; 5 | const localIpfsUrl = "http://127.0.0.1:5001"; 6 | const chains = [ 7 | "mainnet", 8 | "bsc", 9 | "rinkeby", 10 | "kovan", 11 | "okchain", 12 | "arbitrum", 13 | "polygon", 14 | "optimism", 15 | "heco", 16 | "moonriver", 17 | "boba", 18 | "aurora", 19 | "avax", 20 | "cfx", 21 | "base", 22 | "base_mainnet", 23 | "scroll-alpha", 24 | "scroll-sepolia", 25 | "linea", 26 | "scroll", 27 | "manta", 28 | "mantle", 29 | "tokb", 30 | "dodochain-testnet", 31 | "bitlayer", 32 | "zircuit-testnet", 33 | "arb-sep", 34 | "zircuit", 35 | "sepolia", 36 | "okb", 37 | ]; 38 | const supportAlphaChains = ["arbitrum", "polygon", "mainnet"]; 39 | const supportStudioChains = [ 40 | "arbitrum", 41 | "polygon", 42 | "mainnet", 43 | "arb-sep", 44 | "sepolia", 45 | ]; 46 | module.exports = { 47 | studioNodeUrl, 48 | theGraphNodeUrl, 49 | theGraphIpfsUrl, 50 | localNodeUrl, 51 | localIpfsUrl, 52 | chains, 53 | supportAlphaChains, 54 | supportStudioChains, 55 | }; 56 | -------------------------------------------------------------------------------- /bin/index-create.js: -------------------------------------------------------------------------------- 1 | #!/usr/bin/env node 2 | 3 | const program = require("commander"); 4 | const inquirer = require("inquirer"); 5 | const execSh = require("exec-sh"); 6 | 7 | program.option( 8 | "-t, --target ", 9 | "the-graph or studio or dodo-test or dodo" 10 | ); 11 | program.option("-s, --subgraph", "subgraph name"); 12 | program.option("-n, --node", "node server endpoint"); 13 | 14 | program.parse(process.argv); 15 | 16 | const options = program.opts(); 17 | let target = options.target; 18 | let subgraph = options.subgraph; 19 | let node = options.node; 20 | 21 | async function run() { 22 | if (target && subgraph && node) { 23 | console.log( 24 | `target: ${options.target}, subgraph: ${options.subgraph}, node: ${options.node}` 25 | ); 26 | } else { 27 | const promps = []; 28 | if (!target) { 29 | promps.push({ 30 | type: "rawlist", 31 | name: "target", 32 | message: "Please select the target platform", 33 | choices: [ 34 | "the graph", 35 | new inquirer.Separator(), 36 | "studio", 37 | new inquirer.Separator(), 38 | "dodo-test", 39 | new inquirer.Separator(), 40 | "dodo", 41 | ], 42 | }); 43 | } 44 | if (!subgraph) { 45 | promps.push({ 46 | type: "input", 47 | name: "subgraph", 48 | message: "Please input the subgraph name", 49 | }); 50 | } 51 | if (!node) { 52 | promps.push({ 53 | type: "rawlist", 54 | name: "node", 55 | message: "Please select the node server endpoint", 56 | choices: [ 57 | "http://127.0.0.1:7006/jsonrpc", 58 | "https://api.thegraph.com/deploy/", 59 | "https://graph.mainnet.boba.network:8020", 60 | "https://graph.kkt.one/node/", 61 | "https://f.hg.network", 62 | ], 63 | }); 64 | } 65 | const answers = await inquirer.prompt(promps); 66 | target = answers.target; 67 | subgraph = answers.subgraph; 68 | node = answers.node; 69 | } 70 | create(); 71 | } 72 | 73 | run(); 74 | 75 | async function create() { 76 | const cli = 77 | target === "the graph" 78 | ? "./node_modules/.bin/graph" 79 | : "./node_modules/.bin/indexer"; 80 | let commands = `${cli} create --node ${node} ${subgraph}`; 81 | const res = await inquirer.prompt({ 82 | type: "confirm", 83 | name: "confirm", 84 | message: ` 85 | Generated commands: ${commands} 86 | `, 87 | }); 88 | if (res.confirm) { 89 | execSh(commands, {}, (err) => { 90 | if (err) { 91 | console.log("Exit code: ", err.code); 92 | return; 93 | } 94 | }); 95 | } 96 | } 97 | -------------------------------------------------------------------------------- /bin/index.js: -------------------------------------------------------------------------------- 1 | #!/usr/bin/env node 2 | 3 | const program = require("commander"); 4 | const pkg = require("../package.json"); 5 | program 6 | .version(pkg.version, "-v, --version") 7 | .command("create", "Create the subgraph") 8 | .command("deploy", "Deploys the subgraph") 9 | .command("cmd", "run cmd") 10 | .parse(process.argv); 11 | -------------------------------------------------------------------------------- /build/DODOMine/DODOMine.wasm: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/DODOEX/dodoex_v2_subgraph/5f7b51ca6843e5d999e7179c10e3861e63690555/build/DODOMine/DODOMine.wasm -------------------------------------------------------------------------------- /build/DODOZoo/DODOZoo.wasm: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/DODOEX/dodoex_v2_subgraph/5f7b51ca6843e5d999e7179c10e3861e63690555/build/DODOZoo/DODOZoo.wasm -------------------------------------------------------------------------------- /build/DVMFactory/DVMFactory.wasm: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/DODOEX/dodoex_v2_subgraph/5f7b51ca6843e5d999e7179c10e3861e63690555/build/DVMFactory/DVMFactory.wasm -------------------------------------------------------------------------------- /build/templates/CP/CP.wasm: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/DODOEX/dodoex_v2_subgraph/5f7b51ca6843e5d999e7179c10e3861e63690555/build/templates/CP/CP.wasm -------------------------------------------------------------------------------- /build/templates/DODOLpToken/DODOLpToken.wasm: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/DODOEX/dodoex_v2_subgraph/5f7b51ca6843e5d999e7179c10e3861e63690555/build/templates/DODOLpToken/DODOLpToken.wasm -------------------------------------------------------------------------------- /build/templates/DVM/DVM.wasm: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/DODOEX/dodoex_v2_subgraph/5f7b51ca6843e5d999e7179c10e3861e63690555/build/templates/DVM/DVM.wasm -------------------------------------------------------------------------------- /package.json: -------------------------------------------------------------------------------- 1 | { 2 | "name": "dodoex", 3 | "version": "0.1.0", 4 | "scripts": { 5 | "codegen:dodoex_bsc": "graph codegen subgraphs/dodoex/dodoex_bsc.yaml --output-dir ./src/types/dodoex/", 6 | "codegen:dodoex_kovan": "graph codegen subgraphs/dodoex/dodoex_kovan.yaml --output-dir ./src/types/dodoex/", 7 | "codegen:dodoex_mainnet": "graph codegen subgraphs/dodoex/dodoex_mainnet.yaml --output-dir ./src/types/dodoex/", 8 | "build": "graph build", 9 | "build:studio:dodoex_arbitrum": "cp ./src/mappings/constant-arbitrum.ts ./src/mappings/constant.ts &&graph codegen subgraphs/dodoex/dodoex_arbitrum.yaml --output-dir ./src/types/dodoex/ && graph build subgraphs/dodoex/dodoex_arbitrum.yaml", 10 | "create": "node bin/index.js create", 11 | "deploy": "node bin/index.js deploy", 12 | "cmd": "node bin/index.js cmd" 13 | }, 14 | "bin": { 15 | "index": "bin/index.js" 16 | }, 17 | "dependencies": { 18 | "@graphprotocol/graph-cli": "0.78.0", 19 | "@graphprotocol/graph-ts": "0.29.3", 20 | "source-map-support": "^0.5.21" 21 | }, 22 | "devDependencies": { 23 | "commander": "^11.0.0", 24 | "exec-sh": "^0.4.0", 25 | "inquirer": "8.2.0", 26 | "matchstick-as": "0.5.2" 27 | }, 28 | "engines": { 29 | "node": ">= 12.16.0" 30 | } 31 | } 32 | -------------------------------------------------------------------------------- /src/mappings/avatar/helper.ts: -------------------------------------------------------------------------------- 1 | import {Avatar, AvatarBalance, Component, ComponentBalance} from "../../types/avatar/schema" 2 | import {Address, BigInt, BigDecimal} from "@graphprotocol/graph-ts" 3 | import {ZERO_BI} from "../utils/helper"; 4 | 5 | export function getAvatar(tokenID: BigInt): Avatar { 6 | let avatar = Avatar.load(tokenID.toString()); 7 | if (avatar == null) { 8 | avatar = new Avatar(tokenID.toString()); 9 | avatar.balance = ZERO_BI; 10 | avatar.componentsID = ZERO_BI; 11 | avatar.updatedAt = ZERO_BI; 12 | avatar.save(); 13 | } 14 | return avatar as Avatar; 15 | } 16 | 17 | export function getAvatarBalance(user: Address, tokenID: BigInt): AvatarBalance { 18 | let avatarBalance = AvatarBalance.load(user.toHexString().concat("-").concat(tokenID.toString())); 19 | 20 | if (avatarBalance == null) { 21 | avatarBalance = new AvatarBalance(user.toHexString().concat("-").concat(tokenID.toString())); 22 | avatarBalance.amount = ZERO_BI; 23 | avatarBalance.avatar = getAvatar(tokenID).id; 24 | avatarBalance.user = user; 25 | avatarBalance.updatedAt = ZERO_BI; 26 | avatarBalance.save(); 27 | } 28 | 29 | return avatarBalance as AvatarBalance; 30 | 31 | } 32 | 33 | export function getComponent(tokenID: BigInt): Component { 34 | let component = Component.load(tokenID.toString()); 35 | if (component == null) { 36 | component = new Component(tokenID.toString()); 37 | component.balance = ZERO_BI; 38 | component.updatedAt = ZERO_BI; 39 | component.save(); 40 | } 41 | return component as Component; 42 | } 43 | 44 | export function getComponentBalance(user: Address, tokenID: BigInt): ComponentBalance { 45 | let componentBalance = ComponentBalance.load(user.toHexString().concat("-").concat(tokenID.toString())); 46 | 47 | if (componentBalance == null) { 48 | componentBalance = new ComponentBalance(user.toHexString().concat("-").concat(tokenID.toString())); 49 | componentBalance.amount = ZERO_BI; 50 | componentBalance.component = getComponent(tokenID).id; 51 | componentBalance.user = user; 52 | componentBalance.updatedAt = ZERO_BI; 53 | componentBalance.save(); 54 | } 55 | 56 | return componentBalance as ComponentBalance; 57 | } 58 | 59 | -------------------------------------------------------------------------------- /src/mappings/constant-arb-sep.ts: -------------------------------------------------------------------------------- 1 | //kovan 2 | export const TYPE_VIRTUAL_POOL = "VIRTUAL"; 3 | export const TYPE_DVM_POOL = "DVM"; 4 | export const TYPE_DPP_POOL = "DPP"; 5 | export const TYPE_DSP_POOL = "DSP"; 6 | export const TYPE_GSP_POOL = "GSP"; 7 | export const TYPE_CLASSICAL_POOL = "CLASSICAL"; 8 | export const SOURCE_SMART_ROUTE = "SMART_ROUTE"; 9 | export const SOURCE_POOL_SWAP = "DODO_POOL"; 10 | export const DODOZooID = "dodoex-v2-arb-sep"; 11 | export const CHAIN_BASE_COIN_SYMBOL = "ETH"; 12 | export const CHAIN_BASE_COIN_NAME = "ethereum"; 13 | export const DIP3_TIMESTAMP = 1624442400; 14 | 15 | export const SMART_ROUTE_ADDRESSES: string[] = [ 16 | "0x9c2006A5179ee13A90fE4894e75464a3D91Beb70", 17 | ]; 18 | export const DVM_FACTORY_ADDRESS = "0xDF44F395F85D298C7fAD8Bfc71De5dFF9a129d36"; 19 | export const DPP_FACTORY_ADDRESS = "0xed44c4073Dc5e5572670aDAC25EB5B46bAdc178F"; 20 | export const CLASSIC_FACTORY_ADDRESS = 21 | "0x82d5730AB72a5e0ec6E85107418ECe79f4455dBa"; 22 | export const CROWDPOOLING_FACTORY_V2: string[] = [ 23 | "0x82d5730AB72a5e0ec6E85107418ECe79f4455dBa", 24 | ]; 25 | 26 | export const DVM_FACTORY_DEPLOY_BLOCK = 58; 27 | export const DPP_FACTORY_DEPLOY_BLOCK = 58; 28 | 29 | export const ADDRESS_ZERO = "0x0000000000000000000000000000000000000000"; 30 | export const BASE_COIN = "0xeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeee"; 31 | 32 | export const TRANSACTION_TYPE_SWAP = "SWAP"; 33 | export const TRANSACTION_TYPE_LP_ADD = "LP_ADD"; 34 | export const TRANSACTION_TYPE_LP_REMOVE = "LP_REMOVE"; 35 | export const TRANSACTION_TYPE_CP_BID = "CP_BID"; 36 | export const TRANSACTION_TYPE_CP_CANCEL = "CP_CANCEL"; 37 | export const TRANSACTION_TYPE_CP_CLAIM = "CP_CLAIM"; 38 | 39 | /** 40 | * usd pricing 41 | */ 42 | export const WRAPPED_BASE_COIN = "0x3a64Ec3606FF7310E8fAd6FcC008e39705fB496d"; 43 | //pricing supported stable coins 44 | export const STABLE_ONE_ADDRESS = "0xb95ed7e958e196688984951f41ac2888f4b10ab9"; //usdt 45 | export const STABLE_TWO_ADDRESS = "0x46afe01d758a46d64c7d8e0791314d5db3e2e683"; //usdc 46 | //stable coins pairs 47 | export const STABLE_COIN_PAIR_ONE = 48 | "0xe8c1b7e0505c97c59ff2f12ebf91a8eaa59d4c73"; //[USDT_USDC_PAIR] 49 | //base currency pair 50 | export const BASE_COIN_PAIR = "0x75f5d66a7bbb9330a9067c0833ec9b3198b71666"; //[WETH_USDC_PAIR] 51 | -------------------------------------------------------------------------------- /src/mappings/constant-arbitrum.ts: -------------------------------------------------------------------------------- 1 | //mainnet 2 | export const TYPE_VIRTUAL_POOL = "VIRTUAL"; 3 | export const TYPE_DVM_POOL = "DVM"; 4 | export const TYPE_DPP_POOL = "DPP"; 5 | export const TYPE_DSP_POOL = "DSP"; 6 | export const TYPE_GSP_POOL = "GSP"; 7 | export const TYPE_CLASSICAL_POOL = "CLASSICAL"; 8 | export const SOURCE_SMART_ROUTE = "SMART_ROUTE"; 9 | export const SOURCE_POOL_SWAP = "DODO_POOL"; 10 | export const DODOV2Proxy02 = "0x45894c062e6f4e58b257e0826675355305dfef0d"; 11 | export const DIP3_TIMESTAMP = 100; 12 | 13 | export const DODOZooID = "dodoex-v2-arbitrum"; 14 | export const CHAIN_BASE_COIN_SYMBOL = "ETH"; 15 | export const CHAIN_BASE_COIN_NAME = "ether"; 16 | 17 | export const SMART_ROUTE_ADDRESSES: string[] = [ 18 | "0x45894c062e6f4e58b257e0826675355305dfef0d", 19 | ]; 20 | export const DVM_FACTORY_ADDRESS = "0xbab9f4ff4a19a0e8eebc56b06750253228ffac6e"; 21 | export const DPP_FACTORY_ADDRESS = "0xe55154d09265b18ac7cdac6e646672a5460389a1"; 22 | export const CLASSIC_FACTORY_ADDRESS = 23 | "0x357c5e9cfa8b834edcef7c7aabd8f9db09119d11"; //dodo zoo 24 | 25 | export const ADDRESS_ZERO = "0x0000000000000000000000000000000000000000"; 26 | export const BASE_COIN = "0xeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeee"; 27 | 28 | export const TRANSACTION_TYPE_SWAP = "SWAP"; 29 | export const TRANSACTION_TYPE_LP_ADD = "LP_ADD"; 30 | export const TRANSACTION_TYPE_LP_REMOVE = "LP_REMOVE"; 31 | export const TRANSACTION_TYPE_CP_BID = "CP_BID"; 32 | export const TRANSACTION_TYPE_CP_CANCEL = "CP_CANCEL"; 33 | export const TRANSACTION_TYPE_CP_CLAIM = "CP_CLAIM"; 34 | 35 | /** 36 | * usd pricing 37 | */ 38 | export const WRAPPED_BASE_COIN = "0x82af49447d8a07e3bd95bd0d56f35241523fbab1"; 39 | //pricing supported stable coins 40 | export const STABLE_ONE_ADDRESS = "0xfd086bc7cd5c481dcc9c85ebe478a1c0b69fcbb9"; //usdt 41 | export const STABLE_TWO_ADDRESS = "0xff970a61a04b1ca14834a43f5de4533ebddb5cc8"; //usdc 42 | //stable coins pairs 43 | export const STABLE_COIN_PAIR_ONE = 44 | "0xe4b2dfc82977dd2dce7e8d37895a6a8f50cbb4fb"; //[USDT_USDC_PAIR] 45 | //base currency pair 46 | export const BASE_COIN_PAIR = "0xfe176a2b1e1f67250d2903b8d25f56c0dabcd6b2"; //[WETH_USDC_PAIR] 47 | export const CROWDPOOLING_FACTORY_V2: string[] = [ 48 | "0x9a8c0e8b27fff5d00402733ca67432b6d64faff4", 49 | ]; 50 | -------------------------------------------------------------------------------- /src/mappings/constant-aurora.ts: -------------------------------------------------------------------------------- 1 | //mainnet 2 | export const TYPE_VIRTUAL_POOL = "VIRTUAL"; 3 | export const TYPE_DVM_POOL = "DVM"; 4 | export const TYPE_DPP_POOL = "DPP"; 5 | export const TYPE_DSP_POOL = "DSP"; 6 | export const TYPE_GSP_POOL = "GSP"; 7 | export const TYPE_CLASSICAL_POOL = "CLASSICAL"; 8 | export const SOURCE_SMART_ROUTE = "SMART_ROUTE"; 9 | export const SOURCE_POOL_SWAP = "DODO_POOL"; 10 | export const DODOV2Proxy02 = "0x45894c062e6f4e58b257e0826675355305dfef0d"; 11 | export const DIP3_TIMESTAMP = 100; 12 | 13 | export const DODOZooID = "dodoex-v2-aurora"; 14 | export const CHAIN_BASE_COIN_SYMBOL = "ETH"; 15 | export const CHAIN_BASE_COIN_NAME = "ether"; 16 | 17 | export const SMART_ROUTE_ADDRESSES: string[] = [ 18 | "0xd9dec7c3c06e62a4c1beeb07cadf568f496b14c2", 19 | ]; 20 | export const DVM_FACTORY_ADDRESS = "0x5515363c0412add5c72d3e302fe1bd7dcbcf93fe"; 21 | export const DPP_FACTORY_ADDRESS = "0x40672211d4310ad71dadc8cde7aa3fb90d420855"; 22 | export const CLASSIC_FACTORY_ADDRESS = 23 | "0x357c5e9cfa8b834edcef7c7aabd8f9db09119d11"; //dodo zoo 24 | export const CROWDPOOLING_FACTORY_V2: string[] = [ 25 | "0xaf49dbaaf177bee57f84731260a9eb8819d25eff", 26 | ]; 27 | 28 | export const ADDRESS_ZERO = "0x0000000000000000000000000000000000000000"; 29 | export const BASE_COIN = "0xeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeee"; 30 | 31 | export const TRANSACTION_TYPE_SWAP = "SWAP"; 32 | export const TRANSACTION_TYPE_LP_ADD = "LP_ADD"; 33 | export const TRANSACTION_TYPE_LP_REMOVE = "LP_REMOVE"; 34 | export const TRANSACTION_TYPE_CP_BID = "CP_BID"; 35 | export const TRANSACTION_TYPE_CP_CANCEL = "CP_CANCEL"; 36 | export const TRANSACTION_TYPE_CP_CLAIM = "CP_CLAIM"; 37 | 38 | /** 39 | * usd pricing 40 | */ 41 | export const WRAPPED_BASE_COIN = "0xc9bdeed33cd01541e1eed10f90519d2c06fe3feb"; 42 | //pricing supported stable coins 43 | export const STABLE_ONE_ADDRESS = "0x4988a896b1227218e4a686fde5eabdcabd91571f"; //usdt 44 | export const STABLE_TWO_ADDRESS = "0xb12bfca5a55806aaf64e99521918a4bf0fc40802"; //usdc 45 | //stable coins pairs 46 | export const STABLE_COIN_PAIR_ONE = 47 | "0xe4b2dfc82977dd2dce7e8d37895a6a8f50cbb4fb"; //[USDT_USDC_PAIR] todo 48 | //base currency pair 49 | export const BASE_COIN_PAIR = "0xfe176a2b1e1f67250d2903b8d25f56c0dabcd6b2"; //[WETH_USDC_PAIR] todo 50 | -------------------------------------------------------------------------------- /src/mappings/constant-avax.ts: -------------------------------------------------------------------------------- 1 | //mainnet 2 | export const TYPE_VIRTUAL_POOL = "VIRTUAL"; 3 | export const TYPE_DVM_POOL = "DVM"; 4 | export const TYPE_DPP_POOL = "DPP"; 5 | export const TYPE_DSP_POOL = "DSP"; 6 | export const TYPE_GSP_POOL = "GSP"; 7 | export const TYPE_CLASSICAL_POOL = "CLASSICAL"; 8 | export const SOURCE_SMART_ROUTE = "SMART_ROUTE"; 9 | export const SOURCE_POOL_SWAP = "DODO_POOL"; 10 | export const DODOV2Proxy02 = "0x2cd18557e14af72daa8090bcaa95b231ffc9ea26"; 11 | export const DIP3_TIMESTAMP = 100; 12 | 13 | export const DODOZooID = "dodoex-v2-avax"; 14 | export const CHAIN_BASE_COIN_SYMBOL = "AVAX"; 15 | export const CHAIN_BASE_COIN_NAME = "avax"; 16 | 17 | export const SMART_ROUTE_ADDRESSES: string[] = [ 18 | "0x2cd18557e14af72daa8090bcaa95b231ffc9ea26", 19 | ]; 20 | export const DVM_FACTORY_ADDRESS = "0xff133a6d335b50bdaa6612d19e1352b049a8ae6a"; 21 | export const DPP_FACTORY_ADDRESS = "0xb7865a5cee051d35b09a48b624d7057d3362655a"; 22 | export const CLASSIC_FACTORY_ADDRESS = 23 | "0x8ab2d334ce64b50be9ab04184f7ccba2a6bb6391"; //dodo zoo 24 | export const CROWDPOOLING_FACTORY_V2: string[] = [ 25 | "0xc1ba6bd60c6790b751ec2d90288b6cbf87d4f032", 26 | ]; 27 | 28 | export const ADDRESS_ZERO = "0x0000000000000000000000000000000000000000"; 29 | export const BASE_COIN = "0xeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeee"; 30 | 31 | export const TRANSACTION_TYPE_SWAP = "SWAP"; 32 | export const TRANSACTION_TYPE_LP_ADD = "LP_ADD"; 33 | export const TRANSACTION_TYPE_LP_REMOVE = "LP_REMOVE"; 34 | export const TRANSACTION_TYPE_CP_BID = "CP_BID"; 35 | export const TRANSACTION_TYPE_CP_CANCEL = "CP_CANCEL"; 36 | export const TRANSACTION_TYPE_CP_CLAIM = "CP_CLAIM"; 37 | 38 | /** 39 | * usd pricing 40 | */ 41 | export const WRAPPED_BASE_COIN = "0xb31f66aa3c1e785363f0875a1b74e27b85fd66c7"; 42 | //pricing supported stable coins 43 | export const STABLE_ONE_ADDRESS = "0xc7198437980c041c805a1edcba50c1ce5db95118"; //usdt 44 | export const STABLE_TWO_ADDRESS = "0xa7d7079b0fead91f3e65f86e8915cb59c1a4c664"; //usdc 45 | //stable coins pairs 46 | export const STABLE_COIN_PAIR_ONE = 47 | "0xe4b2dfc82977dd2dce7e8d37895a6a8f50cbb4fb"; //[USDT_USDC_PAIR] todo 48 | //base currency pair 49 | export const BASE_COIN_PAIR = "0xfe176a2b1e1f67250d2903b8d25f56c0dabcd6b2"; //[WETH_USDC_PAIR] todo 50 | -------------------------------------------------------------------------------- /src/mappings/constant-base-mainnet.ts: -------------------------------------------------------------------------------- 1 | //kovan 2 | export const TYPE_VIRTUAL_POOL = "VIRTUAL"; 3 | export const TYPE_DVM_POOL = "DVM"; 4 | export const TYPE_DPP_POOL = "DPP"; 5 | export const TYPE_DSP_POOL = "DSP"; 6 | export const TYPE_GSP_POOL = "GSP"; 7 | export const TYPE_CLASSICAL_POOL = "CLASSICAL"; 8 | export const SOURCE_SMART_ROUTE = "SMART_ROUTE"; 9 | export const SOURCE_POOL_SWAP = "DODO_POOL"; 10 | export const DODOZooID = "dodoex-v2-base-mainnet"; 11 | export const CHAIN_BASE_COIN_SYMBOL = "ETH"; 12 | export const CHAIN_BASE_COIN_NAME = "ethereum"; 13 | export const DIP3_TIMESTAMP = 1624442400; 14 | 15 | export const SMART_ROUTE_ADDRESSES: string[] = [ 16 | "0x4CAD0052524648A7Fa2cfE279997b00239295F33", 17 | ]; 18 | export const DVM_FACTORY_ADDRESS = "0x4CAD0052524648A7Fa2cfE279997b00239295F33"; 19 | export const DPP_FACTORY_ADDRESS = "0xc0F9553Df63De5a97Fe64422c8578D0657C360f7"; 20 | export const CLASSIC_FACTORY_ADDRESS = 21 | "0x97bBF5BB1dcfC93A8c67e97E50Bea19DB3416A83"; 22 | export const CROWDPOOLING_FACTORY_V2: string[] = [ 23 | "0x97bBF5BB1dcfC93A8c67e97E50Bea19DB3416A83", 24 | ]; 25 | 26 | export const DVM_FACTORY_DEPLOY_BLOCK = 1996181; 27 | export const DPP_FACTORY_DEPLOY_BLOCK = 1996199; 28 | 29 | export const ADDRESS_ZERO = "0x0000000000000000000000000000000000000000"; 30 | export const BASE_COIN = "0xeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeee"; 31 | 32 | export const TRANSACTION_TYPE_SWAP = "SWAP"; 33 | export const TRANSACTION_TYPE_LP_ADD = "LP_ADD"; 34 | export const TRANSACTION_TYPE_LP_REMOVE = "LP_REMOVE"; 35 | export const TRANSACTION_TYPE_CP_BID = "CP_BID"; 36 | export const TRANSACTION_TYPE_CP_CANCEL = "CP_CANCEL"; 37 | export const TRANSACTION_TYPE_CP_CLAIM = "CP_CLAIM"; 38 | 39 | /** 40 | * usd pricing 41 | */ 42 | export const WRAPPED_BASE_COIN = "0xb26c0d8be2960c70641a95a9195be1f59ac83ac0"; 43 | //pricing supported stable coins 44 | export const STABLE_ONE_ADDRESS = "0x0adcbae18580120667f7ff6c6451a426b13c67b7"; //usdt 45 | export const STABLE_TWO_ADDRESS = "0xab0733588776b8881f7712f6abca98f510e6b63d"; //usdc 46 | //stable coins pairs 47 | export const STABLE_COIN_PAIR_ONE = 48 | "0xe8c1b7e0505c97c59ff2f12ebf91a8eaa59d4c73"; //[USDT_USDC_PAIR] 49 | //base currency pair 50 | export const BASE_COIN_PAIR = "0x75f5d66a7bbb9330a9067c0833ec9b3198b71666"; //[WETH_USDC_PAIR] 51 | -------------------------------------------------------------------------------- /src/mappings/constant-basegor.ts: -------------------------------------------------------------------------------- 1 | //kovan 2 | export const TYPE_VIRTUAL_POOL = "VIRTUAL"; 3 | export const TYPE_DVM_POOL = "DVM"; 4 | export const TYPE_DPP_POOL = "DPP"; 5 | export const TYPE_DSP_POOL = "DSP"; 6 | export const TYPE_GSP_POOL = "GSP"; 7 | export const TYPE_CLASSICAL_POOL = "CLASSICAL"; 8 | export const SOURCE_SMART_ROUTE = "SMART_ROUTE"; 9 | export const SOURCE_POOL_SWAP = "DODO_POOL"; 10 | export const DODOZooID = "dodoex-v2-basegor"; 11 | export const CHAIN_BASE_COIN_SYMBOL = "ETH"; 12 | export const CHAIN_BASE_COIN_NAME = "ethereum"; 13 | export const DIP3_TIMESTAMP = 1624442400; 14 | 15 | export const SMART_ROUTE_ADDRESSES: string[] = [ 16 | "0x0EDf30fffa1D584F1077CFdaE9c499c3E45501c1", 17 | ]; 18 | export const DVM_FACTORY_ADDRESS = "0x888C189EC28dce10c60A404A21f22662Ba8134dd"; 19 | export const DPP_FACTORY_ADDRESS = "0x2851406143e4158Dabc82Bda6498E12C81B93525"; 20 | export const CLASSIC_FACTORY_ADDRESS = 21 | "0x168442fec1e1e782c8770185dbb8328b91dc45c0"; 22 | export const CROWDPOOLING_FACTORY_V2: string[] = [ 23 | "0x79e15fc9b4154d90424b588533ab277d30d573f4", 24 | ]; 25 | 26 | export const DVM_FACTORY_DEPLOY_BLOCK = 8732843; 27 | export const DPP_FACTORY_DEPLOY_BLOCK = 8732843; 28 | 29 | export const ADDRESS_ZERO = "0x0000000000000000000000000000000000000000"; 30 | export const BASE_COIN = "0xeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeee"; 31 | 32 | export const TRANSACTION_TYPE_SWAP = "SWAP"; 33 | export const TRANSACTION_TYPE_LP_ADD = "LP_ADD"; 34 | export const TRANSACTION_TYPE_LP_REMOVE = "LP_REMOVE"; 35 | export const TRANSACTION_TYPE_CP_BID = "CP_BID"; 36 | export const TRANSACTION_TYPE_CP_CANCEL = "CP_CANCEL"; 37 | export const TRANSACTION_TYPE_CP_CLAIM = "CP_CLAIM"; 38 | 39 | /** 40 | * usd pricing 41 | */ 42 | export const WRAPPED_BASE_COIN = "0xb26c0d8be2960c70641a95a9195be1f59ac83ac0"; 43 | //pricing supported stable coins 44 | export const STABLE_ONE_ADDRESS = "0x0adcbae18580120667f7ff6c6451a426b13c67b7"; //usdt 45 | export const STABLE_TWO_ADDRESS = "0xab0733588776b8881f7712f6abca98f510e6b63d"; //usdc 46 | //stable coins pairs 47 | export const STABLE_COIN_PAIR_ONE = 48 | "0xe8c1b7e0505c97c59ff2f12ebf91a8eaa59d4c73"; //[USDT_USDC_PAIR] 49 | //base currency pair 50 | export const BASE_COIN_PAIR = "0x75f5d66a7bbb9330a9067c0833ec9b3198b71666"; //[WETH_USDC_PAIR] 51 | -------------------------------------------------------------------------------- /src/mappings/constant-bitlayer.ts: -------------------------------------------------------------------------------- 1 | //kovan 2 | export const TYPE_VIRTUAL_POOL = "VIRTUAL"; 3 | export const TYPE_DVM_POOL = "DVM"; 4 | export const TYPE_DPP_POOL = "DPP"; 5 | export const TYPE_DSP_POOL = "DSP"; 6 | export const TYPE_GSP_POOL = "GSP"; 7 | export const TYPE_CLASSICAL_POOL = "CLASSICAL"; 8 | export const SOURCE_SMART_ROUTE = "SMART_ROUTE"; 9 | export const SOURCE_POOL_SWAP = "DODO_POOL"; 10 | export const DODOZooID = "dodoex-v2-bitlayer"; 11 | export const CHAIN_BASE_COIN_SYMBOL = "ETH"; 12 | export const CHAIN_BASE_COIN_NAME = "ethereum"; 13 | export const DIP3_TIMESTAMP = 1624442400; 14 | 15 | export const SMART_ROUTE_ADDRESSES: string[] = [ 16 | "0x3b0c6c0CE667844e742Ce0Ca533EaA2b6f422AA8", 17 | ]; 18 | export const DVM_FACTORY_ADDRESS = "0x7Ad992fcebd899ddbEF7f031dCF96f382b81ECea"; 19 | export const DPP_FACTORY_ADDRESS = "0x4c3c61cba411C9B60DC371b031262c730D3Da6a3"; 20 | export const CLASSIC_FACTORY_ADDRESS = 21 | "0xB3d4823e02A9AB9A9A0Cc1636E776c360B67bED1"; 22 | export const CROWDPOOLING_FACTORY_V2: string[] = [ 23 | "0xB3d4823e02A9AB9A9A0Cc1636E776c360B67bED1", 24 | ]; 25 | 26 | export const DVM_FACTORY_DEPLOY_BLOCK = 58; 27 | export const DPP_FACTORY_DEPLOY_BLOCK = 58; 28 | 29 | export const ADDRESS_ZERO = "0x0000000000000000000000000000000000000000"; 30 | export const BASE_COIN = "0xeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeee"; 31 | 32 | export const TRANSACTION_TYPE_SWAP = "SWAP"; 33 | export const TRANSACTION_TYPE_LP_ADD = "LP_ADD"; 34 | export const TRANSACTION_TYPE_LP_REMOVE = "LP_REMOVE"; 35 | export const TRANSACTION_TYPE_CP_BID = "CP_BID"; 36 | export const TRANSACTION_TYPE_CP_CANCEL = "CP_CANCEL"; 37 | export const TRANSACTION_TYPE_CP_CLAIM = "CP_CLAIM"; 38 | 39 | /** 40 | * usd pricing 41 | */ 42 | export const WRAPPED_BASE_COIN = "0x3a64Ec3606FF7310E8fAd6FcC008e39705fB496d"; 43 | //pricing supported stable coins 44 | export const STABLE_ONE_ADDRESS = "0xb95ed7e958e196688984951f41ac2888f4b10ab9"; //usdt 45 | export const STABLE_TWO_ADDRESS = "0x46afe01d758a46d64c7d8e0791314d5db3e2e683"; //usdc 46 | //stable coins pairs 47 | export const STABLE_COIN_PAIR_ONE = 48 | "0xe8c1b7e0505c97c59ff2f12ebf91a8eaa59d4c73"; //[USDT_USDC_PAIR] 49 | //base currency pair 50 | export const BASE_COIN_PAIR = "0x75f5d66a7bbb9330a9067c0833ec9b3198b71666"; //[WETH_USDC_PAIR] 51 | -------------------------------------------------------------------------------- /src/mappings/constant-boba.ts: -------------------------------------------------------------------------------- 1 | //mainnet 2 | export const TYPE_VIRTUAL_POOL = "VIRTUAL"; 3 | export const TYPE_DVM_POOL = "DVM"; 4 | export const TYPE_DPP_POOL = "DPP"; 5 | export const TYPE_DSP_POOL = "DSP"; 6 | export const TYPE_GSP_POOL = "GSP"; 7 | export const TYPE_CLASSICAL_POOL = "CLASSICAL"; 8 | export const SOURCE_SMART_ROUTE = "SMART_ROUTE"; 9 | export const SOURCE_POOL_SWAP = "DODO_POOL"; 10 | export const DODOV2Proxy02 = "0x45894c062e6f4e58b257e0826675355305dfef0d"; 11 | export const DIP3_TIMESTAMP = 100; 12 | 13 | export const DODOZooID = "dodoex-v2-boba"; 14 | export const CHAIN_BASE_COIN_SYMBOL = "ETH"; 15 | export const CHAIN_BASE_COIN_NAME = "ether"; 16 | 17 | export const SMART_ROUTE_ADDRESSES: string[] = [ 18 | "0x55793c2c8a796cce00ef2d1a86cca2e0399bf285", 19 | ]; 20 | export const DVM_FACTORY_ADDRESS = "0x2f2f9460500f27db68aafbfa0472ceddb168a5a6"; 21 | export const DPP_FACTORY_ADDRESS = "0x3a60a76acae8feec74d6b5b665d4dbaab2abc406"; 22 | export const CLASSIC_FACTORY_ADDRESS = 23 | "0x357c5e9cfa8b834edcef7c7aabd8f9db09119d11"; //dodo zoo 24 | export const CROWDPOOLING_FACTORY_V2: string[] = [ 25 | "0x392b2ae9ab6161591582c4724ca9a89c0cc1cab6", 26 | ]; 27 | 28 | export const ADDRESS_ZERO = "0x0000000000000000000000000000000000000000"; 29 | export const BASE_COIN = "0x4200000000000000000000000000000000000006"; 30 | 31 | export const TRANSACTION_TYPE_SWAP = "SWAP"; 32 | export const TRANSACTION_TYPE_LP_ADD = "LP_ADD"; 33 | export const TRANSACTION_TYPE_LP_REMOVE = "LP_REMOVE"; 34 | export const TRANSACTION_TYPE_CP_BID = "CP_BID"; 35 | export const TRANSACTION_TYPE_CP_CANCEL = "CP_CANCEL"; 36 | export const TRANSACTION_TYPE_CP_CLAIM = "CP_CLAIM"; 37 | 38 | /** 39 | * usd pricing 40 | */ 41 | export const WRAPPED_BASE_COIN = "0xdeaddeaddeaddeaddeaddeaddeaddeaddead0000"; 42 | //pricing supported stable coins 43 | export const STABLE_ONE_ADDRESS = "0x5de1677344d3cb0d7d465c10b72a8f60699c062d"; //usdt 44 | export const STABLE_TWO_ADDRESS = "0x66a2a913e447d6b4bf33efbec43aaef87890fbbc"; //usdc 45 | //stable coins pairs 46 | export const STABLE_COIN_PAIR_ONE = 47 | "0xe4b2dfc82977dd2dce7e8d37895a6a8f50cbb4fb"; //[USDT_USDC_PAIR] todo 48 | //base currency pair 49 | export const BASE_COIN_PAIR = "0xfe176a2b1e1f67250d2903b8d25f56c0dabcd6b2"; //[WETH_USDC_PAIR] todo 50 | -------------------------------------------------------------------------------- /src/mappings/constant-bsc.ts: -------------------------------------------------------------------------------- 1 | //bsc 2 | export const TYPE_VIRTUAL_POOL = "VIRTUAL"; 3 | export const TYPE_DVM_POOL = "DVM"; 4 | export const TYPE_DPP_POOL = "DPP"; 5 | export const TYPE_DSP_POOL = "DSP"; 6 | export const TYPE_GSP_POOL = "GSP"; 7 | export const TYPE_CLASSICAL_POOL = "CLASSICAL"; 8 | export const SOURCE_SMART_ROUTE = "SMART_ROUTE"; 9 | export const SOURCE_POOL_SWAP = "DODO_POOL"; 10 | export const DODOV2Proxy01 = "0xb57dd5c265dbb13ca014f2332069e90cd0e22e65"; 11 | export const DODOV2Proxy02_2021_02_17 = 12 | "0xd56281ef996b6b29874c77d2e1464216e8043127"; 13 | export const DODOV2Proxy02 = "0xd56281ef996b6b29874c77d2e1464216e8043127"; 14 | export const DIP3_TIMESTAMP = 1624442400; 15 | 16 | export const DODOZooID = "dodoex-v2-bsc"; 17 | export const CHAIN_BASE_COIN_SYMBOL = "BNB"; 18 | export const CHAIN_BASE_COIN_NAME = "Bnb"; 19 | 20 | export const SMART_ROUTE_ADDRESSES: string[] = [ 21 | "0xb57dd5c265dbb13ca014f2332069e90cd0e22e65", 22 | "0xd56281ef996b6b29874c77d2e1464216e8043127", 23 | "0x8f8dd7db1bda5ed3da8c9daf3bfa471c12d58486", 24 | "0xbe9a66e49503e84ae59a4d0545365AABedf33b40", 25 | ]; 26 | export const DVM_FACTORY_ADDRESS = "0xf50bdc9e90b7a1c138cb7935071b85c417c4cb8e"; 27 | export const DPP_FACTORY_ADDRESS = "0x7737fd30535c69545deeea54ab8dd590ccaebd3c"; 28 | export const CLASSIC_FACTORY_ADDRESS = 29 | "0xca459456a45e300aa7ef447dbb60f87cccb42828"; //dodo zoo 30 | export const CROWDPOOLING_FACTORY_V2: string[] = [ 31 | "0x9c9ef6820a1aa0e25770ccde4e974f81cb28debc", 32 | ]; 33 | 34 | export const ADDRESS_ZERO = "0x0000000000000000000000000000000000000000"; 35 | export const BASE_COIN = "0xeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeee"; 36 | 37 | export const TRANSACTION_TYPE_SWAP = "SWAP"; 38 | export const TRANSACTION_TYPE_LP_ADD = "LP_ADD"; 39 | export const TRANSACTION_TYPE_LP_REMOVE = "LP_REMOVE"; 40 | export const TRANSACTION_TYPE_CP_BID = "CP_BID"; 41 | export const TRANSACTION_TYPE_CP_CANCEL = "CP_CANCEL"; 42 | export const TRANSACTION_TYPE_CP_CLAIM = "CP_CLAIM"; 43 | 44 | /** 45 | * usd pricing 46 | */ 47 | export const WRAPPED_BASE_COIN = "0xbb4cdb9cbd36b01bd1cbaebf2de08d9173bc095c"; 48 | //pricing supported stable coins 49 | export const STABLE_ONE_ADDRESS = "0x55d398326f99059ff775485246999027b3197955"; //usdt 50 | export const STABLE_TWO_ADDRESS = "0xe9e7cea3dedca5984780bafc599bd69add087d56"; //busd 51 | //stable coins pairs 52 | export const STABLE_COIN_PAIR_ONE = 53 | "0xbe60d4c4250438344bec816ec2dec99925deb4c7"; //[USDT_BUSD_PAIR] 54 | //base currency pair 55 | export const BASE_COIN_PAIR = "0x327134de48fcdd75320f4c32498d1980470249ae"; //[WBNB_BUSD_PAIR] 56 | -------------------------------------------------------------------------------- /src/mappings/constant-cfx.ts: -------------------------------------------------------------------------------- 1 | //kovan 2 | export const TYPE_VIRTUAL_POOL = "VIRTUAL"; 3 | export const TYPE_DVM_POOL = "DVM"; 4 | export const TYPE_DPP_POOL = "DPP"; 5 | export const TYPE_DSP_POOL = "DSP"; 6 | export const TYPE_GSP_POOL = "GSP"; 7 | export const TYPE_CLASSICAL_POOL = "CLASSICAL"; 8 | export const SOURCE_SMART_ROUTE = "SMART_ROUTE"; 9 | export const SOURCE_POOL_SWAP = "DODO_POOL"; 10 | export const DODOZooID = "dodoex-v2-cfx"; 11 | export const CHAIN_BASE_COIN_SYMBOL = "CFX"; 12 | export const CHAIN_BASE_COIN_NAME = "conflux"; 13 | export const DIP3_TIMESTAMP = 1624442400; 14 | 15 | export const SMART_ROUTE_ADDRESSES: string[] = [ 16 | "0xbce44767af0a53A108b3B7ba4F740E03D228Ec0A", 17 | ]; 18 | export const DVM_FACTORY_ADDRESS = "0xc77392396be1fb5143f1f66a3ae67dd03fbaba27"; 19 | export const DPP_FACTORY_ADDRESS = "0xaC9a7053bC23D22ecC50F82cc9143d16bbC0E621"; 20 | export const CLASSIC_FACTORY_ADDRESS = 21 | "0x168442fec1e1e782c8770185dbb8328b91dc45c0"; 22 | export const CROWDPOOLING_FACTORY_V2: string[] = [ 23 | "0x79e15fc9b4154d90424b588533ab277d30d573f4", 24 | ]; 25 | 26 | export const DVM_FACTORY_DEPLOY_BLOCK = 70692327; 27 | export const DPP_FACTORY_DEPLOY_BLOCK = 70692370; 28 | 29 | export const ADDRESS_ZERO = "0x0000000000000000000000000000000000000000"; 30 | export const BASE_COIN = "0xeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeee"; 31 | 32 | export const TRANSACTION_TYPE_SWAP = "SWAP"; 33 | export const TRANSACTION_TYPE_LP_ADD = "LP_ADD"; 34 | export const TRANSACTION_TYPE_LP_REMOVE = "LP_REMOVE"; 35 | export const TRANSACTION_TYPE_CP_BID = "CP_BID"; 36 | export const TRANSACTION_TYPE_CP_CANCEL = "CP_CANCEL"; 37 | export const TRANSACTION_TYPE_CP_CLAIM = "CP_CLAIM"; 38 | 39 | /** 40 | * usd pricing 41 | */ 42 | export const WRAPPED_BASE_COIN = "0xb26c0d8be2960c70641a95a9195be1f59ac83ac0"; 43 | //pricing supported stable coins 44 | export const STABLE_ONE_ADDRESS = "0xfe97e85d13abd9c1c33384e796f10b73905637ce"; //usdt 45 | export const STABLE_TWO_ADDRESS = "0x6963efed0ab40f6c3d7bda44a05dcf1437c44372"; //usdc 46 | //stable coins pairs 47 | export const STABLE_COIN_PAIR_ONE = 48 | "0xa5dcd75c853dad730bef4ece3d20f0be7e297a6a"; //[USDT_USDC_PAIR] 49 | //base currency pair 50 | export const BASE_COIN_PAIR = "0x0736b3384531cda2f545f5449e84c6c6bcd6f01b"; //[WETH_USDC_PAIR] 51 | -------------------------------------------------------------------------------- /src/mappings/constant-cronos.ts: -------------------------------------------------------------------------------- 1 | //mainnet 2 | export const TYPE_VIRTUAL_POOL = "VIRTUAL"; 3 | export const TYPE_DVM_POOL = "DVM"; 4 | export const TYPE_DPP_POOL = "DPP"; 5 | export const TYPE_DSP_POOL = "DSP"; 6 | export const TYPE_GSP_POOL = "GSP"; 7 | export const TYPE_CLASSICAL_POOL = "CLASSICAL"; 8 | export const SOURCE_SMART_ROUTE = "SMART_ROUTE"; 9 | export const SOURCE_POOL_SWAP = "DODO_POOL"; 10 | export const DODOV2Proxy02 = "0xddb86ff3984b213bfc951e16b829abb64a3c20c0"; 11 | export const DIP3_TIMESTAMP = 100; 12 | 13 | export const DODOZooID = "dodoex-v2-cronos"; 14 | export const CHAIN_BASE_COIN_SYMBOL = "CRO"; 15 | export const CHAIN_BASE_COIN_NAME = "cro"; 16 | 17 | export const SMART_ROUTE_ADDRESSES: string[] = [ 18 | "0xddb86ff3984b213bfc951e16b829abb64a3c20c0", 19 | ]; 20 | export const DVM_FACTORY_ADDRESS = "0x3d5acf003dc729f0cdf8263733c1329a59967458"; 21 | export const DPP_FACTORY_ADDRESS = "0x41cc4b7f7c915183149834e7d56fdb57dc096980"; 22 | export const CLASSIC_FACTORY_ADDRESS = 23 | "0xe78ec2626f59686254852c135d9428157fb2fb39"; //dodo zoo 24 | 25 | export const ADDRESS_ZERO = "0x0000000000000000000000000000000000000000"; 26 | export const BASE_COIN = "0xeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeee"; 27 | 28 | export const TRANSACTION_TYPE_SWAP = "SWAP"; 29 | export const TRANSACTION_TYPE_LP_ADD = "LP_ADD"; 30 | export const TRANSACTION_TYPE_LP_REMOVE = "LP_REMOVE"; 31 | export const TRANSACTION_TYPE_CP_BID = "CP_BID"; 32 | export const TRANSACTION_TYPE_CP_CANCEL = "CP_CANCEL"; 33 | export const TRANSACTION_TYPE_CP_CLAIM = "CP_CLAIM"; 34 | 35 | /** 36 | * usd pricing 37 | */ 38 | export const WRAPPED_BASE_COIN = "0x5c7f8a570d578ed84e63fdfa7b1ee72deae1ae23"; 39 | //pricing supported stable coins 40 | export const STABLE_ONE_ADDRESS = "0x66e428c3f67a68878562e79a0234c1f83c208770"; //usdt 41 | export const STABLE_TWO_ADDRESS = "0xc21223249ca28397b4b6541dffaecc539bff0c59"; //usdc 42 | //stable coins pairs 43 | export const STABLE_COIN_PAIR_ONE = 44 | "0xe4b2dfc82977dd2dce7e8d37895a6a8f50cbb4fb"; //[USDT_USDC_PAIR] 45 | //base currency pair 46 | export const BASE_COIN_PAIR = "0xfe176a2b1e1f67250d2903b8d25f56c0dabcd6b2"; //[WETH_USDC_PAIR] 47 | export const CROWDPOOLING_FACTORY_V2: string[] = [ 48 | "0x9a8c0e8b27fff5d00402733ca67432b6d64faff4", 49 | ]; 50 | -------------------------------------------------------------------------------- /src/mappings/constant-dodochain-testnet.ts: -------------------------------------------------------------------------------- 1 | //kovan 2 | export const TYPE_VIRTUAL_POOL = "VIRTUAL"; 3 | export const TYPE_DVM_POOL = "DVM"; 4 | export const TYPE_DPP_POOL = "DPP"; 5 | export const TYPE_DSP_POOL = "DSP"; 6 | export const TYPE_GSP_POOL = "GSP"; 7 | export const TYPE_CLASSICAL_POOL = "CLASSICAL"; 8 | export const SOURCE_SMART_ROUTE = "SMART_ROUTE"; 9 | export const SOURCE_POOL_SWAP = "DODO_POOL"; 10 | export const DODOZooID = "dodoex-v2-dodochain-testnet"; 11 | export const CHAIN_BASE_COIN_SYMBOL = "ETH"; 12 | export const CHAIN_BASE_COIN_NAME = "ethereum"; 13 | export const DIP3_TIMESTAMP = 1624442400; 14 | 15 | export const SMART_ROUTE_ADDRESSES: string[] = [ 16 | "0x351a86A2C8dc47D396305AAcd7F126E096b2eee4", 17 | ]; 18 | export const DVM_FACTORY_ADDRESS = "0x7D381e6a9c23A0E6969658f6B8Eba57A4Dbf93a0"; 19 | export const DPP_FACTORY_ADDRESS = "0xF5378974cfD5042A58c458E06cB6D2A2D1c2FAF8"; 20 | export const CLASSIC_FACTORY_ADDRESS = 21 | "0xF9a6c9BE0a1149C69EF537359c78DeB5e6264ec6"; 22 | export const CROWDPOOLING_FACTORY_V2: string[] = [ 23 | "0xF9a6c9BE0a1149C69EF537359c78DeB5e6264ec6", 24 | ]; 25 | 26 | export const DVM_FACTORY_DEPLOY_BLOCK = 58; 27 | export const DPP_FACTORY_DEPLOY_BLOCK = 58; 28 | 29 | export const ADDRESS_ZERO = "0x0000000000000000000000000000000000000000"; 30 | export const BASE_COIN = "0xeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeee"; 31 | 32 | export const TRANSACTION_TYPE_SWAP = "SWAP"; 33 | export const TRANSACTION_TYPE_LP_ADD = "LP_ADD"; 34 | export const TRANSACTION_TYPE_LP_REMOVE = "LP_REMOVE"; 35 | export const TRANSACTION_TYPE_CP_BID = "CP_BID"; 36 | export const TRANSACTION_TYPE_CP_CANCEL = "CP_CANCEL"; 37 | export const TRANSACTION_TYPE_CP_CLAIM = "CP_CLAIM"; 38 | 39 | /** 40 | * usd pricing 41 | */ 42 | export const WRAPPED_BASE_COIN = "0x3a64Ec3606FF7310E8fAd6FcC008e39705fB496d"; 43 | //pricing supported stable coins 44 | export const STABLE_ONE_ADDRESS = "0xb95ed7e958e196688984951f41ac2888f4b10ab9"; //usdt 45 | export const STABLE_TWO_ADDRESS = "0x46afe01d758a46d64c7d8e0791314d5db3e2e683"; //usdc 46 | //stable coins pairs 47 | export const STABLE_COIN_PAIR_ONE = 48 | "0xe8c1b7e0505c97c59ff2f12ebf91a8eaa59d4c73"; //[USDT_USDC_PAIR] 49 | //base currency pair 50 | export const BASE_COIN_PAIR = "0x75f5d66a7bbb9330a9067c0833ec9b3198b71666"; //[WETH_USDC_PAIR] 51 | -------------------------------------------------------------------------------- /src/mappings/constant-goerli.ts: -------------------------------------------------------------------------------- 1 | //kovan 2 | export const TYPE_VIRTUAL_POOL = "VIRTUAL"; 3 | export const TYPE_DVM_POOL = "DVM"; 4 | export const TYPE_DPP_POOL = "DPP"; 5 | export const TYPE_DSP_POOL = "DSP"; 6 | export const TYPE_GSP_POOL = "GSP"; 7 | export const TYPE_CLASSICAL_POOL = "CLASSICAL"; 8 | export const SOURCE_SMART_ROUTE = "SMART_ROUTE"; 9 | export const SOURCE_POOL_SWAP = "DODO_POOL"; 10 | export const DODOZooID = "dodoex-v2-goerli"; 11 | export const CHAIN_BASE_COIN_SYMBOL = "ETH"; 12 | export const CHAIN_BASE_COIN_NAME = "ethereum"; 13 | export const DIP3_TIMESTAMP = 1624442400; 14 | 15 | export const SMART_ROUTE_ADDRESSES: string[] = [ 16 | "0xba001e96af87bf9d8d0bda667067a9921fe6d294", 17 | ]; 18 | export const DVM_FACTORY_ADDRESS = "0x17dddefa0c82e0c850a4adac2afe3f1fe977a242"; 19 | export const DPP_FACTORY_ADDRESS = "0x510b49803e356c750f3a93ba5508c0ffd9f71bdd"; 20 | export const CLASSIC_FACTORY_ADDRESS = 21 | "0x168442fec1e1e782c8770185dbb8328b91dc45c0"; 22 | export const CROWDPOOLING_FACTORY_V2: string[] = [ 23 | "0x79e15fc9b4154d90424b588533ab277d30d573f4", 24 | ]; 25 | 26 | export const DVM_FACTORY_DEPLOY_BLOCK = 8732843; 27 | export const DPP_FACTORY_DEPLOY_BLOCK = 8732843; 28 | 29 | export const ADDRESS_ZERO = "0x0000000000000000000000000000000000000000"; 30 | export const BASE_COIN = "0xeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeee"; 31 | 32 | export const TRANSACTION_TYPE_SWAP = "SWAP"; 33 | export const TRANSACTION_TYPE_LP_ADD = "LP_ADD"; 34 | export const TRANSACTION_TYPE_LP_REMOVE = "LP_REMOVE"; 35 | export const TRANSACTION_TYPE_CP_BID = "CP_BID"; 36 | export const TRANSACTION_TYPE_CP_CANCEL = "CP_CANCEL"; 37 | export const TRANSACTION_TYPE_CP_CLAIM = "CP_CLAIM"; 38 | 39 | /** 40 | * usd pricing 41 | */ 42 | export const WRAPPED_BASE_COIN = "0xb26c0d8be2960c70641a95a9195be1f59ac83ac0"; 43 | //pricing supported stable coins 44 | export const STABLE_ONE_ADDRESS = "0x0adcbae18580120667f7ff6c6451a426b13c67b7"; //usdt 45 | export const STABLE_TWO_ADDRESS = "0xab0733588776b8881f7712f6abca98f510e6b63d"; //usdc 46 | //stable coins pairs 47 | export const STABLE_COIN_PAIR_ONE = 48 | "0xe8c1b7e0505c97c59ff2f12ebf91a8eaa59d4c73"; //[USDT_USDC_PAIR] 49 | //base currency pair 50 | export const BASE_COIN_PAIR = "0x75f5d66a7bbb9330a9067c0833ec9b3198b71666"; //[WETH_USDC_PAIR] 51 | -------------------------------------------------------------------------------- /src/mappings/constant-heco.ts: -------------------------------------------------------------------------------- 1 | //bsc 2 | export const TYPE_VIRTUAL_POOL = "VIRTUAL"; 3 | export const TYPE_DVM_POOL = "DVM"; 4 | export const TYPE_DPP_POOL = "DPP"; 5 | export const TYPE_DSP_POOL = "DSP"; 6 | export const TYPE_GSP_POOL = "GSP"; 7 | export const TYPE_CLASSICAL_POOL = "CLASSICAL"; 8 | export const SOURCE_SMART_ROUTE = "SMART_ROUTE"; 9 | export const SOURCE_POOL_SWAP = "DODO_POOL"; 10 | export const DODOV2Proxy02 = "0xd56281ef996b6b29874c77d2e1464216e8043127"; 11 | export const DIP3_TIMESTAMP = 1624442400; 12 | 13 | export const DODOZooID = "dodoex-v2-heco"; 14 | export const CHAIN_BASE_COIN_SYMBOL = "HT"; 15 | export const CHAIN_BASE_COIN_NAME = "ht"; 16 | 17 | export const SMART_ROUTE_ADDRESSES: string[] = [ 18 | "0xac7cc7d2374492de2d1ce21e2feca26eb0d113e7", 19 | ]; 20 | export const DVM_FACTORY_ADDRESS = "0xd8c77cf0f01222b07b8343a681c46efa3faea985"; 21 | export const DPP_FACTORY_ADDRESS = "0xf5420a3b91c457d336589217d45ccb8f7250eaed"; 22 | export const CLASSIC_FACTORY_ADDRESS = 23 | "0x99bc90b42af3635977ed89e0e7eb6a562da22bd2"; //dodo zoo 24 | export const CROWDPOOLING_FACTORY_V2: string[] = [ 25 | "0x25406177d125c8ab4101954cc02945be49d67515", 26 | ]; 27 | 28 | export const ADDRESS_ZERO = "0x0000000000000000000000000000000000000000"; 29 | export const BASE_COIN = "0xeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeee"; 30 | 31 | export const TRANSACTION_TYPE_SWAP = "SWAP"; 32 | export const TRANSACTION_TYPE_LP_ADD = "LP_ADD"; 33 | export const TRANSACTION_TYPE_LP_REMOVE = "LP_REMOVE"; 34 | export const TRANSACTION_TYPE_CP_BID = "CP_BID"; 35 | export const TRANSACTION_TYPE_CP_CANCEL = "CP_CANCEL"; 36 | export const TRANSACTION_TYPE_CP_CLAIM = "CP_CLAIM"; 37 | 38 | /** 39 | * usd pricing 40 | */ 41 | export const WRAPPED_BASE_COIN = "0x5545153ccfca01fbd7dd11c0b23ba694d9509a6f"; 42 | //pricing supported stable coins 43 | export const STABLE_ONE_ADDRESS = "0xa71edc38d189767582c38a3145b5873052c3e47a"; //usdt 44 | export const STABLE_TWO_ADDRESS = "0x0298c2b32eae4da002a15f36fdf7615bea3da047"; //husd 45 | //stable coins pairs 46 | export const STABLE_COIN_PAIR_ONE = 47 | "0x1053152a60abec125f96f13a980ef469048f978f"; //[USDT_BUSD_PAIR] 48 | //base currency pair 49 | export const BASE_COIN_PAIR = "0x294c1e26eb5c26fb78eff91b9d662d3ed3b63425"; //[WBNB_USDC_PAIR] 50 | -------------------------------------------------------------------------------- /src/mappings/constant-kcc.ts: -------------------------------------------------------------------------------- 1 | //kovan 2 | export const TYPE_VIRTUAL_POOL = "VIRTUAL"; 3 | export const TYPE_DVM_POOL = "DVM"; 4 | export const TYPE_DPP_POOL = "DPP"; 5 | export const TYPE_DSP_POOL = "DSP"; 6 | export const TYPE_GSP_POOL = "GSP"; 7 | export const TYPE_CLASSICAL_POOL = "CLASSICAL"; 8 | export const SOURCE_SMART_ROUTE = "SMART_ROUTE"; 9 | export const SOURCE_POOL_SWAP = "DODO_POOL"; 10 | export const DODOZooID = "dodoex-v2-kcc"; 11 | export const CHAIN_BASE_COIN_SYMBOL = "KCS"; 12 | export const CHAIN_BASE_COIN_NAME = "kcs"; 13 | export const DIP3_TIMESTAMP = 1624442400; 14 | 15 | export const SMART_ROUTE_ADDRESSES: string[] = [ 16 | "0xf0512872fec0173d1d99c2dd8cdcb770054b675b", 17 | ]; 18 | export const DVM_FACTORY_ADDRESS = "0x31ac053c31a77055b2ae2d3899091c0a9c19ce3a"; 19 | export const DPP_FACTORY_ADDRESS = "0x4632e6ebd4a01ebf54739a9d71a62cedb29e9183"; 20 | export const CLASSIC_FACTORY_ADDRESS = 21 | "0x168442fec1e1e782c8770185dbb8328b91dc45c0"; 22 | export const CROWDPOOLING_FACTORY_V2: string[] = [ 23 | "0xae1e7e4c5743321d2a8ceed179264998a56cf1d9", 24 | ]; 25 | 26 | export const DVM_FACTORY_DEPLOY_BLOCK = 8732843; 27 | export const DPP_FACTORY_DEPLOY_BLOCK = 8732843; 28 | 29 | export const ADDRESS_ZERO = "0x0000000000000000000000000000000000000000"; 30 | export const BASE_COIN = "0xeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeee"; 31 | 32 | export const TRANSACTION_TYPE_SWAP = "SWAP"; 33 | export const TRANSACTION_TYPE_LP_ADD = "LP_ADD"; 34 | export const TRANSACTION_TYPE_LP_REMOVE = "LP_REMOVE"; 35 | export const TRANSACTION_TYPE_CP_BID = "CP_BID"; 36 | export const TRANSACTION_TYPE_CP_CANCEL = "CP_CANCEL"; 37 | export const TRANSACTION_TYPE_CP_CLAIM = "CP_CLAIM"; 38 | 39 | /** 40 | * usd pricing 41 | */ 42 | export const WRAPPED_BASE_COIN = "0x4446fc4eb47f2f6586f9faab68b3498f86c07521"; 43 | //pricing supported stable coins 44 | export const STABLE_ONE_ADDRESS = "0x0039f574ee5cc39bdd162e9a88e3eb1f111baf48"; //usdt 45 | export const STABLE_TWO_ADDRESS = "0x980a5afef3d17ad98635f6c5aebcbaeded3c3430"; //usdc 46 | //stable coins pairs 47 | export const STABLE_COIN_PAIR_ONE = 48 | "0xe8c1b7e0505c97c59ff2f12ebf91a8eaa59d4c73"; //[USDT_USDC_PAIR] 49 | //base currency pair 50 | export const BASE_COIN_PAIR = "0x75f5d66a7bbb9330a9067c0833ec9b3198b71666"; //[WETH_USDC_PAIR] 51 | -------------------------------------------------------------------------------- /src/mappings/constant-kovan.ts: -------------------------------------------------------------------------------- 1 | //kovan 2 | export const TYPE_VIRTUAL_POOL = "VIRTUAL"; 3 | export const TYPE_DVM_POOL = "DVM"; 4 | export const TYPE_DPP_POOL = "DPP"; 5 | export const TYPE_DSP_POOL = "DSP"; 6 | export const TYPE_GSP_POOL = "GSP"; 7 | export const TYPE_CLASSICAL_POOL = "CLASSICAL"; 8 | export const SOURCE_SMART_ROUTE = "SMART_ROUTE"; 9 | export const SOURCE_POOL_SWAP = "DODO_POOL"; 10 | export const DODOZooID = "dodoex-v2-kovan"; 11 | export const CHAIN_BASE_COIN_SYMBOL = "ETH"; 12 | export const CHAIN_BASE_COIN_NAME = "ethereum"; 13 | export const DIP3_TIMESTAMP = 1624442400; 14 | 15 | export const SMART_ROUTE_ADDRESSES: string[] = [ 16 | "0x85caa68ae47f047aa01c48bcaa711ca70a950ffb", 17 | ]; 18 | export const DVM_FACTORY_ADDRESS = "0x322f8014c125da09314d3a68d4d9f427823f17fd"; 19 | export const DPP_FACTORY_ADDRESS = "0xc65f8087288aa0a118aa6f3228ef9ecc8187f4b6"; 20 | export const CLASSIC_FACTORY_ADDRESS = 21 | "0x92230e929a2226b29ed3441ae5524886347c60c8"; 22 | 23 | export const DVM_FACTORY_DEPLOY_BLOCK = 23379878; 24 | export const DPP_FACTORY_DEPLOY_BLOCK = 23388901; 25 | 26 | export const ADDRESS_ZERO = "0x0000000000000000000000000000000000000000"; 27 | export const BASE_COIN = "0xeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeee"; 28 | 29 | export const TRANSACTION_TYPE_SWAP = "SWAP"; 30 | export const TRANSACTION_TYPE_LP_ADD = "LP_ADD"; 31 | export const TRANSACTION_TYPE_LP_REMOVE = "LP_REMOVE"; 32 | export const TRANSACTION_TYPE_CP_BID = "CP_BID"; 33 | export const TRANSACTION_TYPE_CP_CANCEL = "CP_CANCEL"; 34 | export const TRANSACTION_TYPE_CP_CLAIM = "CP_CLAIM"; 35 | 36 | /** 37 | * usd pricing 38 | */ 39 | export const WRAPPED_BASE_COIN = "0x5eca15b12d959dfcf9c71c59f8b467eb8c6efd0b"; 40 | //pricing supported stable coins 41 | export const STABLE_ONE_ADDRESS = "0xd02de455eeaa9d6bf8f8d56db13ce6178b46a9c2"; //usdt 42 | export const STABLE_TWO_ADDRESS = "0x3a9fdfef1382a146f390b699413f63a996c6981f"; //usdc 43 | //stable coins pairs 44 | export const STABLE_COIN_PAIR_ONE = 45 | "0xe8c1b7e0505c97c59ff2f12ebf91a8eaa59d4c73"; //[USDT_USDC_PAIR] 46 | //base currency pair 47 | export const BASE_COIN_PAIR = "0x75f5d66a7bbb9330a9067c0833ec9b3198b71666"; //[WETH_USDC_PAIR] 48 | -------------------------------------------------------------------------------- /src/mappings/constant-linea.ts: -------------------------------------------------------------------------------- 1 | //kovan 2 | export const TYPE_VIRTUAL_POOL = "VIRTUAL"; 3 | export const TYPE_DVM_POOL = "DVM"; 4 | export const TYPE_DPP_POOL = "DPP"; 5 | export const TYPE_DSP_POOL = "DSP"; 6 | export const TYPE_GSP_POOL = "GSP"; 7 | export const TYPE_CLASSICAL_POOL = "CLASSICAL"; 8 | export const SOURCE_SMART_ROUTE = "SMART_ROUTE"; 9 | export const SOURCE_POOL_SWAP = "DODO_POOL"; 10 | export const DODOZooID = "dodoex-v2-linea"; 11 | export const CHAIN_BASE_COIN_SYMBOL = "ETH"; 12 | export const CHAIN_BASE_COIN_NAME = "ethereum"; 13 | export const DIP3_TIMESTAMP = 1624442400; 14 | 15 | export const SMART_ROUTE_ADDRESSES: string[] = [ 16 | "0x4cad0052524648a7fa2cfe279997b00239295f33", 17 | ]; 18 | export const DVM_FACTORY_ADDRESS = "0xc0F9553Df63De5a97Fe64422c8578D0657C360f7"; 19 | export const DPP_FACTORY_ADDRESS = "0x97bBF5BB1dcfC93A8c67e97E50Bea19DB3416A83"; 20 | export const CLASSIC_FACTORY_ADDRESS = 21 | "0x6B9577b87666af89bd0e144b9b64e8Ed166E303d"; 22 | export const CROWDPOOLING_FACTORY_V2: string[] = [ 23 | "0x6B9577b87666af89bd0e144b9b64e8Ed166E303d", 24 | ]; 25 | 26 | export const DVM_FACTORY_DEPLOY_BLOCK = 152408; 27 | export const DPP_FACTORY_DEPLOY_BLOCK = 152408; 28 | 29 | export const ADDRESS_ZERO = "0x0000000000000000000000000000000000000000"; 30 | export const BASE_COIN = "0xeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeee"; 31 | 32 | export const TRANSACTION_TYPE_SWAP = "SWAP"; 33 | export const TRANSACTION_TYPE_LP_ADD = "LP_ADD"; 34 | export const TRANSACTION_TYPE_LP_REMOVE = "LP_REMOVE"; 35 | export const TRANSACTION_TYPE_CP_BID = "CP_BID"; 36 | export const TRANSACTION_TYPE_CP_CANCEL = "CP_CANCEL"; 37 | export const TRANSACTION_TYPE_CP_CLAIM = "CP_CLAIM"; 38 | 39 | /** 40 | * usd pricing 41 | */ 42 | export const WRAPPED_BASE_COIN = "0xb26c0d8be2960c70641a95a9195be1f59ac83ac0"; 43 | //pricing supported stable coins 44 | export const STABLE_ONE_ADDRESS = "0x0adcbae18580120667f7ff6c6451a426b13c67b7"; //usdt 45 | export const STABLE_TWO_ADDRESS = "0xab0733588776b8881f7712f6abca98f510e6b63d"; //usdc 46 | //stable coins pairs 47 | export const STABLE_COIN_PAIR_ONE = 48 | "0xe8c1b7e0505c97c59ff2f12ebf91a8eaa59d4c73"; //[USDT_USDC_PAIR] 49 | //base currency pair 50 | export const BASE_COIN_PAIR = "0x75f5d66a7bbb9330a9067c0833ec9b3198b71666"; //[WETH_USDC_PAIR] 51 | -------------------------------------------------------------------------------- /src/mappings/constant-mainnet.ts: -------------------------------------------------------------------------------- 1 | //mainnet 2 | export const TYPE_VIRTUAL_POOL = "VIRTUAL"; 3 | export const TYPE_DVM_POOL = "DVM"; 4 | export const TYPE_DPP_POOL = "DPP"; 5 | export const TYPE_DSP_POOL = "DSP"; 6 | export const TYPE_GSP_POOL = "GSP"; 7 | export const TYPE_CLASSICAL_POOL = "CLASSICAL"; 8 | export const SOURCE_SMART_ROUTE = "SMART_ROUTE"; 9 | export const SOURCE_POOL_SWAP = "DODO_POOL"; 10 | export const DIP3_TIMESTAMP = 1624442400; 11 | 12 | export const DODOV1Proxy01 = "0xd0678ec59d1337e29d1e1b1b6338f3e85d311f5e"; 13 | export const DODOV1Proxy02 = "0x6ed3fd491f5b10384787b3fb162a72227fafbf63"; 14 | export const DODOV1Proxy03 = "0x9a9942458754bdf65dcbcd0b6b4b842a7d4031ab"; 15 | export const DODOV1Proxy04 = "0xa2cb66ebb947d217f61510882096f6e95c1de97d"; 16 | export const DODOV2Proxy01 = "0x9ae501385bc7996a2a4a1fbb00c8d3820611bcb5"; 17 | export const DODOV2Proxy02 = "0xa356867fdcea8e71aeaf87805808803806231fdc"; 18 | 19 | export const DODOZooID = "dodoex-v2"; 20 | export const CHAIN_BASE_COIN_SYMBOL = "ETH"; 21 | export const CHAIN_BASE_COIN_NAME = "ether"; 22 | 23 | export const SMART_ROUTE_ADDRESSES: string[] = [ 24 | "0xd0678ec59d1337e29d1e1b1b6338f3e85d311f5e", 25 | "0x6ed3fd491f5b10384787b3fb162a72227fafbf63", 26 | "0x9a9942458754bdf65dcbcd0b6b4b842a7d4031ab", 27 | "0x9ae501385bc7996a2a4a1fbb00c8d3820611bcb5", 28 | "0xa2cb66ebb947d217f61510882096f6e95c1de97d", 29 | "0xa356867fdcea8e71aeaf87805808803806231fdc", 30 | ]; 31 | export const DVM_FACTORY_ADDRESS = "0x72d220ce168c4f361dd4dee5d826a01ad8598f6c"; 32 | export const DPP_FACTORY_ADDRESS = "0xb5dc5e183c2acf02ab879a8569ab4edaf147d537"; 33 | export const CLASSIC_FACTORY_ADDRESS = 34 | "0x3a97247df274a17c59a3bd12735ea3fcdfb49950"; //dodo zoo 35 | export const CROWDPOOLING_FACTORY_V2: string[] = [ 36 | "0x1e5d8ee8fb7f0d791475c59391db8f6cd06aa656", 37 | ]; 38 | 39 | export const ADDRESS_ZERO = "0x0000000000000000000000000000000000000000"; 40 | export const BASE_COIN = "0xeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeee"; 41 | 42 | export const TRANSACTION_TYPE_SWAP = "SWAP"; 43 | export const TRANSACTION_TYPE_LP_ADD = "LP_ADD"; 44 | export const TRANSACTION_TYPE_LP_REMOVE = "LP_REMOVE"; 45 | export const TRANSACTION_TYPE_CP_BID = "CP_BID"; 46 | export const TRANSACTION_TYPE_CP_CANCEL = "CP_CANCEL"; 47 | export const TRANSACTION_TYPE_CP_CLAIM = "CP_CLAIM"; 48 | 49 | /** 50 | * usd pricing 51 | */ 52 | export const WRAPPED_BASE_COIN = "0xc02aaa39b223fe8d0a0e5c4f27ead9083c756cc2"; 53 | //pricing supported stable coins 54 | export const STABLE_ONE_ADDRESS = "0xdac17f958d2ee523a2206206994597c13d831ec7"; //usdt 55 | export const STABLE_TWO_ADDRESS = "0xa0b86991c6218b36c1d19d4a2e9eb0ce3606eb48"; //usdc 56 | //stable coins pairs 57 | export const STABLE_COIN_PAIR_ONE = 58 | "0xc9f93163c99695c6526b799ebca2207fdf7d61ad"; //[USDT_USDC_PAIR] 59 | //base currency pair 60 | export const BASE_COIN_PAIR = "0x75c23271661d9d143dcb617222bc4bec783eff34"; //[WETH_USDC_PAIR] 61 | -------------------------------------------------------------------------------- /src/mappings/constant-manta.ts: -------------------------------------------------------------------------------- 1 | //kovan 2 | export const TYPE_VIRTUAL_POOL = "VIRTUAL"; 3 | export const TYPE_DVM_POOL = "DVM"; 4 | export const TYPE_DPP_POOL = "DPP"; 5 | export const TYPE_DSP_POOL = "DSP"; 6 | export const TYPE_GSP_POOL = "GSP"; 7 | export const TYPE_CLASSICAL_POOL = "CLASSICAL"; 8 | export const SOURCE_SMART_ROUTE = "SMART_ROUTE"; 9 | export const SOURCE_POOL_SWAP = "DODO_POOL"; 10 | export const DODOZooID = "dodoex-v2-manta"; 11 | export const CHAIN_BASE_COIN_SYMBOL = "ETH"; 12 | export const CHAIN_BASE_COIN_NAME = "ethereum"; 13 | export const DIP3_TIMESTAMP = 1624442400; 14 | 15 | export const SMART_ROUTE_ADDRESSES: string[] = [ 16 | "0x4cad0052524648a7fa2cfe279997b00239295f33", 17 | ]; 18 | export const DVM_FACTORY_ADDRESS = "0x97bBF5BB1dcfC93A8c67e97E50Bea19DB3416A83"; 19 | export const DPP_FACTORY_ADDRESS = "0xa71415675F68f29259ddD63215E5518d2735bf0a"; 20 | export const CLASSIC_FACTORY_ADDRESS = 21 | "0x6B9577b87666af89bd0e144b9b64e8Ed166E303d"; 22 | export const CROWDPOOLING_FACTORY_V2: string[] = [ 23 | "0xFD2b7994f91c08aAa5e013E899334A2DBb500DF1", 24 | ]; 25 | 26 | export const DVM_FACTORY_DEPLOY_BLOCK = 384142; 27 | export const DPP_FACTORY_DEPLOY_BLOCK = 384142; 28 | 29 | export const ADDRESS_ZERO = "0x0000000000000000000000000000000000000000"; 30 | export const BASE_COIN = "0xeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeee"; 31 | 32 | export const TRANSACTION_TYPE_SWAP = "SWAP"; 33 | export const TRANSACTION_TYPE_LP_ADD = "LP_ADD"; 34 | export const TRANSACTION_TYPE_LP_REMOVE = "LP_REMOVE"; 35 | export const TRANSACTION_TYPE_CP_BID = "CP_BID"; 36 | export const TRANSACTION_TYPE_CP_CANCEL = "CP_CANCEL"; 37 | export const TRANSACTION_TYPE_CP_CLAIM = "CP_CLAIM"; 38 | 39 | /** 40 | * usd pricing 41 | */ 42 | export const WRAPPED_BASE_COIN = "0xb26c0d8be2960c70641a95a9195be1f59ac83ac0"; 43 | //pricing supported stable coins 44 | export const STABLE_ONE_ADDRESS = "0xf417F5A458eC102B90352F697D6e2Ac3A3d2851f"; //usdt 45 | export const STABLE_TWO_ADDRESS = "0xb73603C5d87fA094B7314C74ACE2e64D165016fb"; //usdc 46 | //stable coins pairs 47 | export const STABLE_COIN_PAIR_ONE = 48 | "0xe8c1b7e0505c97c59ff2f12ebf91a8eaa59d4c73"; //[USDT_USDC_PAIR] 49 | //base currency pair 50 | export const BASE_COIN_PAIR = "0x75f5d66a7bbb9330a9067c0833ec9b3198b71666"; //[WETH_USDC_PAIR] 51 | -------------------------------------------------------------------------------- /src/mappings/constant-mantle.ts: -------------------------------------------------------------------------------- 1 | //kovan 2 | export const TYPE_VIRTUAL_POOL = "VIRTUAL"; 3 | export const TYPE_DVM_POOL = "DVM"; 4 | export const TYPE_DPP_POOL = "DPP"; 5 | export const TYPE_DSP_POOL = "DSP"; 6 | export const TYPE_GSP_POOL = "GSP"; 7 | export const TYPE_CLASSICAL_POOL = "CLASSICAL"; 8 | export const SOURCE_SMART_ROUTE = "SMART_ROUTE"; 9 | export const SOURCE_POOL_SWAP = "DODO_POOL"; 10 | export const DODOZooID = "dodoex-v2-mantle"; 11 | export const CHAIN_BASE_COIN_SYMBOL = "ETH"; 12 | export const CHAIN_BASE_COIN_NAME = "ethereum"; 13 | export const DIP3_TIMESTAMP = 1624442400; 14 | 15 | export const SMART_ROUTE_ADDRESSES: string[] = [ 16 | "0xe7979E2F3e77196Bb2AB206eaa67Ea278A3E33A2", 17 | ]; 18 | export const DVM_FACTORY_ADDRESS = "0x29C7718e8B606cEF1c44Fe6e43e07aF9D0875DE1"; 19 | export const DPP_FACTORY_ADDRESS = "0x46AF6b152F2cb02a3cFcc74014C2617BC4F6cD5C"; 20 | export const CLASSIC_FACTORY_ADDRESS = 21 | "0x6B9577b87666af89bd0e144b9b64e8Ed166E303d"; 22 | export const CROWDPOOLING_FACTORY_V2: string[] = [ 23 | "0xE2004eE21f88a7D8e1A5EDc3c9617a0460CC7b99", 24 | ]; 25 | 26 | export const DVM_FACTORY_DEPLOY_BLOCK = 21054048; 27 | export const DPP_FACTORY_DEPLOY_BLOCK = 21054104; 28 | 29 | export const ADDRESS_ZERO = "0x0000000000000000000000000000000000000000"; 30 | export const BASE_COIN = "0xeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeee"; 31 | 32 | export const TRANSACTION_TYPE_SWAP = "SWAP"; 33 | export const TRANSACTION_TYPE_LP_ADD = "LP_ADD"; 34 | export const TRANSACTION_TYPE_LP_REMOVE = "LP_REMOVE"; 35 | export const TRANSACTION_TYPE_CP_BID = "CP_BID"; 36 | export const TRANSACTION_TYPE_CP_CANCEL = "CP_CANCEL"; 37 | export const TRANSACTION_TYPE_CP_CLAIM = "CP_CLAIM"; 38 | 39 | /** 40 | * usd pricing 41 | */ 42 | export const WRAPPED_BASE_COIN = "0xdeaddeaddeaddeaddeaddeaddeaddeaddead1111"; 43 | //pricing supported stable coins 44 | export const STABLE_ONE_ADDRESS = "0x201eba5cc46d216ce6dc03f6a759e8e766e956ae"; //usdt 45 | export const STABLE_TWO_ADDRESS = "0x09bc4e0d864854c6afb6eb9a9cdf58ac190d0df9"; //usdc 46 | //stable coins pairs 47 | export const STABLE_COIN_PAIR_ONE = 48 | "0xe8c1b7e0505c97c59ff2f12ebf91a8eaa59d4c73"; //[USDT_USDC_PAIR] 49 | //base currency pair 50 | export const BASE_COIN_PAIR = "0x75f5d66a7bbb9330a9067c0833ec9b3198b71666"; //[WETH_USDC_PAIR] 51 | -------------------------------------------------------------------------------- /src/mappings/constant-moonriver.ts: -------------------------------------------------------------------------------- 1 | //mainnet 2 | export const TYPE_VIRTUAL_POOL = "VIRTUAL"; 3 | export const TYPE_DVM_POOL = "DVM"; 4 | export const TYPE_DPP_POOL = "DPP"; 5 | export const TYPE_DSP_POOL = "DSP"; 6 | export const TYPE_GSP_POOL = "GSP"; 7 | export const TYPE_CLASSICAL_POOL = "CLASSICAL"; 8 | export const SOURCE_SMART_ROUTE = "SMART_ROUTE"; 9 | export const SOURCE_POOL_SWAP = "DODO_POOL"; 10 | export const DIP3_TIMESTAMP = 868288; 11 | 12 | export const DODOV2Proxy02 = "0xa356867fdcea8e71aeaf87805808803806231fdc"; 13 | 14 | export const DODOZooID = "dodoex-v2-moonriver"; 15 | export const CHAIN_BASE_COIN_SYMBOL = "mover"; 16 | export const CHAIN_BASE_COIN_NAME = "moonriver"; 17 | 18 | export const SMART_ROUTE_ADDRESSES: string[] = [ 19 | "0xd9dec7c3c06e62a4c1beeb07cadf568f496b14c2", 20 | ]; 21 | export const DVM_FACTORY_ADDRESS = "0x738ebf387a0ce0eb46b0ef8fa5dea2eae6b1df51"; 22 | export const DPP_FACTORY_ADDRESS = "0xd0e1aa51df0896c126ce6f8a064e551e0dd3d39b"; 23 | export const CLASSIC_FACTORY_ADDRESS = 24 | "0x02fcb21dc1cf221939c1d4277fb54016b5d32bc7"; //dodo zoo 25 | export const CROWDPOOLING_FACTORY_V2: string[] = [ 26 | "0x1b75c99c3ab14764aea1511e68b33f5b9138a241", 27 | ]; 28 | 29 | export const ADDRESS_ZERO = "0x0000000000000000000000000000000000000000"; 30 | export const BASE_COIN = "0xeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeee"; 31 | 32 | export const TRANSACTION_TYPE_SWAP = "SWAP"; 33 | export const TRANSACTION_TYPE_LP_ADD = "LP_ADD"; 34 | export const TRANSACTION_TYPE_LP_REMOVE = "LP_REMOVE"; 35 | export const TRANSACTION_TYPE_CP_BID = "CP_BID"; 36 | export const TRANSACTION_TYPE_CP_CANCEL = "CP_CANCEL"; 37 | export const TRANSACTION_TYPE_CP_CLAIM = "CP_CLAIM"; 38 | 39 | /** 40 | * usd pricing 41 | */ 42 | export const WRAPPED_BASE_COIN = "0xf50225a84382c74cbdea10b0c176f71fc3de0c4d"; 43 | //pricing supported stable coins 44 | export const STABLE_ONE_ADDRESS = "0xb44a9b6905af7c801311e8f4e76932ee959c663c"; //usdt 45 | export const STABLE_TWO_ADDRESS = "0xe3f5a90f9cb311505cd691a46596599aa1a0ad7d"; //usdc 46 | //stable coins pairs todo 47 | export const STABLE_COIN_PAIR_ONE = 48 | "0xc9f93163c99695c6526b799ebca2207fdf7d61ad"; //[USDT_USDC_PAIR] 49 | //base currency pair todo 50 | export const BASE_COIN_PAIR = "0x75c23271661d9d143dcb617222bc4bec783eff34"; //[WETH_USDC_PAIR] 51 | -------------------------------------------------------------------------------- /src/mappings/constant-okb.ts: -------------------------------------------------------------------------------- 1 | //kovan 2 | export const TYPE_VIRTUAL_POOL = "VIRTUAL"; 3 | export const TYPE_DVM_POOL = "DVM"; 4 | export const TYPE_DPP_POOL = "DPP"; 5 | export const TYPE_DSP_POOL = "DSP"; 6 | export const TYPE_GSP_POOL = "GSP"; 7 | export const TYPE_CLASSICAL_POOL = "CLASSICAL"; 8 | export const SOURCE_SMART_ROUTE = "SMART_ROUTE"; 9 | export const SOURCE_POOL_SWAP = "DODO_POOL"; 10 | export const DODOZooID = "dodoex-v2-okb-x1-layer"; 11 | export const CHAIN_BASE_COIN_SYMBOL = "ETH"; 12 | export const CHAIN_BASE_COIN_NAME = "ethereum"; 13 | export const DIP3_TIMESTAMP = 1624442400; 14 | 15 | export const SMART_ROUTE_ADDRESSES: string[] = [ 16 | "0x5b622A373b485CB9BA283ECd6CE6689a8b8FdC05", 17 | ]; 18 | export const DVM_FACTORY_ADDRESS = "0xFaFC924BF0F70BdF4a722231622f559b94e53902"; 19 | export const DPP_FACTORY_ADDRESS = "0xb546Add98c71D97Bb65De60B91021617AcD1262C"; 20 | export const CLASSIC_FACTORY_ADDRESS = 21 | "0x8dD0Fea5FA2f7df535F87f312641Cc15d8B151BA"; 22 | export const CROWDPOOLING_FACTORY_V2: string[] = [ 23 | "0x8dD0Fea5FA2f7df535F87f312641Cc15d8B151BA", 24 | ]; 25 | 26 | export const DVM_FACTORY_DEPLOY_BLOCK = 300062; 27 | export const DPP_FACTORY_DEPLOY_BLOCK = 300062; 28 | 29 | export const ADDRESS_ZERO = "0x0000000000000000000000000000000000000000"; 30 | export const BASE_COIN = "0xeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeee"; 31 | 32 | export const TRANSACTION_TYPE_SWAP = "SWAP"; 33 | export const TRANSACTION_TYPE_LP_ADD = "LP_ADD"; 34 | export const TRANSACTION_TYPE_LP_REMOVE = "LP_REMOVE"; 35 | export const TRANSACTION_TYPE_CP_BID = "CP_BID"; 36 | export const TRANSACTION_TYPE_CP_CANCEL = "CP_CANCEL"; 37 | export const TRANSACTION_TYPE_CP_CLAIM = "CP_CLAIM"; 38 | 39 | /** 40 | * usd pricing 41 | */ 42 | export const WRAPPED_BASE_COIN = "0xb26c0d8be2960c70641a95a9195be1f59ac83ac0"; 43 | //pricing supported stable coins 44 | export const STABLE_ONE_ADDRESS = "0x0adcbae18580120667f7ff6c6451a426b13c67b7"; //usdt 45 | export const STABLE_TWO_ADDRESS = "0xab0733588776b8881f7712f6abca98f510e6b63d"; //usdc 46 | //stable coins pairs 47 | export const STABLE_COIN_PAIR_ONE = 48 | "0xe8c1b7e0505c97c59ff2f12ebf91a8eaa59d4c73"; //[USDT_USDC_PAIR] 49 | //base currency pair 50 | export const BASE_COIN_PAIR = "0x75f5d66a7bbb9330a9067c0833ec9b3198b71666"; //[WETH_USDC_PAIR] 51 | -------------------------------------------------------------------------------- /src/mappings/constant-okchain.ts: -------------------------------------------------------------------------------- 1 | //mainnet 2 | export const TYPE_VIRTUAL_POOL = "VIRTUAL"; 3 | export const TYPE_DVM_POOL = "DVM"; 4 | export const TYPE_DPP_POOL = "DPP"; 5 | export const TYPE_DSP_POOL = "DSP"; 6 | export const TYPE_GSP_POOL = "GSP"; 7 | export const TYPE_CLASSICAL_POOL = "CLASSICAL"; 8 | export const SOURCE_SMART_ROUTE = "SMART_ROUTE"; 9 | export const SOURCE_POOL_SWAP = "DODO_POOL"; 10 | export const DIP3_TIMESTAMP = 1624442400; 11 | 12 | export const DODOZooID = "dodoex-v2-okchain"; 13 | export const CHAIN_BASE_COIN_SYMBOL = "OKT"; 14 | export const CHAIN_BASE_COIN_NAME = "OKT"; 15 | 16 | export const SMART_ROUTE_ADDRESSES: string[] = [ 17 | "0x6b4fa0bc61eddc928e0df9c7f01e407bfcd3e5ef", 18 | ]; 19 | export const DVM_FACTORY_ADDRESS = "0x9ae501385bc7996a2a4a1fbb00c8d3820611bcb5"; 20 | export const DPP_FACTORY_ADDRESS = "0xbab9f4ff4a19a0e8eebc56b06750253228ffac6e"; 21 | export const CLASSIC_FACTORY_ADDRESS = 22 | "0x357c5e9cfa8b834edcef7c7aabd8f9db09119d11"; //dodo zoo 23 | export const CROWDPOOLING_FACTORY_V2: string[] = [ 24 | "0x5333eb1e32522f1893b7c9fea3c263807a02d561", 25 | ]; 26 | 27 | export const ADDRESS_ZERO = "0x0000000000000000000000000000000000000000"; 28 | export const BASE_COIN = "0xeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeee"; 29 | 30 | export const TRANSACTION_TYPE_SWAP = "SWAP"; 31 | export const TRANSACTION_TYPE_LP_ADD = "LP_ADD"; 32 | export const TRANSACTION_TYPE_LP_REMOVE = "LP_REMOVE"; 33 | export const TRANSACTION_TYPE_CP_BID = "CP_BID"; 34 | export const TRANSACTION_TYPE_CP_CANCEL = "CP_CANCEL"; 35 | export const TRANSACTION_TYPE_CP_CLAIM = "CP_CLAIM"; 36 | 37 | /** 38 | * usd pricing 39 | */ 40 | export const WRAPPED_BASE_COIN = "0x8f8526dbfd6e38e3d8307702ca8469bae6c56c15"; 41 | //pricing supported stable coins 42 | export const STABLE_ONE_ADDRESS = "0x382bb369d343125bfb2117af9c149795c6c65c50"; //usdt 43 | export const STABLE_TWO_ADDRESS = "0xc946daf81b08146b1c7a8da2a851ddf2b3eaaf85"; //usdc 44 | //stable coins pairs 45 | export const STABLE_COIN_PAIR_ONE = 46 | "0xc9f93163c99695c6526b799ebca2207fdf7d61ad"; //[USDT_USDC_PAIR] 47 | //base currency pair 48 | export const BASE_COIN_PAIR = "0x75c23271661d9d143dcb617222bc4bec783eff34"; //[WOKT_USDC_PAIR] 49 | -------------------------------------------------------------------------------- /src/mappings/constant-optimism.ts: -------------------------------------------------------------------------------- 1 | //mainnet 2 | export const TYPE_VIRTUAL_POOL = "VIRTUAL"; 3 | export const TYPE_DVM_POOL = "DVM"; 4 | export const TYPE_DPP_POOL = "DPP"; 5 | export const TYPE_DSP_POOL = "DSP"; 6 | export const TYPE_GSP_POOL = "GSP"; 7 | export const TYPE_CLASSICAL_POOL = "CLASSICAL"; 8 | export const SOURCE_SMART_ROUTE = "SMART_ROUTE"; 9 | export const SOURCE_POOL_SWAP = "DODO_POOL"; 10 | export const DODOV2Proxy02 = "0xfd9d2827ad469b72b69329daa325ba7afbdb3c98"; 11 | export const DIP3_TIMESTAMP = 100; 12 | 13 | export const DODOZooID = "dodoex-v2-optimism"; 14 | export const CHAIN_BASE_COIN_SYMBOL = "ETH"; 15 | export const CHAIN_BASE_COIN_NAME = "ether"; 16 | 17 | export const SMART_ROUTE_ADDRESSES: string[] = [ 18 | "0xfd9d2827ad469b72b69329daa325ba7afbdb3c98", 19 | ]; 20 | export const DVM_FACTORY_ADDRESS = "0x2b800dc6270726f7e2266ce8cd5a3f8436fe0b40"; 21 | export const DPP_FACTORY_ADDRESS = "0xdb9c53f2ced34875685b607c97a61a65da2f30a8"; 22 | export const CLASSIC_FACTORY_ADDRESS = 23 | "0xc48936efc01db84ab15fe89c08e3b2b72853eece"; //dodo zoo 24 | 25 | export const ADDRESS_ZERO = "0x0000000000000000000000000000000000000000"; 26 | export const BASE_COIN = "0xeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeee"; 27 | 28 | export const TRANSACTION_TYPE_SWAP = "SWAP"; 29 | export const TRANSACTION_TYPE_LP_ADD = "LP_ADD"; 30 | export const TRANSACTION_TYPE_LP_REMOVE = "LP_REMOVE"; 31 | export const TRANSACTION_TYPE_CP_BID = "CP_BID"; 32 | export const TRANSACTION_TYPE_CP_CANCEL = "CP_CANCEL"; 33 | export const TRANSACTION_TYPE_CP_CLAIM = "CP_CLAIM"; 34 | 35 | /** 36 | * usd pricing 37 | */ 38 | export const WRAPPED_BASE_COIN = "0x4200000000000000000000000000000000000006"; 39 | //pricing supported stable coins 40 | export const STABLE_ONE_ADDRESS = "0x94b008aa00579c1307b0ef2c499ad98a8ce58e58"; //usdt 41 | export const STABLE_TWO_ADDRESS = "0x7f5c764cbc14f9669b88837ca1490cca17c31607"; //usdc 42 | //stable coins pairs 43 | export const STABLE_COIN_PAIR_ONE = 44 | "0xe4b2dfc82977dd2dce7e8d37895a6a8f50cbb4fb"; //[USDT_USDC_PAIR] 45 | //base currency pair 46 | export const BASE_COIN_PAIR = "0xfe176a2b1e1f67250d2903b8d25f56c0dabcd6b2"; //[WETH_USDC_PAIR] 47 | export const CROWDPOOLING_FACTORY_V2: string[] = [ 48 | "0x424976b3997514afa7c5122d053b8973f225d9db", 49 | ]; 50 | -------------------------------------------------------------------------------- /src/mappings/constant-polygon.ts: -------------------------------------------------------------------------------- 1 | //mainnet 2 | export const TYPE_VIRTUAL_POOL = "VIRTUAL"; 3 | export const TYPE_DVM_POOL = "DVM"; 4 | export const TYPE_DPP_POOL = "DPP"; 5 | export const TYPE_DSP_POOL = "DSP"; 6 | export const TYPE_GSP_POOL = "GSP"; 7 | export const TYPE_CLASSICAL_POOL = "CLASSICAL"; 8 | export const SOURCE_SMART_ROUTE = "SMART_ROUTE"; 9 | export const SOURCE_POOL_SWAP = "DODO_POOL"; 10 | export const DODOV2Proxy02 = "0x45894c062e6f4e58b257e0826675355305dfef0d"; 11 | export const DIP3_TIMESTAMP = 1624442400; 12 | 13 | export const DODOZooID = "dodoex-v2-polygon"; 14 | export const CHAIN_BASE_COIN_SYMBOL = "MATIC"; 15 | export const CHAIN_BASE_COIN_NAME = "MATIC"; 16 | 17 | export const SMART_ROUTE_ADDRESSES: string[] = [ 18 | "0x45894c062e6f4e58b257e0826675355305dfef0d", 19 | ]; 20 | export const DVM_FACTORY_ADDRESS = "0xbab9f4ff4a19a0e8eebc56b06750253228ffac6e"; 21 | export const DPP_FACTORY_ADDRESS = "0xe55154d09265b18ac7cdac6e646672a5460389a1"; 22 | export const CLASSIC_FACTORY_ADDRESS = 23 | "0x357c5e9cfa8b834edcef7c7aabd8f9db09119d11"; //dodo zoo 24 | export const CROWDPOOLING_FACTORY_V2: string[] = [ 25 | "0x29e7085fda4a8492fbb16e840488b514149d51f6", 26 | ]; 27 | 28 | export const ADDRESS_ZERO = "0x0000000000000000000000000000000000000000"; 29 | export const BASE_COIN = "0xeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeee"; 30 | 31 | export const TRANSACTION_TYPE_SWAP = "SWAP"; 32 | export const TRANSACTION_TYPE_LP_ADD = "LP_ADD"; 33 | export const TRANSACTION_TYPE_LP_REMOVE = "LP_REMOVE"; 34 | export const TRANSACTION_TYPE_CP_BID = "CP_BID"; 35 | export const TRANSACTION_TYPE_CP_CANCEL = "CP_CANCEL"; 36 | export const TRANSACTION_TYPE_CP_CLAIM = "CP_CLAIM"; 37 | 38 | /** 39 | * usd pricing 40 | */ 41 | export const WRAPPED_BASE_COIN = "0x0d500b1d8e8ef31e21c99d1db9a6444d3adf1270"; 42 | //pricing supported stable coins 43 | export const STABLE_ONE_ADDRESS = "0xc2132d05d31c914a87c6611c10748aeb04b58e8f"; //usdt 44 | export const STABLE_TWO_ADDRESS = "0x2791bca1f2de4661ed88a30c99a7a9449aa84174"; //usdc 45 | //stable coins pairs 46 | export const STABLE_COIN_PAIR_ONE = 47 | "0xc9f93163c99695c6526b799ebca2207fdf7d61ad"; //[USDT_USDC_PAIR] 48 | //base currency pair 49 | export const BASE_COIN_PAIR = "0x75c23271661d9d143dcb617222bc4bec783eff34"; //[WETH_USDC_PAIR] 50 | -------------------------------------------------------------------------------- /src/mappings/constant-rinkeby.ts: -------------------------------------------------------------------------------- 1 | //kovan 2 | export const TYPE_VIRTUAL_POOL = "VIRTUAL"; 3 | export const TYPE_DVM_POOL = "DVM"; 4 | export const TYPE_DPP_POOL = "DPP"; 5 | export const TYPE_DSP_POOL = "DSP"; 6 | export const TYPE_GSP_POOL = "GSP"; 7 | export const TYPE_CLASSICAL_POOL = "CLASSICAL"; 8 | export const SOURCE_SMART_ROUTE = "SMART_ROUTE"; 9 | export const SOURCE_POOL_SWAP = "DODO_POOL"; 10 | export const DODOZooID = "dodoex-v2-rinkeby"; 11 | export const CHAIN_BASE_COIN_SYMBOL = "ETH"; 12 | export const CHAIN_BASE_COIN_NAME = "ethereum"; 13 | export const DIP3_TIMESTAMP = 1624442400; 14 | 15 | export const SMART_ROUTE_ADDRESSES: string[] = [ 16 | "0xba001e96af87bf9d8d0bda667067a9921fe6d294", 17 | ]; 18 | export const DVM_FACTORY_ADDRESS = "0x17dddefa0c82e0c850a4adac2afe3f1fe977a242"; 19 | export const DPP_FACTORY_ADDRESS = "0x510b49803e356c750f3a93ba5508c0ffd9f71bdd"; 20 | export const CLASSIC_FACTORY_ADDRESS = 21 | "0x168442fec1e1e782c8770185dbb8328b91dc45c0"; 22 | export const CROWDPOOLING_FACTORY_V2: string[] = [ 23 | "0x79e15fc9b4154d90424b588533ab277d30d573f4", 24 | ]; 25 | 26 | export const DVM_FACTORY_DEPLOY_BLOCK = 8732843; 27 | export const DPP_FACTORY_DEPLOY_BLOCK = 8732843; 28 | 29 | export const ADDRESS_ZERO = "0x0000000000000000000000000000000000000000"; 30 | export const BASE_COIN = "0xeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeee"; 31 | 32 | export const TRANSACTION_TYPE_SWAP = "SWAP"; 33 | export const TRANSACTION_TYPE_LP_ADD = "LP_ADD"; 34 | export const TRANSACTION_TYPE_LP_REMOVE = "LP_REMOVE"; 35 | export const TRANSACTION_TYPE_CP_BID = "CP_BID"; 36 | export const TRANSACTION_TYPE_CP_CANCEL = "CP_CANCEL"; 37 | export const TRANSACTION_TYPE_CP_CLAIM = "CP_CLAIM"; 38 | 39 | /** 40 | * usd pricing 41 | */ 42 | export const WRAPPED_BASE_COIN = "0xb26c0d8be2960c70641a95a9195be1f59ac83ac0"; 43 | //pricing supported stable coins 44 | export const STABLE_ONE_ADDRESS = "0x0adcbae18580120667f7ff6c6451a426b13c67b7"; //usdt 45 | export const STABLE_TWO_ADDRESS = "0xab0733588776b8881f7712f6abca98f510e6b63d"; //usdc 46 | //stable coins pairs 47 | export const STABLE_COIN_PAIR_ONE = 48 | "0xe8c1b7e0505c97c59ff2f12ebf91a8eaa59d4c73"; //[USDT_USDC_PAIR] 49 | //base currency pair 50 | export const BASE_COIN_PAIR = "0x75f5d66a7bbb9330a9067c0833ec9b3198b71666"; //[WETH_USDC_PAIR] 51 | -------------------------------------------------------------------------------- /src/mappings/constant-scroll-alpha.ts: -------------------------------------------------------------------------------- 1 | //kovan 2 | export const TYPE_VIRTUAL_POOL = "VIRTUAL"; 3 | export const TYPE_DVM_POOL = "DVM"; 4 | export const TYPE_DPP_POOL = "DPP"; 5 | export const TYPE_DSP_POOL = "DSP"; 6 | export const TYPE_GSP_POOL = "GSP"; 7 | export const TYPE_CLASSICAL_POOL = "CLASSICAL"; 8 | export const SOURCE_SMART_ROUTE = "SMART_ROUTE"; 9 | export const SOURCE_POOL_SWAP = "DODO_POOL"; 10 | export const DODOZooID = "dodoex-v2-scroll-alpha"; 11 | export const CHAIN_BASE_COIN_SYMBOL = "ETH"; 12 | export const CHAIN_BASE_COIN_NAME = "ethereum"; 13 | export const DIP3_TIMESTAMP = 1624442400; 14 | 15 | export const SMART_ROUTE_ADDRESSES: string[] = [ 16 | "0x5b622A373b485CB9BA283ECd6CE6689a8b8FdC05", 17 | ]; 18 | export const DVM_FACTORY_ADDRESS = "0x0b96b88B1941C3Df77b5A065dD3075fDB7986301"; 19 | export const DPP_FACTORY_ADDRESS = "0x19e374C28458a44F67D1524898907AfF9E537462"; 20 | export const CLASSIC_FACTORY_ADDRESS = 21 | "0x168442fec1e1e782c8770185dbb8328b91dc45c0"; 22 | export const CROWDPOOLING_FACTORY_V2: string[] = [ 23 | "0x79e15fc9b4154d90424b588533ab277d30d573f4", 24 | ]; 25 | 26 | export const DVM_FACTORY_DEPLOY_BLOCK = 2783342; 27 | export const DPP_FACTORY_DEPLOY_BLOCK = 2783350; 28 | 29 | export const ADDRESS_ZERO = "0x0000000000000000000000000000000000000000"; 30 | export const BASE_COIN = "0xeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeee"; 31 | 32 | export const TRANSACTION_TYPE_SWAP = "SWAP"; 33 | export const TRANSACTION_TYPE_LP_ADD = "LP_ADD"; 34 | export const TRANSACTION_TYPE_LP_REMOVE = "LP_REMOVE"; 35 | export const TRANSACTION_TYPE_CP_BID = "CP_BID"; 36 | export const TRANSACTION_TYPE_CP_CANCEL = "CP_CANCEL"; 37 | export const TRANSACTION_TYPE_CP_CLAIM = "CP_CLAIM"; 38 | 39 | /** 40 | * usd pricing 41 | */ 42 | export const WRAPPED_BASE_COIN = "0xb26c0d8be2960c70641a95a9195be1f59ac83ac0"; 43 | //pricing supported stable coins 44 | export const STABLE_ONE_ADDRESS = "0x0adcbae18580120667f7ff6c6451a426b13c67b7"; //usdt 45 | export const STABLE_TWO_ADDRESS = "0xab0733588776b8881f7712f6abca98f510e6b63d"; //usdc 46 | //stable coins pairs 47 | export const STABLE_COIN_PAIR_ONE = 48 | "0xe8c1b7e0505c97c59ff2f12ebf91a8eaa59d4c73"; //[USDT_USDC_PAIR] 49 | //base currency pair 50 | export const BASE_COIN_PAIR = "0x75f5d66a7bbb9330a9067c0833ec9b3198b71666"; //[WETH_USDC_PAIR] 51 | -------------------------------------------------------------------------------- /src/mappings/constant-scroll-sepolia.ts: -------------------------------------------------------------------------------- 1 | //kovan 2 | export const TYPE_VIRTUAL_POOL = "VIRTUAL"; 3 | export const TYPE_DVM_POOL = "DVM"; 4 | export const TYPE_DPP_POOL = "DPP"; 5 | export const TYPE_DSP_POOL = "DSP"; 6 | export const TYPE_GSP_POOL = "GSP"; 7 | export const TYPE_CLASSICAL_POOL = "CLASSICAL"; 8 | export const SOURCE_SMART_ROUTE = "SMART_ROUTE"; 9 | export const SOURCE_POOL_SWAP = "DODO_POOL"; 10 | export const DODOZooID = "dodoex-v2-scroll-sepolia"; 11 | export const CHAIN_BASE_COIN_SYMBOL = "ETH"; 12 | export const CHAIN_BASE_COIN_NAME = "ethereum"; 13 | export const DIP3_TIMESTAMP = 1624442400; 14 | 15 | export const SMART_ROUTE_ADDRESSES: string[] = [ 16 | "0x5b622A373b485CB9BA283ECd6CE6689a8b8FdC05", 17 | ]; 18 | export const DVM_FACTORY_ADDRESS = "0x0b96b88B1941C3Df77b5A065dD3075fDB7986301"; 19 | export const DPP_FACTORY_ADDRESS = "0x19e374C28458a44F67D1524898907AfF9E537462"; 20 | export const CLASSIC_FACTORY_ADDRESS = 21 | "0x168442fec1e1e782c8770185dbb8328b91dc45c0"; 22 | export const CROWDPOOLING_FACTORY_V2: string[] = [ 23 | "0x79e15fc9b4154d90424b588533ab277d30d573f4", 24 | ]; 25 | 26 | export const DVM_FACTORY_DEPLOY_BLOCK = 2783342; 27 | export const DPP_FACTORY_DEPLOY_BLOCK = 2783350; 28 | 29 | export const ADDRESS_ZERO = "0x0000000000000000000000000000000000000000"; 30 | export const BASE_COIN = "0xeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeee"; 31 | 32 | export const TRANSACTION_TYPE_SWAP = "SWAP"; 33 | export const TRANSACTION_TYPE_LP_ADD = "LP_ADD"; 34 | export const TRANSACTION_TYPE_LP_REMOVE = "LP_REMOVE"; 35 | export const TRANSACTION_TYPE_CP_BID = "CP_BID"; 36 | export const TRANSACTION_TYPE_CP_CANCEL = "CP_CANCEL"; 37 | export const TRANSACTION_TYPE_CP_CLAIM = "CP_CLAIM"; 38 | 39 | /** 40 | * usd pricing 41 | */ 42 | export const WRAPPED_BASE_COIN = "0xb26c0d8be2960c70641a95a9195be1f59ac83ac0"; 43 | //pricing supported stable coins 44 | export const STABLE_ONE_ADDRESS = "0x0adcbae18580120667f7ff6c6451a426b13c67b7"; //usdt 45 | export const STABLE_TWO_ADDRESS = "0xab0733588776b8881f7712f6abca98f510e6b63d"; //usdc 46 | //stable coins pairs 47 | export const STABLE_COIN_PAIR_ONE = 48 | "0xe8c1b7e0505c97c59ff2f12ebf91a8eaa59d4c73"; //[USDT_USDC_PAIR] 49 | //base currency pair 50 | export const BASE_COIN_PAIR = "0x75f5d66a7bbb9330a9067c0833ec9b3198b71666"; //[WETH_USDC_PAIR] 51 | -------------------------------------------------------------------------------- /src/mappings/constant-scroll.ts: -------------------------------------------------------------------------------- 1 | //kovan 2 | export const TYPE_VIRTUAL_POOL = "VIRTUAL"; 3 | export const TYPE_DVM_POOL = "DVM"; 4 | export const TYPE_DPP_POOL = "DPP"; 5 | export const TYPE_DSP_POOL = "DSP"; 6 | export const TYPE_GSP_POOL = "GSP"; 7 | export const TYPE_CLASSICAL_POOL = "CLASSICAL"; 8 | export const SOURCE_SMART_ROUTE = "SMART_ROUTE"; 9 | export const SOURCE_POOL_SWAP = "DODO_POOL"; 10 | export const DODOZooID = "dodoex-v2-scroll"; 11 | export const CHAIN_BASE_COIN_SYMBOL = "ETH"; 12 | export const CHAIN_BASE_COIN_NAME = "ethereum"; 13 | export const DIP3_TIMESTAMP = 1624442400; 14 | 15 | export const SMART_ROUTE_ADDRESSES: string[] = [ 16 | "0xe49781e6186214d88aACFd9eBc8cE40E3CDc066D", 17 | ]; 18 | export const DVM_FACTORY_ADDRESS = "0x5a0C840a7089aa222c4458b3BE0947fe5a5006DE"; 19 | export const DPP_FACTORY_ADDRESS = "0x31AC053c31a77055b2ae2d3899091C0A9c19cE3a"; 20 | export const CLASSIC_FACTORY_ADDRESS = 21 | "0x168442fec1e1e782c8770185dbb8328b91dc45c0"; 22 | export const CROWDPOOLING_FACTORY_V2: string[] = [ 23 | "0x4632e6EBd4a01eBF54739A9D71a62CEdb29E9183", 24 | ]; 25 | 26 | export const DVM_FACTORY_DEPLOY_BLOCK = 2783342; 27 | export const DPP_FACTORY_DEPLOY_BLOCK = 2783350; 28 | 29 | export const ADDRESS_ZERO = "0x0000000000000000000000000000000000000000"; 30 | export const BASE_COIN = "0xeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeee"; 31 | 32 | export const TRANSACTION_TYPE_SWAP = "SWAP"; 33 | export const TRANSACTION_TYPE_LP_ADD = "LP_ADD"; 34 | export const TRANSACTION_TYPE_LP_REMOVE = "LP_REMOVE"; 35 | export const TRANSACTION_TYPE_CP_BID = "CP_BID"; 36 | export const TRANSACTION_TYPE_CP_CANCEL = "CP_CANCEL"; 37 | export const TRANSACTION_TYPE_CP_CLAIM = "CP_CLAIM"; 38 | 39 | /** 40 | * usd pricing 41 | */ 42 | export const WRAPPED_BASE_COIN = "0xb26c0d8be2960c70641a95a9195be1f59ac83ac0"; 43 | //pricing supported stable coins 44 | export const STABLE_ONE_ADDRESS = "0x0adcbae18580120667f7ff6c6451a426b13c67b7"; //usdt 45 | export const STABLE_TWO_ADDRESS = "0xab0733588776b8881f7712f6abca98f510e6b63d"; //usdc 46 | //stable coins pairs 47 | export const STABLE_COIN_PAIR_ONE = 48 | "0xe8c1b7e0505c97c59ff2f12ebf91a8eaa59d4c73"; //[USDT_USDC_PAIR] 49 | //base currency pair 50 | export const BASE_COIN_PAIR = "0x75f5d66a7bbb9330a9067c0833ec9b3198b71666"; //[WETH_USDC_PAIR] 51 | -------------------------------------------------------------------------------- /src/mappings/constant-sepolia.ts: -------------------------------------------------------------------------------- 1 | //kovan 2 | export const TYPE_VIRTUAL_POOL = "VIRTUAL"; 3 | export const TYPE_DVM_POOL = "DVM"; 4 | export const TYPE_DPP_POOL = "DPP"; 5 | export const TYPE_DSP_POOL = "DSP"; 6 | export const TYPE_GSP_POOL = "GSP"; 7 | export const TYPE_CLASSICAL_POOL = "CLASSICAL"; 8 | export const SOURCE_SMART_ROUTE = "SMART_ROUTE"; 9 | export const SOURCE_POOL_SWAP = "DODO_POOL"; 10 | export const DODOZooID = "dodoex-v2-sepolia"; 11 | export const CHAIN_BASE_COIN_SYMBOL = "ETH"; 12 | export const CHAIN_BASE_COIN_NAME = "ethereum"; 13 | export const DIP3_TIMESTAMP = 1624442400; 14 | 15 | export const SMART_ROUTE_ADDRESSES: string[] = [ 16 | "0x6292e8f7647b3b9dDf5795b1Fb77D0187e30E0F9", 17 | ]; 18 | export const DVM_FACTORY_ADDRESS = "0x2F86652dAEF5f1728c54191C955F065Ec3C188c7"; 19 | export const DPP_FACTORY_ADDRESS = "0x0B1467f71c082D8d410aF4376C685D9A6893cF36"; 20 | export const CLASSIC_FACTORY_ADDRESS = 21 | "0xCDA4a6cc5997002B87f28D46852F9F0aA0f3c897"; 22 | export const CROWDPOOLING_FACTORY_V2: string[] = [ 23 | "0xCDA4a6cc5997002B87f28D46852F9F0aA0f3c897", 24 | ]; 25 | 26 | export const DVM_FACTORY_DEPLOY_BLOCK = 58; 27 | export const DPP_FACTORY_DEPLOY_BLOCK = 58; 28 | 29 | export const ADDRESS_ZERO = "0x0000000000000000000000000000000000000000"; 30 | export const BASE_COIN = "0xeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeee"; 31 | 32 | export const TRANSACTION_TYPE_SWAP = "SWAP"; 33 | export const TRANSACTION_TYPE_LP_ADD = "LP_ADD"; 34 | export const TRANSACTION_TYPE_LP_REMOVE = "LP_REMOVE"; 35 | export const TRANSACTION_TYPE_CP_BID = "CP_BID"; 36 | export const TRANSACTION_TYPE_CP_CANCEL = "CP_CANCEL"; 37 | export const TRANSACTION_TYPE_CP_CLAIM = "CP_CLAIM"; 38 | 39 | /** 40 | * usd pricing 41 | */ 42 | export const WRAPPED_BASE_COIN = "0x7b07164ecfaf0f0d85dfc062bc205a4674c75aa0"; 43 | //pricing supported stable coins 44 | export const STABLE_ONE_ADDRESS = "0xdbc836c3cb158197e96228fc5b205f91b65e6779"; //usdt 45 | export const STABLE_TWO_ADDRESS = "0x2442e080c0343d8ab683bf5044303082f66f0a7e"; //usdc 46 | //stable coins pairs 47 | export const STABLE_COIN_PAIR_ONE = 48 | "0xc5135499e4af076949ecdb0a51ace5d36aaa259c"; //[USDT_USDC_PAIR] 49 | //base currency pair 50 | export const BASE_COIN_PAIR = "0xf444ae517c06c607ae0953501701bd19d70fc251"; //[WETH_USDC_PAIR] 51 | -------------------------------------------------------------------------------- /src/mappings/constant-tokb.ts: -------------------------------------------------------------------------------- 1 | //kovan 2 | export const TYPE_VIRTUAL_POOL = "VIRTUAL"; 3 | export const TYPE_DVM_POOL = "DVM"; 4 | export const TYPE_DPP_POOL = "DPP"; 5 | export const TYPE_DSP_POOL = "DSP"; 6 | export const TYPE_GSP_POOL = "GSP"; 7 | export const TYPE_CLASSICAL_POOL = "CLASSICAL"; 8 | export const SOURCE_SMART_ROUTE = "SMART_ROUTE"; 9 | export const SOURCE_POOL_SWAP = "DODO_POOL"; 10 | export const DODOZooID = "dodoex-v2-okb-x1-test"; 11 | export const CHAIN_BASE_COIN_SYMBOL = "ETH"; 12 | export const CHAIN_BASE_COIN_NAME = "ethereum"; 13 | export const DIP3_TIMESTAMP = 1624442400; 14 | 15 | export const SMART_ROUTE_ADDRESSES: string[] = [ 16 | "0x5b622A373b485CB9BA283ECd6CE6689a8b8FdC05", 17 | ]; 18 | export const DVM_FACTORY_ADDRESS = "0xFaFC924BF0F70BdF4a722231622f559b94e53902"; 19 | export const DPP_FACTORY_ADDRESS = "0xb546Add98c71D97Bb65De60B91021617AcD1262C"; 20 | export const CLASSIC_FACTORY_ADDRESS = 21 | "0x8dD0Fea5FA2f7df535F87f312641Cc15d8B151BA"; 22 | export const CROWDPOOLING_FACTORY_V2: string[] = [ 23 | "0x8dD0Fea5FA2f7df535F87f312641Cc15d8B151BA", 24 | ]; 25 | 26 | export const DVM_FACTORY_DEPLOY_BLOCK = 300062; 27 | export const DPP_FACTORY_DEPLOY_BLOCK = 300062; 28 | 29 | export const ADDRESS_ZERO = "0x0000000000000000000000000000000000000000"; 30 | export const BASE_COIN = "0xeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeee"; 31 | 32 | export const TRANSACTION_TYPE_SWAP = "SWAP"; 33 | export const TRANSACTION_TYPE_LP_ADD = "LP_ADD"; 34 | export const TRANSACTION_TYPE_LP_REMOVE = "LP_REMOVE"; 35 | export const TRANSACTION_TYPE_CP_BID = "CP_BID"; 36 | export const TRANSACTION_TYPE_CP_CANCEL = "CP_CANCEL"; 37 | export const TRANSACTION_TYPE_CP_CLAIM = "CP_CLAIM"; 38 | 39 | /** 40 | * usd pricing 41 | */ 42 | export const WRAPPED_BASE_COIN = "0xb26c0d8be2960c70641a95a9195be1f59ac83ac0"; 43 | //pricing supported stable coins 44 | export const STABLE_ONE_ADDRESS = "0x0adcbae18580120667f7ff6c6451a426b13c67b7"; //usdt 45 | export const STABLE_TWO_ADDRESS = "0xab0733588776b8881f7712f6abca98f510e6b63d"; //usdc 46 | //stable coins pairs 47 | export const STABLE_COIN_PAIR_ONE = 48 | "0xe8c1b7e0505c97c59ff2f12ebf91a8eaa59d4c73"; //[USDT_USDC_PAIR] 49 | //base currency pair 50 | export const BASE_COIN_PAIR = "0x75f5d66a7bbb9330a9067c0833ec9b3198b71666"; //[WETH_USDC_PAIR] 51 | -------------------------------------------------------------------------------- /src/mappings/constant-zircuit-testnet.ts: -------------------------------------------------------------------------------- 1 | //kovan 2 | export const TYPE_VIRTUAL_POOL = "VIRTUAL"; 3 | export const TYPE_DVM_POOL = "DVM"; 4 | export const TYPE_DPP_POOL = "DPP"; 5 | export const TYPE_DSP_POOL = "DSP"; 6 | export const TYPE_GSP_POOL = "GSP"; 7 | export const TYPE_CLASSICAL_POOL = "CLASSICAL"; 8 | export const SOURCE_SMART_ROUTE = "SMART_ROUTE"; 9 | export const SOURCE_POOL_SWAP = "DODO_POOL"; 10 | export const DODOZooID = "dodoex-v2-zircuit-testnet"; 11 | export const CHAIN_BASE_COIN_SYMBOL = "ETH"; 12 | export const CHAIN_BASE_COIN_NAME = "ethereum"; 13 | export const DIP3_TIMESTAMP = 1624442400; 14 | 15 | export const SMART_ROUTE_ADDRESSES: string[] = [ 16 | "0x3b0c6c0CE667844e742Ce0Ca533EaA2b6f422AA8", 17 | ]; 18 | export const DVM_FACTORY_ADDRESS = "0x7Ad992fcebd899ddbEF7f031dCF96f382b81ECea"; 19 | export const DPP_FACTORY_ADDRESS = "0x5e132c0ABB9e4E5f1471eF6d1C9740c276Fe520e"; 20 | export const CLASSIC_FACTORY_ADDRESS = 21 | "0xB3d4823e02A9AB9A9A0Cc1636E776c360B67bED1"; 22 | export const CROWDPOOLING_FACTORY_V2: string[] = [ 23 | "0xB3d4823e02A9AB9A9A0Cc1636E776c360B67bED1", 24 | ]; 25 | 26 | export const DVM_FACTORY_DEPLOY_BLOCK = 58; 27 | export const DPP_FACTORY_DEPLOY_BLOCK = 58; 28 | 29 | export const ADDRESS_ZERO = "0x0000000000000000000000000000000000000000"; 30 | export const BASE_COIN = "0xeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeee"; 31 | 32 | export const TRANSACTION_TYPE_SWAP = "SWAP"; 33 | export const TRANSACTION_TYPE_LP_ADD = "LP_ADD"; 34 | export const TRANSACTION_TYPE_LP_REMOVE = "LP_REMOVE"; 35 | export const TRANSACTION_TYPE_CP_BID = "CP_BID"; 36 | export const TRANSACTION_TYPE_CP_CANCEL = "CP_CANCEL"; 37 | export const TRANSACTION_TYPE_CP_CLAIM = "CP_CLAIM"; 38 | 39 | /** 40 | * usd pricing 41 | */ 42 | export const WRAPPED_BASE_COIN = "0x3a64Ec3606FF7310E8fAd6FcC008e39705fB496d"; 43 | //pricing supported stable coins 44 | export const STABLE_ONE_ADDRESS = "0xb95ed7e958e196688984951f41ac2888f4b10ab9"; //usdt 45 | export const STABLE_TWO_ADDRESS = "0x46afe01d758a46d64c7d8e0791314d5db3e2e683"; //usdc 46 | //stable coins pairs 47 | export const STABLE_COIN_PAIR_ONE = 48 | "0xe8c1b7e0505c97c59ff2f12ebf91a8eaa59d4c73"; //[USDT_USDC_PAIR] 49 | //base currency pair 50 | export const BASE_COIN_PAIR = "0x75f5d66a7bbb9330a9067c0833ec9b3198b71666"; //[WETH_USDC_PAIR] 51 | -------------------------------------------------------------------------------- /src/mappings/constant-zircuit.ts: -------------------------------------------------------------------------------- 1 | //kovan 2 | export const TYPE_VIRTUAL_POOL = "VIRTUAL"; 3 | export const TYPE_DVM_POOL = "DVM"; 4 | export const TYPE_DPP_POOL = "DPP"; 5 | export const TYPE_DSP_POOL = "DSP"; 6 | export const TYPE_GSP_POOL = "GSP"; 7 | export const TYPE_CLASSICAL_POOL = "CLASSICAL"; 8 | export const SOURCE_SMART_ROUTE = "SMART_ROUTE"; 9 | export const SOURCE_POOL_SWAP = "DODO_POOL"; 10 | export const DODOZooID = "dodoex-v2-zircuit"; 11 | export const CHAIN_BASE_COIN_SYMBOL = "ETH"; 12 | export const CHAIN_BASE_COIN_NAME = "ethereum"; 13 | export const DIP3_TIMESTAMP = 1624442400; 14 | 15 | export const SMART_ROUTE_ADDRESSES: string[] = [ 16 | "0x5e132c0ABB9e4E5f1471eF6d1C9740c276Fe520e", 17 | ]; 18 | export const DVM_FACTORY_ADDRESS = "0xA909314363840f7c28b8EC314028e21722dd8Cb6"; 19 | export const DPP_FACTORY_ADDRESS = "0xb770C37F3A9eC6f25b791D9c791aDE09B0fb1AB8"; 20 | export const CLASSIC_FACTORY_ADDRESS = 21 | "0x40b4030129FCFE660B4ecF35354e027260343049"; 22 | export const CROWDPOOLING_FACTORY_V2: string[] = [ 23 | "0x40b4030129FCFE660B4ecF35354e027260343049", 24 | ]; 25 | 26 | export const DVM_FACTORY_DEPLOY_BLOCK = 58; 27 | export const DPP_FACTORY_DEPLOY_BLOCK = 58; 28 | 29 | export const ADDRESS_ZERO = "0x0000000000000000000000000000000000000000"; 30 | export const BASE_COIN = "0xeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeee"; 31 | 32 | export const TRANSACTION_TYPE_SWAP = "SWAP"; 33 | export const TRANSACTION_TYPE_LP_ADD = "LP_ADD"; 34 | export const TRANSACTION_TYPE_LP_REMOVE = "LP_REMOVE"; 35 | export const TRANSACTION_TYPE_CP_BID = "CP_BID"; 36 | export const TRANSACTION_TYPE_CP_CANCEL = "CP_CANCEL"; 37 | export const TRANSACTION_TYPE_CP_CLAIM = "CP_CLAIM"; 38 | 39 | /** 40 | * usd pricing 41 | */ 42 | export const WRAPPED_BASE_COIN = "0x4200000000000000000000000000000000000006"; 43 | //pricing supported stable coins 44 | export const STABLE_ONE_ADDRESS = "0xb95ed7e958e196688984951f41ac2888f4b10ab9"; //usdt 45 | export const STABLE_TWO_ADDRESS = "0x46afe01d758a46d64c7d8e0791314d5db3e2e683"; //usdc 46 | //stable coins pairs 47 | export const STABLE_COIN_PAIR_ONE = 48 | "0xe8c1b7e0505c97c59ff2f12ebf91a8eaa59d4c73"; //[USDT_USDC_PAIR] 49 | //base currency pair 50 | export const BASE_COIN_PAIR = "0x75f5d66a7bbb9330a9067c0833ec9b3198b71666"; //[WETH_USDC_PAIR] 51 | -------------------------------------------------------------------------------- /src/mappings/constant.ts: -------------------------------------------------------------------------------- 1 | //mainnet 2 | export const TYPE_VIRTUAL_POOL = "VIRTUAL"; 3 | export const TYPE_DVM_POOL = "DVM"; 4 | export const TYPE_DPP_POOL = "DPP"; 5 | export const TYPE_DSP_POOL = "DSP"; 6 | export const TYPE_GSP_POOL = "GSP"; 7 | export const TYPE_CLASSICAL_POOL = "CLASSICAL"; 8 | export const SOURCE_SMART_ROUTE = "SMART_ROUTE"; 9 | export const SOURCE_POOL_SWAP = "DODO_POOL"; 10 | export const DODOV2Proxy02 = "0x45894c062e6f4e58b257e0826675355305dfef0d"; 11 | export const DIP3_TIMESTAMP = 100; 12 | 13 | export const DODOZooID = "dodoex-v2-arbitrum"; 14 | export const CHAIN_BASE_COIN_SYMBOL = "ETH"; 15 | export const CHAIN_BASE_COIN_NAME = "ether"; 16 | 17 | export const SMART_ROUTE_ADDRESSES: string[] = [ 18 | "0x45894c062e6f4e58b257e0826675355305dfef0d", 19 | ]; 20 | export const DVM_FACTORY_ADDRESS = "0xbab9f4ff4a19a0e8eebc56b06750253228ffac6e"; 21 | export const DPP_FACTORY_ADDRESS = "0xe55154d09265b18ac7cdac6e646672a5460389a1"; 22 | export const CLASSIC_FACTORY_ADDRESS = 23 | "0x357c5e9cfa8b834edcef7c7aabd8f9db09119d11"; //dodo zoo 24 | 25 | export const ADDRESS_ZERO = "0x0000000000000000000000000000000000000000"; 26 | export const BASE_COIN = "0xeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeee"; 27 | 28 | export const TRANSACTION_TYPE_SWAP = "SWAP"; 29 | export const TRANSACTION_TYPE_LP_ADD = "LP_ADD"; 30 | export const TRANSACTION_TYPE_LP_REMOVE = "LP_REMOVE"; 31 | export const TRANSACTION_TYPE_CP_BID = "CP_BID"; 32 | export const TRANSACTION_TYPE_CP_CANCEL = "CP_CANCEL"; 33 | export const TRANSACTION_TYPE_CP_CLAIM = "CP_CLAIM"; 34 | 35 | /** 36 | * usd pricing 37 | */ 38 | export const WRAPPED_BASE_COIN = "0x82af49447d8a07e3bd95bd0d56f35241523fbab1"; 39 | //pricing supported stable coins 40 | export const STABLE_ONE_ADDRESS = "0xfd086bc7cd5c481dcc9c85ebe478a1c0b69fcbb9"; //usdt 41 | export const STABLE_TWO_ADDRESS = "0xff970a61a04b1ca14834a43f5de4533ebddb5cc8"; //usdc 42 | //stable coins pairs 43 | export const STABLE_COIN_PAIR_ONE = 44 | "0xe4b2dfc82977dd2dce7e8d37895a6a8f50cbb4fb"; //[USDT_USDC_PAIR] 45 | //base currency pair 46 | export const BASE_COIN_PAIR = "0xfe176a2b1e1f67250d2903b8d25f56c0dabcd6b2"; //[WETH_USDC_PAIR] 47 | export const CROWDPOOLING_FACTORY_V2: string[] = [ 48 | "0x9a8c0e8b27fff5d00402733ca67432b6d64faff4", 49 | ]; 50 | -------------------------------------------------------------------------------- /src/mappings/dodoex/incentive.ts: -------------------------------------------------------------------------------- 1 | import { 2 | IncentiveRewardHistory, 3 | TradingIncentive 4 | } from "../../types/dodoex/schema" 5 | import { 6 | createUser, 7 | ZERO_BI, 8 | ZERO_BD, 9 | BI_18, 10 | ONE_BI, 11 | convertTokenToDecimal, 12 | } from "./helpers" 13 | 14 | import {Incentive} from "../../types/dodoex/DODOIncentive/DODOIncentive" 15 | import {dataSource} from "@graphprotocol/graph-ts"; 16 | 17 | export function handleIncentive(event: Incentive): void { 18 | let user = createUser(event.params.user,event); 19 | let incentiveRewardHistoryID = event.transaction.hash.toHexString(); 20 | let incentiveRewardHistory = IncentiveRewardHistory.load(incentiveRewardHistoryID); 21 | let amount = convertTokenToDecimal(event.params.reward, BI_18); 22 | 23 | if (incentiveRewardHistory == null) { 24 | incentiveRewardHistory = new IncentiveRewardHistory(incentiveRewardHistoryID); 25 | 26 | incentiveRewardHistory.amount = ZERO_BD; 27 | incentiveRewardHistory.timestamp = event.block.timestamp; 28 | incentiveRewardHistory.user = user.id; 29 | incentiveRewardHistory.times = ZERO_BI; 30 | } 31 | incentiveRewardHistory.times = incentiveRewardHistory.times.plus(ONE_BI); 32 | incentiveRewardHistory.amount = incentiveRewardHistory.amount.plus(amount); 33 | 34 | let tradingIncentive = TradingIncentive.load(dataSource.address().toHexString()); 35 | if (tradingIncentive == null) { 36 | tradingIncentive = new TradingIncentive(dataSource.address().toHexString()) 37 | tradingIncentive.totalUser = ONE_BI; 38 | tradingIncentive.totalAmount = amount; 39 | } else { 40 | if (user.tradingRewardRecieved.equals(ZERO_BD)) { 41 | tradingIncentive.totalUser = tradingIncentive.totalUser.plus(ONE_BI); 42 | } 43 | tradingIncentive.totalAmount = tradingIncentive.totalAmount.plus(amount); 44 | } 45 | 46 | incentiveRewardHistory.totalAmount = tradingIncentive.totalAmount; 47 | incentiveRewardHistory.totalUser = tradingIncentive.totalUser; 48 | user.tradingRewardRecieved = user.tradingRewardRecieved.plus(amount); 49 | 50 | //更新时间戳 51 | tradingIncentive.updatedAt = event.block.timestamp; 52 | incentiveRewardHistory.updatedAt = event.block.timestamp; 53 | user.updatedAt = event.block.timestamp; 54 | 55 | tradingIncentive.save(); 56 | incentiveRewardHistory.save(); 57 | user.save(); 58 | } 59 | -------------------------------------------------------------------------------- /src/mappings/dodoex/lpToken.ts: -------------------------------------------------------------------------------- 1 | import {Transfer} from "../../types/dodoex/templates/DVM/DVM"; 2 | import {LiquidityPosition, LpToken, Pair} from "../../types/dodoex/schema"; 3 | import {convertTokenToDecimal, createUser, ZERO_BD, ZERO_BI} from "./helpers"; 4 | import {ADDRESS_ZERO} from "../constant"; 5 | import {log, BigInt, BigDecimal, Address, ethereum,dataSource} from '@graphprotocol/graph-ts' 6 | 7 | //lptoken handler for classical 8 | export function handleTransfer(event: Transfer): void{ 9 | if (event.params.to.toHexString() == ADDRESS_ZERO || event.params.from.toHexString() == ADDRESS_ZERO) { 10 | return; 11 | } 12 | let fromUser = createUser(event.params.from,event); 13 | let toUser = createUser(event.params.to,event); 14 | let lpToken = LpToken.load(event.address.toHexString()) as LpToken; 15 | let dealedAmount = convertTokenToDecimal(event.params.amount, lpToken.decimals); 16 | 17 | { 18 | let toUserLiquidityPositionID = toUser.id.concat("-").concat(lpToken.id); 19 | let position = LiquidityPosition.load(toUserLiquidityPositionID); 20 | if (position == null) { 21 | position = new LiquidityPosition(toUserLiquidityPositionID); 22 | position.pair = lpToken.pair; 23 | position.user = event.params.to.toHexString(); 24 | position.liquidityTokenBalance = ZERO_BD; 25 | position.lpToken = lpToken.id; 26 | position.lastTxTime = ZERO_BI; 27 | position.liquidityTokenInMining = ZERO_BD; 28 | } 29 | position.liquidityTokenBalance = position.liquidityTokenBalance.plus(dealedAmount); 30 | position.updatedAt = event.block.timestamp; 31 | position.save(); 32 | } 33 | 34 | { 35 | let fromUserLiquidityPositionID = fromUser.id.concat("-").concat(lpToken.id); 36 | let position = LiquidityPosition.load(fromUserLiquidityPositionID); 37 | if (position == null) { 38 | position = new LiquidityPosition(fromUserLiquidityPositionID); 39 | position.pair = lpToken.pair; 40 | position.user = event.params.to.toHexString(); 41 | position.liquidityTokenBalance = ZERO_BD; 42 | position.lpToken = lpToken.id; 43 | position.lastTxTime = ZERO_BI; 44 | position.liquidityTokenInMining = ZERO_BD; 45 | } 46 | position.liquidityTokenBalance = position.liquidityTokenBalance.minus(dealedAmount); 47 | position.updatedAt = event.block.timestamp; 48 | position.save(); 49 | } 50 | 51 | } 52 | -------------------------------------------------------------------------------- /src/mappings/dodoex/transaction.ts: -------------------------------------------------------------------------------- 1 | import { Transaction, Token } from "../../types/dodoex/schema"; 2 | import { Address, BigDecimal, ethereum } from "@graphprotocol/graph-ts"; 3 | import { increaseTxCount } from "./dayUpdates"; 4 | import { ZERO_BD } from "./helpers"; 5 | import { ADDRESS_ZERO } from "../constant"; 6 | 7 | export function addTransaction( 8 | event: ethereum.Event, 9 | sender: string, 10 | type: string 11 | ): Transaction { 12 | let id = event.transaction.hash 13 | .toHexString() 14 | .concat("-") 15 | .concat(event.logIndex.toString()); 16 | let transaction = Transaction.load(id); 17 | if (transaction == null) { 18 | increaseTxCount(event); 19 | transaction = new Transaction(id); 20 | transaction.from = event.transaction.from.toHexString(); 21 | if (event.transaction.to) 22 | transaction.to = (event.transaction.to as Address).toHexString(); 23 | transaction.sender = sender; 24 | transaction.address = event.address; 25 | transaction.type = type; 26 | transaction.tokens = []; 27 | transaction.volumeUSD = ZERO_BD; 28 | transaction.timestamp = event.block.timestamp; 29 | } else { 30 | transaction.sender = transaction.sender.concat("-").concat(sender); 31 | transaction.type = transaction.type.concat("-").concat(type); 32 | } 33 | transaction.updatedAt = event.block.timestamp; 34 | transaction.save(); 35 | return transaction; 36 | } 37 | 38 | export function addToken(transaction: Transaction, token: Token): void { 39 | if (transaction != null && transaction.tokens != null) { 40 | (transaction.tokens as string[]).push(token.id); 41 | transaction.save(); 42 | } 43 | } 44 | 45 | export function addVolume( 46 | transaction: Transaction, 47 | volumeUSD: BigDecimal 48 | ): void { 49 | if (transaction != null) { 50 | transaction.volumeUSD = transaction.volumeUSD.plus(volumeUSD); 51 | transaction.save(); 52 | } 53 | } 54 | 55 | export function replaceVolume( 56 | transaction: Transaction, 57 | volumeUSD: BigDecimal 58 | ): void { 59 | if (transaction != null) { 60 | transaction.volumeUSD = volumeUSD; 61 | transaction.save(); 62 | } 63 | } 64 | -------------------------------------------------------------------------------- /src/mappings/dpoint/factory.ts: -------------------------------------------------------------------------------- 1 | import { CreateVault as CreateVaultEvent } from "../../types/dpoint/LockedTokenVaultFactory/LockedTokenVaultFactory"; 2 | import { LockedTokenVault as LockedTokenVaultTemplate } from "../../types/dpoint/templates"; 3 | 4 | export function handleCreateVault(event: CreateVaultEvent): void { 5 | LockedTokenVaultTemplate.create(event.params.vault); 6 | } -------------------------------------------------------------------------------- /src/mappings/dpoint/index.ts: -------------------------------------------------------------------------------- 1 | import { Address, BigInt, ethereum, log } from "@graphprotocol/graph-ts"; 2 | import { ERC20 } from "../../types/dpoint/LockedTokenVaultFactory/ERC20"; 3 | import { Claimed, Token } from "../../types/dpoint/schema"; 4 | import { Claim as ClaimEvent, LockedTokenVault } from "../../types/dpoint/templates/LockedTokenVault/LockedTokenVault"; 5 | 6 | export function handleClaim(event: ClaimEvent): void { 7 | let entity = new Claimed( 8 | event.transaction.hash.toHexString().concat(event.logIndex.toString()) 9 | ); 10 | entity.hash = event.transaction.hash.toHexString(); 11 | entity.logIndex = event.logIndex.toI32(); 12 | entity.blockNumber = event.block.number; 13 | entity.timestamp = event.block.timestamp; 14 | entity.account = event.params.holder; 15 | entity.amount = event.params.amount; 16 | entity.originAmount = event.params.origin; 17 | entity.claimedAmount = event.params.claimed; 18 | entity.address = event.address; 19 | 20 | let lockedTokenVault = LockedTokenVault.bind(event.address); 21 | let tokenAddress = lockedTokenVault.try__TOKEN_(); 22 | if (tokenAddress.reverted) { 23 | log.info("lockedTokenVault.try__TOKEN_ reverted: {}", [entity.id]); 24 | } 25 | let token = createToken(tokenAddress.value, event); 26 | entity.token = token.id; 27 | 28 | let remainingRatio = lockedTokenVault.try_getRemainingRatio(event.block.timestamp); 29 | if (remainingRatio.reverted) { 30 | log.info("lockedTokenVault.try_getRemainingRatio reverted: {}", [entity.id]); 31 | } 32 | entity.remainingRatio = remainingRatio.value; 33 | 34 | entity.updatedAt = event.block.timestamp; 35 | entity.save(); 36 | } 37 | 38 | function createToken(address: Address, event: ethereum.Event): Token { 39 | let token = Token.load(address.toHexString()); 40 | if (token == null) { 41 | token = new Token(address.toHexString()); 42 | let erc20 = ERC20.bind(address); 43 | token.name = erc20.name(); 44 | token.symbol = erc20.symbol(); 45 | token.decimals = BigInt.fromI32(erc20.decimals()); 46 | let totalSupplyResult = erc20.try_totalSupply(); 47 | if (totalSupplyResult.reverted) { 48 | log.error("ERC20.try_totalSupply reverted. address: {}", [ 49 | address.toHexString(), 50 | ]); 51 | token.totalSupply = BigInt.fromI32(0); 52 | } else { 53 | token.totalSupply = totalSupplyResult.value; 54 | } 55 | token.updatedAt = event.block.timestamp; 56 | token.save(); 57 | } 58 | return token as Token; 59 | } -------------------------------------------------------------------------------- /src/mappings/merkle-airdrop/index.ts: -------------------------------------------------------------------------------- 1 | import { Address, ethereum, log, BigInt } from "@graphprotocol/graph-ts"; 2 | import { 3 | Claimed as ClaimedEvent, 4 | MerkleDistributor, 5 | } from "../../types/merkle/MerkleDistributor/MerkleDistributor"; 6 | import { ERC20 } from "../../types/merkle/MerkleDistributor/ERC20"; 7 | import { Claimed, Token } from "../../types/merkle/schema"; 8 | 9 | export function handleClaimed(event: ClaimedEvent): void { 10 | let entity = new Claimed( 11 | event.transaction.hash.toHexString().concat(event.logIndex.toString()) 12 | ); 13 | entity.hash = event.transaction.hash.toHexString(); 14 | entity.logIndex = event.logIndex.toI32(); 15 | entity.blockNumber = event.block.number; 16 | entity.timestamp = event.block.timestamp; 17 | entity.account = event.params.account; 18 | entity.amount = event.params.amount; 19 | entity.index = event.params.index; 20 | entity.address = event.address; 21 | 22 | let merkleDistributor = MerkleDistributor.bind(event.address); 23 | let tokenAddress = merkleDistributor.try_token(); 24 | if (tokenAddress.reverted) { 25 | log.info("merkleDistributor.try_token reverted: {}", [entity.id]); 26 | } 27 | let token = createToken(tokenAddress.value, event); 28 | entity.token = token.id; 29 | entity.updatedAt = event.block.timestamp; 30 | entity.save(); 31 | } 32 | 33 | function createToken(address: Address, event: ethereum.Event): Token { 34 | let token = Token.load(address.toHexString()); 35 | if (token == null) { 36 | token = new Token(address.toHexString()); 37 | let erc20 = ERC20.bind(address); 38 | token.name = erc20.name(); 39 | token.symbol = erc20.symbol(); 40 | token.decimals = BigInt.fromI32(erc20.decimals()); 41 | let totalSupplyResult = erc20.try_totalSupply(); 42 | if (totalSupplyResult.reverted) { 43 | log.error("ERC20.try_totalSupply reverted. address: {}", [ 44 | address.toHexString(), 45 | ]); 46 | token.totalSupply = BigInt.fromI32(0); 47 | } else { 48 | token.totalSupply = totalSupplyResult.value; 49 | } 50 | token.updatedAt = event.block.timestamp; 51 | token.save(); 52 | } 53 | return token as Token; 54 | } 55 | -------------------------------------------------------------------------------- /src/mappings/mine/helper.ts: -------------------------------------------------------------------------------- 1 | import {ERC20MineV3, ERC20MineV3__rewardTokenInfosResult} from "../../types/mine/DODOMineV3Proxy/ERC20MineV3" 2 | import {Address, BigInt} from "@graphprotocol/graph-ts" 3 | 4 | export function getRewardNum(address: Address): BigInt { 5 | let contract = ERC20MineV3.bind(address); 6 | let num = contract.getRewardNum(); 7 | return num; 8 | } 9 | 10 | export function rewardTokenInfos(address: Address, index: BigInt): ERC20MineV3__rewardTokenInfosResult { 11 | let contract = ERC20MineV3.bind(address); 12 | let rewardTokenInfosResult = contract.rewardTokenInfos(index); 13 | return rewardTokenInfosResult as ERC20MineV3__rewardTokenInfosResult; 14 | } 15 | 16 | export function getIdByRewardToken(address: Address, token: Address): BigInt { 17 | let contract = ERC20MineV3.bind(address); 18 | let ID = contract.getIdByRewardToken(token); 19 | return ID; 20 | } 21 | 22 | export function getToken(address: Address): Address { 23 | let contract = ERC20MineV3.bind(address); 24 | let token = contract._TOKEN_(); 25 | return token; 26 | } 27 | -------------------------------------------------------------------------------- /src/mappings/mine/registry.ts: -------------------------------------------------------------------------------- 1 | import {MinePool, RewardDetail} from "../../types/mine/schema" 2 | import {NewMineV3} from "../../types/mine/DODOMineV3Registry/DODOMineV3Registry" 3 | 4 | export function handleNewMineV3(event: NewMineV3): void { 5 | let minePool = MinePool.load(event.params.mine.toHexString()); 6 | 7 | if (minePool == null) { 8 | minePool = new MinePool(event.params.mine.toHexString()); 9 | } 10 | minePool.pool = event.params.mine; 11 | minePool.isLpToken = event.params.isLpToken; 12 | minePool.updatedAt = event.block.timestamp; 13 | minePool.save(); 14 | } 15 | -------------------------------------------------------------------------------- /src/mappings/nft/buyout/erc721.ts: -------------------------------------------------------------------------------- 1 | import {Nft, Fragment, User, UserNft} from "../../../types/nft/schema"; 2 | import {Address} from "@graphprotocol/graph-ts"; 3 | import {Transfer} from "../../../types/nft/DODONFT/DODONFT" 4 | import {DODONFTMint, DODONFTBurn,DODONFT} from "../../../types/nft/DODONFT/DODONFT" 5 | import {createUser, ZERO_BI, ONE_BI, createAndGetNFT, ADDRESS_ZERO} from "../helpers"; 6 | 7 | export function handleTransfer(event: Transfer): void { 8 | let fromUser = createUser(event.params.from,event); 9 | let toUser = createUser(event.params.to,event); 10 | let nft = createAndGetNFT(event.address,event.params.tokenId,event); 11 | nft.type = "721"; 12 | 13 | let fromUserNftId = event.params.from.toHexString().concat("-").concat(event.address.toHexString()).concat(event.params.tokenId.toString()); 14 | let toUserNftId = event.params.to.toHexString().concat("-").concat(event.address.toHexString()).concat(event.params.tokenId.toString()); 15 | let fromUserNft = UserNft.load(fromUserNftId); 16 | let toUserNft = UserNft.load(toUserNftId); 17 | 18 | if (fromUserNft == null) { 19 | fromUserNft = new UserNft(fromUserNftId); 20 | fromUserNft.owner = fromUser.id; 21 | fromUserNft.amount = ZERO_BI; 22 | fromUserNft.nft = nft.id; 23 | fromUserNft.createdAt = event.block.timestamp; 24 | fromUserNft.isMint = false; 25 | } 26 | fromUserNft.tokenID = event.params.tokenId; 27 | fromUserNft.amount = ZERO_BI; 28 | 29 | if (toUserNft == null) { 30 | toUserNft = new UserNft(toUserNftId); 31 | toUserNft.owner = toUser.id; 32 | toUserNft.amount = ZERO_BI; 33 | toUserNft.nft = nft.id; 34 | toUserNft.createdAt = event.block.timestamp; 35 | if (event.params.from.equals(ADDRESS_ZERO)) { 36 | toUserNft.isMint = true; 37 | } 38 | } 39 | toUserNft.tokenID = event.params.tokenId; 40 | toUserNft.amount = ONE_BI; 41 | 42 | //更新时间戳 43 | nft.updatedAt = event.block.timestamp; 44 | fromUserNft.updatedAt = event.block.timestamp; 45 | toUserNft.updatedAt = event.block.timestamp; 46 | 47 | nft.save(); 48 | fromUserNft.save(); 49 | toUserNft.save(); 50 | } 51 | 52 | export function handleDODONFTMint(event: DODONFTMint): void { 53 | 54 | } 55 | 56 | export function handleDODONFTBurn(event: DODONFTBurn): void { 57 | 58 | } 59 | -------------------------------------------------------------------------------- /src/mappings/nft/buyout/fragment.ts: -------------------------------------------------------------------------------- 1 | import {Buyout, Redeem} from "../../../types/nft/templates/Fragment/Fragment" 2 | import {NftCollateralVault, Fragment, AggregateFragment} from "../../../types/nft/schema" 3 | import {ZERO_BI} from "../helpers"; 4 | 5 | export function handleBuyout(event: Buyout): void { 6 | let fragment = Fragment.load(event.address.toHexString()); 7 | fragment.isBuyOut = true; 8 | fragment.preVault = fragment.vault; 9 | fragment.buyoutTimestamp = event.block.timestamp; 10 | fragment.updatedAt = event.block.timestamp; 11 | fragment.save(); 12 | 13 | let vault = NftCollateralVault.load(fragment.vault); 14 | if (vault !== null) { 15 | vault.owner = event.params.newOwner; 16 | vault.updatedAt = event.block.timestamp; 17 | vault.save(); 18 | } 19 | 20 | 21 | let aggregateFragment = AggregateFragment.load(event.address.toHexString()); 22 | if (aggregateFragment !== null) { 23 | aggregateFragment.nftCount = ZERO_BI; 24 | aggregateFragment.updatedAt = event.block.timestamp; 25 | aggregateFragment.save(); 26 | } 27 | 28 | } 29 | 30 | export function handleRedeem(event: Redeem): void { 31 | 32 | } -------------------------------------------------------------------------------- /src/mappings/nft/buyout/proxy.ts: -------------------------------------------------------------------------------- 1 | import {AggregateFragment, NftCollateralVault} from "../../../types/nft/schema" 2 | import {CreateNFTCollateralVault, CreateFragment} from "../../../types/nft/DODONFTProxy/DODONFTProxy" 3 | import {createAndGetFragment, ZERO_BI} from "../helpers" 4 | import { 5 | NFTCollateralVault as NFTCollateralVaultTemplate, 6 | Fragment as FragmentTemplate 7 | } from "../../../types/nft/templates" 8 | import {BigInt} from "@graphprotocol/graph-ts"; 9 | 10 | export function handleCreateNFTCollateralVault(event: CreateNFTCollateralVault): void { 11 | let vault = NftCollateralVault.load(event.params.vault.toHexString()); 12 | 13 | if (vault == null) { 14 | vault = new NftCollateralVault(event.params.vault.toHexString()); 15 | vault.creator = event.params.creator.toHexString(); 16 | vault.name = event.params.name; 17 | vault.baseURI = event.params.baseURI; 18 | vault.owner = event.params.creator; 19 | vault.nftCount = ZERO_BI; 20 | vault.createdAt = event.block.timestamp; 21 | vault.updatedAt = event.block.timestamp; 22 | vault.save(); 23 | } 24 | NFTCollateralVaultTemplate.create(event.params.vault); 25 | } 26 | 27 | export function handleCreateFragment(event: CreateFragment): void { 28 | let vault = NftCollateralVault.load(event.params.vault.toHexString()); 29 | if (vault == null) return; 30 | vault.fragment = event.params.fragment.toHexString(); 31 | vault.save(); 32 | 33 | let fragment = createAndGetFragment(event.params.fragment, event); 34 | // fragment.vault = event.params.vault.toHexString(); 35 | fragment.dvm = event.params.dvm.toHexString(); 36 | fragment.vault = event.params.vault.toHexString(); 37 | fragment.createdAt = event.block.timestamp; 38 | fragment.updatedAt = event.block.timestamp; 39 | fragment.save(); 40 | 41 | let aggregateFragment = AggregateFragment.load(event.params.fragment.toHexString()); 42 | if (aggregateFragment == null) { 43 | aggregateFragment = new AggregateFragment(event.params.fragment.toHexString()) 44 | aggregateFragment.fragment = fragment.id; 45 | aggregateFragment.timestamp = event.block.timestamp; 46 | aggregateFragment.createdAt = event.block.timestamp; 47 | aggregateFragment.updatedAt = event.block.timestamp; 48 | aggregateFragment.creator = event.transaction.from; 49 | aggregateFragment.type = "BUYOUT" 50 | aggregateFragment.nftCount = vault.nftCount; 51 | aggregateFragment.save(); 52 | } 53 | 54 | FragmentTemplate.create(event.params.fragment); 55 | } 56 | -------------------------------------------------------------------------------- /src/mappings/nft/pool/baseFilterV1.ts: -------------------------------------------------------------------------------- 1 | import {Address} from "@graphprotocol/graph-ts" 2 | import {ChangeFilterName} from "../../../types/nft/templates/FilterERC721V1/FilterERC721V1" 3 | import {Filter} from "../../../types/nft/schema" 4 | 5 | 6 | -------------------------------------------------------------------------------- /src/mappings/nft/pool/filterAdmin.ts: -------------------------------------------------------------------------------- 1 | import {FilterAdmin} from "../../../types/nft/schema" 2 | import {ChangeFeeRate,OwnershipTransferred} from "../../../types/nft/DODONFTPoolProxy/FilterAdmin" 3 | 4 | export function handleChangeFeeRate(event: ChangeFeeRate): void { 5 | let filterAdmin = FilterAdmin.load(event.address.toHexString()); 6 | if (filterAdmin != null) { 7 | filterAdmin.feeRate = event.params.fee; 8 | filterAdmin.save(); 9 | } 10 | } 11 | 12 | export function handleOwnershipTransferred(event: OwnershipTransferred): void{ 13 | let filterAdmin = FilterAdmin.load(event.address.toHexString()); 14 | if (filterAdmin != null) { 15 | filterAdmin.owner = event.params.newOwner; 16 | filterAdmin.save(); 17 | } 18 | } 19 | 20 | 21 | -------------------------------------------------------------------------------- /src/mappings/starter/factory.ts: -------------------------------------------------------------------------------- 1 | import {NewFairFund, NewInstantFund} from "../../types/starter/DODOStarterFactory/DODOStarterFactory" 2 | import {FairFunding as FairFundingTemplate, InstantFunding as InstantFundingTemplate} from "../../types/starter/templates" 3 | import {Starter} from "../../types/starter/schema" 4 | 5 | export function handleNewFairFund(event: NewFairFund): void { 6 | let starter = Starter.load(event.params.fairFundPool.toHexString()); 7 | if (starter == null) { 8 | starter = new Starter(event.params.fairFundPool.toHexString()); 9 | starter.type = "Fair"; 10 | starter.base = event.params.baseToken; 11 | starter.fund = event.params.fundToken; 12 | starter.creator = event.params.creator 13 | starter.timestamp = event.block.timestamp; 14 | starter.updatedAt = event.block.timestamp; 15 | starter.save(); 16 | FairFundingTemplate.create(event.params.fairFundPool); 17 | } 18 | } 19 | 20 | export function handleNewInstantFund(event: NewInstantFund): void { 21 | let starter = Starter.load(event.params.instantFundPool.toHexString()); 22 | if (starter == null) { 23 | starter = new Starter(event.params.instantFundPool.toHexString()); 24 | starter.type = "Instant"; 25 | starter.base = event.params.baseToken; 26 | starter.fund = event.params.fundToken; 27 | starter.creator = event.params.creator 28 | starter.timestamp = event.block.timestamp; 29 | starter.updatedAt = event.block.timestamp; 30 | starter.save(); 31 | InstantFundingTemplate.create(event.params.instantFundPool); 32 | } 33 | } 34 | -------------------------------------------------------------------------------- /src/mappings/starter/helper.ts: -------------------------------------------------------------------------------- 1 | import {Address} from "@graphprotocol/graph-ts" 2 | 3 | -------------------------------------------------------------------------------- /src/mappings/starter/instant.ts: -------------------------------------------------------------------------------- 1 | import {DepositHistory, ClaimHistory,Starter} from "../../types/starter/schema" 2 | import {DepositFund,ClaimToken} from "../../types/starter/templates/InstantFunding/InstantFunding" 3 | import {ZERO_BI} from "../utils/helper"; 4 | 5 | export function handleDepositFund(event: DepositFund): void { 6 | let starter = Starter.load(event.address.toHexString()); 7 | 8 | if(starter ==null){ 9 | return 10 | } 11 | 12 | let id = event.transaction.hash.toHexString().concat("-").concat(event.logIndex.toHexString()); 13 | let depositHistory = DepositHistory.load(id); 14 | if(depositHistory==null){ 15 | depositHistory = new DepositHistory(id); 16 | depositHistory.hash = event.transaction.hash.toHexString(); 17 | depositHistory.starter = starter.id; 18 | depositHistory.user = event.params.account; 19 | depositHistory.amount = event.params.fundAmount; 20 | depositHistory.allocationAmount = event.params.allocationAmount; 21 | depositHistory.timestamp = event.block.timestamp; 22 | depositHistory.updatedAt = event.block.timestamp; 23 | depositHistory.save(); 24 | } 25 | } 26 | 27 | export function handleClaimToken(event: ClaimToken): void { 28 | let starter = Starter.load(event.address.toHexString()); 29 | 30 | if(starter ==null){ 31 | return 32 | } 33 | 34 | let id = event.transaction.hash.toHexString().concat("-").concat(event.logIndex.toHexString()); 35 | let claimHistory = ClaimHistory.load(id); 36 | if(claimHistory==null){ 37 | claimHistory = new ClaimHistory(id); 38 | claimHistory.hash = event.transaction.hash.toHexString(); 39 | claimHistory.starter = starter.id; 40 | claimHistory.user = event.params.to; 41 | claimHistory.tokenAmount = event.params.tokenAmount; 42 | claimHistory.fundAmount = ZERO_BI; 43 | claimHistory.starter=starter.id; 44 | claimHistory.timestamp = event.block.timestamp; 45 | claimHistory.updatedAt = event.block.timestamp; 46 | claimHistory.save(); 47 | } 48 | } -------------------------------------------------------------------------------- /src/mappings/token/factory.ts: -------------------------------------------------------------------------------- 1 | import {NewERC20} from "../../types/token/ERC20Factory/ERC20Factory" 2 | import { 3 | createUser, 4 | fetchTokenName, 5 | fetchTokenDecimals, 6 | fetchTokenSymbol, 7 | fetchTokenTotalSupply, 8 | ZERO_BI, 9 | getDODOToken, 10 | fetchTokenNameByCall, fetchTokenSymbolByCall, fetchTokenDecimalsByCall, fetchTokenTotalSupplyByCall, ONE_BI 11 | } from "./helpers" 12 | import {Token} from "../../types/token/schema" 13 | 14 | export function handleNewERC20(event: NewERC20): void { 15 | let user = createUser(event.params.creator, event); 16 | let token = Token.load(event.params.erc20.toHexString()); 17 | 18 | let dodoToken = getDODOToken(); 19 | if (token == null) { 20 | token = new Token(event.params.erc20.toHexString()) 21 | token.creator = user.id; 22 | token.name = fetchTokenName(event.params.erc20); 23 | token.symbol = fetchTokenSymbol(event.params.erc20); 24 | token.decimals = fetchTokenDecimals(event.params.erc20); 25 | token.totalSupply = fetchTokenTotalSupply(event.params.erc20); 26 | token.timestamp = event.block.timestamp; 27 | token.type = ZERO_BI; 28 | token.holderCount = ZERO_BI; 29 | token.updatedAt = event.block.timestamp; 30 | dodoToken.tokens = dodoToken.tokens.plus(ONE_BI); 31 | dodoToken.updatedAt = event.block.timestamp; 32 | } 33 | 34 | token.save(); 35 | dodoToken.save(); 36 | } -------------------------------------------------------------------------------- /src/mappings/token/factoryv2.ts: -------------------------------------------------------------------------------- 1 | import {NewERC20} from "../../types/token/ERC20V2Factory/ERC20V2Factory" 2 | import { 3 | createUser, 4 | fetchTokenName, 5 | fetchTokenDecimals, 6 | fetchTokenSymbol, 7 | fetchTokenTotalSupply, 8 | ZERO_BI, 9 | getDODOToken, ONE_BI 10 | } from "./helpers" 11 | import {Token} from "../../types/token/schema" 12 | 13 | export function handleNewERC20(event: NewERC20): void { 14 | let user = createUser(event.params.creator, event); 15 | let token = Token.load(event.params.erc20.toHexString()); 16 | let dodoToken = getDODOToken(); 17 | 18 | if (token == null) { 19 | token = new Token(event.params.erc20.toHexString()) 20 | token.creator = user.id; 21 | token.name = fetchTokenName(event.params.erc20); 22 | token.symbol = fetchTokenSymbol(event.params.erc20); 23 | token.decimals = fetchTokenDecimals(event.params.erc20); 24 | token.totalSupply = fetchTokenTotalSupply(event.params.erc20); 25 | token.timestamp = event.block.timestamp; 26 | token.type = event.params.erc20Type; 27 | token.holderCount = ZERO_BI; 28 | token.updatedAt = event.block.timestamp; 29 | dodoToken.tokens = dodoToken.tokens.plus(ONE_BI); 30 | dodoToken.updatedAt = event.block.timestamp; 31 | } 32 | 33 | token.save(); 34 | dodoToken.save(); 35 | } -------------------------------------------------------------------------------- /src/mappings/tools/dodoNftBalance/erc721.ts: -------------------------------------------------------------------------------- 1 | import {Nft, Balance} from "../../../types/tools/schema"; 2 | import {Address} from "@graphprotocol/graph-ts"; 3 | import {Transfer} from "../../../types/tools/DODONFT/DODONFT" 4 | import {DODONFTMint, DODONFTBurn,DODONFT} from "../../../types/tools/DODONFT/DODONFT" 5 | import {createAccount, ZERO_BI, ONE_BI, createAndGetNFT} from "./helpers"; 6 | 7 | export function handleTransfer(event: Transfer): void { 8 | let fromUser = createAccount(event.params.from,event); 9 | let toUser = createAccount(event.params.to,event); 10 | let nft = createAndGetNFT(event.address,event.params.tokenId,event); 11 | nft.type = "721"; 12 | 13 | let fromUserNftId = event.params.from.toHexString().concat("-").concat(event.address.toHexString()).concat(event.params.tokenId.toString()); 14 | let toUserNftId = event.params.to.toHexString().concat("-").concat(event.address.toHexString()).concat(event.params.tokenId.toString()); 15 | let fromUserNftBalance = Balance.load(fromUserNftId); 16 | let toUserNftBalance = Balance.load(toUserNftId); 17 | 18 | if (fromUserNftBalance == null) { 19 | fromUserNftBalance = new Balance(fromUserNftId); 20 | fromUserNftBalance.account = fromUser.id; 21 | fromUserNftBalance.value = ZERO_BI; 22 | fromUserNftBalance.nft = nft.id; 23 | fromUserNftBalance.createdAt = event.block.timestamp; 24 | fromUserNftBalance.updatedAt = event.block.timestamp; 25 | } 26 | fromUserNftBalance.tokenID = event.params.tokenId; 27 | fromUserNftBalance.value = ZERO_BI; 28 | 29 | if (toUserNftBalance == null) { 30 | toUserNftBalance = new Balance(toUserNftId); 31 | toUserNftBalance.account = toUser.id; 32 | toUserNftBalance.value = ZERO_BI; 33 | toUserNftBalance.nft = nft.id; 34 | toUserNftBalance.createdAt = event.block.timestamp; 35 | toUserNftBalance.updatedAt = event.block.timestamp; 36 | } 37 | toUserNftBalance.tokenID = event.params.tokenId; 38 | toUserNftBalance.value = ONE_BI; 39 | 40 | //更新时间戳 41 | nft.updatedAt = event.block.timestamp; 42 | fromUserNftBalance.updatedAt = event.block.timestamp; 43 | toUserNftBalance.updatedAt = event.block.timestamp; 44 | 45 | nft.save(); 46 | fromUserNftBalance.save(); 47 | toUserNftBalance.save(); 48 | } 49 | 50 | export function handleDODONFTMint(event: DODONFTMint): void { 51 | 52 | } 53 | 54 | export function handleDODONFTBurn(event: DODONFTBurn): void { 55 | 56 | } 57 | -------------------------------------------------------------------------------- /src/mappings/utils/helper.ts: -------------------------------------------------------------------------------- 1 | import {BigDecimal, BigInt,Address} from "@graphprotocol/graph-ts/index"; 2 | 3 | export let ZERO_BI = BigInt.fromI32(0) 4 | export let ONE_BI = BigInt.fromI32(1) 5 | export let ZERO_BD = BigDecimal.fromString('0') 6 | export let ONE_BD = BigDecimal.fromString('1') 7 | export let BI_18 = BigInt.fromI32(18) 8 | export const ADDRESS_ZERO = Address.fromString('0x0000000000000000000000000000000000000000') 9 | export const BASE_COIN = Address.fromString('0xeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeee'); -------------------------------------------------------------------------------- /src/mappings/vdodo/constants.ts: -------------------------------------------------------------------------------- 1 | export const DODO_ADDRESS_MAINNET="0x43dfc4159d86f3a37a5a4b3d4580b888ad7d4ddd"; 2 | export const DODO_ADDRESS_KOVAN="0x854b0f89baa9101e49bfb357a38071c9db5d0dfa"; 3 | -------------------------------------------------------------------------------- /subgraphs/dodoex/abis/ERC20NameBytes.json: -------------------------------------------------------------------------------- 1 | [ 2 | { 3 | "constant": true, 4 | "inputs": [], 5 | "name": "name", 6 | "outputs": [ 7 | { 8 | "internalType": "bytes32", 9 | "name": "", 10 | "type": "bytes32" 11 | } 12 | ], 13 | "payable": false, 14 | "stateMutability": "view", 15 | "type": "function" 16 | } 17 | ] -------------------------------------------------------------------------------- /subgraphs/dodoex/abis/ERC20SymbolBytes.json: -------------------------------------------------------------------------------- 1 | [ 2 | { 3 | "constant": true, 4 | "inputs": [], 5 | "name": "symbol", 6 | "outputs": [ 7 | { 8 | "internalType": "bytes32", 9 | "name": "", 10 | "type": "bytes32" 11 | } 12 | ], 13 | "payable": false, 14 | "stateMutability": "view", 15 | "type": "function" 16 | } 17 | ] -------------------------------------------------------------------------------- /subgraphs/dpoint/dpoint.graphql: -------------------------------------------------------------------------------- 1 | type Claimed @entity { 2 | " { Transaction hash }-{ Log index } " 3 | id: ID! 4 | " Transaction hash of the transaction that emitted this event " 5 | hash: String! 6 | " Event log index. For transactions that don't emit event, create arbitrary index starting from 0 " 7 | logIndex: Int! 8 | " Block number of this event " 9 | blockNumber: BigInt! 10 | " Timestamp of this event " 11 | timestamp: BigInt! 12 | account: Bytes! 13 | amount: BigInt! 14 | claimedAmount: BigInt! 15 | originAmount: BigInt! 16 | remainingRatio: BigInt! 17 | address: Bytes! 18 | token: Token! 19 | "updatedAt" 20 | updatedAt: BigInt! 21 | } 22 | 23 | type Token @entity { 24 | "token address" 25 | id: ID! 26 | "token symbol" 27 | symbol: String! 28 | "token name" 29 | name: String! 30 | "token decimals" 31 | decimals: BigInt! 32 | "total supply" 33 | totalSupply: BigInt! 34 | "updatedAt" 35 | updatedAt: BigInt! 36 | } 37 | -------------------------------------------------------------------------------- /subgraphs/dpoint/dpoint_goerli.yaml: -------------------------------------------------------------------------------- 1 | specVersion: 0.0.4 2 | description: Dodoex.io 3 | repository: https://github.com/DODOEX/dodoex_v2_subgraph 4 | schema: 5 | file: ./dpoint.graphql 6 | dataSources: 7 | - kind: ethereum/contract 8 | name: LockedTokenVaultFactory 9 | network: goerli 10 | source: 11 | address: '0x7A6a6bCeA8bfA93893aCC3df6D2A81ECb0E8dC1d' 12 | abi: LockedTokenVaultFactory 13 | startBlock: 10381816 14 | mapping: 15 | kind: ethereum/events 16 | apiVersion: 0.0.6 17 | language: wasm/assemblyscript 18 | file: ../../src/mappings/dpoint/factory.ts 19 | entities: [] 20 | abis: 21 | - name: LockedTokenVaultFactory 22 | file: ../../abis/LockedTokenVaultFactory.json 23 | - name: LockedTokenVault 24 | file: ../../abis/LockedTokenVault.json 25 | - name: ERC20 26 | file: ../../abis/ERC20.json 27 | eventHandlers: 28 | - event: CreateVault(address) 29 | handler: handleCreateVault 30 | templates: 31 | - kind: ethereum/contract 32 | name: LockedTokenVault 33 | network: goerli 34 | source: 35 | abi: LockedTokenVault 36 | mapping: 37 | kind: ethereum/events 38 | apiVersion: 0.0.6 39 | language: wasm/assemblyscript 40 | file: ../../src/mappings/dpoint/index.ts 41 | entities: 42 | - ERC20 43 | - Claimed 44 | abis: 45 | - name: LockedTokenVault 46 | file: ../../abis/LockedTokenVault.json 47 | - name: ERC20 48 | file: ../../abis/ERC20.json 49 | eventHandlers: 50 | - event: Claim(indexed address,uint256,uint256,uint256) 51 | handler: handleClaim 52 | -------------------------------------------------------------------------------- /subgraphs/dpoint/dpoint_scroll.yaml: -------------------------------------------------------------------------------- 1 | specVersion: 0.0.4 2 | description: Dodoex.io 3 | repository: https://github.com/DODOEX/dodoex_v2_subgraph 4 | schema: 5 | file: ./dpoint.graphql 6 | dataSources: 7 | - kind: ethereum/contract 8 | name: LockedTokenVaultFactory 9 | network: scroll 10 | source: 11 | address: '0xEAf81DeAf1477C6DE6981D7902A287988E65e439' 12 | abi: LockedTokenVaultFactory 13 | startBlock: 2765712 14 | mapping: 15 | kind: ethereum/events 16 | apiVersion: 0.0.6 17 | language: wasm/assemblyscript 18 | file: ../../src/mappings/dpoint/factory.ts 19 | entities: [] 20 | abis: 21 | - name: LockedTokenVaultFactory 22 | file: ../../abis/LockedTokenVaultFactory.json 23 | - name: LockedTokenVault 24 | file: ../../abis/LockedTokenVault.json 25 | eventHandlers: 26 | - event: CreateVault(address) 27 | handler: handleCreateVault 28 | templates: 29 | - kind: ethereum/contract 30 | name: LockedTokenVault 31 | network: scroll 32 | source: 33 | abi: LockedTokenVault 34 | mapping: 35 | kind: ethereum/events 36 | apiVersion: 0.0.6 37 | language: wasm/assemblyscript 38 | file: ../../src/mappings/dpoint/index.ts 39 | entities: 40 | - ERC20 41 | - Claimed 42 | abis: 43 | - name: LockedTokenVault 44 | file: ../../abis/LockedTokenVault.json 45 | - name: ERC20 46 | file: ../../abis/ERC20.json 47 | eventHandlers: 48 | - event: Claim(indexed address,uint256,uint256,uint256) 49 | handler: handleClaim 50 | -------------------------------------------------------------------------------- /subgraphs/merkle-airdrop/merkle.graphql: -------------------------------------------------------------------------------- 1 | type Claimed @entity { 2 | " { Transaction hash }-{ Log index } " 3 | id: ID! 4 | " Transaction hash of the transaction that emitted this event " 5 | hash: String! 6 | " Event log index. For transactions that don't emit event, create arbitrary index starting from 0 " 7 | logIndex: Int! 8 | " Block number of this event " 9 | blockNumber: BigInt! 10 | " Timestamp of this event " 11 | timestamp: BigInt! 12 | index: BigInt! 13 | account: Bytes! 14 | amount: BigInt! 15 | address: Bytes! 16 | token: Token! 17 | "updatedAt" 18 | updatedAt: BigInt! 19 | } 20 | 21 | type Token @entity { 22 | "token address" 23 | id: ID! 24 | "token symbol" 25 | symbol: String! 26 | "token name" 27 | name: String! 28 | "token decimals" 29 | decimals: BigInt! 30 | "total supply" 31 | totalSupply: BigInt! 32 | "updatedAt" 33 | updatedAt: BigInt! 34 | } 35 | -------------------------------------------------------------------------------- /subgraphs/merkle-airdrop/merkle_base_mainnet.yaml: -------------------------------------------------------------------------------- 1 | specVersion: 0.0.4 2 | description: Dodoex.io 3 | repository: https://github.com/DODOEX/dodoex_v2_subgraph 4 | schema: 5 | file: ./merkle.graphql 6 | dataSources: 7 | - kind: ethereum/contract 8 | name: MerkleDistributor 9 | network: base 10 | source: 11 | address: '0x39767dc49cb7ef6a1f32b8c1e65e4faf51692471' 12 | abi: MerkleDistributor 13 | startBlock: 3091658 14 | mapping: 15 | kind: ethereum/events 16 | apiVersion: 0.0.6 17 | language: wasm/assemblyscript 18 | file: ../../src/mappings/merkle-airdrop/index.ts 19 | entities: 20 | - Claimed 21 | abis: 22 | - name: MerkleDistributor 23 | file: ../../abis/MerkleDistributor.json 24 | - name: ERC20 25 | file: ../../abis/ERC20.json 26 | eventHandlers: 27 | - event: Claimed(uint256,address,uint256) 28 | handler: handleClaimed 29 | -------------------------------------------------------------------------------- /subgraphs/merkle-airdrop/merkle_goerli.yaml: -------------------------------------------------------------------------------- 1 | specVersion: 0.0.4 2 | description: Dodoex.io 3 | repository: https://github.com/DODOEX/dodoex_v2_subgraph 4 | schema: 5 | file: ./merkle.graphql 6 | dataSources: 7 | - kind: ethereum/contract 8 | name: MerkleDistributor 9 | network: goerli 10 | source: 11 | address: '0xfF0f9997737e4588F24209E427B44Cd19839010B' 12 | abi: MerkleDistributor 13 | startBlock: 9520465 14 | mapping: 15 | kind: ethereum/events 16 | apiVersion: 0.0.6 17 | language: wasm/assemblyscript 18 | file: ../../src/mappings/merkle-airdrop/index.ts 19 | entities: 20 | - Claimed 21 | abis: 22 | - name: MerkleDistributor 23 | file: ../../abis/MerkleDistributor.json 24 | - name: ERC20 25 | file: ../../abis/ERC20.json 26 | eventHandlers: 27 | - event: Claimed(uint256,address,uint256) 28 | handler: handleClaimed 29 | -------------------------------------------------------------------------------- /subgraphs/mine/abis/ERC20NameBytes.json: -------------------------------------------------------------------------------- 1 | [ 2 | { 3 | "constant": true, 4 | "inputs": [], 5 | "name": "name", 6 | "outputs": [ 7 | { 8 | "internalType": "bytes32", 9 | "name": "", 10 | "type": "bytes32" 11 | } 12 | ], 13 | "payable": false, 14 | "stateMutability": "view", 15 | "type": "function" 16 | } 17 | ] -------------------------------------------------------------------------------- /subgraphs/mine/abis/ERC20SymbolBytes.json: -------------------------------------------------------------------------------- 1 | [ 2 | { 3 | "constant": true, 4 | "inputs": [], 5 | "name": "symbol", 6 | "outputs": [ 7 | { 8 | "internalType": "bytes32", 9 | "name": "", 10 | "type": "bytes32" 11 | } 12 | ], 13 | "payable": false, 14 | "stateMutability": "view", 15 | "type": "function" 16 | } 17 | ] -------------------------------------------------------------------------------- /subgraphs/mine/mine.graphql: -------------------------------------------------------------------------------- 1 | type MinePool @entity { 2 | "id" 3 | id: ID! 4 | "timestamp" 5 | timestamp: BigInt 6 | "creator" 7 | creator: Bytes 8 | "mine pool address" 9 | pool: Bytes! 10 | "stake token" 11 | stakeToken:Bytes 12 | "isLptoken" 13 | isLpToken: Boolean 14 | "mineType" 15 | platform:BigInt 16 | "reward details" 17 | rewardDetail:[RewardDetail!]! @derivedFrom(field: "minePool") 18 | "updatedAt" 19 | updatedAt:BigInt! 20 | } 21 | 22 | type RewardDetail @entity{ 23 | "id" 24 | id: ID! 25 | "minepool" 26 | minePool: MinePool! 27 | "rewardTokens" 28 | token: Bytes! 29 | "reward per block" 30 | rewardPerBlock: BigInt! 31 | "start block" 32 | startBlock: BigInt! 33 | "end block" 34 | endBlock: BigInt! 35 | "updatedAt" 36 | updatedAt:BigInt! 37 | } 38 | 39 | type UserStake @entity{ 40 | "user - pool" 41 | id: ID! 42 | "user address" 43 | user:Bytes! 44 | "pool" 45 | pool:Bytes! 46 | "balance" 47 | balance:BigInt! 48 | "updatedAt" 49 | updatedAt:BigInt! 50 | } 51 | -------------------------------------------------------------------------------- /subgraphs/mine/mine_aurora.yaml: -------------------------------------------------------------------------------- 1 | specVersion: 0.0.6 2 | description: Dodoex.io 3 | repository: https://github.com/DODOEX/dodoex_v2_subgraph 4 | schema: 5 | file: ./mine.graphql 6 | dataSources: 7 | - kind: ethereum/contract 8 | name: DODOMineV3Proxy 9 | network: aurora 10 | source: 11 | address: '0x4775b1858f1e417C9609D455C3Ad8751ec01daC4' 12 | abi: DODOMineV3Proxy 13 | startBlock: 51265155 14 | mapping: 15 | kind: ethereum/events 16 | apiVersion: 0.0.6 17 | language: wasm/assemblyscript 18 | file: ../../src/mappings/mine/mineProxy.ts 19 | entities: 20 | - MinePool 21 | abis: 22 | - name: DODOMineV3Proxy 23 | file: ../../abis/DODOMineV3Proxy.json 24 | - name: ERC20MineV3 25 | file: ../../abis/ERC20MineV3.json 26 | - name: ERC20 27 | file: ../../abis/ERC20.json 28 | - name: ERC20SymbolBytes 29 | file: ../../abis/ERC20SymbolBytes.json 30 | - name: ERC20NameBytes 31 | file: ../../abis/ERC20NameBytes.json 32 | eventHandlers: 33 | - event: CreateMineV3(address,address) 34 | handler: handleCreateMineV3 35 | - kind: ethereum/contract 36 | name: DODOMineV3Registry 37 | network: aurora 38 | source: 39 | address: '0xfDDCA6ffCE24dF5bE3e8AaD32081822f86178048' 40 | abi: DODOMineV3Registry 41 | startBlock: 51265155 42 | mapping: 43 | kind: ethereum/events 44 | apiVersion: 0.0.6 45 | language: wasm/assemblyscript 46 | file: ../../src/mappings/mine/registry.ts 47 | entities: 48 | - MinePool 49 | abis: 50 | - name: DODOMineV3Proxy 51 | file: ../../abis/DODOMineV3Proxy.json 52 | - name: DODOMineV3Registry 53 | file: ../../abis/DODOMineV3Registry.json 54 | - name: ERC20MineV3 55 | file: ../../abis/ERC20MineV3.json 56 | - name: ERC20 57 | file: ../../abis/ERC20.json 58 | - name: ERC20SymbolBytes 59 | file: ../../abis/ERC20SymbolBytes.json 60 | - name: ERC20NameBytes 61 | file: ../../abis/ERC20NameBytes.json 62 | eventHandlers: 63 | - event: NewMineV3(address,address,bool) 64 | handler: handleNewMineV3 65 | templates: 66 | - kind: ethereum/contract 67 | name: ERC20MineV3 68 | network: aurora 69 | source: 70 | abi: ERC20MineV3 71 | mapping: 72 | kind: ethereum/events 73 | apiVersion: 0.0.6 74 | language: wasm/assemblyscript 75 | file: ../../src/mappings/mine/mine.ts 76 | entities: 77 | - MinePool 78 | abis: 79 | - name: ERC20MineV3 80 | file: ../../abis/ERC20MineV3.json 81 | eventHandlers: 82 | - event: Deposit(indexed address,uint256) 83 | handler: handleDeposit 84 | - event: Withdraw(indexed address,uint256) 85 | handler: handleWithdraw 86 | - event: NewRewardToken(indexed uint256,address) 87 | handler: handleNewRewardToken 88 | -------------------------------------------------------------------------------- /subgraphs/mine/mine_boba.yaml: -------------------------------------------------------------------------------- 1 | specVersion: 0.0.2 2 | description: Dodoex.io 3 | repository: https://github.com/DODOEX/dodoex_v2_subgraph 4 | schema: 5 | file: ./mine.graphql 6 | dataSources: 7 | - kind: ethereum/contract 8 | name: DODOMineV3Proxy 9 | network: boba 10 | source: 11 | address: '0xb0C7cB15b52b0093130487209e96CFeC0Ba4Ff66' 12 | abi: DODOMineV3Proxy 13 | startBlock: 100 14 | mapping: 15 | kind: ethereum/events 16 | apiVersion: 0.0.4 17 | language: wasm/assemblyscript 18 | file: ../../src/mappings/mine/mineProxy.ts 19 | entities: 20 | - MinePool 21 | abis: 22 | - name: DODOMineV3Proxy 23 | file: ../../abis/DODOMineV3Proxy.json 24 | - name: ERC20MineV3 25 | file: ../../abis/ERC20MineV3.json 26 | - name: ERC20 27 | file: ../../abis/ERC20.json 28 | - name: ERC20SymbolBytes 29 | file: ../../abis/ERC20SymbolBytes.json 30 | - name: ERC20NameBytes 31 | file: ../../abis/ERC20NameBytes.json 32 | eventHandlers: 33 | - event: CreateMineV3(address,address) 34 | handler: handleCreateMineV3 35 | - kind: ethereum/contract 36 | name: DODOMineV3Registry 37 | network: boba 38 | source: 39 | address: '0x2b0d94Eb7A63B8a2909dE1CB3951ecF7Ae76D2fE' 40 | abi: DODOMineV3Registry 41 | startBlock: 100 42 | mapping: 43 | kind: ethereum/events 44 | apiVersion: 0.0.4 45 | language: wasm/assemblyscript 46 | file: ../../src/mappings/mine/registry.ts 47 | entities: 48 | - MinePool 49 | abis: 50 | - name: DODOMineV3Proxy 51 | file: ../../abis/DODOMineV3Proxy.json 52 | - name: DODOMineV3Registry 53 | file: ../../abis/DODOMineV3Registry.json 54 | - name: ERC20MineV3 55 | file: ../../abis/ERC20MineV3.json 56 | - name: ERC20 57 | file: ../../abis/ERC20.json 58 | - name: ERC20SymbolBytes 59 | file: ../../abis/ERC20SymbolBytes.json 60 | - name: ERC20NameBytes 61 | file: ../../abis/ERC20NameBytes.json 62 | eventHandlers: 63 | - event: NewMineV3(address,address,bool) 64 | handler: handleNewMineV3 65 | templates: 66 | - kind: ethereum/contract 67 | name: ERC20MineV3 68 | network: boba 69 | source: 70 | abi: ERC20MineV3 71 | mapping: 72 | kind: ethereum/events 73 | apiVersion: 0.0.4 74 | language: wasm/assemblyscript 75 | file: ../../src/mappings/mine/mine.ts 76 | entities: 77 | - MinePool 78 | abis: 79 | - name: ERC20MineV3 80 | file: ../../abis/ERC20MineV3.json 81 | eventHandlers: 82 | - event: Deposit(indexed address,uint256) 83 | handler: handleDeposit 84 | - event: Withdraw(indexed address,uint256) 85 | handler: handleWithdraw 86 | - event: NewRewardToken(indexed uint256,address) 87 | handler: handleNewRewardToken 88 | -------------------------------------------------------------------------------- /subgraphs/mine/mine_heco.yaml: -------------------------------------------------------------------------------- 1 | specVersion: 0.0.2 2 | description: Dodoex.io 3 | repository: https://github.com/DODOEX/dodoex_v2_subgraph 4 | schema: 5 | file: ./mine.graphql 6 | dataSources: 7 | - kind: ethereum/contract 8 | name: DODOMineV3Proxy 9 | network: heco 10 | source: 11 | address: '0x50832DEdCF8b390160D892654530Fb96042d674B' 12 | abi: DODOMineV3Proxy 13 | startBlock: 6849639 14 | mapping: 15 | kind: ethereum/events 16 | apiVersion: 0.0.4 17 | language: wasm/assemblyscript 18 | file: ../../src/mappings/mine/mineProxy.ts 19 | entities: 20 | - MinePool 21 | abis: 22 | - name: DODOMineV3Proxy 23 | file: ../../abis/DODOMineV3Proxy.json 24 | - name: ERC20MineV3 25 | file: ../../abis/ERC20MineV3.json 26 | - name: ERC20 27 | file: ../../abis/ERC20.json 28 | - name: ERC20SymbolBytes 29 | file: ../../abis/ERC20SymbolBytes.json 30 | - name: ERC20NameBytes 31 | file: ../../abis/ERC20NameBytes.json 32 | eventHandlers: 33 | - event: CreateMineV3(address,address) 34 | handler: handleCreateMineV3 35 | - kind: ethereum/contract 36 | name: DODOMineV3Registry 37 | network: heco 38 | source: 39 | address: '0xeA73542FbF76b35e46901e0Ca19BcC5A0361F5BF' 40 | abi: DODOMineV3Registry 41 | startBlock: 6849639 42 | mapping: 43 | kind: ethereum/events 44 | apiVersion: 0.0.4 45 | language: wasm/assemblyscript 46 | file: ../../src/mappings/mine/registry.ts 47 | entities: 48 | - MinePool 49 | abis: 50 | - name: DODOMineV3Proxy 51 | file: ../../abis/DODOMineV3Proxy.json 52 | - name: DODOMineV3Registry 53 | file: ../../abis/DODOMineV3Registry.json 54 | - name: ERC20MineV3 55 | file: ../../abis/ERC20MineV3.json 56 | - name: ERC20 57 | file: ../../abis/ERC20.json 58 | - name: ERC20SymbolBytes 59 | file: ../../abis/ERC20SymbolBytes.json 60 | - name: ERC20NameBytes 61 | file: ../../abis/ERC20NameBytes.json 62 | eventHandlers: 63 | - event: NewMineV3(address,address,bool) 64 | handler: handleNewMineV3 65 | templates: 66 | - kind: ethereum/contract 67 | name: ERC20MineV3 68 | network: heco 69 | source: 70 | abi: ERC20MineV3 71 | mapping: 72 | kind: ethereum/events 73 | apiVersion: 0.0.4 74 | language: wasm/assemblyscript 75 | file: ../../src/mappings/mine/mine.ts 76 | entities: 77 | - MinePool 78 | abis: 79 | - name: ERC20MineV3 80 | file: ../../abis/ERC20MineV3.json 81 | eventHandlers: 82 | - event: Deposit(indexed address,uint256) 83 | handler: handleDeposit 84 | - event: Withdraw(indexed address,uint256) 85 | handler: handleWithdraw 86 | - event: NewRewardToken(indexed uint256,address) 87 | handler: handleNewRewardToken 88 | -------------------------------------------------------------------------------- /subgraphs/mine/mine_okchain.yaml: -------------------------------------------------------------------------------- 1 | specVersion: 0.0.2 2 | description: Dodoex.io 3 | repository: https://github.com/DODOEX/dodoex_v2_subgraph 4 | schema: 5 | file: ./mine.graphql 6 | dataSources: 7 | - kind: ethereum/contract 8 | name: DODOMineV3Proxy 9 | network: mainnet 10 | source: 11 | address: '0x958f79e2998DFe417208b9A07D799265B0298e58' 12 | abi: DODOMineV3Proxy 13 | startBlock: 4702907 14 | mapping: 15 | kind: ethereum/events 16 | apiVersion: 0.0.4 17 | language: wasm/assemblyscript 18 | file: ../../src/mappings/mine/mineProxy.ts 19 | entities: 20 | - MinePool 21 | abis: 22 | - name: DODOMineV3Proxy 23 | file: ../../abis/DODOMineV3Proxy.json 24 | - name: ERC20MineV3 25 | file: ../../abis/ERC20MineV3.json 26 | - name: ERC20 27 | file: ../../abis/ERC20.json 28 | - name: ERC20SymbolBytes 29 | file: ../../abis/ERC20SymbolBytes.json 30 | - name: ERC20NameBytes 31 | file: ../../abis/ERC20NameBytes.json 32 | eventHandlers: 33 | - event: CreateMineV3(address,address) 34 | handler: handleCreateMineV3 35 | - kind: ethereum/contract 36 | name: DODOMineV3Registry 37 | network: mainnet 38 | source: 39 | address: '0xb159260989012fA98af560A3Fa6D9cd11a64cf6E' 40 | abi: DODOMineV3Registry 41 | startBlock: 4702907 42 | mapping: 43 | kind: ethereum/events 44 | apiVersion: 0.0.4 45 | language: wasm/assemblyscript 46 | file: ../../src/mappings/mine/registry.ts 47 | entities: 48 | - MinePool 49 | abis: 50 | - name: DODOMineV3Proxy 51 | file: ../../abis/DODOMineV3Proxy.json 52 | - name: DODOMineV3Registry 53 | file: ../../abis/DODOMineV3Registry.json 54 | - name: ERC20MineV3 55 | file: ../../abis/ERC20MineV3.json 56 | - name: ERC20 57 | file: ../../abis/ERC20.json 58 | - name: ERC20SymbolBytes 59 | file: ../../abis/ERC20SymbolBytes.json 60 | - name: ERC20NameBytes 61 | file: ../../abis/ERC20NameBytes.json 62 | eventHandlers: 63 | - event: NewMineV3(address,address,bool) 64 | handler: handleNewMineV3 65 | templates: 66 | - kind: ethereum/contract 67 | name: ERC20MineV3 68 | network: mainnet 69 | source: 70 | abi: ERC20MineV3 71 | mapping: 72 | kind: ethereum/events 73 | apiVersion: 0.0.4 74 | language: wasm/assemblyscript 75 | file: ../../src/mappings/mine/mine.ts 76 | entities: 77 | - MinePool 78 | abis: 79 | - name: ERC20MineV3 80 | file: ../../abis/ERC20MineV3.json 81 | eventHandlers: 82 | - event: Deposit(indexed address,uint256) 83 | handler: handleDeposit 84 | - event: Withdraw(indexed address,uint256) 85 | handler: handleWithdraw 86 | - event: NewRewardToken(indexed uint256,address) 87 | handler: handleNewRewardToken 88 | -------------------------------------------------------------------------------- /subgraphs/mine/mine_polygon.yaml: -------------------------------------------------------------------------------- 1 | specVersion: 0.0.4 2 | description: Dodoex.io 3 | repository: https://github.com/DODOEX/dodoex_v2_subgraph 4 | schema: 5 | file: ./mine.graphql 6 | dataSources: 7 | - kind: ethereum/contract 8 | name: DODOMineV3Proxy 9 | network: matic 10 | source: 11 | address: '0x47a65e74dd6b6b5e3243dbb01eded9d55ba234ad' 12 | abi: DODOMineV3Proxy 13 | startBlock: 17462462 14 | mapping: 15 | kind: ethereum/events 16 | apiVersion: 0.0.6 17 | language: wasm/assemblyscript 18 | file: ../../src/mappings/mine/mineProxy.ts 19 | entities: 20 | - MinePool 21 | abis: 22 | - name: DODOMineV3Proxy 23 | file: ../../abis/DODOMineV3Proxy.json 24 | - name: ERC20MineV3 25 | file: ../../abis/ERC20MineV3.json 26 | - name: ERC20 27 | file: ../../abis/ERC20.json 28 | - name: ERC20SymbolBytes 29 | file: ../../abis/ERC20SymbolBytes.json 30 | - name: ERC20NameBytes 31 | file: ../../abis/ERC20NameBytes.json 32 | eventHandlers: 33 | - event: CreateMineV3(address,address) 34 | handler: handleCreateMineV3 35 | - kind: ethereum/contract 36 | name: DODOMineV3Registry 37 | network: matic 38 | source: 39 | address: '0x27566bf9504466f6f3a1571e1863da42fff4d25e' 40 | abi: DODOMineV3Registry 41 | startBlock: 17462450 42 | mapping: 43 | kind: ethereum/events 44 | apiVersion: 0.0.6 45 | language: wasm/assemblyscript 46 | file: ../../src/mappings/mine/registry.ts 47 | entities: 48 | - MinePool 49 | abis: 50 | - name: DODOMineV3Proxy 51 | file: ../../abis/DODOMineV3Proxy.json 52 | - name: DODOMineV3Registry 53 | file: ../../abis/DODOMineV3Registry.json 54 | - name: ERC20MineV3 55 | file: ../../abis/ERC20MineV3.json 56 | - name: ERC20 57 | file: ../../abis/ERC20.json 58 | - name: ERC20SymbolBytes 59 | file: ../../abis/ERC20SymbolBytes.json 60 | - name: ERC20NameBytes 61 | file: ../../abis/ERC20NameBytes.json 62 | eventHandlers: 63 | - event: NewMineV3(address,address,bool) 64 | handler: handleNewMineV3 65 | templates: 66 | - kind: ethereum/contract 67 | name: ERC20MineV3 68 | network: matic 69 | source: 70 | abi: ERC20MineV3 71 | mapping: 72 | kind: ethereum/events 73 | apiVersion: 0.0.6 74 | language: wasm/assemblyscript 75 | file: ../../src/mappings/mine/mine.ts 76 | entities: 77 | - MinePool 78 | abis: 79 | - name: ERC20MineV3 80 | file: ../../abis/ERC20MineV3.json 81 | eventHandlers: 82 | - event: Deposit(indexed address,uint256) 83 | handler: handleDeposit 84 | - event: Withdraw(indexed address,uint256) 85 | handler: handleWithdraw 86 | - event: NewRewardToken(indexed uint256,address) 87 | handler: handleNewRewardToken 88 | -------------------------------------------------------------------------------- /subgraphs/nft/abis/ERC20NameBytes.json: -------------------------------------------------------------------------------- 1 | [ 2 | { 3 | "constant": true, 4 | "inputs": [], 5 | "name": "name", 6 | "outputs": [ 7 | { 8 | "internalType": "bytes32", 9 | "name": "", 10 | "type": "bytes32" 11 | } 12 | ], 13 | "payable": false, 14 | "stateMutability": "view", 15 | "type": "function" 16 | } 17 | ] -------------------------------------------------------------------------------- /subgraphs/nft/abis/ERC20SymbolBytes.json: -------------------------------------------------------------------------------- 1 | [ 2 | { 3 | "constant": true, 4 | "inputs": [], 5 | "name": "symbol", 6 | "outputs": [ 7 | { 8 | "internalType": "bytes32", 9 | "name": "", 10 | "type": "bytes32" 11 | } 12 | ], 13 | "payable": false, 14 | "stateMutability": "view", 15 | "type": "function" 16 | } 17 | ] -------------------------------------------------------------------------------- /subgraphs/nft/dodo_topia_goerli.yaml: -------------------------------------------------------------------------------- 1 | specVersion: 0.0.2 2 | description: Dodoex.io 3 | repository: https://github.com/DODOEX/dodoex_v2_subgraph 4 | schema: 5 | file: ./nft.graphql 6 | dataSources: 7 | - kind: ethereum/contract 8 | name: DODOTopia 9 | network: goerli 10 | source: 11 | abi: DODONFT 12 | address: '0xb546add98c71d97bb65de60b91021617acd1262c' 13 | startBlock: 7547427 14 | mapping: 15 | kind: ethereum/events 16 | apiVersion: 0.0.4 17 | language: wasm/assemblyscript 18 | file: ../../src/mappings/nft/buyout/erc721.ts 19 | entities: 20 | - NftCollateralVault 21 | - Nft 22 | - VaultNft 23 | - Fragment 24 | abis: 25 | - name: DODONFT 26 | file: ../../abis/DODONFT.json 27 | - name: DODONFT1155 28 | file: ../../abis/DODONFT1155.json 29 | eventHandlers: 30 | - event: DODONFTMint(address,uint256) 31 | handler: handleDODONFTMint 32 | - event: DODONFTBurn(uint256) 33 | handler: handleDODONFTBurn 34 | - event: Transfer(indexed address,indexed address,indexed uint256) 35 | handler: handleTransfer -------------------------------------------------------------------------------- /subgraphs/nft/dodo_topia_mainnet.yaml: -------------------------------------------------------------------------------- 1 | specVersion: 0.0.2 2 | description: Dodoex.io 3 | repository: https://github.com/DODOEX/dodoex_v2_subgraph 4 | schema: 5 | file: ./nft.graphql 6 | dataSources: 7 | - kind: ethereum/contract 8 | name: DODOTopia 9 | network: mainnet 10 | source: 11 | abi: DODONFT 12 | address: '0x89872650fA1A391f58B4E144222bB02e44db7e3B' 13 | startBlock: 15631473 14 | mapping: 15 | kind: ethereum/events 16 | apiVersion: 0.0.4 17 | language: wasm/assemblyscript 18 | file: ../../src/mappings/nft/buyout/erc721.ts 19 | entities: 20 | - NftCollateralVault 21 | - Nft 22 | - VaultNft 23 | - Fragment 24 | abis: 25 | - name: DODONFT 26 | file: ../../abis/DODONFT.json 27 | - name: DODONFT1155 28 | file: ../../abis/DODONFT1155.json 29 | eventHandlers: 30 | - event: DODONFTMint(address,uint256) 31 | handler: handleDODONFTMint 32 | - event: DODONFTBurn(uint256) 33 | handler: handleDODONFTBurn 34 | - event: Transfer(indexed address,indexed address,indexed uint256) 35 | handler: handleTransfer -------------------------------------------------------------------------------- /subgraphs/starter/starter.graphql: -------------------------------------------------------------------------------- 1 | type DodoStarter @entity{ 2 | "id" 3 | id:ID! 4 | } 5 | 6 | enum PoolType { 7 | Fair, 8 | Instant 9 | } 10 | 11 | enum OperationType { 12 | Deposit, 13 | Claim, 14 | Withdraw 15 | } 16 | 17 | type Starter @entity{ 18 | "id address" 19 | id:ID! 20 | "type: Instant、Fund" 21 | type:PoolType! 22 | "base token address" 23 | base: Bytes! 24 | "fund token address" 25 | fund: Bytes! 26 | "creator" 27 | creator: Bytes! 28 | "timestamp" 29 | timestamp: BigInt! 30 | "updatedAt" 31 | updatedAt: BigInt! 32 | } 33 | 34 | type DepositHistory @entity{ 35 | "id hash-logindex" 36 | id: ID! 37 | "Starter" 38 | starter:Starter! 39 | "hash" 40 | hash:String! 41 | "user" 42 | user: Bytes! 43 | "fund amount" 44 | amount: BigInt! 45 | "allocation amount" 46 | allocationAmount: BigInt! 47 | "timestamp" 48 | timestamp: BigInt! 49 | "updatedAt" 50 | updatedAt: BigInt! 51 | } 52 | 53 | type ClaimHistory @entity{ 54 | "id hash-logindex" 55 | id: ID! 56 | "Starter" 57 | starter:Starter! 58 | "hash" 59 | hash:String! 60 | "user" 61 | user: Bytes! 62 | "token amount" 63 | tokenAmount: BigInt! 64 | "fund amount" 65 | fundAmount: BigInt! 66 | "timestamp" 67 | timestamp: BigInt! 68 | "updatedAt" 69 | updatedAt: BigInt! 70 | } 71 | 72 | type WithdrawFundHistory @entity{ 73 | "id hash-logindex" 74 | id: ID! 75 | "Starter" 76 | starter:Starter! 77 | "hash" 78 | hash:String! 79 | "user" 80 | user: Bytes! 81 | "fund amount" 82 | fundAmount: BigInt! 83 | "timestamp" 84 | timestamp: BigInt! 85 | "updatedAt" 86 | updatedAt: BigInt! 87 | } 88 | -------------------------------------------------------------------------------- /subgraphs/starter/starter_goerli.yaml: -------------------------------------------------------------------------------- 1 | specVersion: 0.0.2 2 | description: Dodoex.io 3 | repository: https://github.com/DODOEX/dodoex_v2_subgraph 4 | schema: 5 | file: ./starter.graphql 6 | dataSources: 7 | - kind: ethereum/contract 8 | name: DODOStarterFactory 9 | network: goerli 10 | source: 11 | address: '0x17644d3B366273faC75A07996E2F90A99A2946a7' # DODOStarterFactoryV2 12 | abi: DODOStarterFactory 13 | startBlock: 7326888 14 | mapping: 15 | kind: ethereum/events 16 | apiVersion: 0.0.4 17 | language: wasm/assemblyscript 18 | file: ../../src/mappings/starter/factory.ts 19 | entities: 20 | - DodoStarter 21 | - Starter 22 | - DepositHistory 23 | - ClaimHistory 24 | - WithdrawFundHistory 25 | abis: 26 | - name: DODOStarterFactory 27 | file: ../../abis/DODOStarterFactory.json 28 | eventHandlers: 29 | - event: NewFairFund(address,address,address,address) 30 | handler: handleNewFairFund 31 | - event: NewInstantFund(address,address,address,address) 32 | handler: handleNewInstantFund 33 | templates: 34 | - kind: ethereum/contract 35 | name: FairFunding 36 | network: goerli 37 | source: 38 | abi: FairFunding 39 | mapping: 40 | kind: ethereum/events 41 | apiVersion: 0.0.4 42 | language: wasm/assemblyscript 43 | file: ../../src/mappings/starter/fair.ts 44 | entities: 45 | - User 46 | - Token 47 | - UserTokenBlance 48 | - TransferHistories 49 | abis: 50 | - name: FairFunding 51 | file: ../../abis/FairFunding.json 52 | eventHandlers: 53 | - event: DepositFund(indexed address,uint256) 54 | handler: handleDepositFund 55 | - event: WithdrawFund(indexed address,indexed address,uint256,bool) 56 | handler: handleWithdrawFund 57 | - event: ClaimToken(indexed address,indexed address,uint256,uint256) 58 | handler: handleClaimToken 59 | - kind: ethereum/contract 60 | name: InstantFunding 61 | network: goerli 62 | source: 63 | abi: InstantFunding 64 | mapping: 65 | kind: ethereum/events 66 | apiVersion: 0.0.4 67 | language: wasm/assemblyscript 68 | file: ../../src/mappings/starter/instant.ts 69 | entities: 70 | - User 71 | - Token 72 | - UserTokenBlance 73 | - TransferHistories 74 | abis: 75 | - name: InstantFunding 76 | file: ../../abis/InstantFunding.json 77 | eventHandlers: 78 | - event: DepositFund(indexed address,uint256,uint256) 79 | handler: handleDepositFund 80 | - event: ClaimToken(indexed address,indexed address,uint256) 81 | handler: handleClaimToken -------------------------------------------------------------------------------- /subgraphs/starter/starter_rinkeby.yaml: -------------------------------------------------------------------------------- 1 | specVersion: 0.0.2 2 | description: Dodoex.io 3 | repository: https://github.com/DODOEX/dodoex_v2_subgraph 4 | schema: 5 | file: ./starter.graphql 6 | dataSources: 7 | - kind: ethereum/contract 8 | name: DODOStarterFactory 9 | network: rinkeby 10 | source: 11 | address: '0xc3cF2F9faAeE87b67E4ceAb3F67B6074Ae939cF3' 12 | abi: DODOStarterFactory 13 | startBlock: 11200914 14 | mapping: 15 | kind: ethereum/events 16 | apiVersion: 0.0.4 17 | language: wasm/assemblyscript 18 | file: ../../src/mappings/starter/factory.ts 19 | entities: 20 | - DodoStarter 21 | - Starter 22 | - DepositHistory 23 | - ClaimHistory 24 | - WithdrawFundHistory 25 | abis: 26 | - name: DODOStarterFactory 27 | file: ../../abis/DODOStarterFactory.json 28 | eventHandlers: 29 | - event: NewFairFund(address,address,address,address) 30 | handler: handleNewFairFund 31 | - event: NewInstantFund(address,address,address,address) 32 | handler: handleNewInstantFund 33 | templates: 34 | - kind: ethereum/contract 35 | name: FairFunding 36 | network: rinkeby 37 | source: 38 | abi: FairFunding 39 | mapping: 40 | kind: ethereum/events 41 | apiVersion: 0.0.4 42 | language: wasm/assemblyscript 43 | file: ../../src/mappings/starter/fair.ts 44 | entities: 45 | - User 46 | - Token 47 | - UserTokenBlance 48 | - TransferHistories 49 | abis: 50 | - name: FairFunding 51 | file: ../../abis/FairFunding.json 52 | eventHandlers: 53 | - event: DepositFund(indexed address,uint256) 54 | handler: handleDepositFund 55 | - event: WithdrawFund(indexed address,indexed address,uint256,bool) 56 | handler: handleWithdrawFund 57 | - event: ClaimToken(indexed address,indexed address,uint256,uint256) 58 | handler: handleClaimToken 59 | - kind: ethereum/contract 60 | name: InstantFunding 61 | network: rinkeby 62 | source: 63 | abi: InstantFunding 64 | mapping: 65 | kind: ethereum/events 66 | apiVersion: 0.0.4 67 | language: wasm/assemblyscript 68 | file: ../../src/mappings/starter/instant.ts 69 | entities: 70 | - User 71 | - Token 72 | - UserTokenBlance 73 | - TransferHistories 74 | abis: 75 | - name: InstantFunding 76 | file: ../../abis/InstantFunding.json 77 | eventHandlers: 78 | - event: DepositFund(indexed address,uint256,uint256) 79 | handler: handleDepositFund 80 | - event: ClaimToken(indexed address,indexed address,uint256) 81 | handler: handleClaimToken -------------------------------------------------------------------------------- /subgraphs/token/token.graphql: -------------------------------------------------------------------------------- 1 | type DodoToken @entity { 2 | "DODO Token" 3 | id:ID! 4 | "tokens count" 5 | tokens: BigInt! 6 | "updatedAt" 7 | updatedAt:BigInt! 8 | } 9 | 10 | type User @entity { 11 | "user address" 12 | id: ID! 13 | "tokens" 14 | tokens: [Token!] 15 | "timestamp" 16 | timestamp: BigInt! 17 | "updatedAt" 18 | updatedAt:BigInt! 19 | } 20 | 21 | type Token @entity { 22 | "token address" 23 | id: ID! 24 | "token symbol" 25 | symbol: String! 26 | "token name" 27 | name: String! 28 | "token decimals" 29 | decimals: BigInt! 30 | "total supply" 31 | totalSupply: BigInt! 32 | "creator" 33 | creator: String! 34 | "create timestamp" 35 | timestamp: BigInt! 36 | "erc20Type" 37 | type: BigInt! 38 | "holder count" 39 | holderCount: BigInt! 40 | "updatedAt" 41 | updatedAt:BigInt! 42 | } 43 | 44 | type UserTokenBlance @entity{ 45 | "user address - token address" 46 | id: ID! 47 | "balance" 48 | balance: BigDecimal! 49 | "updatedAt" 50 | updatedAt:BigInt! 51 | } 52 | 53 | type TransferHistory @entity{ 54 | "token - hash" 55 | id: ID! 56 | "from" 57 | from: User! 58 | "to" 59 | to: User! 60 | "amount" 61 | amount: BigDecimal! 62 | "updatedAt" 63 | updatedAt:BigInt! 64 | } -------------------------------------------------------------------------------- /subgraphs/token/token_arb-sep.yaml: -------------------------------------------------------------------------------- 1 | specVersion: 0.0.6 2 | description: Dodoex.io 3 | repository: https://github.com/DODOEX/dodoex_v2_subgraph 4 | schema: 5 | file: ./token.graphql 6 | dataSources: 7 | - kind: ethereum/contract 8 | name: ERC20V3Factory 9 | network: arbitrum-sepolia 10 | source: 11 | address: '0xf51705E360f706f46b83029A6f42Cb7b491a24dd' 12 | abi: ERC20V3Factory 13 | startBlock: 64710120 14 | mapping: 15 | kind: ethereum/events 16 | apiVersion: 0.0.6 17 | language: wasm/assemblyscript 18 | file: ../../src/mappings/token/factoryv2.ts 19 | entities: 20 | - User 21 | - Token 22 | - UserTokenBlance 23 | - TransferHistories 24 | abis: 25 | - name: ERC20Factory 26 | file: ../../abis/ERC20Factory.json 27 | - name: ERC20V2Factory 28 | file: ../../abis/ERC20V2Factory.json 29 | - name: ERC20V3Factory 30 | file: ../../abis/ERC20V3Factory.json 31 | - name: ERC20 32 | file: ../../abis/ERC20.json 33 | - name: ERC20SymbolBytes 34 | file: ../../abis/ERC20SymbolBytes.json 35 | - name: ERC20NameBytes 36 | file: ../../abis/ERC20NameBytes.json 37 | eventHandlers: 38 | - event: NewERC20(address,address,uint256) 39 | handler: handleNewERC20 40 | -------------------------------------------------------------------------------- /subgraphs/token/token_arbitrum.yaml: -------------------------------------------------------------------------------- 1 | specVersion: 0.0.2 2 | description: Dodoex.io 3 | repository: https://github.com/DODOEX/dodoex_v2_subgraph 4 | schema: 5 | file: ./token.graphql 6 | dataSources: 7 | - kind: ethereum/contract 8 | name: ERC20V2Factory 9 | network: arbitrum-one 10 | source: 11 | address: '0x750B153E6a69DCA16eb12D5aEdDFD80ca3f10d1C' 12 | abi: ERC20V2Factory 13 | startBlock: 226000 14 | mapping: 15 | kind: ethereum/events 16 | apiVersion: 0.0.4 17 | language: wasm/assemblyscript 18 | file: ../../src/mappings/token/factoryv2.ts 19 | entities: 20 | - User 21 | - Token 22 | - UserTokenBlance 23 | - TransferHistories 24 | abis: 25 | - name: ERC20Factory 26 | file: ../../abis/ERC20Factory.json 27 | - name: ERC20V2Factory 28 | file: ../../abis/ERC20V2Factory.json 29 | - name: ERC20 30 | file: ../../abis/ERC20.json 31 | - name: ERC20SymbolBytes 32 | file: ../../abis/ERC20SymbolBytes.json 33 | - name: ERC20NameBytes 34 | file: ../../abis/ERC20NameBytes.json 35 | eventHandlers: 36 | - event: NewERC20(address,address,uint256) 37 | handler: handleNewERC20 38 | - kind: ethereum/contract 39 | name: ERC20V3Factory 40 | network: arbitrum-one 41 | source: 42 | address: '0x5ca5e03228a3c16ef262d29e588adb6c2445fdbc' 43 | abi: ERC20V3Factory 44 | startBlock: 6524514 45 | mapping: 46 | kind: ethereum/events 47 | apiVersion: 0.0.4 48 | language: wasm/assemblyscript 49 | file: ../../src/mappings/token/factoryv2.ts 50 | entities: 51 | - User 52 | - Token 53 | - UserTokenBlance 54 | - TransferHistories 55 | abis: 56 | - name: ERC20Factory 57 | file: ../../abis/ERC20Factory.json 58 | - name: ERC20V2Factory 59 | file: ../../abis/ERC20V2Factory.json 60 | - name: ERC20V3Factory 61 | file: ../../abis/ERC20V3Factory.json 62 | - name: ERC20 63 | file: ../../abis/ERC20.json 64 | - name: ERC20SymbolBytes 65 | file: ../../abis/ERC20SymbolBytes.json 66 | - name: ERC20NameBytes 67 | file: ../../abis/ERC20NameBytes.json 68 | eventHandlers: 69 | - event: NewERC20(address,address,uint256) 70 | handler: handleNewERC20 71 | -------------------------------------------------------------------------------- /subgraphs/token/token_arbitrum_rinkeby.yaml: -------------------------------------------------------------------------------- 1 | specVersion: 0.0.2 2 | description: Dodoex.io 3 | repository: https://github.com/DODOEX/dodoex_v2_subgraph 4 | schema: 5 | file: ./token.graphql 6 | dataSources: 7 | - kind: ethereum/contract 8 | name: ERC20V3Factory 9 | network: arbitrum-rinkeby 10 | source: 11 | address: '0x585adbb35d0ee28b0d2adc7213284d37bab7ea4b' 12 | abi: ERC20V3Factory 13 | startBlock: 13987587 14 | mapping: 15 | kind: ethereum/events 16 | apiVersion: 0.0.4 17 | language: wasm/assemblyscript 18 | file: ../../src/mappings/token/factoryv2.ts 19 | entities: 20 | - User 21 | - Token 22 | - UserTokenBlance 23 | - TransferHistories 24 | abis: 25 | - name: ERC20Factory 26 | file: ../../abis/ERC20Factory.json 27 | - name: ERC20V2Factory 28 | file: ../../abis/ERC20V2Factory.json 29 | - name: ERC20V3Factory 30 | file: ../../abis/ERC20V3Factory.json 31 | - name: ERC20 32 | file: ../../abis/ERC20.json 33 | - name: ERC20SymbolBytes 34 | file: ../../abis/ERC20SymbolBytes.json 35 | - name: ERC20NameBytes 36 | file: ../../abis/ERC20NameBytes.json 37 | eventHandlers: 38 | - event: NewERC20(address,address,uint256) 39 | handler: handleNewERC20 40 | -------------------------------------------------------------------------------- /subgraphs/token/token_aurora.yaml: -------------------------------------------------------------------------------- 1 | specVersion: 0.0.6 2 | description: Dodoex.io 3 | schema: 4 | file: ./token.graphql 5 | dataSources: 6 | - kind: ethereum/contract 7 | name: ERC20V2Factory 8 | network: aurora 9 | source: 10 | address: '0xDfaf9584F5d229A9DBE5978523317820A8897C5A' 11 | abi: ERC20V2Factory 12 | startBlock: 51265155 13 | mapping: 14 | kind: ethereum/events 15 | apiVersion: 0.0.6 16 | language: wasm/assemblyscript 17 | file: ../../src/mappings/token/factoryv2.ts 18 | entities: 19 | - User 20 | - Token 21 | - UserTokenBlance 22 | - TransferHistories 23 | abis: 24 | - name: ERC20Factory 25 | file: ../../abis/ERC20Factory.json 26 | - name: ERC20V2Factory 27 | file: ../../abis/ERC20V2Factory.json 28 | - name: ERC20 29 | file: ../../abis/ERC20.json 30 | - name: ERC20SymbolBytes 31 | file: ../../abis/ERC20SymbolBytes.json 32 | - name: ERC20NameBytes 33 | file: ../../abis/ERC20NameBytes.json 34 | eventHandlers: 35 | - event: NewERC20(address,address,uint256) 36 | handler: handleNewERC20 37 | - kind: ethereum/contract 38 | name: ERC20V3Factory 39 | network: aurora 40 | source: 41 | address: '0xD6Bd9f3d4ad1b4464e8DdfF2da2bcAC1ff55D868' 42 | abi: ERC20V3Factory 43 | startBlock: 60025406 44 | mapping: 45 | kind: ethereum/events 46 | apiVersion: 0.0.6 47 | language: wasm/assemblyscript 48 | file: ../../src/mappings/token/factoryv2.ts 49 | entities: 50 | - User 51 | - Token 52 | - UserTokenBlance 53 | - TransferHistories 54 | abis: 55 | - name: ERC20Factory 56 | file: ../../abis/ERC20Factory.json 57 | - name: ERC20V2Factory 58 | file: ../../abis/ERC20V2Factory.json 59 | - name: ERC20V3Factory 60 | file: ../../abis/ERC20V3Factory.json 61 | - name: ERC20 62 | file: ../../abis/ERC20.json 63 | - name: ERC20SymbolBytes 64 | file: ../../abis/ERC20SymbolBytes.json 65 | - name: ERC20NameBytes 66 | file: ../../abis/ERC20NameBytes.json 67 | eventHandlers: 68 | - event: NewERC20(address,address,uint256) 69 | handler: handleNewERC20 70 | -------------------------------------------------------------------------------- /subgraphs/token/token_avax.yaml: -------------------------------------------------------------------------------- 1 | specVersion: 0.0.2 2 | description: Dodoex.io 3 | repository: https://github.com/DODOEX/dodoex_v2_subgraph 4 | schema: 5 | file: ./token.graphql 6 | dataSources: 7 | - kind: ethereum/contract 8 | name: ERC20V2Factory 9 | network: avalanche 10 | source: 11 | address: '0x141b4497a298340e8b451ac4eee947b00adbe07a' 12 | abi: ERC20V2Factory 13 | startBlock: 8489207 14 | mapping: 15 | kind: ethereum/events 16 | apiVersion: 0.0.4 17 | language: wasm/assemblyscript 18 | file: ../../src/mappings/token/factoryv2.ts 19 | entities: 20 | - User 21 | - Token 22 | - UserTokenBlance 23 | - TransferHistories 24 | abis: 25 | - name: ERC20Factory 26 | file: ../../abis/ERC20Factory.json 27 | - name: ERC20V2Factory 28 | file: ../../abis/ERC20V2Factory.json 29 | - name: ERC20 30 | file: ../../abis/ERC20.json 31 | - name: ERC20SymbolBytes 32 | file: ../../abis/ERC20SymbolBytes.json 33 | - name: ERC20NameBytes 34 | file: ../../abis/ERC20NameBytes.json 35 | eventHandlers: 36 | - event: NewERC20(address,address,uint256) 37 | handler: handleNewERC20 38 | - kind: ethereum/contract 39 | name: ERC20V3Factory 40 | network: avalanche 41 | source: 42 | address: '0x00971e21955f1bb8021a5ef2546bec2ff896ee42' 43 | abi: ERC20V3Factory 44 | startBlock: 11196881 45 | mapping: 46 | kind: ethereum/events 47 | apiVersion: 0.0.4 48 | language: wasm/assemblyscript 49 | file: ../../src/mappings/token/factoryv2.ts 50 | entities: 51 | - User 52 | - Token 53 | - UserTokenBlance 54 | - TransferHistories 55 | abis: 56 | - name: ERC20Factory 57 | file: ../../abis/ERC20Factory.json 58 | - name: ERC20V2Factory 59 | file: ../../abis/ERC20V2Factory.json 60 | - name: ERC20V3Factory 61 | file: ../../abis/ERC20V3Factory.json 62 | - name: ERC20 63 | file: ../../abis/ERC20.json 64 | - name: ERC20SymbolBytes 65 | file: ../../abis/ERC20SymbolBytes.json 66 | - name: ERC20NameBytes 67 | file: ../../abis/ERC20NameBytes.json 68 | eventHandlers: 69 | - event: NewERC20(address,address,uint256) 70 | handler: handleNewERC20 71 | 72 | -------------------------------------------------------------------------------- /subgraphs/token/token_base_mainnet.yaml: -------------------------------------------------------------------------------- 1 | specVersion: 0.0.6 2 | description: Dodoex.io 3 | repository: https://github.com/DODOEX/dodoex_v2_subgraph 4 | schema: 5 | file: ./token.graphql 6 | dataSources: 7 | # - kind: ethereum/contract 8 | # name: ERC20V2Factory 9 | # network: base 10 | # source: 11 | # address: '0x4E4f8d8742822AF3B0E61cF6B2725Ff64515ce84' 12 | # abi: ERC20V2Factory 13 | # startBlock: 3435939 14 | # mapping: 15 | # kind: ethereum/events 16 | # apiVersion: 0.0.6 17 | # language: wasm/assemblyscript 18 | # file: ../../src/mappings/token/factoryv2.ts 19 | # entities: 20 | # - User 21 | # - Token 22 | # - UserTokenBlance 23 | # - TransferHistories 24 | # abis: 25 | # - name: ERC20Factory 26 | # file: ../../abis/ERC20Factory.json 27 | # - name: ERC20V2Factory 28 | # file: ../../abis/ERC20V2Factory.json 29 | # - name: ERC20 30 | # file: ../../abis/ERC20.json 31 | # - name: ERC20SymbolBytes 32 | # file: ../../abis/ERC20SymbolBytes.json 33 | # - name: ERC20NameBytes 34 | # file: ../../abis/ERC20NameBytes.json 35 | # eventHandlers: 36 | # - event: NewERC20(address,address,uint256) 37 | # handler: handleNewERC20 38 | - kind: ethereum/contract 39 | name: ERC20V3Factory 40 | network: base 41 | source: 42 | address: '0xCb3dC90E800C961d4a206BeAAFd92A6d2E06495e' 43 | abi: ERC20V3Factory 44 | startBlock: 1992320 45 | mapping: 46 | kind: ethereum/events 47 | apiVersion: 0.0.6 48 | language: wasm/assemblyscript 49 | file: ../../src/mappings/token/factoryv2.ts 50 | entities: 51 | - User 52 | - Token 53 | - UserTokenBlance 54 | - TransferHistories 55 | abis: 56 | - name: ERC20Factory 57 | file: ../../abis/ERC20Factory.json 58 | - name: ERC20V2Factory 59 | file: ../../abis/ERC20V2Factory.json 60 | - name: ERC20V3Factory 61 | file: ../../abis/ERC20V3Factory.json 62 | - name: ERC20 63 | file: ../../abis/ERC20.json 64 | - name: ERC20SymbolBytes 65 | file: ../../abis/ERC20SymbolBytes.json 66 | - name: ERC20NameBytes 67 | file: ../../abis/ERC20NameBytes.json 68 | eventHandlers: 69 | - event: NewERC20(address,address,uint256) 70 | handler: handleNewERC20 71 | -------------------------------------------------------------------------------- /subgraphs/token/token_basegor.yaml: -------------------------------------------------------------------------------- 1 | specVersion: 0.0.6 2 | description: Dodoex.io 3 | repository: https://github.com/DODOEX/dodoex_v2_subgraph 4 | schema: 5 | file: ./token.graphql 6 | dataSources: 7 | - kind: ethereum/contract 8 | name: ERC20V2Factory 9 | network: base-testnet 10 | source: 11 | address: '0x4E4f8d8742822AF3B0E61cF6B2725Ff64515ce84' 12 | abi: ERC20V2Factory 13 | startBlock: 3435939 14 | mapping: 15 | kind: ethereum/events 16 | apiVersion: 0.0.6 17 | language: wasm/assemblyscript 18 | file: ../../src/mappings/token/factoryv2.ts 19 | entities: 20 | - User 21 | - Token 22 | - UserTokenBlance 23 | - TransferHistories 24 | abis: 25 | - name: ERC20Factory 26 | file: ../../abis/ERC20Factory.json 27 | - name: ERC20V2Factory 28 | file: ../../abis/ERC20V2Factory.json 29 | - name: ERC20 30 | file: ../../abis/ERC20.json 31 | - name: ERC20SymbolBytes 32 | file: ../../abis/ERC20SymbolBytes.json 33 | - name: ERC20NameBytes 34 | file: ../../abis/ERC20NameBytes.json 35 | eventHandlers: 36 | - event: NewERC20(address,address,uint256) 37 | handler: handleNewERC20 38 | - kind: ethereum/contract 39 | name: ERC20V3Factory 40 | network: base-testnet 41 | source: 42 | address: '0xcC1ddBe8654bb807106550903e5B910AA8782578' 43 | abi: ERC20V3Factory 44 | startBlock: 3436432 45 | mapping: 46 | kind: ethereum/events 47 | apiVersion: 0.0.6 48 | language: wasm/assemblyscript 49 | file: ../../src/mappings/token/factoryv2.ts 50 | entities: 51 | - User 52 | - Token 53 | - UserTokenBlance 54 | - TransferHistories 55 | abis: 56 | - name: ERC20Factory 57 | file: ../../abis/ERC20Factory.json 58 | - name: ERC20V2Factory 59 | file: ../../abis/ERC20V2Factory.json 60 | - name: ERC20V3Factory 61 | file: ../../abis/ERC20V3Factory.json 62 | - name: ERC20 63 | file: ../../abis/ERC20.json 64 | - name: ERC20SymbolBytes 65 | file: ../../abis/ERC20SymbolBytes.json 66 | - name: ERC20NameBytes 67 | file: ../../abis/ERC20NameBytes.json 68 | eventHandlers: 69 | - event: NewERC20(address,address,uint256) 70 | handler: handleNewERC20 71 | -------------------------------------------------------------------------------- /subgraphs/token/token_bitlayer.yaml: -------------------------------------------------------------------------------- 1 | specVersion: 0.0.6 2 | description: Dodoex.io 3 | repository: https://github.com/DODOEX/dodoex_v2_subgraph 4 | schema: 5 | file: ./token.graphql 6 | dataSources: 7 | - kind: ethereum/contract 8 | name: ERC20V3Factory 9 | network: bitlayer 10 | source: 11 | address: '0xe8bD8C45e8D0638d1Bfd39bC3B06534631DB3F13' 12 | abi: ERC20V3Factory 13 | startBlock: 2019532 14 | mapping: 15 | kind: ethereum/events 16 | apiVersion: 0.0.6 17 | language: wasm/assemblyscript 18 | file: ../../src/mappings/token/factoryv2.ts 19 | entities: 20 | - User 21 | - Token 22 | - UserTokenBlance 23 | - TransferHistories 24 | abis: 25 | - name: ERC20Factory 26 | file: ../../abis/ERC20Factory.json 27 | - name: ERC20V2Factory 28 | file: ../../abis/ERC20V2Factory.json 29 | - name: ERC20V3Factory 30 | file: ../../abis/ERC20V3Factory.json 31 | - name: ERC20 32 | file: ../../abis/ERC20.json 33 | - name: ERC20SymbolBytes 34 | file: ../../abis/ERC20SymbolBytes.json 35 | - name: ERC20NameBytes 36 | file: ../../abis/ERC20NameBytes.json 37 | eventHandlers: 38 | - event: NewERC20(address,address,uint256) 39 | handler: handleNewERC20 40 | -------------------------------------------------------------------------------- /subgraphs/token/token_boba.yaml: -------------------------------------------------------------------------------- 1 | specVersion: 0.0.2 2 | description: Dodoex.io 3 | repository: https://github.com/DODOEX/dodoex_v2_subgraph 4 | schema: 5 | file: ./token.graphql 6 | dataSources: 7 | - kind: ethereum/contract 8 | name: ERC20V2Factory 9 | network: boba 10 | source: 11 | address: '0x313fcb27BD83607C33998AA60E409C79Fb2251fd' 12 | abi: ERC20V2Factory 13 | startBlock: 428 14 | mapping: 15 | kind: ethereum/events 16 | apiVersion: 0.0.4 17 | language: wasm/assemblyscript 18 | file: ../../src/mappings/token/factoryv2.ts 19 | entities: 20 | - User 21 | - Token 22 | - UserTokenBlance 23 | - TransferHistories 24 | abis: 25 | - name: ERC20Factory 26 | file: ../../abis/ERC20Factory.json 27 | - name: ERC20V2Factory 28 | file: ../../abis/ERC20V2Factory.json 29 | - name: ERC20 30 | file: ../../abis/ERC20.json 31 | - name: ERC20SymbolBytes 32 | file: ../../abis/ERC20SymbolBytes.json 33 | - name: ERC20NameBytes 34 | file: ../../abis/ERC20NameBytes.json 35 | eventHandlers: 36 | - event: NewERC20(address,address,uint256) 37 | handler: handleNewERC20 38 | - kind: ethereum/contract 39 | name: ERC20V3Factory 40 | network: boba 41 | source: 42 | address: '0x2DdAD36517d5795120bd38F1d87E434C25f60Eca' 43 | abi: ERC20V3Factory 44 | startBlock: 428 45 | mapping: 46 | kind: ethereum/events 47 | apiVersion: 0.0.4 48 | language: wasm/assemblyscript 49 | file: ../../src/mappings/token/factoryv2.ts 50 | entities: 51 | - User 52 | - Token 53 | - UserTokenBlance 54 | - TransferHistories 55 | abis: 56 | - name: ERC20Factory 57 | file: ../../abis/ERC20Factory.json 58 | - name: ERC20V2Factory 59 | file: ../../abis/ERC20V2Factory.json 60 | - name: ERC20V3Factory 61 | file: ../../abis/ERC20V3Factory.json 62 | - name: ERC20 63 | file: ../../abis/ERC20.json 64 | - name: ERC20SymbolBytes 65 | file: ../../abis/ERC20SymbolBytes.json 66 | - name: ERC20NameBytes 67 | file: ../../abis/ERC20NameBytes.json 68 | eventHandlers: 69 | - event: NewERC20(address,address,uint256) 70 | handler: handleNewERC20 71 | 72 | -------------------------------------------------------------------------------- /subgraphs/token/token_cfx.yaml: -------------------------------------------------------------------------------- 1 | specVersion: 0.0.6 2 | description: Dodoex.io 3 | repository: https://github.com/DODOEX/dodoex_v2_subgraph 4 | schema: 5 | file: ./token.graphql 6 | dataSources: 7 | - kind: ethereum/contract 8 | name: ERC20V3Factory 9 | network: cfx 10 | source: 11 | address: '0x585adbB35d0eE28B0d2AdC7213284D37bab7EA4B' 12 | abi: ERC20V3Factory 13 | startBlock: 70692290 14 | mapping: 15 | kind: ethereum/events 16 | apiVersion: 0.0.6 17 | language: wasm/assemblyscript 18 | file: ../../src/mappings/token/factoryv2.ts 19 | entities: 20 | - User 21 | - Token 22 | - UserTokenBlance 23 | - TransferHistories 24 | abis: 25 | - name: ERC20Factory 26 | file: ../../abis/ERC20Factory.json 27 | - name: ERC20V2Factory 28 | file: ../../abis/ERC20V2Factory.json 29 | - name: ERC20V3Factory 30 | file: ../../abis/ERC20V3Factory.json 31 | - name: ERC20 32 | file: ../../abis/ERC20.json 33 | - name: ERC20SymbolBytes 34 | file: ../../abis/ERC20SymbolBytes.json 35 | - name: ERC20NameBytes 36 | file: ../../abis/ERC20NameBytes.json 37 | eventHandlers: 38 | - event: NewERC20(address,address,uint256) 39 | handler: handleNewERC20 40 | -------------------------------------------------------------------------------- /subgraphs/token/token_cronos.yaml: -------------------------------------------------------------------------------- 1 | specVersion: 0.0.2 2 | description: Dodoex.io 3 | repository: https://github.com/DODOEX/dodoex_v2_subgraph 4 | schema: 5 | file: ./token.graphql 6 | dataSources: 7 | - kind: ethereum/contract 8 | name: ERC20V3Factory 9 | network: cronos 10 | source: 11 | address: '0x57A5A387BE79dedf6a6C4CBC5dF443EC2f8b1eFB' 12 | abi: ERC20V3Factory 13 | startBlock: 2482000 14 | mapping: 15 | kind: ethereum/events 16 | apiVersion: 0.0.4 17 | language: wasm/assemblyscript 18 | file: ../../src/mappings/token/factoryv2.ts 19 | entities: 20 | - User 21 | - Token 22 | - UserTokenBlance 23 | - TransferHistories 24 | abis: 25 | - name: ERC20Factory 26 | file: ../../abis/ERC20Factory.json 27 | - name: ERC20V2Factory 28 | file: ../../abis/ERC20V2Factory.json 29 | - name: ERC20V3Factory 30 | file: ../../abis/ERC20V3Factory.json 31 | - name: ERC20 32 | file: ../../abis/ERC20.json 33 | - name: ERC20SymbolBytes 34 | file: ../../abis/ERC20SymbolBytes.json 35 | - name: ERC20NameBytes 36 | file: ../../abis/ERC20NameBytes.json 37 | eventHandlers: 38 | - event: NewERC20(address,address,uint256) 39 | handler: handleNewERC20 40 | -------------------------------------------------------------------------------- /subgraphs/token/token_dodochain-testnet.yaml: -------------------------------------------------------------------------------- 1 | specVersion: 0.0.6 2 | description: Dodoex.io 3 | repository: https://github.com/DODOEX/dodoex_v2_subgraph 4 | schema: 5 | file: ./token.graphql 6 | dataSources: 7 | - kind: ethereum/contract 8 | name: ERC20V3Factory 9 | network: dodochain-testnet3 10 | source: 11 | address: '0xDC249Ea92D2e532ed63B45dc7C05B21926B97c6F' 12 | abi: ERC20V3Factory 13 | startBlock: 58 14 | mapping: 15 | kind: ethereum/events 16 | apiVersion: 0.0.6 17 | language: wasm/assemblyscript 18 | file: ../../src/mappings/token/factoryv2.ts 19 | entities: 20 | - User 21 | - Token 22 | - UserTokenBlance 23 | - TransferHistories 24 | abis: 25 | - name: ERC20Factory 26 | file: ../../abis/ERC20Factory.json 27 | - name: ERC20V2Factory 28 | file: ../../abis/ERC20V2Factory.json 29 | - name: ERC20V3Factory 30 | file: ../../abis/ERC20V3Factory.json 31 | - name: ERC20 32 | file: ../../abis/ERC20.json 33 | - name: ERC20SymbolBytes 34 | file: ../../abis/ERC20SymbolBytes.json 35 | - name: ERC20NameBytes 36 | file: ../../abis/ERC20NameBytes.json 37 | eventHandlers: 38 | - event: NewERC20(address,address,uint256) 39 | handler: handleNewERC20 40 | -------------------------------------------------------------------------------- /subgraphs/token/token_goerli.yaml: -------------------------------------------------------------------------------- 1 | specVersion: 0.0.2 2 | description: Dodoex.io 3 | repository: https://github.com/DODOEX/dodoex_v2_subgraph 4 | schema: 5 | file: ./token.graphql 6 | dataSources: 7 | - kind: ethereum/contract 8 | name: ERC20V3Factory 9 | network: goerli 10 | source: 11 | address: '0xde1eCf0f7C8141FfC2149405947206f76951816e' 12 | abi: ERC20V3Factory 13 | startBlock: 7462578 14 | mapping: 15 | kind: ethereum/events 16 | apiVersion: 0.0.4 17 | language: wasm/assemblyscript 18 | file: ../../src/mappings/token/factoryv2.ts 19 | entities: 20 | - User 21 | - Token 22 | - UserTokenBlance 23 | - TransferHistories 24 | abis: 25 | - name: ERC20Factory 26 | file: ../../abis/ERC20Factory.json 27 | - name: ERC20V2Factory 28 | file: ../../abis/ERC20V2Factory.json 29 | - name: ERC20V3Factory 30 | file: ../../abis/ERC20V3Factory.json 31 | - name: ERC20 32 | file: ../../abis/ERC20.json 33 | - name: ERC20SymbolBytes 34 | file: ../../abis/ERC20SymbolBytes.json 35 | - name: ERC20NameBytes 36 | file: ../../abis/ERC20NameBytes.json 37 | eventHandlers: 38 | - event: NewERC20(address,address,uint256) 39 | handler: handleNewERC20 40 | templates: 41 | - kind: ethereum/contract 42 | name: MintableERC20 43 | network: goerli 44 | source: 45 | abi: MintableERC20 46 | mapping: 47 | kind: ethereum/events 48 | apiVersion: 0.0.4 49 | language: wasm/assemblyscript 50 | file: ../../src/mappings/token/mintableERC20.ts 51 | entities: 52 | - User 53 | - Token 54 | - UserTokenBlance 55 | - TransferHistories 56 | abis: 57 | - name: MintableERC20 58 | file: ../../abis/MintableERC20.json 59 | eventHandlers: 60 | - event: Transfer(indexed address,indexed address,uint256) 61 | handler: handleTransfer 62 | - event: Mint(indexed address,uint256) 63 | handler: handleMint 64 | - event: Burn(indexed address,uint256) 65 | handler: handleBurn -------------------------------------------------------------------------------- /subgraphs/token/token_kcc.yaml: -------------------------------------------------------------------------------- 1 | specVersion: 0.0.2 2 | description: Dodoex.io 3 | repository: https://github.com/DODOEX/dodoex_v2_subgraph 4 | schema: 5 | file: ./token.graphql 6 | dataSources: 7 | - kind: ethereum/contract 8 | name: ERC20V3Factory 9 | network: kcc 10 | source: 11 | address: '0x5a0C840a7089aa222c4458b3BE0947fe5a5006DE' 12 | abi: ERC20V3Factory 13 | startBlock: 13155477 14 | mapping: 15 | kind: ethereum/events 16 | apiVersion: 0.0.4 17 | language: wasm/assemblyscript 18 | file: ../../src/mappings/token/factoryv2.ts 19 | entities: 20 | - User 21 | - Token 22 | - UserTokenBlance 23 | - TransferHistories 24 | abis: 25 | - name: ERC20Factory 26 | file: ../../abis/ERC20Factory.json 27 | - name: ERC20V2Factory 28 | file: ../../abis/ERC20V2Factory.json 29 | - name: ERC20V3Factory 30 | file: ../../abis/ERC20V3Factory.json 31 | - name: ERC20 32 | file: ../../abis/ERC20.json 33 | - name: ERC20SymbolBytes 34 | file: ../../abis/ERC20SymbolBytes.json 35 | - name: ERC20NameBytes 36 | file: ../../abis/ERC20NameBytes.json 37 | eventHandlers: 38 | - event: NewERC20(address,address,uint256) 39 | handler: handleNewERC20 40 | templates: 41 | - kind: ethereum/contract 42 | name: MintableERC20 43 | network: kcc 44 | source: 45 | abi: MintableERC20 46 | mapping: 47 | kind: ethereum/events 48 | apiVersion: 0.0.4 49 | language: wasm/assemblyscript 50 | file: ../../src/mappings/token/mintableERC20.ts 51 | entities: 52 | - User 53 | - Token 54 | - UserTokenBlance 55 | - TransferHistories 56 | abis: 57 | - name: MintableERC20 58 | file: ../../abis/MintableERC20.json 59 | eventHandlers: 60 | - event: Transfer(indexed address,indexed address,uint256) 61 | handler: handleTransfer 62 | - event: Mint(indexed address,uint256) 63 | handler: handleMint 64 | - event: Burn(indexed address,uint256) 65 | handler: handleBurn -------------------------------------------------------------------------------- /subgraphs/token/token_linea.yaml: -------------------------------------------------------------------------------- 1 | specVersion: 0.0.6 2 | description: Dodoex.io 3 | repository: https://github.com/DODOEX/dodoex_v2_subgraph 4 | schema: 5 | file: ./token.graphql 6 | dataSources: 7 | # - kind: ethereum/contract 8 | # name: ERC20V2Factory 9 | # network: linea 10 | # source: 11 | # address: '0x4E4f8d8742822AF3B0E61cF6B2725Ff64515ce84' 12 | # abi: ERC20V2Factory 13 | # startBlock: 3435939 14 | # mapping: 15 | # kind: ethereum/events 16 | # apiVersion: 0.0.6 17 | # language: wasm/assemblyscript 18 | # file: ../../src/mappings/token/factoryv2.ts 19 | # entities: 20 | # - User 21 | # - Token 22 | # - UserTokenBlance 23 | # - TransferHistories 24 | # abis: 25 | # - name: ERC20Factory 26 | # file: ../../abis/ERC20Factory.json 27 | # - name: ERC20V2Factory 28 | # file: ../../abis/ERC20V2Factory.json 29 | # - name: ERC20 30 | # file: ../../abis/ERC20.json 31 | # - name: ERC20SymbolBytes 32 | # file: ../../abis/ERC20SymbolBytes.json 33 | # - name: ERC20NameBytes 34 | # file: ../../abis/ERC20NameBytes.json 35 | # eventHandlers: 36 | # - event: NewERC20(address,address,uint256) 37 | # handler: handleNewERC20 38 | - kind: ethereum/contract 39 | name: ERC20V3Factory 40 | network: linea 41 | source: 42 | address: '0x0226fCE8c969604C3A0AD19c37d1FAFac73e13c2' 43 | abi: ERC20V3Factory 44 | startBlock: 91463 45 | mapping: 46 | kind: ethereum/events 47 | apiVersion: 0.0.6 48 | language: wasm/assemblyscript 49 | file: ../../src/mappings/token/factoryv2.ts 50 | entities: 51 | - User 52 | - Token 53 | - UserTokenBlance 54 | - TransferHistories 55 | abis: 56 | - name: ERC20Factory 57 | file: ../../abis/ERC20Factory.json 58 | - name: ERC20V2Factory 59 | file: ../../abis/ERC20V2Factory.json 60 | - name: ERC20V3Factory 61 | file: ../../abis/ERC20V3Factory.json 62 | - name: ERC20 63 | file: ../../abis/ERC20.json 64 | - name: ERC20SymbolBytes 65 | file: ../../abis/ERC20SymbolBytes.json 66 | - name: ERC20NameBytes 67 | file: ../../abis/ERC20NameBytes.json 68 | eventHandlers: 69 | - event: NewERC20(address,address,uint256) 70 | handler: handleNewERC20 71 | -------------------------------------------------------------------------------- /subgraphs/token/token_manta.yaml: -------------------------------------------------------------------------------- 1 | specVersion: 0.0.6 2 | description: Dodoex.io 3 | repository: https://github.com/DODOEX/dodoex_v2_subgraph 4 | schema: 5 | file: ./token.graphql 6 | dataSources: 7 | # - kind: ethereum/contract 8 | # name: ERC20V2Factory 9 | # network: manta 10 | # source: 11 | # address: '0x4E4f8d8742822AF3B0E61cF6B2725Ff64515ce84' 12 | # abi: ERC20V2Factory 13 | # startBlock: 3435939 14 | # mapping: 15 | # kind: ethereum/events 16 | # apiVersion: 0.0.6 17 | # language: wasm/assemblyscript 18 | # file: ../../src/mappings/token/factoryv2.ts 19 | # entities: 20 | # - User 21 | # - Token 22 | # - UserTokenBlance 23 | # - TransferHistories 24 | # abis: 25 | # - name: ERC20Factory 26 | # file: ../../abis/ERC20Factory.json 27 | # - name: ERC20V2Factory 28 | # file: ../../abis/ERC20V2Factory.json 29 | # - name: ERC20 30 | # file: ../../abis/ERC20.json 31 | # - name: ERC20SymbolBytes 32 | # file: ../../abis/ERC20SymbolBytes.json 33 | # - name: ERC20NameBytes 34 | # file: ../../abis/ERC20NameBytes.json 35 | # eventHandlers: 36 | # - event: NewERC20(address,address,uint256) 37 | # handler: handleNewERC20 38 | - kind: ethereum/contract 39 | name: ERC20V3Factory 40 | network: manta 41 | source: 42 | address: '0xc0F9553Df63De5a97Fe64422c8578D0657C360f7' 43 | abi: ERC20V3Factory 44 | startBlock: 384132 45 | mapping: 46 | kind: ethereum/events 47 | apiVersion: 0.0.6 48 | language: wasm/assemblyscript 49 | file: ../../src/mappings/token/factoryv2.ts 50 | entities: 51 | - User 52 | - Token 53 | - UserTokenBlance 54 | - TransferHistories 55 | abis: 56 | - name: ERC20Factory 57 | file: ../../abis/ERC20Factory.json 58 | - name: ERC20V2Factory 59 | file: ../../abis/ERC20V2Factory.json 60 | - name: ERC20V3Factory 61 | file: ../../abis/ERC20V3Factory.json 62 | - name: ERC20 63 | file: ../../abis/ERC20.json 64 | - name: ERC20SymbolBytes 65 | file: ../../abis/ERC20SymbolBytes.json 66 | - name: ERC20NameBytes 67 | file: ../../abis/ERC20NameBytes.json 68 | eventHandlers: 69 | - event: NewERC20(address,address,uint256) 70 | handler: handleNewERC20 71 | -------------------------------------------------------------------------------- /subgraphs/token/token_mantle.yaml: -------------------------------------------------------------------------------- 1 | specVersion: 0.0.6 2 | description: Dodoex.io 3 | repository: https://github.com/DODOEX/dodoex_v2_subgraph 4 | schema: 5 | file: ./token.graphql 6 | dataSources: 7 | # - kind: ethereum/contract 8 | # name: ERC20V2Factory 9 | # network: mantle 10 | # source: 11 | # address: '0x4E4f8d8742822AF3B0E61cF6B2725Ff64515ce84' 12 | # abi: ERC20V2Factory 13 | # startBlock: 3435939 14 | # mapping: 15 | # kind: ethereum/events 16 | # apiVersion: 0.0.6 17 | # language: wasm/assemblyscript 18 | # file: ../../src/mappings/token/factoryv2.ts 19 | # entities: 20 | # - User 21 | # - Token 22 | # - UserTokenBlance 23 | # - TransferHistories 24 | # abis: 25 | # - name: ERC20Factory 26 | # file: ../../abis/ERC20Factory.json 27 | # - name: ERC20V2Factory 28 | # file: ../../abis/ERC20V2Factory.json 29 | # - name: ERC20 30 | # file: ../../abis/ERC20.json 31 | # - name: ERC20SymbolBytes 32 | # file: ../../abis/ERC20SymbolBytes.json 33 | # - name: ERC20NameBytes 34 | # file: ../../abis/ERC20NameBytes.json 35 | # eventHandlers: 36 | # - event: NewERC20(address,address,uint256) 37 | # handler: handleNewERC20 38 | - kind: ethereum/contract 39 | name: ERC20V3Factory 40 | network: mantle 41 | source: 42 | address: '0xFD2b7994f91c08aAa5e013E899334A2DBb500DF1' 43 | abi: ERC20V3Factory 44 | startBlock: 21053981 45 | mapping: 46 | kind: ethereum/events 47 | apiVersion: 0.0.6 48 | language: wasm/assemblyscript 49 | file: ../../src/mappings/token/factoryv2.ts 50 | entities: 51 | - User 52 | - Token 53 | - UserTokenBlance 54 | - TransferHistories 55 | abis: 56 | - name: ERC20Factory 57 | file: ../../abis/ERC20Factory.json 58 | - name: ERC20V2Factory 59 | file: ../../abis/ERC20V2Factory.json 60 | - name: ERC20V3Factory 61 | file: ../../abis/ERC20V3Factory.json 62 | - name: ERC20 63 | file: ../../abis/ERC20.json 64 | - name: ERC20SymbolBytes 65 | file: ../../abis/ERC20SymbolBytes.json 66 | - name: ERC20NameBytes 67 | file: ../../abis/ERC20NameBytes.json 68 | eventHandlers: 69 | - event: NewERC20(address,address,uint256) 70 | handler: handleNewERC20 71 | -------------------------------------------------------------------------------- /subgraphs/token/token_moonbeam.yaml: -------------------------------------------------------------------------------- 1 | specVersion: 0.0.2 2 | description: Dodoex.io 3 | repository: https://github.com/DODOEX/dodoex_v2_subgraph 4 | schema: 5 | file: ./token.graphql 6 | dataSources: 7 | - kind: ethereum/contract 8 | name: ERC20V2Factory 9 | network: mbase 10 | source: 11 | address: '0xaeb5cf31b97dce6134e416129845e01106ffb177' 12 | abi: ERC20V2Factory 13 | startBlock: 545211 14 | mapping: 15 | kind: ethereum/events 16 | apiVersion: 0.0.4 17 | language: wasm/assemblyscript 18 | file: ../../src/mappings/token/factoryv2.ts 19 | entities: 20 | - User 21 | - Token 22 | - UserTokenBlance 23 | - TransferHistories 24 | abis: 25 | - name: ERC20Factory 26 | file: ../../abis/ERC20Factory.json 27 | - name: ERC20V2Factory 28 | file: ../../abis/ERC20V2Factory.json 29 | - name: ERC20 30 | file: ../../abis/ERC20.json 31 | - name: ERC20SymbolBytes 32 | file: ../../abis/ERC20SymbolBytes.json 33 | - name: ERC20NameBytes 34 | file: ../../abis/ERC20NameBytes.json 35 | eventHandlers: 36 | - event: NewERC20(address,address,uint256) 37 | handler: handleNewERC20 38 | 39 | -------------------------------------------------------------------------------- /subgraphs/token/token_moonriver.yaml: -------------------------------------------------------------------------------- 1 | specVersion: 0.0.2 2 | description: Dodoex.io 3 | repository: https://github.com/DODOEX/dodoex_v2_subgraph 4 | schema: 5 | file: ./token.graphql 6 | dataSources: 7 | - kind: ethereum/contract 8 | name: ERC20V2Factory 9 | network: moonriver 10 | source: 11 | address: '0xaeb5cf31b97dce6134e416129845e01106ffb177' 12 | abi: ERC20V2Factory 13 | startBlock: 545211 14 | mapping: 15 | kind: ethereum/events 16 | apiVersion: 0.0.4 17 | language: wasm/assemblyscript 18 | file: ../../src/mappings/token/factoryv2.ts 19 | entities: 20 | - User 21 | - Token 22 | - UserTokenBlance 23 | - TransferHistories 24 | abis: 25 | - name: ERC20Factory 26 | file: ../../abis/ERC20Factory.json 27 | - name: ERC20V2Factory 28 | file: ../../abis/ERC20V2Factory.json 29 | - name: ERC20 30 | file: ../../abis/ERC20.json 31 | - name: ERC20SymbolBytes 32 | file: ../../abis/ERC20SymbolBytes.json 33 | - name: ERC20NameBytes 34 | file: ../../abis/ERC20NameBytes.json 35 | eventHandlers: 36 | - event: NewERC20(address,address,uint256) 37 | handler: handleNewERC20 38 | - kind: ethereum/contract 39 | name: ERC20V3Factory 40 | network: moonriver 41 | source: 42 | address: '0x1518e34156F12049b387620a7778685bf4d0D61B' 43 | abi: ERC20V3Factory 44 | startBlock: 1509867 45 | mapping: 46 | kind: ethereum/events 47 | apiVersion: 0.0.4 48 | language: wasm/assemblyscript 49 | file: ../../src/mappings/token/factoryv2.ts 50 | entities: 51 | - User 52 | - Token 53 | - UserTokenBlance 54 | - TransferHistories 55 | abis: 56 | - name: ERC20Factory 57 | file: ../../abis/ERC20Factory.json 58 | - name: ERC20V2Factory 59 | file: ../../abis/ERC20V2Factory.json 60 | - name: ERC20V3Factory 61 | file: ../../abis/ERC20V3Factory.json 62 | - name: ERC20 63 | file: ../../abis/ERC20.json 64 | - name: ERC20SymbolBytes 65 | file: ../../abis/ERC20SymbolBytes.json 66 | - name: ERC20NameBytes 67 | file: ../../abis/ERC20NameBytes.json 68 | eventHandlers: 69 | - event: NewERC20(address,address,uint256) 70 | handler: handleNewERC20 71 | 72 | -------------------------------------------------------------------------------- /subgraphs/token/token_okb.yaml: -------------------------------------------------------------------------------- 1 | specVersion: 0.0.6 2 | description: Dodoex.io 3 | repository: https://github.com/DODOEX/dodoex_v2_subgraph 4 | schema: 5 | file: ./token.graphql 6 | dataSources: 7 | - kind: ethereum/contract 8 | name: ERC20V3Factory 9 | network: okb 10 | source: 11 | address: '0x40b4030129FCFE660B4ecF35354e027260343049' 12 | abi: ERC20V3Factory 13 | startBlock: 299037 14 | mapping: 15 | kind: ethereum/events 16 | apiVersion: 0.0.6 17 | language: wasm/assemblyscript 18 | file: ../../src/mappings/token/factoryv2.ts 19 | entities: 20 | - User 21 | - Token 22 | - UserTokenBlance 23 | - TransferHistories 24 | abis: 25 | - name: ERC20Factory 26 | file: ../../abis/ERC20Factory.json 27 | - name: ERC20V2Factory 28 | file: ../../abis/ERC20V2Factory.json 29 | - name: ERC20V3Factory 30 | file: ../../abis/ERC20V3Factory.json 31 | - name: ERC20 32 | file: ../../abis/ERC20.json 33 | - name: ERC20SymbolBytes 34 | file: ../../abis/ERC20SymbolBytes.json 35 | - name: ERC20NameBytes 36 | file: ../../abis/ERC20NameBytes.json 37 | eventHandlers: 38 | - event: NewERC20(address,address,uint256) 39 | handler: handleNewERC20 40 | -------------------------------------------------------------------------------- /subgraphs/token/token_okchain.yaml: -------------------------------------------------------------------------------- 1 | specVersion: 0.0.2 2 | description: Dodoex.io 3 | repository: https://github.com/DODOEX/dodoex_v2_subgraph 4 | schema: 5 | file: ./token.graphql 6 | dataSources: 7 | - kind: ethereum/contract 8 | name: ERC20V2Factory 9 | network: mainnet 10 | source: 11 | address: '0xfDDCA6ffCE24dF5bE3e8AaD32081822f86178048' 12 | abi: ERC20V2Factory 13 | startBlock: 4702797 14 | mapping: 15 | kind: ethereum/events 16 | apiVersion: 0.0.4 17 | language: wasm/assemblyscript 18 | file: ../../src/mappings/token/factoryv2.ts 19 | entities: 20 | - User 21 | - Token 22 | - UserTokenBlance 23 | - TransferHistories 24 | abis: 25 | - name: ERC20Factory 26 | file: ../../abis/ERC20Factory.json 27 | - name: ERC20V2Factory 28 | file: ../../abis/ERC20V2Factory.json 29 | - name: ERC20 30 | file: ../../abis/ERC20.json 31 | - name: ERC20SymbolBytes 32 | file: ../../abis/ERC20SymbolBytes.json 33 | - name: ERC20NameBytes 34 | file: ../../abis/ERC20NameBytes.json 35 | eventHandlers: 36 | - event: NewERC20(address,address,uint256) 37 | handler: handleNewERC20 38 | - kind: ethereum/contract 39 | name: ERC20V3Factory 40 | network: mainnet 41 | source: 42 | address: '0x48D77f44416fD0b08f1Eca90Bc437D0a3e4e550d' 43 | abi: ERC20V3Factory 44 | startBlock: 4702797 45 | mapping: 46 | kind: ethereum/events 47 | apiVersion: 0.0.4 48 | language: wasm/assemblyscript 49 | file: ../../src/mappings/token/factoryv2.ts 50 | entities: 51 | - User 52 | - Token 53 | - UserTokenBlance 54 | - TransferHistories 55 | abis: 56 | - name: ERC20Factory 57 | file: ../../abis/ERC20Factory.json 58 | - name: ERC20V2Factory 59 | file: ../../abis/ERC20V2Factory.json 60 | - name: ERC20V3Factory 61 | file: ../../abis/ERC20V3Factory.json 62 | - name: ERC20 63 | file: ../../abis/ERC20.json 64 | - name: ERC20SymbolBytes 65 | file: ../../abis/ERC20SymbolBytes.json 66 | - name: ERC20NameBytes 67 | file: ../../abis/ERC20NameBytes.json 68 | eventHandlers: 69 | - event: NewERC20(address,address,uint256) 70 | handler: handleNewERC20 71 | 72 | -------------------------------------------------------------------------------- /subgraphs/token/token_optimism.yaml: -------------------------------------------------------------------------------- 1 | specVersion: 0.0.2 2 | description: Dodoex.io 3 | repository: https://github.com/DODOEX/dodoex_v2_subgraph 4 | schema: 5 | file: ./token.graphql 6 | dataSources: 7 | - kind: ethereum/contract 8 | name: ERC20V3Factory 9 | network: optimism 10 | source: 11 | address: '0x5a274f1deadf90fc844c9ff94f79f9c1ff0e0acc' 12 | abi: ERC20V3Factory 13 | startBlock: 5952947 14 | mapping: 15 | kind: ethereum/events 16 | apiVersion: 0.0.4 17 | language: wasm/assemblyscript 18 | file: ../../src/mappings/token/factoryv2.ts 19 | entities: 20 | - User 21 | - Token 22 | - UserTokenBlance 23 | - TransferHistories 24 | abis: 25 | - name: ERC20Factory 26 | file: ../../abis/ERC20Factory.json 27 | - name: ERC20V2Factory 28 | file: ../../abis/ERC20V2Factory.json 29 | - name: ERC20V3Factory 30 | file: ../../abis/ERC20V3Factory.json 31 | - name: ERC20 32 | file: ../../abis/ERC20.json 33 | - name: ERC20SymbolBytes 34 | file: ../../abis/ERC20SymbolBytes.json 35 | - name: ERC20NameBytes 36 | file: ../../abis/ERC20NameBytes.json 37 | eventHandlers: 38 | - event: NewERC20(address,address,uint256) 39 | handler: handleNewERC20 40 | -------------------------------------------------------------------------------- /subgraphs/token/token_scroll-alpha.yaml: -------------------------------------------------------------------------------- 1 | specVersion: 0.0.6 2 | description: Dodoex.io 3 | repository: https://github.com/DODOEX/dodoex_v2_subgraph 4 | schema: 5 | file: ./token.graphql 6 | dataSources: 7 | - kind: ethereum/contract 8 | name: ERC20V3Factory 9 | network: scroll-alpha 10 | source: 11 | address: '0x3370Ae17aC73A8Eb920F924967a2964479Eb2Ce3' 12 | abi: ERC20V3Factory 13 | startBlock: 2783334 14 | mapping: 15 | kind: ethereum/events 16 | apiVersion: 0.0.6 17 | language: wasm/assemblyscript 18 | file: ../../src/mappings/token/factoryv2.ts 19 | entities: 20 | - User 21 | - Token 22 | - UserTokenBlance 23 | - TransferHistories 24 | abis: 25 | - name: ERC20Factory 26 | file: ../../abis/ERC20Factory.json 27 | - name: ERC20V2Factory 28 | file: ../../abis/ERC20V2Factory.json 29 | - name: ERC20V3Factory 30 | file: ../../abis/ERC20V3Factory.json 31 | - name: ERC20 32 | file: ../../abis/ERC20.json 33 | - name: ERC20SymbolBytes 34 | file: ../../abis/ERC20SymbolBytes.json 35 | - name: ERC20NameBytes 36 | file: ../../abis/ERC20NameBytes.json 37 | eventHandlers: 38 | - event: NewERC20(address,address,uint256) 39 | handler: handleNewERC20 40 | -------------------------------------------------------------------------------- /subgraphs/token/token_scroll-sepolia.yaml: -------------------------------------------------------------------------------- 1 | specVersion: 0.0.6 2 | description: Dodoex.io 3 | repository: https://github.com/DODOEX/dodoex_v2_subgraph 4 | schema: 5 | file: ./token.graphql 6 | dataSources: 7 | - kind: ethereum/contract 8 | name: ERC20V3Factory 9 | network: scroll-sepolia 10 | source: 11 | address: '0x97bBF5BB1dcfC93A8c67e97E50Bea19DB3416A83' 12 | abi: ERC20V3Factory 13 | startBlock: 12083 14 | mapping: 15 | kind: ethereum/events 16 | apiVersion: 0.0.6 17 | language: wasm/assemblyscript 18 | file: ../../src/mappings/token/factoryv2.ts 19 | entities: 20 | - User 21 | - Token 22 | - UserTokenBlance 23 | - TransferHistories 24 | abis: 25 | - name: ERC20Factory 26 | file: ../../abis/ERC20Factory.json 27 | - name: ERC20V2Factory 28 | file: ../../abis/ERC20V2Factory.json 29 | - name: ERC20V3Factory 30 | file: ../../abis/ERC20V3Factory.json 31 | - name: ERC20 32 | file: ../../abis/ERC20.json 33 | - name: ERC20SymbolBytes 34 | file: ../../abis/ERC20SymbolBytes.json 35 | - name: ERC20NameBytes 36 | file: ../../abis/ERC20NameBytes.json 37 | eventHandlers: 38 | - event: NewERC20(address,address,uint256) 39 | handler: handleNewERC20 40 | -------------------------------------------------------------------------------- /subgraphs/token/token_scroll.yaml: -------------------------------------------------------------------------------- 1 | specVersion: 0.0.6 2 | description: Dodoex.io 3 | repository: https://github.com/DODOEX/dodoex_v2_subgraph 4 | schema: 5 | file: ./token.graphql 6 | dataSources: 7 | - kind: ethereum/contract 8 | name: ERC20V3Factory 9 | network: scroll 10 | source: 11 | address: '0x1F076a800005c758a505E759720eb6737136e893' 12 | abi: ERC20V3Factory 13 | startBlock: 83057 14 | mapping: 15 | kind: ethereum/events 16 | apiVersion: 0.0.6 17 | language: wasm/assemblyscript 18 | file: ../../src/mappings/token/factoryv2.ts 19 | entities: 20 | - User 21 | - Token 22 | - UserTokenBlance 23 | - TransferHistories 24 | abis: 25 | - name: ERC20Factory 26 | file: ../../abis/ERC20Factory.json 27 | - name: ERC20V2Factory 28 | file: ../../abis/ERC20V2Factory.json 29 | - name: ERC20V3Factory 30 | file: ../../abis/ERC20V3Factory.json 31 | - name: ERC20 32 | file: ../../abis/ERC20.json 33 | - name: ERC20SymbolBytes 34 | file: ../../abis/ERC20SymbolBytes.json 35 | - name: ERC20NameBytes 36 | file: ../../abis/ERC20NameBytes.json 37 | eventHandlers: 38 | - event: NewERC20(address,address,uint256) 39 | handler: handleNewERC20 40 | -------------------------------------------------------------------------------- /subgraphs/token/token_sepolia.yaml: -------------------------------------------------------------------------------- 1 | specVersion: 0.0.6 2 | description: Dodoex.io 3 | repository: https://github.com/DODOEX/dodoex_v2_subgraph 4 | schema: 5 | file: ./token.graphql 6 | dataSources: 7 | - kind: ethereum/contract 8 | name: ERC20V3Factory 9 | network: sepolia 10 | source: 11 | address: '0x4CAD0052524648A7Fa2cfE279997b00239295F33' 12 | abi: ERC20V3Factory 13 | startBlock: 5142709 14 | mapping: 15 | kind: ethereum/events 16 | apiVersion: 0.0.6 17 | language: wasm/assemblyscript 18 | file: ../../src/mappings/token/factoryv2.ts 19 | entities: 20 | - User 21 | - Token 22 | - UserTokenBlance 23 | - TransferHistories 24 | abis: 25 | - name: ERC20Factory 26 | file: ../../abis/ERC20Factory.json 27 | - name: ERC20V2Factory 28 | file: ../../abis/ERC20V2Factory.json 29 | - name: ERC20V3Factory 30 | file: ../../abis/ERC20V3Factory.json 31 | - name: ERC20 32 | file: ../../abis/ERC20.json 33 | - name: ERC20SymbolBytes 34 | file: ../../abis/ERC20SymbolBytes.json 35 | - name: ERC20NameBytes 36 | file: ../../abis/ERC20NameBytes.json 37 | eventHandlers: 38 | - event: NewERC20(address,address,uint256) 39 | handler: handleNewERC20 40 | -------------------------------------------------------------------------------- /subgraphs/token/token_tokb.yaml: -------------------------------------------------------------------------------- 1 | specVersion: 0.0.6 2 | description: Dodoex.io 3 | repository: https://github.com/DODOEX/dodoex_v2_subgraph 4 | schema: 5 | file: ./token.graphql 6 | dataSources: 7 | - kind: ethereum/contract 8 | name: ERC20V3Factory 9 | network: tokb 10 | source: 11 | address: '0x4A81Aa47722E1cF27A8726F247E68a766bE58d8e' 12 | abi: ERC20V3Factory 13 | startBlock: 299037 14 | mapping: 15 | kind: ethereum/events 16 | apiVersion: 0.0.6 17 | language: wasm/assemblyscript 18 | file: ../../src/mappings/token/factoryv2.ts 19 | entities: 20 | - User 21 | - Token 22 | - UserTokenBlance 23 | - TransferHistories 24 | abis: 25 | - name: ERC20Factory 26 | file: ../../abis/ERC20Factory.json 27 | - name: ERC20V2Factory 28 | file: ../../abis/ERC20V2Factory.json 29 | - name: ERC20V3Factory 30 | file: ../../abis/ERC20V3Factory.json 31 | - name: ERC20 32 | file: ../../abis/ERC20.json 33 | - name: ERC20SymbolBytes 34 | file: ../../abis/ERC20SymbolBytes.json 35 | - name: ERC20NameBytes 36 | file: ../../abis/ERC20NameBytes.json 37 | eventHandlers: 38 | - event: NewERC20(address,address,uint256) 39 | handler: handleNewERC20 40 | -------------------------------------------------------------------------------- /subgraphs/token/token_zircuit-testnet.yaml: -------------------------------------------------------------------------------- 1 | specVersion: 0.0.6 2 | description: Dodoex.io 3 | repository: https://github.com/DODOEX/dodoex_v2_subgraph 4 | schema: 5 | file: ./token.graphql 6 | dataSources: 7 | - kind: ethereum/contract 8 | name: ERC20V3Factory 9 | network: zircuit_testnet 10 | source: 11 | address: '0x40b4030129FCFE660B4ecF35354e027260343049' 12 | abi: ERC20V3Factory 13 | startBlock: 9389726 14 | mapping: 15 | kind: ethereum/events 16 | apiVersion: 0.0.6 17 | language: wasm/assemblyscript 18 | file: ../../src/mappings/token/factoryv2.ts 19 | entities: 20 | - User 21 | - Token 22 | - UserTokenBlance 23 | - TransferHistories 24 | abis: 25 | - name: ERC20Factory 26 | file: ../../abis/ERC20Factory.json 27 | - name: ERC20V2Factory 28 | file: ../../abis/ERC20V2Factory.json 29 | - name: ERC20V3Factory 30 | file: ../../abis/ERC20V3Factory.json 31 | - name: ERC20 32 | file: ../../abis/ERC20.json 33 | - name: ERC20SymbolBytes 34 | file: ../../abis/ERC20SymbolBytes.json 35 | - name: ERC20NameBytes 36 | file: ../../abis/ERC20NameBytes.json 37 | eventHandlers: 38 | - event: NewERC20(address,address,uint256) 39 | handler: handleNewERC20 40 | -------------------------------------------------------------------------------- /subgraphs/token/token_zircuit.yaml: -------------------------------------------------------------------------------- 1 | specVersion: 0.0.6 2 | description: Dodoex.io 3 | repository: https://github.com/DODOEX/dodoex_v2_subgraph 4 | schema: 5 | file: ./token.graphql 6 | dataSources: 7 | - kind: ethereum/contract 8 | name: ERC20V3Factory 9 | network: zircuit 10 | source: 11 | address: '0xec627fef2AbC5632C01BA9435caAa78871E2e305' 12 | abi: ERC20V3Factory 13 | startBlock: 1454181 14 | mapping: 15 | kind: ethereum/events 16 | apiVersion: 0.0.6 17 | language: wasm/assemblyscript 18 | file: ../../src/mappings/token/factoryv2.ts 19 | entities: 20 | - User 21 | - Token 22 | - UserTokenBlance 23 | - TransferHistories 24 | abis: 25 | - name: ERC20Factory 26 | file: ../../abis/ERC20Factory.json 27 | - name: ERC20V2Factory 28 | file: ../../abis/ERC20V2Factory.json 29 | - name: ERC20V3Factory 30 | file: ../../abis/ERC20V3Factory.json 31 | - name: ERC20 32 | file: ../../abis/ERC20.json 33 | - name: ERC20SymbolBytes 34 | file: ../../abis/ERC20SymbolBytes.json 35 | - name: ERC20NameBytes 36 | file: ../../abis/ERC20NameBytes.json 37 | eventHandlers: 38 | - event: NewERC20(address,address,uint256) 39 | handler: handleNewERC20 40 | -------------------------------------------------------------------------------- /subgraphs/tools/dodoNftBalance/nft.graphql: -------------------------------------------------------------------------------- 1 | type Nft @entity{ 2 | "nft address - token id" 3 | id: ID! 4 | "type(721、1155)" 5 | type: String 6 | "nft contract address" 7 | address: Bytes! 8 | "token uri" 9 | uri: String 10 | "createdAt" 11 | createdAt: BigInt! 12 | "updatedAt" 13 | updatedAt: BigInt! 14 | } 15 | 16 | type Account @entity{ 17 | "user address" 18 | id: ID! 19 | "balances" 20 | balances: [Balance!]! @derivedFrom(field:"account") 21 | "createdAt" 22 | createdAt: BigInt! 23 | "updatedAt" 24 | updatedAt: BigInt! 25 | } 26 | 27 | type Balance @entity{ 28 | "user address - nft address - token id" 29 | id: ID! 30 | "vault" 31 | account: Account! 32 | "nft" 33 | nft: Nft! 34 | "token id" 35 | tokenID: BigInt! 36 | "token value" 37 | value: BigInt! 38 | "createdAt" 39 | createdAt: BigInt! 40 | "updatedAt" 41 | updatedAt: BigInt! 42 | } 43 | 44 | 45 | -------------------------------------------------------------------------------- /subgraphs/vdodo/abis/ERC20NameBytes.json: -------------------------------------------------------------------------------- 1 | [ 2 | { 3 | "constant": true, 4 | "inputs": [], 5 | "name": "name", 6 | "outputs": [ 7 | { 8 | "internalType": "bytes32", 9 | "name": "", 10 | "type": "bytes32" 11 | } 12 | ], 13 | "payable": false, 14 | "stateMutability": "view", 15 | "type": "function" 16 | } 17 | ] -------------------------------------------------------------------------------- /subgraphs/vdodo/abis/ERC20SymbolBytes.json: -------------------------------------------------------------------------------- 1 | [ 2 | { 3 | "constant": true, 4 | "inputs": [], 5 | "name": "symbol", 6 | "outputs": [ 7 | { 8 | "internalType": "bytes32", 9 | "name": "", 10 | "type": "bytes32" 11 | } 12 | ], 13 | "payable": false, 14 | "stateMutability": "view", 15 | "type": "function" 16 | } 17 | ] -------------------------------------------------------------------------------- /subgraphs/vdodo/vdodo_kovan.yaml: -------------------------------------------------------------------------------- 1 | specVersion: 0.0.2 2 | description: Dodoex.io 3 | repository: https://github.com/DODOEX/dodoex_v2_subgraph 4 | schema: 5 | file: ./vdodo.graphql 6 | dataSources: 7 | - kind: ethereum/contract 8 | name: vDODOToken 9 | network: kovan 10 | source: 11 | address: '0xf7119bf8be41dd9080bd0a9ab04788b5eca140d5' 12 | abi: vDODOToken 13 | startBlock: 23461928 14 | mapping: 15 | kind: ethereum/events 16 | apiVersion: 0.0.4 17 | language: wasm/assemblyscript 18 | file: ../../src/mappings/vdodo/core.ts 19 | entities: 20 | - User 21 | - StakeHistory 22 | abis: 23 | - name: vDODOToken 24 | file: ../../abis/vDODOToken.json 25 | - name: ERC20 26 | file: ../../abis/ERC20.json 27 | - name: ERC20SymbolBytes 28 | file: ../../abis/ERC20SymbolBytes.json 29 | - name: ERC20NameBytes 30 | file: ../../abis/ERC20NameBytes.json 31 | eventHandlers: 32 | - event: MintVDODO(address,address,uint256) 33 | handler: handleMintVDODO 34 | - event: RedeemVDODO(address,uint256,uint256,uint256) 35 | handler: handleRedeemVDODO 36 | - event: Transfer(indexed address,indexed address,uint256) 37 | handler: handleTransfer 38 | - event: PreDeposit(uint256) 39 | handler: handlePreDeposit 40 | - event: ChangePerReward(uint256) 41 | handler: handleChangePerReward 42 | - event: DonateDODO(address,uint256) 43 | handler: handleDonateDODO 44 | -------------------------------------------------------------------------------- /subgraphs/vdodo/vdodo_mainnet.yaml: -------------------------------------------------------------------------------- 1 | specVersion: 0.0.4 2 | description: Dodoex.io 3 | repository: https://github.com/DODOEX/dodoex_v2_subgraph 4 | schema: 5 | file: ./vdodo.graphql 6 | dataSources: 7 | - kind: ethereum/contract 8 | name: vDODOToken 9 | network: mainnet 10 | source: 11 | address: '0xc4436fbae6eba5d95bf7d53ae515f8a707bd402a' 12 | abi: vDODOToken 13 | startBlock: 11848651 14 | mapping: 15 | kind: ethereum/events 16 | apiVersion: 0.0.6 17 | language: wasm/assemblyscript 18 | file: ../../src/mappings/vdodo/core.ts 19 | entities: 20 | - User 21 | - StakeHistory 22 | abis: 23 | - name: vDODOToken 24 | file: ../../abis/vDODOToken.json 25 | - name: ERC20 26 | file: ../../abis/ERC20.json 27 | - name: ERC20SymbolBytes 28 | file: ../../abis/ERC20SymbolBytes.json 29 | - name: ERC20NameBytes 30 | file: ../../abis/ERC20NameBytes.json 31 | eventHandlers: 32 | - event: MintVDODO(address,address,uint256) 33 | handler: handleMintVDODO 34 | - event: RedeemVDODO(address,uint256,uint256,uint256) 35 | handler: handleRedeemVDODO 36 | - event: Transfer(indexed address,indexed address,uint256) 37 | handler: handleTransfer 38 | - event: PreDeposit(uint256) 39 | handler: handlePreDeposit 40 | - event: ChangePerReward(uint256) 41 | handler: handleChangePerReward 42 | - event: DonateDODO(address,uint256) 43 | handler: handleDonateDODO 44 | 45 | 46 | -------------------------------------------------------------------------------- /subgraphs/vdodo/vdodo_rinkeby.yaml: -------------------------------------------------------------------------------- 1 | specVersion: 0.0.2 2 | description: Dodoex.io 3 | repository: https://github.com/DODOEX/dodoex_v2_subgraph 4 | schema: 5 | file: ./vdodo.graphql 6 | dataSources: 7 | - kind: ethereum/contract 8 | name: vDODOToken 9 | network: rinkeby 10 | source: 11 | address: '0x8751f874eCd2874f2a5ced95A08364C203e4146A' 12 | abi: vDODOToken 13 | startBlock: 8733542 14 | mapping: 15 | kind: ethereum/events 16 | apiVersion: 0.0.4 17 | language: wasm/assemblyscript 18 | file: ../../src/mappings/vdodo/core.ts 19 | entities: 20 | - User 21 | - StakeHistory 22 | abis: 23 | - name: vDODOToken 24 | file: ../../abis/vDODOToken.json 25 | - name: ERC20 26 | file: ../../abis/ERC20.json 27 | - name: ERC20SymbolBytes 28 | file: ../../abis/ERC20SymbolBytes.json 29 | - name: ERC20NameBytes 30 | file: ../../abis/ERC20NameBytes.json 31 | eventHandlers: 32 | - event: MintVDODO(address,address,uint256) 33 | handler: handleMintVDODO 34 | - event: RedeemVDODO(address,uint256,uint256,uint256) 35 | handler: handleRedeemVDODO 36 | - event: Transfer(indexed address,indexed address,uint256) 37 | handler: handleTransfer 38 | - event: PreDeposit(uint256) 39 | handler: handlePreDeposit 40 | - event: ChangePerReward(uint256) 41 | handler: handleChangePerReward 42 | - event: DonateDODO(address,uint256) 43 | handler: handleDonateDODO 44 | --------------------------------------------------------------------------------