Skip to content

Commit

Permalink
added Chain.feeToken field
Browse files Browse the repository at this point in the history
  • Loading branch information
alecdwm committed Oct 1, 2023
1 parent 4f6adb8 commit b939eed
Show file tree
Hide file tree
Showing 4 changed files with 9 additions and 1 deletion.
4 changes: 4 additions & 0 deletions chaindata.json
Original file line number Diff line number Diff line change
Expand Up @@ -1281,6 +1281,7 @@
"account": "*25519",
"subscanUrl": "https://equilibrium.subscan.io/",
"overrideNativeTokenId": "equilibrium-polkadot-substrate-equilibrium-eq",
"feeToken": "equilibrium-polkadot-substrate-equilibrium-eq",
"rpcs": ["wss://equilibrium-rpc.dwellir.com", "wss://node.pol.equilibrium.io/"],
"paraId": 2011,
"relay": {
Expand Down Expand Up @@ -1647,6 +1648,7 @@
"chainspecQrUrl": "https://metadata.novasama.io/qr/interlay-parachain_specs.png",
"latestMetadataQrUrl": "https://metadata.novasama.io/qr/interlay-parachain_metadata_latest.apng",
"overrideNativeTokenId": "interlay-substrate-tokens-intr",
"feeToken": "interlay-substrate-tokens-intr",
"rpcs": [
"wss://interlay.api.onfinality.io/public-ws",
"wss://interlay-rpc.dwellir.com",
Expand Down Expand Up @@ -2266,6 +2268,7 @@
"chainspecQrUrl": "https://metadata.novasama.io/qr/kintsugi-parachain_specs.png",
"latestMetadataQrUrl": "https://metadata.novasama.io/qr/kintsugi-parachain_metadata_latest.apng",
"overrideNativeTokenId": "kintsugi-substrate-tokens-kint",
"feeToken": "kintsugi-substrate-tokens-kint",
"rpcs": ["wss://kintsugi.api.onfinality.io/public-ws", "wss://api-kusama.interlay.io/parachain"],
"paraId": 2092,
"relay": {
Expand Down Expand Up @@ -2558,6 +2561,7 @@
"chainspecQrUrl": "https://metadata.novasama.io/qr/mangata-parachain_specs.png",
"latestMetadataQrUrl": "https://metadata.novasama.io/qr/mangata-parachain_metadata_latest.apng",
"overrideNativeTokenId": "mangata-substrate-tokens-mgx",
"feeToken": "mangata-substrate-tokens-mgx",
"rpcs": ["wss://kusama-archive.mangata.online", "wss://kusama-rpc.mangata.online"],
"paraId": 2110,
"relay": {
Expand Down
1 change: 1 addition & 0 deletions schemas/json/chaindata.json
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,7 @@
"chainspecQrUrl": { "type": "string" },
"latestMetadataQrUrl": { "type": "string" },
"overrideNativeTokenId": { "type": "string" },
"feeToken": { "type": "string" },
"isUnknownFeeToken": { "type": "boolean" },
"rpcs": {
"type": "array",
Expand Down
4 changes: 3 additions & 1 deletion scripts/build/steps/addChains.ts
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,8 @@ import { SubstrateRpc, Chain as UpstreamChain, githubChainLogoUrl } from '@talis
import { sharedData } from './_sharedData'

// TODO: Switch to the updated type in `@talismn/chaindata`
type Chain = Omit<UpstreamChain, 'rpcs' | 'isHealthy' | 'balanceMetadata'> & {
type Chain = Omit<UpstreamChain, 'feeToken' | 'rpcs' | 'isHealthy' | 'balanceMetadata'> & {
feeToken: string | null
rpcs: Array<Pick<SubstrateRpc, 'url'>> | null

balancesConfig: Array<{ moduleType: string; moduleConfig: unknown }>
Expand Down Expand Up @@ -43,6 +44,7 @@ export const addChains = async () => {
chainspecQrUrl: configChain.chainspecQrUrl ?? null,
latestMetadataQrUrl: configChain.latestMetadataQrUrl ?? null,
isUnknownFeeToken: configChain.isUnknownFeeToken || false,
feeToken: configChain.feeToken || null,
rpcs: (configChain.rpcs || []).map((url) => ({ url })),
evmNetworks: [],

Expand Down
1 change: 1 addition & 0 deletions scripts/build/types.ts
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,7 @@ export type ConfigChain = {
latestMetadataQrUrl?: string
overrideNativeTokenId?: string
isUnknownFeeToken?: boolean
feeToken?: string
rpcs?: string[]
paraId?: number
relay?: { id: string }
Expand Down

0 comments on commit b939eed

Please sign in to comment.