man-c / pycoingecko

Python wrapper for the CoinGecko API
MIT License
1.04k stars 268 forks source link

Some Id's don't work. #27

Closed NathanRussell22 closed 3 years ago

NathanRussell22 commented 3 years ago

cg.get_price(ids='Crypto.com Coin', vs_currencies='cad') returns {}

you can see the crypto.com id is valid by calling cg.get_coins_list()

man-c commented 3 years ago

Hi, You are using wrong id. The id for crypto.com is "crypto-com-chain".

You can find the ids using cg.get_coins_list() (List with all supported coins id, name and symbol). The info for _crypto.com_in the list is:

  {
    "id": "crypto-com-chain",
    "symbol": "cro",
    "name": "Crypto.com Coin"
  }