COINBASE PRIME API - Price in USD

Is it possible to have USD prices whenever there is a coin to coin transactions (e.g BTC to ETH). I mean at that trade time, what was the value to BTC-USD and ETH-USD?

Hello @achuckoury, we thank you for your interest in trying out Coinbase Cloud APIs. Before anything else, may we ask if you already have an account with Coinbase Prime?

For starters, you may visit https://help.coinbase.com/en/prime/coinbase-prime-api/coinbase-prime-api to check out the overview on this service. Additionally, you may visit the following links for the proper documentation of Coinbase Prime API:

Coinbase Prime Docs
Coinbase Prime API References

Hi Jonathan,

I already have my API key with with I am trying to make API call to get the trading data. Currently I am able to get the limit price, filled_quantity, filled_value, average_filled_price but I would like to get the trading price in USD.

Anyone who can help me to get USD price for coin to coin transactions?

Hi @achuckoury! To answer your question, you would need to convert this yourself. It is essentially an FX Pairing, e.g. If I am trading USD/GBP and I want the EUR value of each I would need to get the price of EUR at the time of the trade and convert manually myself.

Similarly in this scenario if I am trading BTC/EUR and I want the BTC/USD value at the time then I would need to get a historical price point for that time and convert it.

Having said that, Coinbase does not have market data current & past via the API yet, so you would need to use Exchange endpoint: Get product candles. You do not need a Pro/Exchange account to use this and the price will not be exact but the best estimate we can provide.

1 Like