CoinMarketCap provides an API to get listing information (https://coinmarketcap.com/api/documentation/v1/#operation/getV1CryptocurrencyListingsLatest)
It returns a listing (token/coin) information. If that's a token, it will fill the platform
field with an object describing platform.
E.g.
{
...,
platform: {
id: 1027,
name: 'Ethereum',
symbol: 'ETH',
slug: 'ethereum',
token_address: '0xc02aaa39b223fe8d0a0e5c4f27ead9083c756cc2'
},
...
}
But wrapped tokens have many contracts for different platforms. Take Wrapped ETH as an example: https://coinmarketcap.com/currencies/weth/
The API returns info on Ethereum network only. Polygon, for example, has WETH as well, and it has a different token address.
Is there a way to fetch platforms list for a token from Coinmarketcap API?
The following endpoint returns a list of contract addresses
https://coinmarketcap.com/api/documentation/v1/#operation/getV2CryptocurrencyInfo