Comments (5)
from bettertouchtool-crypto.
Can anyone post code to view TRX and ADA?
from bettertouchtool-crypto.
this isn't going to give you a snazzy icon, but it does the work.
the icons are being drawn by their code in these examples, which I do not have handy
we re-use the icons provided by the other examples given to us these working tabs
Ultimately, all we're really doing is changing the ticker address. Hope this helps.
This first one is for TRX Tron, others are commented out
set json to do shell script "curl -H 'CB-VERSION: 2015-04-08' https://api.coinbase.com/v2/prices/ETH-USD/spot"
set json to do shell script "sed s/warnings.*//g <<< " & json
set eth to do shell script "sed s/[a-zA-Z:{},]//g <<< " & json
set eth to eth as real
set pay to do shell script "curl -s 'https://bittrex.com/api/v1.1/public/getticker?market=eth-trx' | grep -oE '(Last).' | sed 's/[^0-9\\.]//g'"
set pay to pay as real
set answer to pay * eth
set answer to answer * 100
set answer to round answer
set answer to answer / 100
return "$" & answer
verge XVG below
set json to do shell script "curl -H 'CB-VERSION: 2015-04-08' https://api.coinbase.com/v2/prices/BTC-USD/spot"
set json to do shell script "sed s/warnings.*//g <<< " & json
set eth to do shell script "sed s/[a-zA-Z:{},]//g <<< " & json
set eth to eth as real
set pay to do shell script "curl -s 'https://bittrex.com/api/v1.1/public/getticker?market=btc-xvg' | grep -oE '(Last).' | sed 's/[^0-9\\.]//g'"
set pay to pay as real
set answer to pay * eth
set answer to answer * 100
set answer to round answer
set answer to answer / 100
return "$" & answer
cardano / ada below
set json to do shell script "curl -H 'CB-VERSION: 2015-04-08' https://api.coinbase.com/v2/prices/BTC-USD/spot"
set json to do shell script "sed s/warnings.*//g <<< " & json
set eth to do shell script "sed s/[a-zA-Z:{},]//g <<< " & json
set eth to eth as real
set pay to do shell script "curl -s 'https://bittrex.com/api/v1.1/public/getticker?market=btc-ada' | grep -oE '(Last).' | sed 's/[^0-9\\.]//g'"
set pay to pay as real
set answer to pay * eth
set answer to answer * 100
set answer to round answer
set answer to answer / 100
return "$" & answer
from bettertouchtool-crypto.
Thanks!!!
from bettertouchtool-crypto.
https://github.com/github/docs/blob/main/articles/types-of-github-accounts
from bettertouchtool-crypto.
Related Issues (11)
- Request: Is it possible to get an example to fetch from the coinmarketcap API? HOT 4
- Can't make "#" into type real
- Change prices to remove decimal places?
- Tag posible stable releases
- Is it possible to get images of the tokens from the coinmarketcap api? HOT 1
- Nice Project! Could you add BitYep Price? HOT 2
- Warnings in api call, process hangs up HOT 1
- Sparklines would be great HOT 3
- Feature Request: Flash button background on update HOT 1
- Displaying BTC prices
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from bettertouchtool-crypto.