Skip to content

Commit fa2f789

Browse files
author
方佳
committed
Merge branch 'main_merge_260605' into 'main'
feat: Add support for Webull BR and MX See merge request webull/webull-openapi-java-sdk!34
2 parents 4ce6234 + 0d36a08 commit fa2f789

9 files changed

Lines changed: 34 additions & 19 deletions

File tree

‎README.md‎

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
# Webull OpenAPI Java SDK
22

3-
Note: This is the new version of the Webull SDK, currently applicable only to Webull Hong Kong, Webull US, Webull JP, Webull SG, Webull TH, Webull AU, Webull MY, or Webull UK customers.
3+
Note: This is the new version of the Webull SDK, currently applicable only to Webull Hong Kong, Webull US, Webull JP, Webull SG, Webull TH, Webull AU, Webull MY, Webull UK, Webull BR, or Webull MX customers.
44

55
Webull OpenAPI aims to provide quantitative trading investors with convenient, fast and secure services. Webull aims to help every quant traders achieve flexible and changeable trading or market strategies.
66

@@ -28,6 +28,8 @@ Subscription to real-time information: Subscribe to order status changes, market
2828
| Webull AU | https://www.webull.com.au/open-api-management |
2929
| Webull MY | https://www.webull.com.my/open-api-management |
3030
| Webull UK | https://www.webull-uk.com/open-api-management |
31+
| Webull BR | https://www.webull.com.br/open-api-management |
32+
| Webull MX | https://www.webull.com.mx/open-api-management |
3133

3234
- Requires JDK 8 and above.
3335

@@ -53,3 +55,5 @@ The bottom layer of Webull OpenAPI provides three protocols, HTTP / GRPC / MQTT,
5355
| Webull AU | https://developer.webull.com.au/apis/docs |
5456
| Webull MY | https://developer.webull.com.my/apis/docs |
5557
| Webull UK | https://developer.webull-uk.com/apis/docs |
58+
| Webull BR | https://developer.webull.com.br/apis/docs |
59+
| Webull MX | https://developer.webull.com.mx/apis/docs |

‎pom.xml‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,7 @@
2121
<groupId>com.webull.openapi</groupId>
2222
<artifactId>webull-openapi-java-sdk-parent</artifactId>
2323
<packaging>pom</packaging>
24-
<version>1.1.11</version>
24+
<version>1.1.12</version>
2525

2626
<name>webull-openapi-java-sdk-parent</name>
2727
<url>https://github.com/webull-inc/webull-openapi-java-sdk/</url>

‎webull-openapi-java-sdk-samples/pom.xml‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@
1919
<parent>
2020
<groupId>com.webull.openapi</groupId>
2121
<artifactId>webull-openapi-java-sdk-parent</artifactId>
22-
<version>1.1.11</version>
22+
<version>1.1.12</version>
2323
</parent>
2424
<modelVersion>4.0.0</modelVersion>
2525

‎webull-openapi-java-sdk/pom.xml‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@
77
<parent>
88
<groupId>com.webull.openapi</groupId>
99
<artifactId>webull-openapi-java-sdk-parent</artifactId>
10-
<version>1.1.11</version>
10+
<version>1.1.12</version>
1111
</parent>
1212

1313
<artifactId>webull-openapi-java-sdk</artifactId>

‎webull-openapi-java-sdk/src/main/java/com/webull/openapi/core/common/ApiModule.java‎

Lines changed: 6 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -22,17 +22,20 @@ public enum ApiModule {
2222
* api
2323
*/
2424
API(DefaultHost.API_US, DefaultHost.API_HK, DefaultHost.API_JP, DefaultHost.API_SG,
25-
DefaultHost.API_TH, DefaultHost.API_AU, DefaultHost.API_MY, DefaultHost.API_UK),
25+
DefaultHost.API_TH, DefaultHost.API_AU, DefaultHost.API_MY, DefaultHost.API_UK,
26+
DefaultHost.API_BR, DefaultHost.API_MX),
2627
/**
2728
* quotes api
2829
*/
2930
QUOTES(DefaultHost.QUOTES_US, DefaultHost.QUOTES_HK, DefaultHost.QUOTES_JP, DefaultHost.QUOTES_SG,
30-
DefaultHost.QUOTES_TH, DefaultHost.QUOTES_AU, DefaultHost.QUOTES_MY, DefaultHost.QUOTES_UK),
31+
DefaultHost.QUOTES_TH, DefaultHost.QUOTES_AU, DefaultHost.QUOTES_MY, DefaultHost.QUOTES_UK,
32+
DefaultHost.QUOTES_BR, DefaultHost.QUOTES_MX),
3133
/**
3234
* events api
3335
*/
3436
EVENTS(DefaultHost.EVENTS_US, DefaultHost.EVENTS_HK, DefaultHost.EVENTS_JP, DefaultHost.EVENTS_SG,
35-
DefaultHost.EVENTS_TH, DefaultHost.EVENTS_AU, DefaultHost.EVENTS_MY, DefaultHost.EVENTS_UK),
37+
DefaultHost.EVENTS_TH, DefaultHost.EVENTS_AU, DefaultHost.EVENTS_MY, DefaultHost.EVENTS_UK,
38+
DefaultHost.EVENTS_BR, DefaultHost.EVENTS_MX),
3639
;
3740

3841
private final EnumMap<Region, String> hosts;

‎webull-openapi-java-sdk/src/main/java/com/webull/openapi/core/common/DefaultHost.java‎

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -51,6 +51,14 @@ private DefaultHost() {}
5151
public static final String QUOTES_UK = "data-api.webull-uk.com";
5252
public static final String EVENTS_UK = "events-api.webull-uk.com";
5353

54+
public static final String API_BR = "api.webull.com";
55+
public static final String QUOTES_BR = "data-api.webull.com";
56+
public static final String EVENTS_BR = "events-api.webull.com";
57+
58+
public static final String API_MX = "api.webull.com";
59+
public static final String QUOTES_MX = "data-api.webull.com";
60+
public static final String EVENTS_MX = "events-api.webull.com";
61+
5462
public static final String API_HK_SANDBOX = "api.sandbox.webull.hk";
5563
public static final String EVENTS_HK_SANDBOX = "events-api.sandbox.webull.hk";
5664

‎webull-openapi-java-sdk/src/main/java/com/webull/openapi/core/common/Region.java‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@
1919

2020
public enum Region {
2121

22-
us, hk, jp, sg, th, au, my, uk;
22+
us, hk, jp, sg, th, au, my, uk, br, mx;
2323

2424
public static Optional<Region> of(String name) {
2525
for (Region region : Region.values()) {

‎webull-openapi-java-sdk/src/main/java/com/webull/openapi/core/config/ProjectReaderHelper.java‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,7 @@ private ProjectReaderHelper() {
2424

2525
private static final String APPLICATION_VERSION = "application.version";
2626

27-
private static final String DEFAULT_APPLICATION_VERSION = "1.1.11";
27+
private static final String DEFAULT_APPLICATION_VERSION = "1.1.12";
2828

2929
private static final String APPLICATION_NAME = "application.name";
3030

‎webull-openapi-java-sdk/src/main/java/com/webull/openapi/trade/http/ITradeV3Client.java‎

Lines changed: 10 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -9,19 +9,19 @@
99
public interface ITradeV3Client {
1010

1111
/**
12-
* This interface is currently supported only for Webull HK, Webull US, Webull SG, Webull TH, Webull AU, Webull MY, Webull UK, and Webull JP.
12+
* This interface is currently supported only for Webull HK, Webull US, Webull SG, Webull TH, Webull AU, Webull MY, Webull UK, Webull JP, Webull BR, and Webull MX.
1313
* Support for other regions will be available in future updates.
1414
*/
1515
List<Account> listAccount();
1616

1717
/**
18-
* This interface is currently supported only for Webull HK, Webull US, Webull SG, Webull TH, Webull AU, Webull MY, Webull UK, and Webull JP.
18+
* This interface is currently supported only for Webull HK, Webull US, Webull SG, Webull TH, Webull AU, Webull MY, Webull UK, Webull JP, Webull BR, and Webull MX.
1919
* Support for other regions will be available in future updates.
2020
*/
2121
AccountBalanceInfo balanceAccount(String accountId);
2222

2323
/**
24-
* This interface is currently supported only for Webull HK, Webull US, Webull SG, Webull TH, Webull AU, Webull MY, Webull UK, and Webull JP.
24+
* This interface is currently supported only for Webull HK, Webull US, Webull SG, Webull TH, Webull AU, Webull MY, Webull UK, Webull JP, Webull BR, and Webull MX.
2525
* Support for other regions will be available in future updates.
2626
*/
2727
List<AccountPositionsInfo> positionsAccount(String accountId);
@@ -33,13 +33,13 @@ public interface ITradeV3Client {
3333
List<AccountPositionDetailsInfo> positionDetailsAccount(String accountId, String instrumentId, Integer pageSize, String lastId);
3434

3535
/**
36-
* This interface is currently supported only for Webull HK, Webull US, Webull SG, Webull TH, Webull AU, Webull MY, Webull UK, and Webull JP.
36+
* This interface is currently supported only for Webull HK, Webull US, Webull SG, Webull TH, Webull AU, Webull MY, Webull UK, Webull JP, Webull BR, and Webull MX.
3737
* Support for other regions will be available in future updates.
3838
*/
3939
PreviewOrderResponse previewOrder(String accountId, TradeOrder tradeOrder);
4040

4141
/**
42-
* This interface is currently supported only for Webull HK, Webull US, Webull SG, Webull TH, Webull AU, Webull MY, Webull UK, and Webull JP.
42+
* This interface is currently supported only for Webull HK, Webull US, Webull SG, Webull TH, Webull AU, Webull MY, Webull UK, Webull JP, Webull BR, and Webull MX.
4343
* Support for other regions will be available in future updates.
4444
*/
4545
TradeOrderResponse placeOrder(String accountId, TradeOrder tradeOrder);
@@ -51,32 +51,32 @@ public interface ITradeV3Client {
5151
TradeBatchPlaceResponse batchPlaceOrder(String accountId, TradeOrder tradeOrder);
5252

5353
/**
54-
* This interface is currently supported only for Webull HK, Webull US, Webull SG, Webull TH, Webull AU, Webull MY, Webull UK, and Webull JP.
54+
* This interface is currently supported only for Webull HK, Webull US, Webull SG, Webull TH, Webull AU, Webull MY, Webull UK, Webull JP, Webull BR, and Webull MX.
5555
* Support for other regions will be available in future updates.
5656
*/
5757
TradeOrderResponse replaceOrder(String accountId, TradeOrder tradeOrder);
5858

5959
/**
60-
* This interface is currently supported only for Webull HK, Webull US, Webull SG, Webull TH, Webull AU, Webull MY, Webull UK, and Webull JP.
60+
* This interface is currently supported only for Webull HK, Webull US, Webull SG, Webull TH, Webull AU, Webull MY, Webull UK, Webull JP, Webull BR, and Webull MX.
6161
* Support for other regions will be available in future updates.
6262
*/
6363
TradeOrderResponse cancelOrder(String accountId, TradeOrder tradeOrder);
6464

6565
/**
66-
* This interface is currently supported only for Webull HK, Webull US, Webull SG, Webull TH, Webull AU, Webull MY, Webull UK, and Webull JP.
66+
* This interface is currently supported only for Webull HK, Webull US, Webull SG, Webull TH, Webull AU, Webull MY, Webull UK, Webull JP, Webull BR, and Webull MX.
6767
* Support for other regions will be available in future updates.
6868
*/
6969
List<OrderHistory> listOrders(String accountId, Integer pageSize, String startDate, String endDate,
7070
String lastClientOrderId);
7171

7272
/**
73-
* This interface is currently supported only for Webull HK, Webull US, Webull SG, Webull TH, Webull AU, Webull MY, Webull UK, and Webull JP.
73+
* This interface is currently supported only for Webull HK, Webull US, Webull SG, Webull TH, Webull AU, Webull MY, Webull UK, Webull JP, Webull BR, and Webull MX.
7474
* Support for other regions will be available in future updates.
7575
*/
7676
List<OrderHistory> openOrders(String accountId, Integer pageSize, String lastClientOrderId);
7777

7878
/**
79-
* This interface is currently supported only for Webull HK, Webull US, Webull SG, Webull TH, Webull AU, Webull MY, Webull UK, and Webull JP.
79+
* This interface is currently supported only for Webull HK, Webull US, Webull SG, Webull TH, Webull AU, Webull MY, Webull UK, Webull JP, Webull BR, and Webull MX.
8080
* Support for other regions will be available in future updates.
8181
*/
8282
OrderHistory getOrderDetails(String accountId, String clientOrderId);

0 commit comments

Comments
 (0)