From e77b17df9eb95a18517dd5fd7b6e4f60d234c763 Mon Sep 17 00:00:00 2001 From: alipjxhub <67893243+alipjxhub@users.noreply.github.com> Date: Mon, 6 Jul 2020 14:31:30 +0430 Subject: [PATCH] Add trade fee function the function requests the updated trade fee of peer/symbol offered by binance in percentage --- php-binance-api.php | 19 +++++++++++++++++++ 1 file changed, 19 insertions(+) diff --git a/php-binance-api.php b/php-binance-api.php index b5bcb124..c9145000 100755 --- a/php-binance-api.php +++ b/php-binance-api.php @@ -547,6 +547,25 @@ public function assetDetail() $params["wapi"] = true; return $this->httpRequest("v3/assetDetail.html", 'GET', $params, true); } + + + /** + * Fetch current(daily) trade fee of symbol, values in percentage. + * for more info visit binance official api document + * + * $symbol = "BNBBTC"; or any other symbol or even a set of symbols in an array + * @param string $symbol + * @return mixed + */ + public function tradeFee(string $symbol) + { + $params = [ + "symbol" => $symbol, + "wapi" => true, + ]; + + return $this->httpRequest("v3/tradeFee.html", 'GET', $params, true); + } /** * withdraw requests a asset be withdrawn from binance to another wallet