hello,
it’s for sure a javascript noob question, i’m trying to fetch price from the Deep index api like this :
async function getPrice() {
fetch(
"https://deep-index.moralis.io/api/token/ERC20/0xe53ec727dbdeb9e2d5456c3be40cff031ab40a55/price?chain=eth&chain_name=mainnet",
{
method: "GET",
headers: {
"X-API-KEY":
"apiKey",
},
}
)
.then((res) => res)
.then((data) => console.log(data));
}
getPrice();
I’m getting a success Response object like this
Response {type: "cors", url: "https://deep-index.moralis.io/api/token/ERC20/0xe5…0cff031ab40a55/price?chain=eth&chain_name=mainnet", redirected: false, status: 200, ok: true, …}
how can i now retrieve the token price then?