diff --git a/chains/README.md b/chains/README.md index fece76f4..c56ef5f0 100644 --- a/chains/README.md +++ b/chains/README.md @@ -38,13 +38,56 @@ "logo": "https://dl.airtable.com/.attachments/e54f814bba8c0f9af8a3056020210de0/2d1155fb/cosmos-hub.svg" } ``` -- **chain_name** the name to identify the chain on ping.pub, would be better to use the same one as regitstry +- **chain_name** the name to identify the chain on ping.pub, would be better to use the same one as registry - **api** the rest api endpoint.(make sure that CORS is enabled: `Allow-Control-Allow-Origin: *`) - **rpc** the rpc endpoint, make sure that the port is added. rpc endpoint is only used for state sync. it's optional. - **assets** Native Assets on blockchain. Endpoint providers will be listed in the "Popular" tab of the staking. +# Token Unit conversion + +We have two methods to load token metadata for token unit conversion: + +## Loading from a REST endpoint (recommended). + +you can define the metadata in the `bank` -> `metadata` section of the blockchain's genesis file. if you don't define, the `[]` will return. + +```json +{ + "name": "atom", + "description": "The native staking token of the Cosmos Hub.", + "denom_units": [ + { + "denom": "uatom", + "exponent": 0, + "aliases": [ + "microatom" + ], + }, + { + "denom": "matom", + "exponent": 3, + "aliases": [ + "milliatom" + ] + }, + { + "denom": "atom", + "exponent": 6, + } + ], + "base": "uatom", + "display": "atom", +} +``` +you can see more details here: +https://github.com/cosmos/cosmos-sdk/blob/main/docs/architecture/adr-024-coin-metadata.md + +## Loading from Cosmos Registry: + +https://github.com/cosmos/chain-registry + # Test please add these check points in comments with your PR, and adding your test result by clicking the checkbox of each line diff --git a/chains/testnet/agoric.json b/chains/testnet/agoric.json index aecc436a..0b397d20 100644 --- a/chains/testnet/agoric.json +++ b/chains/testnet/agoric.json @@ -21,8 +21,8 @@ "logo": "https://raw.githubusercontent.com/Agoric/agoric-sdk/master/packages/wallet/ui/public/tokens/BLD.svg" }, { - "symbol": "RUN", - "base": "urun", + "symbol": "IST", + "base": "uist", "exponent": 6, "coingecko_id": "agoric", "logo": "https://raw.githubusercontent.com/Agoric/agoric-sdk/master/packages/wallet/ui/public/tokens/RUN.svg" diff --git a/chains/testnet/dymension.json b/chains/testnet/dymension.json new file mode 100644 index 00000000..60f8025a --- /dev/null +++ b/chains/testnet/dymension.json @@ -0,0 +1,20 @@ +{ + "chain_name": "dymension", + "api": ["https://dymension-testnet.api.kjnodes.com"], + "rpc": ["https://dymension-testnet.rpc.kjnodes.com"], + "snapshot_provider": "", + "sdk_version": "0.45.10", + "coin_type": "60", + "min_tx_fee": "5000", + "addr_prefix": "dymd", + "logo": "/logos/dymension.png", + "keplr_features": ["ibc-transfer", "ibc-go", "eth-address-gen", "eth-key-sign"], + "theme_color": "#e2d3c7", + "assets": [{ + "base": "udym", + "symbol": "DYMD", + "exponent": "18", + "coingecko_id": "", + "logo": "/logos/dymension.png" + }] +} diff --git a/public/logos/dymension.png b/public/logos/dymension.png new file mode 100644 index 00000000..15e0049a Binary files /dev/null and b/public/logos/dymension.png differ