|
Binance C++ Connector 2.0.0
Official C++ connectors for the Binance APIs
|
#include <account_api.hpp>
Public Member Functions | |
| AccountApi (std::shared_ptr< common::RestClient > client) | |
| common::RestApiResponse< AccountCommissionResponse > | account_commission (const AccountCommissionParams ¶ms) const |
| Query Commission Rates (USER_DATA). | |
| template<class CompletionToken> | |
| auto | async_account_commission (const AccountCommissionParams ¶ms, CompletionToken &&token) const |
| Asynchronous account_commission(). | |
| common::RestApiResponse< std::vector< AllOrderListResponseInner > > | all_order_list (const AllOrderListParams ¶ms={}) const |
| Query all Order lists (USER_DATA). | |
| template<class CompletionToken> | |
| auto | async_all_order_list (const AllOrderListParams ¶ms, CompletionToken &&token) const |
| Asynchronous all_order_list(). | |
| common::RestApiResponse< std::vector< AllOrdersResponseInner > > | all_orders (const AllOrdersParams ¶ms) const |
| All orders (USER_DATA). | |
| template<class CompletionToken> | |
| auto | async_all_orders (const AllOrdersParams ¶ms, CompletionToken &&token) const |
| Asynchronous all_orders(). | |
| common::RestApiResponse< GetAccountResponse > | get_account (const GetAccountParams ¶ms={}) const |
| Account information (USER_DATA). | |
| template<class CompletionToken> | |
| auto | async_get_account (const GetAccountParams ¶ms, CompletionToken &&token) const |
| Asynchronous get_account(). | |
| common::RestApiResponse< std::vector< GetOpenOrdersResponseInner > > | get_open_orders (const GetOpenOrdersParams ¶ms={}) const |
| Current open orders (USER_DATA). | |
| template<class CompletionToken> | |
| auto | async_get_open_orders (const GetOpenOrdersParams ¶ms, CompletionToken &&token) const |
| Asynchronous get_open_orders(). | |
| common::RestApiResponse< GetOrderResponse > | get_order (const GetOrderParams ¶ms) const |
| Query order (USER_DATA). | |
| template<class CompletionToken> | |
| auto | async_get_order (const GetOrderParams ¶ms, CompletionToken &&token) const |
| Asynchronous get_order(). | |
| common::RestApiResponse< GetOrderListResponse > | get_order_list (const GetOrderListParams ¶ms={}) const |
| Query Order list (USER_DATA). | |
| template<class CompletionToken> | |
| auto | async_get_order_list (const GetOrderListParams ¶ms, CompletionToken &&token) const |
| Asynchronous get_order_list(). | |
| common::RestApiResponse< std::vector< MyAllocationsResponseInner > > | my_allocations (const MyAllocationsParams ¶ms) const |
| Query Allocations (USER_DATA). | |
| template<class CompletionToken> | |
| auto | async_my_allocations (const MyAllocationsParams ¶ms, CompletionToken &&token) const |
| Asynchronous my_allocations(). | |
| common::RestApiResponse< MyFiltersResponse > | my_filters (const MyFiltersParams ¶ms) const |
| Query relevant filters (USER_DATA). | |
| template<class CompletionToken> | |
| auto | async_my_filters (const MyFiltersParams ¶ms, CompletionToken &&token) const |
| Asynchronous my_filters(). | |
| common::RestApiResponse< std::vector< MyPreventedMatchesResponseInner > > | my_prevented_matches (const MyPreventedMatchesParams ¶ms) const |
| Query Prevented Matches (USER_DATA). | |
| template<class CompletionToken> | |
| auto | async_my_prevented_matches (const MyPreventedMatchesParams ¶ms, CompletionToken &&token) const |
| Asynchronous my_prevented_matches(). | |
| common::RestApiResponse< std::vector< MyTradesResponseInner > > | my_trades (const MyTradesParams ¶ms) const |
| Account trade list (USER_DATA). | |
| template<class CompletionToken> | |
| auto | async_my_trades (const MyTradesParams ¶ms, CompletionToken &&token) const |
| Asynchronous my_trades(). | |
| common::RestApiResponse< std::vector< OpenOrderListResponseInner > > | open_order_list (const OpenOrderListParams ¶ms={}) const |
| Query Open Order lists (USER_DATA). | |
| template<class CompletionToken> | |
| auto | async_open_order_list (const OpenOrderListParams ¶ms, CompletionToken &&token) const |
| Asynchronous open_order_list(). | |
| common::RestApiResponse< std::vector< OrderAmendmentsResponseInner > > | order_amendments (const OrderAmendmentsParams ¶ms) const |
| Query Order Amendments (USER_DATA). | |
| template<class CompletionToken> | |
| auto | async_order_amendments (const OrderAmendmentsParams ¶ms, CompletionToken &&token) const |
| Asynchronous order_amendments(). | |
| common::RestApiResponse< std::vector< RateLimitOrderResponseInner > > | rate_limit_order (const RateLimitOrderParams ¶ms={}) const |
| Query Unfilled Order Count (USER_DATA). | |
| template<class CompletionToken> | |
| auto | async_rate_limit_order (const RateLimitOrderParams ¶ms, CompletionToken &&token) const |
| Asynchronous rate_limit_order(). | |
|
explicit |
|
nodiscard |
Query Commission Rates (USER_DATA).
GET /api/v3/account/commission.
Get current account commission rates.
Weight(IP): 20
Security Type: USER_DATA
Notes: Data Source: Database
|
inline |
Asynchronous account_commission().
Completes with void(std::exception_ptr, common::RestApiResponse<AccountCommissionResponse>).
|
nodiscard |
Query all Order lists (USER_DATA).
GET /api/v3/allOrderList.
Retrieves all order lists based on provided optional parameters.
Note that the time between startTime and endTime can't be longer than 24 hours.
Weight(IP): 20
Security Type: USER_DATA
Notes: Data Source: Database
|
inline |
Asynchronous all_order_list().
Completes with void(std::exception_ptr, common::RestApiResponse<std::vector<AllOrderListResponseInner>>).
|
nodiscard |
All orders (USER_DATA).
GET /api/v3/allOrders.
Get all account orders; active, canceled, or filled.
Weight(IP): 20
Security Type: USER_DATA
Notes: Data Source: Database
Response Notes: Note: The payload above does not show all fields that can appear. Please refer to Conditional fields in Order Responses.
|
inline |
Asynchronous all_orders().
Completes with void(std::exception_ptr, common::RestApiResponse<std::vector<AllOrdersResponseInner>>).
|
nodiscard |
Account information (USER_DATA).
GET /api/v3/account.
Get current account information.
Weight(IP): 20
Security Type: USER_DATA
Notes: Data Source: Memory => Database
|
inline |
Asynchronous get_account().
Completes with void(std::exception_ptr, common::RestApiResponse<GetAccountResponse>).
|
nodiscard |
Current open orders (USER_DATA).
GET /api/v3/openOrders.
Get all open orders on a symbol. Careful when accessing this with no symbol.
Weight: 6 for a single symbol; 80 when the symbol parameter is omitted
Security Type: USER_DATA
Notes: Data Source: Memory => Database
Response Notes: Note: The payload above does not show all fields that can appear. Please refer to Conditional fields in Order Responses.
|
inline |
Asynchronous get_open_orders().
Completes with void(std::exception_ptr, common::RestApiResponse<std::vector<GetOpenOrdersResponseInner>>).
|
nodiscard |
Query order (USER_DATA).
GET /api/v3/order.
Check an order's status.
Weight(IP): 4
Security Type: USER_DATA
Notes: Data Source: Memory => Database
Response Notes: Note: The payload above does not show all fields that can appear. Please refer to Conditional fields in Order Responses.
|
inline |
Asynchronous get_order().
Completes with void(std::exception_ptr, common::RestApiResponse<GetOrderResponse>).
|
nodiscard |
Query Order list (USER_DATA).
GET /api/v3/orderList.
Retrieves a specific order list based on provided optional parameters.
Weight(IP): 4
Security Type: USER_DATA
Notes: Data Source: Database
|
inline |
Asynchronous get_order_list().
Completes with void(std::exception_ptr, common::RestApiResponse<GetOrderListResponse>).
|
nodiscard |
Query Allocations (USER_DATA).
GET /api/v3/myAllocations.
Retrieves allocations resulting from SOR order placement.
Weight(IP): 20
Security Type: USER_DATA
Notes: Data Source: Database" Supported parameter combinations: <table class="markdownTable"> <tr class="markdownTableHead"> <th class="markdownTableHeadNone"> Parameters
Response
symbol
allocations from oldest to newest
symbol + startTime
oldest allocations since startTime
symbol + endTime
newest allocations until endTime
symbol + startTime + endTime
allocations within the time range
symbol + fromAllocationId
allocations by allocation ID
symbol + orderId
allocations related to an order starting with
oldest | symbol + orderId + fromAllocationId | allocations related to an order by allocation ID |
Note: The time between startTime and endTime can't be longer than 24 hours.
|
inline |
Asynchronous my_allocations().
Completes with void(std::exception_ptr, common::RestApiResponse<std::vector<MyAllocationsResponseInner>>).
|
nodiscard |
Query relevant filters (USER_DATA).
GET /api/v3/myFilters.
Retrieves the list of filters relevant to an account on a given symbol. This is the only endpoint that shows if an account has MAX_ASSET filters applied to it.
Weight(IP): 40
Security Type: USER_DATA
Notes: Data Source: Memory
|
inline |
Asynchronous my_filters().
Completes with void(std::exception_ptr, common::RestApiResponse<MyFiltersResponse>).
|
nodiscard |
Query Prevented Matches (USER_DATA).
GET /api/v3/myPreventedMatches.
Displays the list of orders that were expired due to STP.
These are the combinations supported:
| Weight: Case | Weight |
|---|---|
| If symbol is invalid | 2 |
| Querying by preventedMatchId | 2 |
| Querying by orderId | 20 |
Security Type: USER_DATA
Notes: Data Source: Database
|
inline |
Asynchronous my_prevented_matches().
Completes with void(std::exception_ptr, common::RestApiResponse<std::vector<MyPreventedMatchesResponseInner>>).
|
nodiscard |
Account trade list (USER_DATA).
GET /api/v3/myTrades.
Get trades for a specific account and symbol.
| Weight: Condition | Weight |
|---|---|
| Without orderId | 20 |
| With orderId | 5 |
Security Type: USER_DATA
Notes: Data Source: Memory => Database
Notes::
|
inline |
Asynchronous my_trades().
Completes with void(std::exception_ptr, common::RestApiResponse<std::vector<MyTradesResponseInner>>).
|
nodiscard |
Query Open Order lists (USER_DATA).
GET /api/v3/openOrderList.
Query Open Order lists
Weight(IP): 6
Security Type: USER_DATA
Notes: Data Source: Memory -> Database
|
inline |
Asynchronous open_order_list().
Completes with void(std::exception_ptr, common::RestApiResponse<std::vector<OpenOrderListResponseInner>>).
|
nodiscard |
Query Order Amendments (USER_DATA).
GET /api/v3/order/amendments.
Queries all amendments of a single order.
Weight(IP): 4
Security Type: USER_DATA
Notes: Data Source: Database
|
inline |
Asynchronous order_amendments().
Completes with void(std::exception_ptr, common::RestApiResponse<std::vector<OrderAmendmentsResponseInner>>).
|
nodiscard |
Query Unfilled Order Count (USER_DATA).
GET /api/v3/rateLimit/order.
Displays the user's unfilled order count for all intervals.
Weight(IP): 40
Security Type: USER_DATA
Notes: Data Source: Memory
|
inline |
Asynchronous rate_limit_order().
Completes with void(std::exception_ptr, common::RestApiResponse<std::vector<RateLimitOrderResponseInner>>).