binance-exchange / binance-java-api

binance-java-api is a lightweight Java library for the Binance API, supporting synchronous and asynchronous requests, as well as event streaming using WebSockets.
MIT License
831 stars 628 forks source link

Filter by Volume and BTC pairs #273

Open ken4ward opened 4 years ago

ken4ward commented 4 years ago

I am new to this API. Thanks for the 2017 winner of Binance API client competition. I'll like to filter by volume but have not seen anywhere in the documentation to do so, Please, how do I?

This is my simple code

private void BTCPairsOnly(){
        List<TickerPrice> allPrices = client.getAllPrices();
        for (TickerPrice tickerPrice: allPrices ) {
            if (tickerPrice.getSymbol().contains("BTC") && volume is greater than 100 ){
                System.out.println("BTC Pairs Only");
                System.out.println(tickerPrice);
            }
        }
    }