mirror of
https://github.com/d0zingcat/gocryptotrader.git
synced 2026-06-07 15:11:03 +00:00
engine/exchanges: Add GetCurrencyTradeURL wrapper func/gRPC endpoint (#1521)
* beginning the concept * expands testing and implementations * test standardisation, expansion * more * finish remainder, add rpc func * lint * grammar? I barely know her! * wow i forgot something wow wow wow wow * rm SendPayload * enFixio! * improve binance long-dated support * update test design, update wrapper funcs * adds kraken futures, adds bybit support * fixes SIMPLE bugs * s is for sucks * fixed option url x2 * fixed silly test
This commit is contained in:
@@ -864,3 +864,13 @@ func (b *Bithumb) GetFuturesContractDetails(context.Context, asset.Item) ([]futu
|
||||
func (b *Bithumb) GetLatestFundingRates(context.Context, *fundingrate.LatestRateRequest) ([]fundingrate.LatestRateResponse, error) {
|
||||
return nil, common.ErrFunctionNotSupported
|
||||
}
|
||||
|
||||
// GetCurrencyTradeURL returns the URL to the exchange's trade page for the given asset and currency pair
|
||||
func (b *Bithumb) GetCurrencyTradeURL(_ context.Context, a asset.Item, cp currency.Pair) (string, error) {
|
||||
_, err := b.CurrencyPairs.IsPairEnabled(cp, a)
|
||||
if err != nil {
|
||||
return "", err
|
||||
}
|
||||
cp.Delimiter = currency.DashDelimiter
|
||||
return tradeBaseURL + cp.Upper().String(), nil
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user