From 33c8d4e24d699f06c15ae05052936ae80d91b01c Mon Sep 17 00:00:00 2001 From: Raj Ranjan Date: Fri, 29 Dec 2023 02:59:16 +0530 Subject: [PATCH] return chain_id --- config.json | 1 + server.ts | 3 ++- 2 files changed, 3 insertions(+), 1 deletion(-) diff --git a/config.json b/config.json index 644cc0e..66c4fe1 100644 --- a/config.json +++ b/config.json @@ -16,6 +16,7 @@ "MAX_LIMIT_CAP": 5000 }, "MAINNET_BALANCE_CHECK_RPC": "https://api.avax.network/ext/C/rpc", + "MAINNET_BALANCE_CHECK_CHAIN_ID": 43114, "evmchains": [ { "ID": "C", diff --git a/server.ts b/server.ts index 286a196..a8e7ba6 100644 --- a/server.ts +++ b/server.ts @@ -20,6 +20,7 @@ import { NATIVE_CLIENT, DEBUG, MAINNET_BALANCE_CHECK_RPC, + MAINNET_BALANCE_CHECK_CHAIN_ID, } from './config.json' import { CouponService } from './CouponService/couponService' import { @@ -190,7 +191,7 @@ router.post('/sendToken', captcha.middleware, async (req: any, res: any) => { // GET request for fetching all the chain and token configurations router.get('/getChainConfigs', (req: any, res: any) => { const configs: any = [...evmchains, ...erc20tokens] - res.send({ configs, MAINNET_BALANCE_CHECK_RPC }) + res.send({ configs, MAINNET_BALANCE_CHECK_RPC, MAINNET_BALANCE_CHECK_CHAIN_ID }) }) // GET request for fetching faucet address for the specified chain