BTCMarkets / API

API
119 stars 30 forks source link

Discrepancy between available funds on website and API call #155

Closed mitch-1211 closed 4 years ago

mitch-1211 commented 5 years ago

Hi,

When using the call to endpoint https://api.btcmarkets.net/account/balance, the following is returned for the AUD balance:

{"balance":827203564,"pendingFunds":100849999,"currency":"AUD"}

However on the website my available funds are $7.27 (screenshot attached). The balance returned from the API call does not take into account the pending funds, however the balance reported on the website does.

screen shot 2018-10-10 at 6 22 41 pm

Is this behaviour intentional?

liamwhittle commented 5 years ago

It's clear that "balance" from the API call is the sum of pending and available, whereas the website shows available. You could just take balance - pendingFunds to get available.

martin-nginio commented 4 years ago

Hi @dev-duzza

Thanks for your feedback.

You are correct and we currently use different concepts for the website vs the API. I can confirm the underlying data is the same but the website users balance to indicate total available fund. I will discuss this with our team to see if we can get the terminologies to be consistent.

By the way, we have developed new generation of API that comes with several improvements and new features (including better error handling). Please feel free to check it below and If you have any questions please let us know. https://api.btcmarkets.net/doc/v3#section/Introduction

Thanks again.

Regards, Martin