6

I'm looking for an API that literally exchanges USD to Bitcoin, not only value.

I've been looking all over for an exchange that accepts USD in it's API.

I've found tons that will do Crypto => Crypto but none that would do USD => Crypto.

Can someone share a service that does that? Or is there another way to exchange USD to Crypto programmatically?

2
  • You cannot send "USD" via an API call, so do you want dollars sent from your Paypal account? You cannot mail a check via an API call. That would be a lot more than an "API". That would be an entire service.
    – abelenky
    Nov 30, 2017 at 19:53
  • @abelenky I get your point, maybe I wasn't clear enough. Changelly for example, allows you to exchange USD to Crypto. To charge USD, you open a URL and pay with your Visa/Mastercard. I just want that URL (In this example). There is a way somehow...
    – elongl
    Dec 2, 2017 at 12:40

4 Answers 4

4

This looks like a service that does what you're asking for, if I'm understanding your ask and this page correctly: https://developers.coinbase.com/docs/wallet/guides/send-receive

This would require you to already have USD on deposit in your Coinbase account. The page says they are working on a feature to automatically withdraw USD from a linked bank account (I wouldn't hold my breath for this).

Since you explicitly asked about doing this via an API, I looked into this aspect a little bit, too: https://developers.coinbase.com/api/v2#transactions

In the example json on the right, I'm seeing that it has separate "amount" and "native amount" sections specifying BTC and USD respectively, and there's an "instant_exchange" field. This leads me to believe it can do exactly what you're asking for, provided you have USD on deposit and instantly available:

  • Hold USD, not BTC
  • Create a new transaction to send BTC, via API
  • USD is converted to BTC "just-in-time" at time of transaction

I didn't look into converting a USD amount to BTC based on the current price via Coinbase's API, but of course their API will provide for that (via a previous request).

blockchain.info also offers a free API to do this, although I'm sure the precise exchange rate on Coinbase will vary slightly from what blockchain.info reports: https://blockchain.info/tobtc?currency=USD&value=500

Hope that helps.. although I imagine you've probably answered this yourself since posting this question.

1

You have to use Coinbase. Their API description is a bit confusing because it combines Coinbase and Gdax. Coinbase is to transfer USD into crypto, and Gdax for crypto-to-crypto trades. An API is a software, it is not an exchange. To trade USD into crypto, you need an exchange (not an API). To make the exchange, you have to do it via an API that interfaces you with an exchange (this is how your question could have been more clear).

0

I am not aware of any exchange that accepts USD directly, however in the API description of Poloniex exchange there are buy and sell methods which should accept USD trading.

Please note that although you can trade with USD at Poloniex, you can only deposit and withdraw Coins not USD.

0

Yes, you could use blockchain.info api, they provide this service.

Link : https://blockchain.info/tobtc?currency=USD&value=500

Value should be your USD amount, also you could change currency to any currency.

You could do that mathematically but you will need bitcoin price.

For example 1 bitcoin worth $10,000

value in USD = exchange rate * amount of bitcoins

Or expressed in the units of the terms:

[USD] = [USD/BTC] * [BTC]


After your edit:

You can use bitfinx they offer API for buy/sell crypto currency.

Bitfinex's API are designed to offer an easy and efficient way to build digital asset trading applications and tools: create your own charts, monitor and edit your orders and positions,track your trading history and wallets movements. Discover all the possibilities.

4
  • 4
    I couldn't be more specific when I said "I'm looking for an API that literally exchanges USD to Bitcoin, not only value."
    – elongl
    Nov 30, 2017 at 17:14
  • 1
    Where would you put the USD? In the DVD drive? Take a picture of the bill with a camera?
    – abelenky
    Nov 30, 2017 at 20:13
  • @abelenky A site appears that charges money from me. Like buying something online.
    – elongl
    Dec 3, 2017 at 14:10
  • Then that is a site that charges your credit card and provides BTC, which is not the same thing as converting USD to BTC.
    – abelenky
    Dec 3, 2017 at 16:23

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge that you have read and understand our privacy policy and code of conduct.

Not the answer you're looking for? Browse other questions tagged or ask your own question.