Bitcoin Forum
December 13, 2024, 07:00:41 PM *
News: Latest Bitcoin Core release: 28.0 [Torrent]
 
   Home   Help Search Login Register More  
Pages: [1]
  Print  
Author Topic: [GUIDE] How To create a CryptoTracker  (Read 196 times)
bitbollo (OP)
Legendary
*
Offline Offline

Activity: 3472
Merit: 3963


Nec Recisa Recedit


View Profile
May 04, 2020, 05:55:05 PM
Last edit: May 05, 2020, 01:30:41 PM by bitbollo
Merited by hugeblack (3), Tytanowy Janusz (1)
 #1

What is the best Cryptotracker?
I tried several tools but personally I decide to realize one by myself with google drive & google sheet.
It's very easy to use and ready to be adapted for personal interest or purpose.

Just stay online and you get easily a real-time update of quotations in “euro/usd/btc/eth” related any cryptocurrencies/token.

Here I would describe a basic version. 1
I am not a programmer and the code of this script is not written by myself.
But the system is working fine and does it duty very well.

SETUP
Open google drive and choose “New” and select “Google Sheet”
https://drive.google.com/drive/my-drive 2
(You can create a new account if you are scared that google want track your coins)

Once sheet is open, click on “instruments” and choose “Script Editor”
DELETE all text that appear and copy past this code below.

Code:
function CC(name, currencyOpt, dataOpt) {

    var currency = currencyOpt || "usd";

    var url = 'https://api.coingecko.com/api/v3/simple/price?ids=' + name + '&vs_currencies=' + currency.toLowerCase() + '&include_24hr_change=true'
    var response = UrlFetchApp.fetch(url);
    var json = response.getContentText();
    var jsonobject = JSON.parse(json);

    if (dataOpt == undefined) {
        var data = currency.toLowerCase()
    } else {
        var data = currencyOpt + "_" + dataOpt
    }

    var datatoreturn = jsonobject[name][data]

    return datatoreturn;
location.reload(dataOpt)
}

Save the function with “cc” name

Go again to your google sheet and create the column (this is just an example and you can personalize according preference or personal usage)
Code:
 Token Name || Token Number || LIVE FIAT	|| BTC || Note || LIVE USD || LIVE BTC 	

First Column - Token Name , this the label of your token, let’s start with “bitcoin”
Second Column - Token Number, we enter numerically how many coins you want to track (like 100 bitcoins ...).
Third Column
Code:
=cc("bitcoin";"usd") 

There are two variables.
-By substituting "bitcoin" = you can choose the token to be tracked.
Go to https://www.coingecko.com/ for the coin you want to trace. Do not enter the ticker.
Here is an example with Litecoin https://www.coingecko.com/it/monete/litecoin

-By substituting "usd" = you can choose which currency to receive the value from.
You can also choose other fiat or crypto currencies! (Eth / btc / usd / eur)

Fourth Column
Code:
=cc("bitcoin";"btc")
You can insert a fixed reference on the value in bitcoin (value of your token [1 unit]  compared to 1 bitcoin)
[as seen in the third column but here we trace the value no longer in usd but in bitcoin]

Fifth column  
Note field is optional but it is useful for keeping some information, E.G address or other useful info.

Multiplying Token Number x LIVE USD
Code:
=B2*C2

or for the BTC column
Code:
=B2*D2

You will get automatically the value of your portfolio expressed in fiat or cryptocurrency!

Please find below a screenshot!


And here the link a copy already online (demo)

These values can be modified or adapted in graphs like a pie chart and it's very useful for seeing the evolution of your portfolio over time.
It can possible create infinite graphs, highlight trends, in short, free space to imagination!
With a script like this you can manage your crypto portfolio and ALWAYS be updated on the market trend Cool

You can directly aggregate these values ​​in a pie chart, useful for seeing the evolution of your portfolio over time.
You can create graphs in which the trend is highlighted, in short, free space to imagination, with such a script you can manage your crypto portfolio and ALWAYS be updated on the market trend.

FAQ

Why did I publish this guide?
[1] I have not found a complete tutorial or guide, just "pieces" detached from each other and not easy to use.

Why did I use COINGECKO?
I can tracks any crypto, shittoken etc. Following the value of some tokens and checking between CMC the market (exchanges) it seems more reliable for that purpose.

Isn't it risky to keep this information on google sheet?
[2] For a hypothetical privacy discussion yes of course.
But if you have an archive where you list all the works of the Louvre, this does not mean that you are the owner of those works of art. : Smiley
I recommend creating a secondary account in google.

Why use a DIY crypto tracker
It is much easier to use and customizable than an online tools.

This is a translated version from my original topic posted here
to moderators= Please feel free to delete or move if it's not the right place to post it or isn't allowed a guide like this




███████████████████████████
███████▄████████████▄██████
████████▄████████▄████████
███▀█████▀▄███▄▀█████▀███
█████▀█▀▄██▀▀▀██▄▀█▀█████
███████▄███████████▄███████
███████████████████████████
███████▀███████████▀███████
████▄██▄▀██▄▄▄██▀▄██▄████
████▄████▄▀███▀▄████▄████
██▄███▀▀█▀██████▀█▀███▄███
██▀█▀████████████████▀█▀███
███████████████████████████
.
.Duelbits.
..........UNLEASH..........
THE ULTIMATE
GAMING EXPERIENCE
DUELBITS
FANTASY
SPORTS
████▄▄█████▄▄
░▄████
███████████▄
▐███
███████████████▄
███
████████████████
███
████████████████▌
███
██████████████████
████████████████▀▀▀
███████████████▌
███████████████▌
████████████████
████████████████
████████████████
████▀▀███████▀▀
.
▬▬
VS
▬▬
████▄▄▄█████▄▄▄
░▄████████████████▄
▐██████████████████▄
████████████████████
████████████████████▌
█████████████████████
███████████████████
███████████████▌
███████████████▌
████████████████
████████████████
████████████████
████▀▀███████▀▀
/// PLAY FOR  FREE  ///
WIN FOR REAL
..PLAY NOW..
Tytanowy Janusz
Legendary
*
Offline Offline

Activity: 2198
Merit: 1649


Top-tier crypto casino and sportsbook


View Profile
May 05, 2020, 08:14:45 AM
 #2

Great work with guide. I always support DIY tools. When you once do you own working tool that saves your time you will never be the same person Smiley

Isn't it risky to keep this information on google sheet?
[2] For a hypothetical privacy discussion yes of course.
But if you have an archive where you list all the works of the Louvre, this does not mean that you are the owner of those works of art. : Smiley
I recommend creating a secondary account in google.

It's 100% safe. What can be risky with this? I think there is nothing that google can do knowing that 1 random guy is collecting price data for few coins.



bitbollo (OP)
Legendary
*
Offline Offline

Activity: 3472
Merit: 3963


Nec Recisa Recedit


View Profile
January 12, 2021, 08:06:50 AM
 #3

It's 100% safe. What can be risky with this? I think there is nothing that google can do knowing that 1 random guy is collecting price data for few coins.

Hi @Tytanowy Janusz sorry for my late reply.
I have read some "paranoid" people that doesn't want to share their personal information with google or other third part service.
I can understand but with a limit, since only in some rare situation it could be something dangerous (likewise some one try to kidnapping because they have read you have a lot of crypto .... or a government could always track this information and use against the user).
These are extreme situation, nothing that could have a real impact for a simple user.

I have tried to fix a problem regarded this tracker since it seems that API from coingecko are not working with some coins like:
Code:
=cc(“enjin-coin”;“usd”) =cc(“quant”;“usd”) =cc(“synthetix-network-token”;“usd”) =cc(“ren”;“usd”)
Any idea?

███████████████████████████
███████▄████████████▄██████
████████▄████████▄████████
███▀█████▀▄███▄▀█████▀███
█████▀█▀▄██▀▀▀██▄▀█▀█████
███████▄███████████▄███████
███████████████████████████
███████▀███████████▀███████
████▄██▄▀██▄▄▄██▀▄██▄████
████▄████▄▀███▀▄████▄████
██▄███▀▀█▀██████▀█▀███▄███
██▀█▀████████████████▀█▀███
███████████████████████████
.
.Duelbits.
..........UNLEASH..........
THE ULTIMATE
GAMING EXPERIENCE
DUELBITS
FANTASY
SPORTS
████▄▄█████▄▄
░▄████
███████████▄
▐███
███████████████▄
███
████████████████
███
████████████████▌
███
██████████████████
████████████████▀▀▀
███████████████▌
███████████████▌
████████████████
████████████████
████████████████
████▀▀███████▀▀
.
▬▬
VS
▬▬
████▄▄▄█████▄▄▄
░▄████████████████▄
▐██████████████████▄
████████████████████
████████████████████▌
█████████████████████
███████████████████
███████████████▌
███████████████▌
████████████████
████████████████
████████████████
████▀▀███████▀▀
/// PLAY FOR  FREE  ///
WIN FOR REAL
..PLAY NOW..
hatshepsut93
Legendary
*
Offline Offline

Activity: 3038
Merit: 2162


View Profile
January 12, 2021, 11:10:15 AM
Merited by bitbollo (1)
 #4

You may want to look at my project called Coin Watcher

It's a very similar idea - pulling data from Coingeko to make a simple crypto tracker that stores everything on client side to guarantee privacy. I added features like price alerts with sound and push notification, selections of prices in all supported currencies, autocomplete for coin names, total sum of the portfolio.
bitbollo (OP)
Legendary
*
Offline Offline

Activity: 3472
Merit: 3963


Nec Recisa Recedit


View Profile
January 12, 2021, 12:02:42 PM
 #5

You may want to look at my project called Coin Watcher

It's a very similar idea - pulling data from Coingeko to make a simple crypto tracker that stores everything on client side to guarantee privacy. I added features like price alerts with sound and push notification, selections of prices in all supported currencies, autocomplete for coin names, total sum of the portfolio.



I have not competence to realize something like your! I was searching something like a crypto tracking in excel / updated on google drive, but your work is definitely another level! very good job.

███████████████████████████
███████▄████████████▄██████
████████▄████████▄████████
███▀█████▀▄███▄▀█████▀███
█████▀█▀▄██▀▀▀██▄▀█▀█████
███████▄███████████▄███████
███████████████████████████
███████▀███████████▀███████
████▄██▄▀██▄▄▄██▀▄██▄████
████▄████▄▀███▀▄████▄████
██▄███▀▀█▀██████▀█▀███▄███
██▀█▀████████████████▀█▀███
███████████████████████████
.
.Duelbits.
..........UNLEASH..........
THE ULTIMATE
GAMING EXPERIENCE
DUELBITS
FANTASY
SPORTS
████▄▄█████▄▄
░▄████
███████████▄
▐███
███████████████▄
███
████████████████
███
████████████████▌
███
██████████████████
████████████████▀▀▀
███████████████▌
███████████████▌
████████████████
████████████████
████████████████
████▀▀███████▀▀
.
▬▬
VS
▬▬
████▄▄▄█████▄▄▄
░▄████████████████▄
▐██████████████████▄
████████████████████
████████████████████▌
█████████████████████
███████████████████
███████████████▌
███████████████▌
████████████████
████████████████
████████████████
████▀▀███████▀▀
/// PLAY FOR  FREE  ///
WIN FOR REAL
..PLAY NOW..
hatshepsut93
Legendary
*
Offline Offline

Activity: 3038
Merit: 2162


View Profile
January 12, 2021, 01:12:52 PM
 #6

I have not competence to realize something like your! I was searching something like a crypto tracking in excel / updated on google drive, but your work is definitely another level! very good job.

Well, I too didn't have competence when I started working on it, as this was my first web app. In fact I was starting from scratch a few times while I was figuring out how to work with those frontend frameworks, but it all paid off because I obtained massive amounts of experience and knowledge.

I still don't consider this project finished, because I have some ideas for new features, and I don't like the current design, which is very crude.
masterzino
Hero Member
*****
Offline Offline

Activity: 1218
Merit: 513



View Profile
January 12, 2021, 05:07:22 PM
 #7

Interesting! I didn't know that Google Docs are so powerful, allowing plain API calls/response recording.

I made a similar tracker long time using NodeJS, but this is better.

Pages: [1]
  Print  
 
Jump to:  

Powered by MySQL Powered by PHP Powered by SMF 1.1.19 | SMF © 2006-2009, Simple Machines Valid XHTML 1.0! Valid CSS!