Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions .env.example
Original file line number Diff line number Diff line change
Expand Up @@ -45,6 +45,7 @@ DD_ENV=development
#LUKSO_TESTNET_RPC_URL
#METIS_ANDROMEDA_RPC_URL
#GNOSIS_RPC_URL
#HEDERA_RPC_URL

#COINGECKO_API_KEY=
#IPFS_GATEWAYs=[]
Expand Down
2 changes: 1 addition & 1 deletion fly.toml
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ kill_timeout = "5s"
DEPLOYMENT_ENVIRONMENT = "production"
ENABLE_RESOURCE_MONITOR = "false"
ESTIMATES_LINEARQF_WORKER_POOL_SIZE = "10"
INDEXED_CHAINS = "mainnet,optimism,fantom,arbitrum,polygon,sepolia,avalanche,avalanche-fuji,scroll,scroll-sepolia,base,zksync-era-mainnet,lukso-mainnet,lukso-testnet,celo-mainnet,celo-testnet,metisAndromeda,gnosis,sei-mainnet"
INDEXED_CHAINS = "mainnet,optimism,fantom,arbitrum,polygon,sepolia,avalanche,avalanche-fuji,scroll,scroll-sepolia,base,zksync-era-mainnet,lukso-mainnet,lukso-testnet,celo-mainnet,celo-testnet,metisAndromeda,gnosis,sei-mainnet,hedera"
LOG_LEVEL = "debug"
NODE_OPTIONS = "--max-old-space-size=4096"
PORT = "8080"
Expand Down
35 changes: 34 additions & 1 deletion src/config.ts
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,8 @@ type CoingeckoSupportedChainId =
| 1329
| 42
| 42220
| 1088;
| 1088
| 295;

const CHAIN_DATA_VERSION = "87";
const IPFS_DATA_VERSION = "1";
Expand Down Expand Up @@ -1828,6 +1829,38 @@ const CHAINS: Chain[] = [
},
],
},
{
id: 295,
name: "hedera",
rpc: rpcUrl
.default("https://mainnet.hashio.io/api")
.parse(process.env.HEDERA_RPC_URL),
pricesFromTimestamp: Date.UTC(2025, 1, 1, 0, 0, 0),
tokens: [
{
code: "HBAR",
address: "0x0000000000000000000000000000000000000000",
decimals: 8,
priceSource: {
chainId: 295,
address: "0x0000000000000000000000000000000000000000",
},
},
],
subscriptions: [
// Allo V2
{
contractName: "AlloV2/Registry/V1",
address: "0x4aacca72145e1df2aec137e1f3c5e3d75db8b5f3",
fromBlock: 75239000,
},
{
contractName: "AlloV2/Allo/V1",
address: "0x1133eA7Af70876e64665ecD07C0A0476d09465a1",
fromBlock: 75239000,
},
],
},
];

export const getDecimalsForToken = (
Expand Down
2 changes: 2 additions & 0 deletions src/prices/coinGecko.ts
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,7 @@ const platforms: { [key: number]: string } = {
42220: "celo",
1088: "metis",
100: "xdai",
295: "hedera-hashgraph",
};

const nativeTokens: { [key: number]: string } = {
Expand All @@ -31,6 +32,7 @@ const nativeTokens: { [key: number]: string } = {
42220: "celo",
1088: "metis-token",
100: "xdai",
295: "hedera-hashgraph",
};

type TimestampInMs = number;
Expand Down