Skip to content

Commit

Permalink
Add mode network volume to MantisSwap dex
Browse files Browse the repository at this point in the history
  • Loading branch information
oogway112 committed Mar 12, 2024
1 parent 998bf07 commit b285361
Showing 1 changed file with 6 additions and 4 deletions.
10 changes: 6 additions & 4 deletions dexs/MantisSwap/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -10,10 +10,8 @@ type PoolData = {
const fetch = (chain: string) => async (timestamp: number) => {
const from = timestamp - 86400; // 60*60*24
const to = timestamp;
const stats: PoolData = (
await fetchURL(
`https://api.mantissa.finance/api/pool/stats/volume/${chain}/?from_timestamp=${from}&to_timestamp=${to}`
)
const stats: PoolData = await fetchURL(
`https://api.mantissa.finance/api/pool/stats/volume/${chain}/?from_timestamp=${from}&to_timestamp=${to}`
);
return {
totalVolume: `${stats.total_volume}`,
Expand All @@ -32,6 +30,10 @@ const adapter: SimpleAdapter = {
fetch: fetch("1101"),
start: 1685355566,
},
[CHAIN.MODE]: {
fetch: fetch("34443"),
start: 1709717650,
},
},
};

Expand Down

0 comments on commit b285361

Please sign in to comment.