Skip to content

Commit

Permalink
Release v3.4.1
Browse files Browse the repository at this point in the history
  • Loading branch information
dimitrisn442 committed Jan 8, 2025
1 parent 5da82a1 commit 1724da8
Show file tree
Hide file tree
Showing 13 changed files with 172 additions and 168 deletions.
4 changes: 4 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,9 @@
# Changelog

## 3.4.1 - 2025-01-08
### Changed
- Updated documentation links.

## 3.4.0 - 2024-10-02
### Added
- New Margin endpoints:
Expand Down
2 changes: 1 addition & 1 deletion pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@

<groupId>io.github.binance</groupId>
<artifactId>binance-connector-java</artifactId>
<version>3.4.0</version>
<version>3.4.1</version>
<packaging>jar</packaging>
<name>${project.groupId}:${project.artifactId}</name>
<description>lightweight connector to API</description>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -506,10 +506,10 @@ public int diffDepthStream(String symbol, int speed, WebSocketOpenCallback onOpe
* User Data Streams are accessed at /ws/&lt;listenKey&gt;
*
* @param listenKey listen key obtained from this
* <a href="https://developers.binance.com/docs/binance-spot-api-docs/rest-api#user-data-stream-endpoints">endpoint</a>
* <a href="https://developers.binance.com/docs/binance-spot-api-docs/user-data-stream">endpoint</a>
* @return int - Connection ID
* @see <a href="https://developers.binance.com/docs/binance-spot-api-docs/rest-api#start-user-data-stream-user_stream">
* https://developers.binance.com/docs/binance-spot-api-docs/rest-api#start-user-data-stream-user_stream</a>
* @see <a href="https://developers.binance.com/docs/binance-spot-api-docs/user-data-stream">
* https://developers.binance.com/docs/binance-spot-api-docs/user-data-stream</a>
*/
@Override
public int listenUserStream(String listenKey, WebSocketMessageCallback callback) {
Expand All @@ -520,7 +520,7 @@ public int listenUserStream(String listenKey, WebSocketMessageCallback callback)
* Same as {@link #listenUserStream(String, WebSocketMessageCallback)} plus accepts callbacks for all major websocket connection events.
*
* @param listenKey listen key obtained from this
* <a href="https://developers.binance.com/docs/binance-spot-api-docs/rest-api#user-data-stream-endpoints">endpoint</a>
* <a href="https://developers.binance.com/docs/binance-spot-api-docs/user-data-stream">endpoint</a>
* @param onOpenCallback Callback for when the websocket connection is opened
* @param onMessageCallback Callback for when a message is received
* @param onClosingCallback Callback for when the websocket connection is closing
Expand Down
60 changes: 30 additions & 30 deletions src/main/java/com/binance/connector/client/impl/spot/Market.java
Original file line number Diff line number Diff line change
Expand Up @@ -35,8 +35,8 @@ public Market(String baseUrl, String apiKey, boolean showLimitUsage, ProxyAuth p
* GET /api/v3/ping
* <br>
* @return String
* @see <a href="https://developers.binance.com/docs/binance-spot-api-docs/rest-api#test-connectivity">
* https://developers.binance.com/docs/binance-spot-api-docs/rest-api#test-connectivity</a>
* @see <a href="https://developers.binance.com/docs/binance-spot-api-docs/rest-api/general-endpoints#test-connectivity">
* https://developers.binance.com/docs/binance-spot-api-docs/rest-api/general-endpoints#test-connectivity</a>
*/
public String ping() {
return requestHandler.sendPublicRequest(baseUrl, PING, null, HttpMethod.GET, showLimitUsage);
Expand All @@ -49,8 +49,8 @@ public String ping() {
* GET /api/v3/time
* <br>
* @return String
* @see <a href="https://developers.binance.com/docs/binance-spot-api-docs/rest-api#test-connectivity">
* https://developers.binance.com/docs/binance-spot-api-docs/rest-api#check-server-time</a>
* @see <a href="https://developers.binance.com/docs/binance-spot-api-docs/rest-api/general-endpoints#check-server-time">
* https://developers.binance.com/docs/binance-spot-api-docs/rest-api/general-endpoints#check-server-time</a>
*/
public String time() {
return requestHandler.sendPublicRequest(baseUrl, TIME, null, HttpMethod.GET, showLimitUsage);
Expand All @@ -70,8 +70,8 @@ public String time() {
* symbols -- optional/ArrayList <br>
* permissions -- optional/ArrayList -- support single or multiple values (e.g. "SPOT", ["MARGIN","LEVERAGED"]) <br>
* @return String
* @see <a href="https://developers.binance.com/docs/binance-spot-api-docs/rest-api#exchange-information">
* https://developers.binance.com/docs/binance-spot-api-docs/rest-api#exchange-information</a>
* @see <a href="https://developers.binance.com/docs/binance-spot-api-docs/rest-api/general-endpoints#exchange-information">
* https://developers.binance.com/docs/binance-spot-api-docs/rest-api/general-endpoints#exchange-information</a>
*/
public String exchangeInfo(Map<String, Object> parameters) {
if (parameters.containsKey("symbol") && parameters.containsKey("symbols")) {
Expand Down Expand Up @@ -106,8 +106,8 @@ public String exchangeInfo(Map<String, Object> parameters) {
* limit -- optional/integer -- limit the results
* Default 100; max 5000. Valid limits:[5, 10, 20, 50, 100, 500, 1000, 5000] <br>
* @return String
* @see <a href="https://developers.binance.com/docs/binance-spot-api-docs/rest-api#order-book">
* https://developers.binance.com/docs/binance-spot-api-docs/rest-api#order-book</a>
* @see <a href="https://developers.binance.com/docs/binance-spot-api-docs/rest-api/market-data-endpoints#order-book">
* https://developers.binance.com/docs/binance-spot-api-docs/rest-api/market-data-endpoints#order-book</a>
*/
public String depth(Map<String, Object> parameters) {
ParameterChecker.checkParameter(parameters, "symbol", String.class);
Expand All @@ -127,8 +127,8 @@ public String depth(Map<String, Object> parameters) {
* symbol -- mandatory/string <br>
* limit -- optional/integer -- limit the results Default 500; max 1000 <br>
* @return String
* @see <a href="https://developers.binance.com/docs/binance-spot-api-docs/rest-api#recent-trades-list">
* https://developers.binance.com/docs/binance-spot-api-docs/rest-api#recent-trades-list</a>
* @see <a href="https://developers.binance.com/docs/binance-spot-api-docs/rest-api/market-data-endpoints#recent-trades-list">
* https://developers.binance.com/docs/binance-spot-api-docs/rest-api/market-data-endpoints#recent-trades-list</a>
*/
public String trades(Map<String, Object> parameters) {
ParameterChecker.checkParameter(parameters, "symbol", String.class);
Expand All @@ -149,8 +149,8 @@ public String trades(Map<String, Object> parameters) {
* limit -- optional/integer -- limit the result Default 500; max 1000 <br>
* fromId -- optional/long -- trade id to fetch from. Default gets most recent trades <br>
* @return String
* @see <a href="https://developers.binance.com/docs/binance-spot-api-docs/rest-api#old-trade-lookup">
* https://developers.binance.com/docs/binance-spot-api-docs/rest-api#old-trade-lookup</a>
* @see <a href="https://developers.binance.com/docs/binance-spot-api-docs/rest-api/market-data-endpoints#old-trade-lookup">
* https://developers.binance.com/docs/binance-spot-api-docs/rest-api/market-data-endpoints#old-trade-lookup</a>
*
*/
public String historicalTrades(Map<String, Object> parameters) {
Expand All @@ -175,8 +175,8 @@ public String historicalTrades(Map<String, Object> parameters) {
* endTime -- optional/long -- Timestamp in ms to get aggregate trades until INCLUSIVE <br>
* limit -- optional/integer -- limit the results Default 500; max 1000 <br>
* @return String
* @see <a href="https://developers.binance.com/docs/binance-spot-api-docs/rest-api#compressedaggregate-trades-list">
* https://developers.binance.com/docs/binance-spot-api-docs/rest-api#compressedaggregate-trades-list</a>
* @see <a href="https://developers.binance.com/docs/binance-spot-api-docs/rest-api/market-data-endpoints#compressedaggregate-trades-list">
* https://developers.binance.com/docs/binance-spot-api-docs/rest-api/market-data-endpoints#compressedaggregate-trades-list</a>
*/
public String aggTrades(Map<String, Object> parameters) {
ParameterChecker.checkParameter(parameters, "symbol", String.class);
Expand All @@ -201,8 +201,8 @@ public String aggTrades(Map<String, Object> parameters) {
* timeZone -- optional/string -- Default:0 (UTC) <br>
* limit -- optional/integer -- limit the results Default 500; max 1000 <br>
* @return String
* @see <a href="https://developers.binance.com/docs/binance-spot-api-docs/rest-api#klinecandlestick-data">
* https://developers.binance.com/docs/binance-spot-api-docs/rest-api#klinecandlestick-data</a>
* @see <a href="https://developers.binance.com/docs/binance-spot-api-docs/rest-api/market-data-endpoints#klinecandlestick-data">
* https://developers.binance.com/docs/binance-spot-api-docs/rest-api/market-data-endpoints#klinecandlestick-data</a>
*/
public String klines(Map<String, Object> parameters) {
ParameterChecker.checkParameter(parameters, "symbol", String.class);
Expand All @@ -228,8 +228,8 @@ public String klines(Map<String, Object> parameters) {
* timeZone -- optional/string -- Default:0 (UTC) <br>
* limit -- optional/integer -- limit the results Default 500; max 1000 <br>
* @return String
* @see <a href="https://developers.binance.com/docs/binance-spot-api-docs/rest-api#uiklines">
* https://developers.binance.com/docs/binance-spot-api-docs/rest-api#uiklines</a>
* @see <a href="https://developers.binance.com/docs/binance-spot-api-docs/rest-api/market-data-endpoints#uiklines">
* https://developers.binance.com/docs/binance-spot-api-docs/rest-api/market-data-endpoints#uiklines</a>
*/
public String uiKlines(Map<String, Object> parameters) {
ParameterChecker.checkParameter(parameters, "symbol", String.class);
Expand All @@ -249,8 +249,8 @@ public String uiKlines(Map<String, Object> parameters) {
* <br><br>
* symbol -- mandatory/string -- the trading pair <br>
* @return String
* @see <a href="https://developers.binance.com/docs/binance-spot-api-docs/rest-api#current-average-price">
* https://developers.binance.com/docs/binance-spot-api-docs/rest-api#current-average-price</a>
* @see <a href="https://developers.binance.com/docs/binance-spot-api-docs/rest-api/market-data-endpoints#current-average-price">
* https://developers.binance.com/docs/binance-spot-api-docs/rest-api/market-data-endpoints#current-average-price</a>
*/
public String averagePrice(Map<String, Object> parameters) {
ParameterChecker.checkParameter(parameters, "symbol", String.class);
Expand All @@ -271,8 +271,8 @@ public String averagePrice(Map<String, Object> parameters) {
* symbols -- optional/string <br>
* type -- optional/enum -- Supported values: FULL or MINI. If none provided, the default is FULL <br>
* @return String
* @see <a href="https://developers.binance.com/docs/binance-spot-api-docs/rest-api#24hr-ticker-price-change-statistics">
* https://developers.binance.com/docs/binance-spot-api-docs/rest-api#24hr-ticker-price-change-statistics</a>
* @see <a href="https://developers.binance.com/docs/binance-spot-api-docs/rest-api/market-data-endpoints#24hr-ticker-price-change-statistics">
* https://developers.binance.com/docs/binance-spot-api-docs/rest-api/market-data-endpoints#24hr-ticker-price-change-statistics</a>
*/
public String ticker24H(Map<String, Object> parameters) {
if (parameters.containsKey("symbol") && parameters.containsKey("symbols")) {
Expand All @@ -299,8 +299,8 @@ public String ticker24H(Map<String, Object> parameters) {
* symbol -- optional/string -- the trading pair <br>
* symbols -- optional/string <br>
* @return String
* @see <a href="https://developers.binance.com/docs/binance-spot-api-docs/rest-api#symbol-price-ticker">
* https://developers.binance.com/docs/binance-spot-api-docs/rest-api#symbol-price-ticker</a>
* @see <a href="https://developers.binance.com/docs/binance-spot-api-docs/rest-api/market-data-endpoints#symbol-price-ticker">
* https://developers.binance.com/docs/binance-spot-api-docs/rest-api/market-data-endpoints#symbol-price-ticker</a>
*/
public String tickerSymbol(Map<String, Object> parameters) {
if (parameters.containsKey("symbol") && parameters.containsKey("symbols")) {
Expand All @@ -327,8 +327,8 @@ public String tickerSymbol(Map<String, Object> parameters) {
* symbol -- optional/string -- the trading pair <br>
* symbols -- optional/string <br>
* @return String
* @see <a href="https://developers.binance.com/docs/binance-spot-api-docs/rest-api#symbol-order-book-ticker">
* https://developers.binance.com/docs/binance-spot-api-docs/rest-api#symbol-order-book-ticker</a>
* @see <a href="https://developers.binance.com/docs/binance-spot-api-docs/rest-api/market-data-endpoints#symbol-order-book-ticker">
* https://developers.binance.com/docs/binance-spot-api-docs/rest-api/market-data-endpoints#symbol-order-book-ticker</a>
*/
public String bookTicker(Map<String, Object> parameters) {
if (parameters.containsKey("symbol") && parameters.containsKey("symbols")) {
Expand Down Expand Up @@ -359,8 +359,8 @@ public String bookTicker(Map<String, Object> parameters) {
* windowSize -- optional/enum -- Defaults to 1d if no parameter provided <br>
* type -- optional/enum -- Supported values: FULL or MINI. If none provided, the default is FULL <br>
* @return String
* @see <a href="https://developers.binance.com/docs/binance-spot-api-docs/rest-api#rolling-window-price-change-statistics">
* https://developers.binance.com/docs/binance-spot-api-docs/rest-api#rolling-window-price-change-statistics</a>
* @see <a href="https://developers.binance.com/docs/binance-spot-api-docs/rest-api/market-data-endpoints#rolling-window-price-change-statistics">
* https://developers.binance.com/docs/binance-spot-api-docs/rest-api/market-data-endpoints#rolling-window-price-change-statistics</a>
*/
public String ticker(Map<String, Object> parameters) {
if (parameters.containsKey("symbol") && parameters.containsKey("symbols")) {
Expand Down Expand Up @@ -392,8 +392,8 @@ public String ticker(Map<String, Object> parameters) {
* timeZone -- optional/enum -- Default: 0 (UTC) <br>
* type -- optional/enum -- Supported values: FULL or MINI. If none provided, the default is FULL <br>
* @return String
* @see <a href="https://developers.binance.com/docs/binance-spot-api-docs/rest-api#trading-day-ticker">
* https://developers.binance.com/docs/binance-spot-api-docs/rest-api#trading-day-ticker</a>
* @see <a href="https://developers.binance.com/docs/binance-spot-api-docs/rest-api/market-data-endpoints#trading-day-ticker">
* https://developers.binance.com/docs/binance-spot-api-docs/rest-api/market-data-endpoints#trading-day-ticker</a>
*/
public String tradingDayTicker(Map<String, Object> parameters) {
if (parameters.containsKey("symbol") && parameters.containsKey("symbols")) {
Expand Down
Loading

0 comments on commit 1724da8

Please sign in to comment.