a lighter and free alternative to the excellent CryptoFinance google sheet plugin to get all crypto data from the also excellent CoinPaprika API.
it pulls all tickers data into a single sheet (to ensure a fair use of the API), then a CRYPTODATA("symbol"; "data")
function allows you to pull specific data for ay coin.
- open your favorite crypto spreadsheet, and create an empty sheet named
data
- go to the menu
Tools > Script Editor
- paste the content of the file
cryptodata.gs
into the editor, then save - go back to your spreadsheet, refresh the page
- you should now have a menu item called
CryptoData
. Click on it, then click onUpdate
- you can now use the plugin anywhere like this :
=CRYPTODATA("ETH"; "btc_price")
❗ do not use the data
sheet, it's used by the script, create a new one if you want to use the script data
=CRYPTODATA("ETH"; "btc_price")
(you can discover the available data in the data
sheet)
=CRYPTODATAHISTORY("<coin>"; "<date>"; "<type of data>"; "<quote>")
with params being :
- coin : a single coin ticket like "ETH" or "BTC" or "XMR"
- date : something like "2018-02-20"
- type of data : can be "price", "volume_24h" or "market_cap"
- quote : optional, defaults to usd, but can be set to "usd" or "btc"
=CRYPTODATAGLOBAL("bitcoin_dominance_percentage")
see all available properties here : https://api.coinpaprika.com/#tag/Global/paths/~1global/get
-> You might need to change the ;
in the formula by ,
- first, click on the menu item
CryptoData
, then click onUpdate
(will refresh raw data) - to refresh your calls in other sheets, the best way i found is adding a dummy reference in the formula like this :
=CRYPTODATA("ETH", "btc_price", $A$1)
and updating the $A$1
cell with whatever data.
Another way to find data with better performance (but poor readability) :
=INDEX(data!$A$1:$ZZ; MATCH("ETH"; data!$C$1:$C; 0); MATCH("btc_price"; data!$A$1:$1; 0))
- can give you data in USD/BTC/ETH (according to what CoinPaprika is providing)
- won't give you any specific exchange data
- should respect CoinPaprika API fair use since it pull all data in one API call (rate limit is 10 reqs/s), but since request come from google's servers, i can't guarantee the fair use
- for now CoinPaprika's API is free, i can't guarantee it won't change
- performances might not be great, but it does the job (remember, it's free)
- i'm welcoming issues, forks and PR, feel free to do better than what i did and if you do, share it !
BTC : 389avCg3HYBBqnBX8S2PB2mvXPfGKx3cm4
LTC : LbaaxtsCeB9rt4EiXtFYwkZC9TnZtsvExt