diff --git a/src/api/eosio_core.ts b/src/api/eosio_core.ts index 7c559d0..b2a3a5c 100644 --- a/src/api/eosio_core.ts +++ b/src/api/eosio_core.ts @@ -23,7 +23,6 @@ const eosioCore = new APIClient({ export const getAccount = async function ( address: string, ): Promise { - console.log('osioCore.v1.chain.get_account(address)', eosioCore.v1.chain.get_account(address)); return await eosioCore.v1.chain.get_account(address); }; diff --git a/src/api/hyperion.ts b/src/api/hyperion.ts index a5e61b7..87d506a 100644 --- a/src/api/hyperion.ts +++ b/src/api/hyperion.ts @@ -30,6 +30,8 @@ import { GetActionsResponse } from 'src/types/Actions'; const chain: Chain = getChain(); const hyperion = axios.create({ baseURL: chain.getHyperionEndpoint() }); +const api = axios.create({ baseURL: chain.getApiEndpoint() }); + const controller = new AbortController(); export const DEFAULT_ICON = 'data:image/svg+xml;base64,PHN2ZyB3aWR0aD0iMjciIGhlaWdodD0iMTgiIHZpZXdCb3g9IjAgMCAyNyAxOCIgZmlsbD0ibm9uZSIgeG1sbnM9Imh0dHA6Ly93d3cudzMub3JnLzIwMDAvc3ZnIj4KPGNpcmNsZSBjeD0iMTgiIGN5PSI5IiByPSI4IiBmaWxsPSJ3aGl0ZSIgc3Ryb2tlPSJibGFjayIgc3Ryb2tlLXdpZHRoPSIyIi8+CjxjaXJjbGUgY3g9IjkiIGN5PSI5IiByPSI4IiBmaWxsPSJ3aGl0ZSIgc3Ryb2tlPSJibGFjayIgc3Ryb2tlLXdpZHRoPSIyIi8+Cjwvc3ZnPgo='; @@ -217,7 +219,7 @@ export const getPermissionLinks = async function ( export const getTableByScope = async function ( data: unknown, ): Promise { - const response = await hyperion.post('v1/chain/get_table_by_scope', data); + const response = await api.post('v1/chain/get_table_by_scope', data); return (response.data as {rows:TableByScope[]}).rows; }; diff --git a/src/api/price.ts b/src/api/price.ts index ef80174..2a39a83 100644 --- a/src/api/price.ts +++ b/src/api/price.ts @@ -8,7 +8,7 @@ export const getCoingeckoUsdPrice = async ( const stats: PriceStats = await axios.get( getCoingeckoExchangeStatsUrl(tokenId), ); - console.log('stats', stats); + return stats.data[tokenId].usd; }; diff --git a/src/config/chains/pangea-testnet/index.ts b/src/config/chains/pangea-testnet/index.ts index e119c4a..e00916b 100644 --- a/src/config/chains/pangea-testnet/index.ts +++ b/src/config/chains/pangea-testnet/index.ts @@ -1,18 +1,20 @@ /* -# MAINNET VALUES -# NETWORK_CHAIN_ID=4667b205c6838ef70ff7988f6e8257e8be0e1284a2f59699054a018f743b1d11 -# NETWORK_HOST=mainnet.telos.net -# NETWORK_PORT=443 -# NETWORK_PROTOCOL=https -# NETWORK_EVM_RPC=https://mainnet.telos.net/evm -# NETWORK_EVM_ENDPOINT=https://mainnet.telos.net -# NETWORK_EVM_CONTRACT=eosio.evm -# NETWORK_EVM_CHAIN_ID=40 -# HYPERION_ENDPOINT=https://mainnet.telos.net -# TELOS_API_ENDPOINT=https://api.telos.net/v1 +NETWORK_CHAIN_ID= +NETWORK_HOST=testnet.telos.net +NETWORK_PORT=443 +NETWORK_PROTOCOL=https +NETWORK_EVM_RPC=https://testnet.telos.net/evm +NETWORK_EVM_ENDPOINT=https://testnet.telos.net +NETWORK_EVM_CONTRACT=eosio.evm +NETWORK_EVM_CHAIN_ID=41 +HYPERION_ENDPOINT=https://testnet.telos.net +TELOS_API_ENDPOINT=https://api-dev.telos.net/v1 + +# TELOS_API_ENDPOINT=localhost:9999/v1 +APP_NAME=OBE +PRODUCER_BUCKET_URL= */ - import BaseChain, { baseUiConfiguration } from 'src/config/BaseChain'; import { RpcEndpoint } from 'universal-authenticator-library'; import { @@ -106,7 +108,7 @@ const THEME = { 'color-footer-background': '#67D7ED', }; -export default class Telos extends BaseChain { +export default class PangeaTestnet extends BaseChain { getName(): string { return NAME; }