Author

Topic: BitsPerDollar.com • Instant USD⇔Bits/BTC conv. • API • Dynamic images • Twitter (Read 3353 times)

member
Activity: 60
Merit: 10
I was rather hoping to avoid parsing json as this is a simple project but I guess I'll have to look into it. If I do that I can just use any of the publicly available APIs from exchanges or preev etc. PS - the price on bitsperdollar is no longer updating or I would use it like it is. Any chance you can PM me an email address for the new owner(s)? I tweeted at them but there was no response and the whois appears to still be under your info.
legendary
Activity: 1862
Merit: 1469
https://Ecua.Mobi
How can one show the results of your API calls on a webpage? I want to show the extended value that I get from the API and not from the images (images seem to stop at 4 decimal places). Sorry to necro this thread but there is no documentation listed on the site. I currently have the api url in an iframe but I assume there is a more elegant way to do this.

Hi. This site is no longer mine, it was sold a few months ago.

Regarding your question, you can just query the API http://bitsperdollar.com/api.json
Then you'll need to parse it, read the field you need and do the math yourself.

Or you can use what's described under "Automatic conversion" in OP, only if that fits your needs.
member
Activity: 60
Merit: 10
How can one show the results of your API calls on a webpage? I want to show the extended value that I get from the API and not from the images (images seem to stop at 4 decimal places). Sorry to necro this thread but there is no documentation listed on the site. I currently have the api url in an iframe but I assume there is a more elegant way to do this.
legendary
Activity: 1862
Merit: 1469
https://Ecua.Mobi
legendary
Activity: 1862
Merit: 1469
https://Ecua.Mobi
Now you can follow @BitsPerDollar to get the latest rate of bitcoin along with the number of bits (millionths of BTC) per dollar. It will be automatically posted every 12 hours.

legendary
Activity: 1862
Merit: 1469
https://Ecua.Mobi
I've added some more features to the site:


Check OP or the site for more information.
sr. member
Activity: 252
Merit: 250
wow cool good idea nice concept and great feature Smiley

its very helpful for us to converts from bits to dollar and otherwise

simple and good looking and the price automatic update , thank you for this feature Smiley
legendary
Activity: 2324
Merit: 1267
In Memory of Zepher
Awesome, I think that looks a lot better! Thanks for taking my suggestions into account  Cheesy
legendary
Activity: 1862
Merit: 1469
https://Ecua.Mobi
The sheer amount of empty space on the site looks a bit strange, it would maybe look better if you enlarged the logo at the top and removed a line break or two.
Maybe removing one or two line breaks from the top of the main box and the prices written in text would be good, it also looks a little strange that there is more empty space above the prices than below them.
The input areas look a bit strange imo being so tall yet not having the text fill them properly, this may just be me though.

As for things that could be added, maybe conversions below the box which match the values in the text area could be useful. For example if the box said 100 bits it could have (=0.0001BTC) underneath or something. Granted the site is about bits per dollar, but maybe to give the user a bit more of an idea on how much that actually is.

All of the other things that you have planned sound pretty good, looking forward to seeing how this turns out!

Thank you for your suggestions. I've implemented the UI changes.
I also added the equivalent value in both bitcoins and satoshis below the text fields.
legendary
Activity: 2324
Merit: 1267
In Memory of Zepher
The sheer amount of empty space on the site looks a bit strange, it would maybe look better if you enlarged the logo at the top and removed a line break or two.
Maybe removing one or two line breaks from the top of the main box and the prices written in text would be good, it also looks a little strange that there is more empty space above the prices than below them.
The input areas look a bit strange imo being so tall yet not having the text fill them properly, this may just be me though.

As for things that could be added, maybe conversions below the box which match the values in the text area could be useful. For example if the box said 100 bits it could have (=0.0001BTC) underneath or something. Granted the site is about bits per dollar, but maybe to give the user a bit more of an idea on how much that actually is.

All of the other things that you have planned sound pretty good, looking forward to seeing how this turns out!
legendary
Activity: 1862
Merit: 1469
https://Ecua.Mobi

I've created a simple website that converts bits to US dollars and dollars to bits.
At the moment it has only one functionality: it allows you to enter a value in either unit and it instantly shows the conversion (JS is required).
It also shows the equivalent in bitcoins and satoshis (as suggested by minifrij).


The exchange rate is updated every 10 minutes from BitcoinAverage.

Here are some features I'm adding soon:
  • API support Done
  • Dynamic images: enter a price in USD and get an image that shows the equivalent number of bits (updated every 10 minutes) Done

Let me know any comments or suggestions to change or implement.
Here are the current features:

Dynamic images

Display the amount of bits based on a fixed value in US dollars. Just use this format:
Code:
[img]http://bitsperdollar.com/img/value_in_dollars[/img]

For example:

$1 =
Code:
[img]http://bitsperdollar.com/img/1[/img]

$99.99 =
Code:
[img]http://bitsperdollar.com/img/99.99[/img]

If you prefer to get the value in bitcoins just add /btc at the end:

$99.99 =
Code:
[img]http://bitsperdollar.com/img/99.99/btc[/img]

API

This API allows you to query the number of bits per dollar (or dollars per bitcoin) programmatically:
http://bitsperdollar.com/api.json

This will provide the following information in JSON format:
  • "bpd": Number of bits per dollar, as integer.
  • "btc": Number of dollars per bitcoin, as integer.
  • "bpd_format": Number of bits per dollar, as string, formatted.
  • "btc_format": Number of dollars per bitcoin, as string, formatted.

Automatic conversion

You can automatically convert any amount of dollars to either bits or bitcoins with a simple call.
The API will return a formatted plain text result ready to be displayed.
Code:
http://bitsperdollar.com/api/value_in_dollars


If you prefer to get the price in bitcoin, add /btc at the end

Direct link

Simply add /value_in_dollars to directly link to a pre-defined conversion. For example:


Additionally when entering a conversion on the site you will get the corresponding HTML and BB (forum) code to insert a dynamic image along with a direct link. It's ready to be used on bitcointalk.org and other forums.

Code:
[url=http://bitsperdollar.com/9.99][img]http://bitsperdollar.com/img/9.99/btc[/img][/url]



Twitter

Now you can follow @BitsPerDollar to get the latest rate of bitcoin along with the number of bits (millionths of BTC) per dollar. It will be automatically posted every 12 hours.
Jump to: