Bitstamp: Add new trading fees API endpoint; refine fee calcuations and test coverage (#1289)

* Bitstamp: WIP fixing trading fees

* Bitstamp/amended the TestGetFee test and currected the getTradingFee function

* Bitstamp: TestGetFee implemented for maker and taker

* Bitfinex: added a wrapped error

* Bitstamp: GetTradingFee and test updated, fetched from the API

Progresses #1271

* Bitstamp: minor changes- whitespace removal and comment added

* Bitstamp: fixed lint issues in TestGetBalance and TestGetTransactions

* Bitstamp:Typo in types TradingFee comment

* Bitstamp: GetAccountTradingFees at view the fees on all pairs

	modified:   exchanges/bitstamp/bitstamp.go

* Bitstamp: returning the TradingFee info instead of just MakerTakerFees

* Bitstamp:TestGetAccountTradingFees + TestGetAccountTradingFees added,data structure amended to match the outcome

* Bitstamp:error and a test for empty pair added in GetAccountTradingFee

* Bitstamp: RM the whitespace linter error
This commit is contained in:
Bea
2023-10-13 11:34:21 +07:00
committed by GitHub
parent 8430509807
commit 859c4512fb
5 changed files with 159 additions and 69 deletions

View File

@@ -148,6 +148,56 @@
}
]
},
"/api/v2/fees/trading/ltcbtc/": {
"POST": [
{
"data": {
"currency_pair": "ltcbtc",
"fees":
{
"maker": "0.3",
"taker": "0.2"
}
},
"queryString": "",
"bodyParams": "key=\u0026nonce=1690610275327495000\u0026signature=B619E1AEF317B95D3BB28025F36EEF94CABCDE425CE3E13E8A1861C0A9777F2A",
"headers": {
"Content-Type": [
"application/x-www-form-urlencoded"
]
}
}
]
},
"/api/v2/fees/trading/": {
"POST": [
{
"data": [
{
"currency_pair":"ltcbtc",
"fees": {
"maker": "0.3",
"taker": "0.2"
}
},
{
"currency_pair":"btcusd",
"fees": {
"maker": "0.3",
"taker": "0.2"
}
}
],
"queryString": "",
"bodyParams": "key=&nonce=1696325404980771000&signature=85B2B7E60567E352241BD98BDD08C0A435C2A77CB8F386739DD471BFFFA6C660",
"headers": {
"Content-Type": [
"application/x-www-form-urlencoded"
]
}
}
]
},
"/api/v2/buy/market/btcusd/": {
"POST": [
{