dcrdex icon indicating copy to clipboard operation
dcrdex copied to clipboard

Market Maker - no oracles available for DCR/LTC

Open bochinchero opened this issue 1 year ago • 2 comments

Fully aware that the MM bot is POC at this point, but I imagine this will be an issue on pretty much any market that doesn't already exist in a CEX. When the market doesn't have too much activity on the books (like DCR/LTC now) the basis price can drift significantly from where it should be (e.g. right now its 0.17 and in binance its ~0.20), oracles would really come in handy here.

Could this be calculated based on thbe USD or BTC prices of both assets on the pair?

bochinchero avatar May 02 '23 07:05 bochinchero

Yes, if there is no oracle available, then the USD prices will be used to calculate a rate.

martonp avatar May 06 '23 09:05 martonp

coingecko and probably other sources can give conversions for arbitrary pairs.

$ curl -X 'GET' 'https://api.coingecko.com/api/v3/simple/price?ids=decred&vs_currencies=ltc' -H 'accept: application/json'
{"decred":{"ltc":0.20197442}}

chappjc avatar May 11 '23 18:05 chappjc