diff --git a/docs/_fetch-cbridge-tokens.py b/docs/_fetch-cbridge-tokens.py new file mode 100644 index 00000000..aaae9ad9 --- /dev/null +++ b/docs/_fetch-cbridge-tokens.py @@ -0,0 +1,37 @@ +#!/usr/bin/env python3 +""" +Retrieves all of the Celer cBridge tokens to/from Oasis Sapphire mainnet +""" +import json +from urllib.request import urlopen + +def format_result(data): + chains = {} + for c in data["chains"]: + chains[c["id"]] = c + for p in data['pegged_pair_configs']: + org_chain = chains[p['org_chain_id']] + pegged_chain = chains[p['pegged_chain_id']] + if p['org_chain_id'] in [0x5afe,0x5aff] or p['pegged_chain_id'] in [0x5afe,0x5aff]: + src_url = org_chain['explore_url'] + 'address/' + p["org_token"]["token"]["address"] + dest_url = pegged_chain['explore_url'] + 'address/' + p["pegged_token"]["token"]["address"] + print(f'| {org_chain["name"]} ({org_chain["id"]}) | {p["org_token"]["token"]["symbol"]} | [`{p["org_token"]["token"]["address"]}`]({src_url}) | {pegged_chain["name"]} ({pegged_chain["id"]}) | [`{p["pegged_token"]["token"]["address"]}`]({dest_url}) |') + +print('# Celer cBridge Tokens (Mainnet)') +print(""" + +| Source Chain | Token Name | Source Address | Dest. Chain | Dest Address | +| ------------ | ---------- | -------------- | ----------- | ------------ |""") +with urlopen('https://cbridge-prod2.celer.app/v1/getTransferConfigs') as h: + data = json.load(h) + format_result(data) + +print() +print('# Testnet cBridge Tokens') +print(""" + +| Source Chain | Token Name | Source Address | Dest. Chain | Dest Address | +| ------------ | ---------- | -------------- | ----------- | ------------ |""") +with urlopen('https://cbridge-v2-test.celer.network/v1/getTransferConfigs') as h: + data = json.load(h) + format_result(data) diff --git a/docs/addresses.md b/docs/addresses.md index cf813a45..c0852bee 100644 --- a/docs/addresses.md +++ b/docs/addresses.md @@ -17,3 +17,26 @@ description: List of Standard Contract Addresses [wrose-source]: https://github.com/oasisprotocol/sapphire-paratime/blob/main/contracts/contracts/WrappedROSE.sol [wrose-verify-mainnet]: https://sourcify.dev/#/lookup/0x8Bc2B030b299964eEfb5e1e0b36991352E56D2D3 [wrose-verify-testnet]: https://sourcify.dev/#/lookup/0xB759a0fbc1dA517aF257D5Cf039aB4D86dFB3b94 + +# Celer cBridge Tokens (Mainnet) + + +| Source Chain | Token Name | Source Address | Dest. Chain | Dest Address | +| ------------ | ---------- | -------------- | ----------- | ------------ | +| Ethereum Mainnet (1) | OCEAN | [`0x967da4048cD07aB37855c090aAF366e4ce1b9F48`](https://etherscan.io/address/0x967da4048cD07aB37855c090aAF366e4ce1b9F48) | Oasis Sapphire (23294) | [`0x39d22B78A7651A76Ffbde2aaAB5FD92666Aca520`](https://explorer.oasis.io/mainnet/sapphire/address/0x39d22B78A7651A76Ffbde2aaAB5FD92666Aca520) | +| Ethereum Mainnet (1) | USDC | [`0xA0b86991c6218b36c1d19D4a2e9Eb0cE3606eB48`](https://etherscan.io/address/0xA0b86991c6218b36c1d19D4a2e9Eb0cE3606eB48) | Oasis Sapphire (23294) | [`0x2c2E3812742Ab2DA53a728A09F5DE670Aba584b6`](https://explorer.oasis.io/mainnet/sapphire/address/0x2c2E3812742Ab2DA53a728A09F5DE670Aba584b6) | +| Ethereum Mainnet (1) | USDT | [`0xdAC17F958D2ee523a2206206994597C13D831ec7`](https://etherscan.io/address/0xdAC17F958D2ee523a2206206994597C13D831ec7) | Oasis Sapphire (23294) | [`0xE48151964556381B33f93E05E36381Fd53Ec053E`](https://explorer.oasis.io/mainnet/sapphire/address/0xE48151964556381B33f93E05E36381Fd53Ec053E) | +| Ethereum Mainnet (1) | WBTC | [`0x2260FAC5E5542a773Aa44fBCfeDf7C193bc2C599`](https://etherscan.io/address/0x2260FAC5E5542a773Aa44fBCfeDf7C193bc2C599) | Oasis Sapphire (23294) | [`0xE9533976C590200E32d95C53f06AE12d292cFc47`](https://explorer.oasis.io/mainnet/sapphire/address/0xE9533976C590200E32d95C53f06AE12d292cFc47) | +| Ethereum Mainnet (1) | WETH | [`0xC02aaA39b223FE8D0A0e5C4F27eAD9083C756Cc2`](https://etherscan.io/address/0xC02aaA39b223FE8D0A0e5C4F27eAD9083C756Cc2) | Oasis Sapphire (23294) | [`0xfc6b18d694F2D137dB762B152736Ba098F9808d9`](https://explorer.oasis.io/mainnet/sapphire/address/0xfc6b18d694F2D137dB762B152736Ba098F9808d9) | +| BNB Chain (56) | BNB | [`0xbb4CdB9CBd36B01bD1cBaEBF2De08d9173bc095c`](https://bscscan.com/address/0xbb4CdB9CBd36B01bD1cBaEBF2De08d9173bc095c) | Oasis Sapphire (23294) | [`0xe95E3a9f1a45B5EDa71781448F6047d7B7e31cbF`](https://explorer.oasis.io/mainnet/sapphire/address/0xe95E3a9f1a45B5EDa71781448F6047d7B7e31cbF) | +| Polygon PoS (137) | MATIC | [`0x0d500B1d8E8eF31E21C99d1Db9A6444d3ADf1270`](https://polygonscan.com/address/0x0d500B1d8E8eF31E21C99d1Db9A6444d3ADf1270) | Oasis Sapphire (23294) | [`0xa349005a68FA33e8DACAAa850c45175bbcD49B19`](https://explorer.oasis.io/mainnet/sapphire/address/0xa349005a68FA33e8DACAAa850c45175bbcD49B19) | +| Oasis Sapphire (23294) | wROSE | [`0x8Bc2B030b299964eEfb5e1e0b36991352E56D2D3`](https://explorer.oasis.io/mainnet/sapphire/address/0x8Bc2B030b299964eEfb5e1e0b36991352E56D2D3) | BNB Chain (56) | [`0xF00600eBC7633462BC4F9C61eA2cE99F5AAEBd4a`](https://bscscan.com/address/0xF00600eBC7633462BC4F9C61eA2cE99F5AAEBd4a) | + +# Testnet cBridge Tokens + + +| Source Chain | Token Name | Source Address | Dest. Chain | Dest Address | +| ------------ | ---------- | -------------- | ----------- | ------------ | +| Goerli (5) | USDT | [`0xf4B2cbc3bA04c478F0dC824f4806aC39982Dce73`](https://goerli.etherscan.io/address/0xf4B2cbc3bA04c478F0dC824f4806aC39982Dce73) | Oasis Sapphire Testnet (23295) | [`0xa55C7E1274bE5db2275a0BDd055f81e8263b7954`](https://testnet.explorer.sapphire.oasis.dev/address/0xa55C7E1274bE5db2275a0BDd055f81e8263b7954) | +| Oasis Sapphire Testnet (23295) | wROSE | [`0xB759a0fbc1dA517aF257D5Cf039aB4D86dFB3b94`](https://testnet.explorer.sapphire.oasis.dev/address/0xB759a0fbc1dA517aF257D5Cf039aB4D86dFB3b94) | BSC Testnet (97) | [`0x26a6f43BaEDD1767c283e2555A9E1236E5aE3A55`](https://testnet.bscscan.com/address/0x26a6f43BaEDD1767c283e2555A9E1236E5aE3A55) | +| Oasis Sapphire Testnet (23295) | wROSE | [`0xB759a0fbc1dA517aF257D5Cf039aB4D86dFB3b94`](https://testnet.explorer.sapphire.oasis.dev/address/0xB759a0fbc1dA517aF257D5Cf039aB4D86dFB3b94) | Polygon Mumbai (80001) | [`0xE9533976C590200E32d95C53f06AE12d292cFc47`](https://mumbai.polygonscan.com/address/0xE9533976C590200E32d95C53f06AE12d292cFc47) |