Providing contract address for the tokens

Hey Team,

In the https://api.coinranking.com/v2/coins api, it would be great if you can provide the contract address of the token

1 Like

Designing an endpoints usually means making a lot of compromises between performance, conciseness and completeness. We want to keep endpoints that retrieve lists, such as the coins endpoint you mention fast and concise, at the cost in this case of contract addresses.

We do however provide contract addresses at a different endpoint, you can read more about it here:

1 Like

Hey Team, Thanks for replying. The problem with the endpoint you are referring to is, I have to make individual request for each coin. So imagine I fetched all the coins a wallet is holding (I have contract address of each coin), how do I use the information from wallet holdings to fetch current price from coinranking? I can do with symbol but that’s not accurate because symbols are not unique which is why I was asking for contract address

1 Like

Thanks for stressing this point. I think Wout has a good point that speed and conciseness matter to our endpoints.

But, you make a good case for why we all need smart contract support in Coinranking API. Symbols aren’t available always or standardized enough to reliably retrieve the coins that you want. You can expect this feature (request coin by smart contract address, which we call reference) to be launched soon. In a couple of weeks, maybe months.

Thanks again!

1 Like

Hi @Mohit_Tilwani, we’ve just launched contract address support earlier than expected. Get a coin for any contract address / assetid etc. All blockchains are supported with this feature.

Let me know what you think and what we could do to make it better for you.

Happy building.

As @mark mentioned we updated our api. To be precise, we added three features:

  • You can now use contractAddress filters on the /coins endpoint, to only find coins that have a specific address.
  • Both the /coin/:uuid and /coins endpoint return coins with their contractAddresses
  • Our searchSuggestions endpoint also supports contractAddresses. This also means you can now search for coins using their addresses with the search on our website.

More features regarding smart contract addresses are still coming!

1 Like

We have added a couple more blockchain related features to our API. You can now filter /coins on blockhains. So you can filter coins that are minted on ethereum for example.

Furthermore, we’ve added three more endpoints:

  • Get a list of all blockchains
  • Get details about a blockchain
  • Find a token on a blockchain by its smart contract address

This last one is particularly useful if you have a smart contract address, and you want to know if we have listed this particular coin. You can find the coin in our api by requesting something like this: api.coinranking.com/v2/blockchain/ethereum/0x1234.

1 Like