Skip to main content
Version: 1.x

Vision

 Maven Central Sonatype Nexus  License: MIT

Description

Binance4j-vision is a Java connector for the public data endpoints of the Binance REST API.

Installation

Dependencies

pom.xml
<dependency>
<groupId>{{groupId}}</groupId>
<artifactId>{{artifactId}}</artifactId>
<version>{{version}}</version>
</dependency>

SPOT endpoints

Get klines

  
SpotClient client = new SpotClient();

try{
ZipInputStream response = client.getKlines("BNBBTC", CandlestickInterval.FIVE_MINUTE, "2022", "01").getZip();
}catch(ApiException e){
//...
}

Get trades

  
SpotClient client = new SpotClient();

try{
ZipInputStream response = client.getTrades("BNBBTC", "2022", "01").getZip();
}catch(ApiException e){
//...
}

Get aggregate trades

  
SpotClient client = new SpotClient();

try{
ZipInputStream response = client.getAggTrades("BNBBTC", "2022", "01").getZip();
}catch(ApiException e){
//...
}