binance-sdk-derivatives-trading-portfolio-margin 1.0.0__py3-none-any.whl
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Potentially problematic release.
This version of binance-sdk-derivatives-trading-portfolio-margin might be problematic. Click here for more details.
- CHANGELOG.md +5 -0
- README.md +293 -0
- binance_sdk_derivatives_trading_portfolio_margin/__init__.py +39 -0
- binance_sdk_derivatives_trading_portfolio_margin/derivatives_trading_portfolio_margin.py +68 -0
- binance_sdk_derivatives_trading_portfolio_margin/metadata.py +1 -0
- binance_sdk_derivatives_trading_portfolio_margin/rest_api/__init__.py +13 -0
- binance_sdk_derivatives_trading_portfolio_margin/rest_api/api/__init__.py +14 -0
- binance_sdk_derivatives_trading_portfolio_margin/rest_api/api/account_api.py +2096 -0
- binance_sdk_derivatives_trading_portfolio_margin/rest_api/api/market_data_api.py +62 -0
- binance_sdk_derivatives_trading_portfolio_margin/rest_api/api/trade_api.py +3557 -0
- binance_sdk_derivatives_trading_portfolio_margin/rest_api/api/user_data_streams_api.py +132 -0
- binance_sdk_derivatives_trading_portfolio_margin/rest_api/models/__init__.py +550 -0
- binance_sdk_derivatives_trading_portfolio_margin/rest_api/models/account_balance_response.py +145 -0
- binance_sdk_derivatives_trading_portfolio_margin/rest_api/models/account_balance_response1.py +81 -0
- binance_sdk_derivatives_trading_portfolio_margin/rest_api/models/account_balance_response1_inner.py +164 -0
- binance_sdk_derivatives_trading_portfolio_margin/rest_api/models/account_balance_response2.py +159 -0
- binance_sdk_derivatives_trading_portfolio_margin/rest_api/models/account_information_response.py +145 -0
- binance_sdk_derivatives_trading_portfolio_margin/rest_api/models/bnb_transfer_response.py +102 -0
- binance_sdk_derivatives_trading_portfolio_margin/rest_api/models/cancel_all_cm_open_conditional_orders_response.py +103 -0
- binance_sdk_derivatives_trading_portfolio_margin/rest_api/models/cancel_all_cm_open_orders_response.py +103 -0
- binance_sdk_derivatives_trading_portfolio_margin/rest_api/models/cancel_all_um_open_conditional_orders_response.py +103 -0
- binance_sdk_derivatives_trading_portfolio_margin/rest_api/models/cancel_all_um_open_orders_response.py +103 -0
- binance_sdk_derivatives_trading_portfolio_margin/rest_api/models/cancel_cm_conditional_order_response.py +161 -0
- binance_sdk_derivatives_trading_portfolio_margin/rest_api/models/cancel_cm_order_response.py +156 -0
- binance_sdk_derivatives_trading_portfolio_margin/rest_api/models/cancel_margin_account_all_open_orders_on_a_symbol_response.py +83 -0
- binance_sdk_derivatives_trading_portfolio_margin/rest_api/models/cancel_margin_account_all_open_orders_on_a_symbol_response_inner.py +215 -0
- binance_sdk_derivatives_trading_portfolio_margin/rest_api/models/cancel_margin_account_all_open_orders_on_a_symbol_response_inner_order_reports_inner.py +156 -0
- binance_sdk_derivatives_trading_portfolio_margin/rest_api/models/cancel_margin_account_all_open_orders_on_a_symbol_response_inner_orders_inner.py +110 -0
- binance_sdk_derivatives_trading_portfolio_margin/rest_api/models/cancel_margin_account_oco_orders_response.py +174 -0
- binance_sdk_derivatives_trading_portfolio_margin/rest_api/models/cancel_margin_account_oco_orders_response_order_reports_inner.py +151 -0
- binance_sdk_derivatives_trading_portfolio_margin/rest_api/models/cancel_margin_account_oco_orders_response_orders_inner.py +110 -0
- binance_sdk_derivatives_trading_portfolio_margin/rest_api/models/cancel_margin_account_order_response.py +145 -0
- binance_sdk_derivatives_trading_portfolio_margin/rest_api/models/cancel_um_conditional_order_response.py +172 -0
- binance_sdk_derivatives_trading_portfolio_margin/rest_api/models/cancel_um_order_response.py +164 -0
- binance_sdk_derivatives_trading_portfolio_margin/rest_api/models/change_auto_repay_futures_status_response.py +102 -0
- binance_sdk_derivatives_trading_portfolio_margin/rest_api/models/change_cm_initial_leverage_response.py +110 -0
- binance_sdk_derivatives_trading_portfolio_margin/rest_api/models/change_cm_position_mode_response.py +103 -0
- binance_sdk_derivatives_trading_portfolio_margin/rest_api/models/change_um_initial_leverage_response.py +112 -0
- binance_sdk_derivatives_trading_portfolio_margin/rest_api/models/change_um_position_mode_response.py +103 -0
- binance_sdk_derivatives_trading_portfolio_margin/rest_api/models/cm_account_trade_list_response.py +81 -0
- binance_sdk_derivatives_trading_portfolio_margin/rest_api/models/cm_account_trade_list_response_inner.py +153 -0
- binance_sdk_derivatives_trading_portfolio_margin/rest_api/models/cm_notional_and_leverage_brackets_response.py +81 -0
- binance_sdk_derivatives_trading_portfolio_margin/rest_api/models/cm_notional_and_leverage_brackets_response_inner.py +129 -0
- binance_sdk_derivatives_trading_portfolio_margin/rest_api/models/cm_notional_and_leverage_brackets_response_inner_brackets_inner.py +125 -0
- binance_sdk_derivatives_trading_portfolio_margin/rest_api/models/cm_position_adl_quantile_estimation_response.py +83 -0
- binance_sdk_derivatives_trading_portfolio_margin/rest_api/models/cm_position_adl_quantile_estimation_response_inner.py +122 -0
- binance_sdk_derivatives_trading_portfolio_margin/rest_api/models/cm_position_adl_quantile_estimation_response_inner_adl_quantile.py +112 -0
- binance_sdk_derivatives_trading_portfolio_margin/rest_api/models/enums.py +278 -0
- binance_sdk_derivatives_trading_portfolio_margin/rest_api/models/fund_auto_collection_response.py +102 -0
- binance_sdk_derivatives_trading_portfolio_margin/rest_api/models/fund_collection_by_asset_response.py +102 -0
- binance_sdk_derivatives_trading_portfolio_margin/rest_api/models/get_auto_repay_futures_status_response.py +102 -0
- binance_sdk_derivatives_trading_portfolio_margin/rest_api/models/get_cm_account_detail_response.py +142 -0
- binance_sdk_derivatives_trading_portfolio_margin/rest_api/models/get_cm_account_detail_response_assets_inner.py +135 -0
- binance_sdk_derivatives_trading_portfolio_margin/rest_api/models/get_cm_account_detail_response_positions_inner.py +147 -0
- binance_sdk_derivatives_trading_portfolio_margin/rest_api/models/get_cm_current_position_mode_response.py +104 -0
- binance_sdk_derivatives_trading_portfolio_margin/rest_api/models/get_cm_income_history_response.py +81 -0
- binance_sdk_derivatives_trading_portfolio_margin/rest_api/models/get_cm_income_history_response_inner.py +129 -0
- binance_sdk_derivatives_trading_portfolio_margin/rest_api/models/get_download_id_for_um_futures_order_history_response.py +110 -0
- binance_sdk_derivatives_trading_portfolio_margin/rest_api/models/get_download_id_for_um_futures_trade_history_response.py +110 -0
- binance_sdk_derivatives_trading_portfolio_margin/rest_api/models/get_download_id_for_um_futures_transaction_history_response.py +110 -0
- binance_sdk_derivatives_trading_portfolio_margin/rest_api/models/get_margin_borrow_loan_interest_history_response.py +127 -0
- binance_sdk_derivatives_trading_portfolio_margin/rest_api/models/get_margin_borrow_loan_interest_history_response_rows_inner.py +131 -0
- binance_sdk_derivatives_trading_portfolio_margin/rest_api/models/get_um_account_detail_response.py +142 -0
- binance_sdk_derivatives_trading_portfolio_margin/rest_api/models/get_um_account_detail_response_positions_inner.py +153 -0
- binance_sdk_derivatives_trading_portfolio_margin/rest_api/models/get_um_account_detail_v2_response.py +142 -0
- binance_sdk_derivatives_trading_portfolio_margin/rest_api/models/get_um_account_detail_v2_response_assets_inner.py +135 -0
- binance_sdk_derivatives_trading_portfolio_margin/rest_api/models/get_um_account_detail_v2_response_positions_inner.py +131 -0
- binance_sdk_derivatives_trading_portfolio_margin/rest_api/models/get_um_current_position_mode_response.py +104 -0
- binance_sdk_derivatives_trading_portfolio_margin/rest_api/models/get_um_futures_bnb_burn_status_response.py +102 -0
- binance_sdk_derivatives_trading_portfolio_margin/rest_api/models/get_um_futures_order_download_link_by_id_response.py +128 -0
- binance_sdk_derivatives_trading_portfolio_margin/rest_api/models/get_um_futures_trade_download_link_by_id_response.py +128 -0
- binance_sdk_derivatives_trading_portfolio_margin/rest_api/models/get_um_futures_transaction_download_link_by_id_response.py +128 -0
- binance_sdk_derivatives_trading_portfolio_margin/rest_api/models/get_um_income_history_response.py +81 -0
- binance_sdk_derivatives_trading_portfolio_margin/rest_api/models/get_um_income_history_response_inner.py +129 -0
- binance_sdk_derivatives_trading_portfolio_margin/rest_api/models/get_user_commission_rate_for_cm_response.py +118 -0
- binance_sdk_derivatives_trading_portfolio_margin/rest_api/models/get_user_commission_rate_for_um_response.py +118 -0
- binance_sdk_derivatives_trading_portfolio_margin/rest_api/models/margin_account_borrow_response.py +102 -0
- binance_sdk_derivatives_trading_portfolio_margin/rest_api/models/margin_account_new_oco_response.py +182 -0
- binance_sdk_derivatives_trading_portfolio_margin/rest_api/models/margin_account_new_oco_response_order_reports_inner.py +149 -0
- binance_sdk_derivatives_trading_portfolio_margin/rest_api/models/margin_account_new_oco_response_orders_inner.py +110 -0
- binance_sdk_derivatives_trading_portfolio_margin/rest_api/models/margin_account_repay_debt_response.py +122 -0
- binance_sdk_derivatives_trading_portfolio_margin/rest_api/models/margin_account_repay_response.py +102 -0
- binance_sdk_derivatives_trading_portfolio_margin/rest_api/models/margin_account_trade_list_response.py +81 -0
- binance_sdk_derivatives_trading_portfolio_margin/rest_api/models/margin_account_trade_list_response_inner.py +138 -0
- binance_sdk_derivatives_trading_portfolio_margin/rest_api/models/margin_max_borrow_response.py +105 -0
- binance_sdk_derivatives_trading_portfolio_margin/rest_api/models/modify_cm_order_response.py +159 -0
- binance_sdk_derivatives_trading_portfolio_margin/rest_api/models/modify_um_order_response.py +167 -0
- binance_sdk_derivatives_trading_portfolio_margin/rest_api/models/new_cm_conditional_order_response.py +164 -0
- binance_sdk_derivatives_trading_portfolio_margin/rest_api/models/new_cm_order_response.py +156 -0
- binance_sdk_derivatives_trading_portfolio_margin/rest_api/models/new_margin_order_response.py +173 -0
- binance_sdk_derivatives_trading_portfolio_margin/rest_api/models/new_margin_order_response_fills_inner.py +117 -0
- binance_sdk_derivatives_trading_portfolio_margin/rest_api/models/new_um_conditional_order_response.py +172 -0
- binance_sdk_derivatives_trading_portfolio_margin/rest_api/models/new_um_order_response.py +164 -0
- binance_sdk_derivatives_trading_portfolio_margin/rest_api/models/portfolio_margin_um_trading_quantitative_rules_indicators_response.py +122 -0
- binance_sdk_derivatives_trading_portfolio_margin/rest_api/models/portfolio_margin_um_trading_quantitative_rules_indicators_response_indicators.py +154 -0
- binance_sdk_derivatives_trading_portfolio_margin/rest_api/models/portfolio_margin_um_trading_quantitative_rules_indicators_response_indicators_account_inner.py +124 -0
- binance_sdk_derivatives_trading_portfolio_margin/rest_api/models/portfolio_margin_um_trading_quantitative_rules_indicators_response_indicators_btcusdt_inner.py +134 -0
- binance_sdk_derivatives_trading_portfolio_margin/rest_api/models/query_all_cm_conditional_orders_response.py +81 -0
- binance_sdk_derivatives_trading_portfolio_margin/rest_api/models/query_all_cm_conditional_orders_response_inner.py +167 -0
- binance_sdk_derivatives_trading_portfolio_margin/rest_api/models/query_all_cm_orders_response.py +81 -0
- binance_sdk_derivatives_trading_portfolio_margin/rest_api/models/query_all_cm_orders_response_inner.py +159 -0
- binance_sdk_derivatives_trading_portfolio_margin/rest_api/models/query_all_current_cm_open_conditional_orders_response.py +83 -0
- binance_sdk_derivatives_trading_portfolio_margin/rest_api/models/query_all_current_cm_open_conditional_orders_response_inner.py +155 -0
- binance_sdk_derivatives_trading_portfolio_margin/rest_api/models/query_all_current_cm_open_orders_response.py +81 -0
- binance_sdk_derivatives_trading_portfolio_margin/rest_api/models/query_all_current_um_open_conditional_orders_response.py +83 -0
- binance_sdk_derivatives_trading_portfolio_margin/rest_api/models/query_all_current_um_open_conditional_orders_response_inner.py +166 -0
- binance_sdk_derivatives_trading_portfolio_margin/rest_api/models/query_all_current_um_open_orders_response.py +81 -0
- binance_sdk_derivatives_trading_portfolio_margin/rest_api/models/query_all_current_um_open_orders_response_inner.py +167 -0
- binance_sdk_derivatives_trading_portfolio_margin/rest_api/models/query_all_margin_account_orders_response.py +81 -0
- binance_sdk_derivatives_trading_portfolio_margin/rest_api/models/query_all_margin_account_orders_response_inner.py +173 -0
- binance_sdk_derivatives_trading_portfolio_margin/rest_api/models/query_all_um_conditional_orders_response.py +81 -0
- binance_sdk_derivatives_trading_portfolio_margin/rest_api/models/query_all_um_conditional_orders_response_inner.py +178 -0
- binance_sdk_derivatives_trading_portfolio_margin/rest_api/models/query_all_um_orders_response.py +81 -0
- binance_sdk_derivatives_trading_portfolio_margin/rest_api/models/query_cm_conditional_order_history_response.py +176 -0
- binance_sdk_derivatives_trading_portfolio_margin/rest_api/models/query_cm_modify_order_history_response.py +81 -0
- binance_sdk_derivatives_trading_portfolio_margin/rest_api/models/query_cm_modify_order_history_response_inner.py +138 -0
- binance_sdk_derivatives_trading_portfolio_margin/rest_api/models/query_cm_modify_order_history_response_inner_amendment.py +136 -0
- binance_sdk_derivatives_trading_portfolio_margin/rest_api/models/query_cm_modify_order_history_response_inner_amendment_orig_qty.py +105 -0
- binance_sdk_derivatives_trading_portfolio_margin/rest_api/models/query_cm_modify_order_history_response_inner_amendment_price.py +105 -0
- binance_sdk_derivatives_trading_portfolio_margin/rest_api/models/query_cm_order_response.py +159 -0
- binance_sdk_derivatives_trading_portfolio_margin/rest_api/models/query_cm_position_information_response.py +81 -0
- binance_sdk_derivatives_trading_portfolio_margin/rest_api/models/query_cm_position_information_response_inner.py +142 -0
- binance_sdk_derivatives_trading_portfolio_margin/rest_api/models/query_current_cm_open_conditional_order_response.py +155 -0
- binance_sdk_derivatives_trading_portfolio_margin/rest_api/models/query_current_cm_open_order_response.py +159 -0
- binance_sdk_derivatives_trading_portfolio_margin/rest_api/models/query_current_margin_open_order_response.py +81 -0
- binance_sdk_derivatives_trading_portfolio_margin/rest_api/models/query_current_margin_open_order_response_inner.py +173 -0
- binance_sdk_derivatives_trading_portfolio_margin/rest_api/models/query_current_um_open_conditional_order_response.py +166 -0
- binance_sdk_derivatives_trading_portfolio_margin/rest_api/models/query_current_um_open_order_response.py +167 -0
- binance_sdk_derivatives_trading_portfolio_margin/rest_api/models/query_margin_account_order_response.py +173 -0
- binance_sdk_derivatives_trading_portfolio_margin/rest_api/models/query_margin_accounts_all_oco_response.py +81 -0
- binance_sdk_derivatives_trading_portfolio_margin/rest_api/models/query_margin_accounts_all_oco_response_inner.py +152 -0
- binance_sdk_derivatives_trading_portfolio_margin/rest_api/models/query_margin_accounts_all_oco_response_inner_orders_inner.py +110 -0
- binance_sdk_derivatives_trading_portfolio_margin/rest_api/models/query_margin_accounts_oco_response.py +150 -0
- binance_sdk_derivatives_trading_portfolio_margin/rest_api/models/query_margin_accounts_oco_response_orders_inner.py +110 -0
- binance_sdk_derivatives_trading_portfolio_margin/rest_api/models/query_margin_accounts_open_oco_response.py +81 -0
- binance_sdk_derivatives_trading_portfolio_margin/rest_api/models/query_margin_accounts_open_oco_response_inner.py +152 -0
- binance_sdk_derivatives_trading_portfolio_margin/rest_api/models/query_margin_accounts_open_oco_response_inner_orders_inner.py +110 -0
- binance_sdk_derivatives_trading_portfolio_margin/rest_api/models/query_margin_loan_record_response.py +125 -0
- binance_sdk_derivatives_trading_portfolio_margin/rest_api/models/query_margin_loan_record_response_rows_inner.py +120 -0
- binance_sdk_derivatives_trading_portfolio_margin/rest_api/models/query_margin_max_withdraw_response.py +102 -0
- binance_sdk_derivatives_trading_portfolio_margin/rest_api/models/query_margin_repay_record_response.py +125 -0
- binance_sdk_derivatives_trading_portfolio_margin/rest_api/models/query_margin_repay_record_response_rows_inner.py +126 -0
- binance_sdk_derivatives_trading_portfolio_margin/rest_api/models/query_portfolio_margin_negative_balance_interest_history_response.py +83 -0
- binance_sdk_derivatives_trading_portfolio_margin/rest_api/models/query_portfolio_margin_negative_balance_interest_history_response_inner.py +122 -0
- binance_sdk_derivatives_trading_portfolio_margin/rest_api/models/query_um_conditional_order_history_response.py +181 -0
- binance_sdk_derivatives_trading_portfolio_margin/rest_api/models/query_um_modify_order_history_response.py +81 -0
- binance_sdk_derivatives_trading_portfolio_margin/rest_api/models/query_um_modify_order_history_response_inner.py +141 -0
- binance_sdk_derivatives_trading_portfolio_margin/rest_api/models/query_um_order_response.py +167 -0
- binance_sdk_derivatives_trading_portfolio_margin/rest_api/models/query_um_position_information_response.py +81 -0
- binance_sdk_derivatives_trading_portfolio_margin/rest_api/models/query_um_position_information_response_inner.py +144 -0
- binance_sdk_derivatives_trading_portfolio_margin/rest_api/models/query_user_negative_balance_auto_exchange_record_response.py +129 -0
- binance_sdk_derivatives_trading_portfolio_margin/rest_api/models/query_user_negative_balance_auto_exchange_record_response_rows_inner.py +131 -0
- binance_sdk_derivatives_trading_portfolio_margin/rest_api/models/query_user_negative_balance_auto_exchange_record_response_rows_inner_details_inner.py +120 -0
- binance_sdk_derivatives_trading_portfolio_margin/rest_api/models/query_user_rate_limit_response.py +81 -0
- binance_sdk_derivatives_trading_portfolio_margin/rest_api/models/query_user_rate_limit_response_inner.py +117 -0
- binance_sdk_derivatives_trading_portfolio_margin/rest_api/models/query_users_cm_force_orders_response.py +81 -0
- binance_sdk_derivatives_trading_portfolio_margin/rest_api/models/query_users_cm_force_orders_response_inner.py +159 -0
- binance_sdk_derivatives_trading_portfolio_margin/rest_api/models/query_users_margin_force_orders_response.py +125 -0
- binance_sdk_derivatives_trading_portfolio_margin/rest_api/models/query_users_margin_force_orders_response_rows_inner.py +132 -0
- binance_sdk_derivatives_trading_portfolio_margin/rest_api/models/query_users_um_force_orders_response.py +81 -0
- binance_sdk_derivatives_trading_portfolio_margin/rest_api/models/query_users_um_force_orders_response_inner.py +156 -0
- binance_sdk_derivatives_trading_portfolio_margin/rest_api/models/repay_futures_negative_balance_response.py +102 -0
- binance_sdk_derivatives_trading_portfolio_margin/rest_api/models/start_user_data_stream_response.py +102 -0
- binance_sdk_derivatives_trading_portfolio_margin/rest_api/models/toggle_bnb_burn_on_um_futures_trade_response.py +103 -0
- binance_sdk_derivatives_trading_portfolio_margin/rest_api/models/um_account_trade_list_response.py +81 -0
- binance_sdk_derivatives_trading_portfolio_margin/rest_api/models/um_account_trade_list_response_inner.py +147 -0
- binance_sdk_derivatives_trading_portfolio_margin/rest_api/models/um_futures_account_configuration_response.py +133 -0
- binance_sdk_derivatives_trading_portfolio_margin/rest_api/models/um_futures_symbol_configuration_response.py +81 -0
- binance_sdk_derivatives_trading_portfolio_margin/rest_api/models/um_futures_symbol_configuration_response_inner.py +124 -0
- binance_sdk_derivatives_trading_portfolio_margin/rest_api/models/um_notional_and_leverage_brackets_response.py +81 -0
- binance_sdk_derivatives_trading_portfolio_margin/rest_api/models/um_notional_and_leverage_brackets_response_inner.py +131 -0
- binance_sdk_derivatives_trading_portfolio_margin/rest_api/models/um_notional_and_leverage_brackets_response_inner_brackets_inner.py +125 -0
- binance_sdk_derivatives_trading_portfolio_margin/rest_api/models/um_position_adl_quantile_estimation_response.py +83 -0
- binance_sdk_derivatives_trading_portfolio_margin/rest_api/models/um_position_adl_quantile_estimation_response_inner.py +122 -0
- binance_sdk_derivatives_trading_portfolio_margin/rest_api/rest_api.py +3837 -0
- binance_sdk_derivatives_trading_portfolio_margin/websocket_streams/__init__.py +13 -0
- binance_sdk_derivatives_trading_portfolio_margin/websocket_streams/models/__init__.py +38 -0
- binance_sdk_derivatives_trading_portfolio_margin/websocket_streams/models/account_config_update.py +118 -0
- binance_sdk_derivatives_trading_portfolio_margin/websocket_streams/models/account_config_update_ac.py +99 -0
- binance_sdk_derivatives_trading_portfolio_margin/websocket_streams/models/account_update.py +120 -0
- binance_sdk_derivatives_trading_portfolio_margin/websocket_streams/models/account_update_a.py +134 -0
- binance_sdk_derivatives_trading_portfolio_margin/websocket_streams/models/account_update_ab_inner.py +108 -0
- binance_sdk_derivatives_trading_portfolio_margin/websocket_streams/models/account_update_ap_inner.py +114 -0
- binance_sdk_derivatives_trading_portfolio_margin/websocket_streams/models/balanceupdate.py +110 -0
- binance_sdk_derivatives_trading_portfolio_margin/websocket_streams/models/conditional_order_trade_update.py +118 -0
- binance_sdk_derivatives_trading_portfolio_margin/websocket_streams/models/conditional_order_trade_update_so.py +164 -0
- binance_sdk_derivatives_trading_portfolio_margin/websocket_streams/models/enums.py +9 -0
- binance_sdk_derivatives_trading_portfolio_margin/websocket_streams/models/executionreport.py +227 -0
- binance_sdk_derivatives_trading_portfolio_margin/websocket_streams/models/liabilitychange.py +114 -0
- binance_sdk_derivatives_trading_portfolio_margin/websocket_streams/models/listenkeyexpired.py +98 -0
- binance_sdk_derivatives_trading_portfolio_margin/websocket_streams/models/openorderloss.py +118 -0
- binance_sdk_derivatives_trading_portfolio_margin/websocket_streams/models/openorderloss_o_inner.py +99 -0
- binance_sdk_derivatives_trading_portfolio_margin/websocket_streams/models/order_trade_update.py +120 -0
- binance_sdk_derivatives_trading_portfolio_margin/websocket_streams/models/order_trade_update_o.py +188 -0
- binance_sdk_derivatives_trading_portfolio_margin/websocket_streams/models/outboundaccountposition.py +125 -0
- binance_sdk_derivatives_trading_portfolio_margin/websocket_streams/models/outboundaccountposition_b_inner.py +102 -0
- binance_sdk_derivatives_trading_portfolio_margin/websocket_streams/models/risklevelchange.py +112 -0
- binance_sdk_derivatives_trading_portfolio_margin/websocket_streams/models/user_data_stream_events_response.py +386 -0
- binance_sdk_derivatives_trading_portfolio_margin/websocket_streams/streams/__init__.py +9 -0
- binance_sdk_derivatives_trading_portfolio_margin/websocket_streams/websocket_streams.py +105 -0
- binance_sdk_derivatives_trading_portfolio_margin-1.0.0.dist-info/LICENCE +21 -0
- binance_sdk_derivatives_trading_portfolio_margin-1.0.0.dist-info/METADATA +321 -0
- binance_sdk_derivatives_trading_portfolio_margin-1.0.0.dist-info/RECORD +204 -0
- binance_sdk_derivatives_trading_portfolio_margin-1.0.0.dist-info/WHEEL +4 -0
|
@@ -0,0 +1,110 @@
|
|
|
1
|
+
# coding: utf-8
|
|
2
|
+
|
|
3
|
+
"""
|
|
4
|
+
Binance Derivatives Trading Portfolio Margin REST API
|
|
5
|
+
|
|
6
|
+
OpenAPI Specification for the Binance Derivatives Trading Portfolio Margin REST API
|
|
7
|
+
The version of the OpenAPI document: 1.0.0
|
|
8
|
+
Generated by OpenAPI Generator (https://openapi-generator.tech)
|
|
9
|
+
|
|
10
|
+
Do not edit the class manually.
|
|
11
|
+
"""
|
|
12
|
+
|
|
13
|
+
|
|
14
|
+
from __future__ import annotations
|
|
15
|
+
import pprint
|
|
16
|
+
import re # noqa: F401
|
|
17
|
+
import json
|
|
18
|
+
|
|
19
|
+
from pydantic import BaseModel, ConfigDict, Field, StrictInt, StrictStr
|
|
20
|
+
from typing import Any, ClassVar, Dict, List, Optional
|
|
21
|
+
from typing import Set
|
|
22
|
+
from typing_extensions import Self
|
|
23
|
+
|
|
24
|
+
|
|
25
|
+
class CancelMarginAccountAllOpenOrdersOnASymbolResponseInnerOrdersInner(BaseModel):
|
|
26
|
+
"""
|
|
27
|
+
CancelMarginAccountAllOpenOrdersOnASymbolResponseInnerOrdersInner
|
|
28
|
+
""" # noqa: E501
|
|
29
|
+
|
|
30
|
+
symbol: Optional[StrictStr] = None
|
|
31
|
+
order_id: Optional[StrictInt] = Field(default=None, alias="orderId")
|
|
32
|
+
client_order_id: Optional[StrictStr] = Field(default=None, alias="clientOrderId")
|
|
33
|
+
additional_properties: Dict[str, Any] = {}
|
|
34
|
+
__properties: ClassVar[List[str]] = ["symbol", "orderId", "clientOrderId"]
|
|
35
|
+
|
|
36
|
+
model_config = ConfigDict(
|
|
37
|
+
populate_by_name=True,
|
|
38
|
+
validate_assignment=True,
|
|
39
|
+
protected_namespaces=(),
|
|
40
|
+
)
|
|
41
|
+
|
|
42
|
+
def to_str(self) -> str:
|
|
43
|
+
"""Returns the string representation of the model using alias"""
|
|
44
|
+
return pprint.pformat(self.model_dump(by_alias=True))
|
|
45
|
+
|
|
46
|
+
def to_json(self) -> str:
|
|
47
|
+
"""Returns the JSON representation of the model using alias"""
|
|
48
|
+
# TODO: pydantic v2: use .model_dump_json(by_alias=True, exclude_unset=True) instead
|
|
49
|
+
return json.dumps(self.to_dict())
|
|
50
|
+
|
|
51
|
+
@classmethod
|
|
52
|
+
def is_array(cls) -> bool:
|
|
53
|
+
return False
|
|
54
|
+
|
|
55
|
+
@classmethod
|
|
56
|
+
def from_json(cls, json_str: str) -> Optional[Self]:
|
|
57
|
+
"""Create an instance of CancelMarginAccountAllOpenOrdersOnASymbolResponseInnerOrdersInner from a JSON string"""
|
|
58
|
+
return cls.from_dict(json.loads(json_str))
|
|
59
|
+
|
|
60
|
+
def to_dict(self) -> Dict[str, Any]:
|
|
61
|
+
"""Return the dictionary representation of the model using alias.
|
|
62
|
+
|
|
63
|
+
This has the following differences from calling pydantic's
|
|
64
|
+
`self.model_dump(by_alias=True)`:
|
|
65
|
+
|
|
66
|
+
* `None` is only added to the output dict for nullable fields that
|
|
67
|
+
were set at model initialization. Other fields with value `None`
|
|
68
|
+
are ignored.
|
|
69
|
+
* Fields in `self.additional_properties` are added to the output dict.
|
|
70
|
+
"""
|
|
71
|
+
excluded_fields: Set[str] = set(
|
|
72
|
+
[
|
|
73
|
+
"additional_properties",
|
|
74
|
+
]
|
|
75
|
+
)
|
|
76
|
+
|
|
77
|
+
_dict = self.model_dump(
|
|
78
|
+
by_alias=True,
|
|
79
|
+
exclude=excluded_fields,
|
|
80
|
+
exclude_none=True,
|
|
81
|
+
)
|
|
82
|
+
# puts key-value pairs in additional_properties in the top level
|
|
83
|
+
if self.additional_properties is not None:
|
|
84
|
+
for _key, _value in self.additional_properties.items():
|
|
85
|
+
_dict[_key] = _value
|
|
86
|
+
|
|
87
|
+
return _dict
|
|
88
|
+
|
|
89
|
+
@classmethod
|
|
90
|
+
def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
|
|
91
|
+
"""Create an instance of CancelMarginAccountAllOpenOrdersOnASymbolResponseInnerOrdersInner from a dict"""
|
|
92
|
+
if obj is None:
|
|
93
|
+
return None
|
|
94
|
+
|
|
95
|
+
if not isinstance(obj, dict):
|
|
96
|
+
return cls.model_validate(obj)
|
|
97
|
+
|
|
98
|
+
_obj = cls.model_validate(
|
|
99
|
+
{
|
|
100
|
+
"symbol": obj.get("symbol"),
|
|
101
|
+
"orderId": obj.get("orderId"),
|
|
102
|
+
"clientOrderId": obj.get("clientOrderId"),
|
|
103
|
+
}
|
|
104
|
+
)
|
|
105
|
+
# store additional fields in additional_properties
|
|
106
|
+
for _key in obj.keys():
|
|
107
|
+
if _key not in cls.__properties:
|
|
108
|
+
_obj.additional_properties[_key] = obj.get(_key)
|
|
109
|
+
|
|
110
|
+
return _obj
|
|
@@ -0,0 +1,174 @@
|
|
|
1
|
+
# coding: utf-8
|
|
2
|
+
|
|
3
|
+
"""
|
|
4
|
+
Binance Derivatives Trading Portfolio Margin REST API
|
|
5
|
+
|
|
6
|
+
OpenAPI Specification for the Binance Derivatives Trading Portfolio Margin REST API
|
|
7
|
+
The version of the OpenAPI document: 1.0.0
|
|
8
|
+
Generated by OpenAPI Generator (https://openapi-generator.tech)
|
|
9
|
+
|
|
10
|
+
Do not edit the class manually.
|
|
11
|
+
"""
|
|
12
|
+
|
|
13
|
+
|
|
14
|
+
from __future__ import annotations
|
|
15
|
+
import pprint
|
|
16
|
+
import re # noqa: F401
|
|
17
|
+
import json
|
|
18
|
+
|
|
19
|
+
from pydantic import BaseModel, ConfigDict, Field, StrictInt, StrictStr
|
|
20
|
+
from typing import Any, ClassVar, Dict, List, Optional
|
|
21
|
+
from binance_sdk_derivatives_trading_portfolio_margin.rest_api.models.cancel_margin_account_oco_orders_response_order_reports_inner import (
|
|
22
|
+
CancelMarginAccountOcoOrdersResponseOrderReportsInner,
|
|
23
|
+
)
|
|
24
|
+
from binance_sdk_derivatives_trading_portfolio_margin.rest_api.models.cancel_margin_account_oco_orders_response_orders_inner import (
|
|
25
|
+
CancelMarginAccountOcoOrdersResponseOrdersInner,
|
|
26
|
+
)
|
|
27
|
+
from typing import Set
|
|
28
|
+
from typing_extensions import Self
|
|
29
|
+
|
|
30
|
+
|
|
31
|
+
class CancelMarginAccountOcoOrdersResponse(BaseModel):
|
|
32
|
+
"""
|
|
33
|
+
CancelMarginAccountOcoOrdersResponse
|
|
34
|
+
""" # noqa: E501
|
|
35
|
+
|
|
36
|
+
order_list_id: Optional[StrictInt] = Field(default=None, alias="orderListId")
|
|
37
|
+
contingency_type: Optional[StrictStr] = Field(default=None, alias="contingencyType")
|
|
38
|
+
list_status_type: Optional[StrictStr] = Field(default=None, alias="listStatusType")
|
|
39
|
+
list_order_status: Optional[StrictStr] = Field(
|
|
40
|
+
default=None, alias="listOrderStatus"
|
|
41
|
+
)
|
|
42
|
+
list_client_order_id: Optional[StrictStr] = Field(
|
|
43
|
+
default=None, alias="listClientOrderId"
|
|
44
|
+
)
|
|
45
|
+
transaction_time: Optional[StrictInt] = Field(default=None, alias="transactionTime")
|
|
46
|
+
symbol: Optional[StrictStr] = None
|
|
47
|
+
orders: Optional[List[CancelMarginAccountOcoOrdersResponseOrdersInner]] = None
|
|
48
|
+
order_reports: Optional[
|
|
49
|
+
List[CancelMarginAccountOcoOrdersResponseOrderReportsInner]
|
|
50
|
+
] = Field(default=None, alias="orderReports")
|
|
51
|
+
additional_properties: Dict[str, Any] = {}
|
|
52
|
+
__properties: ClassVar[List[str]] = [
|
|
53
|
+
"orderListId",
|
|
54
|
+
"contingencyType",
|
|
55
|
+
"listStatusType",
|
|
56
|
+
"listOrderStatus",
|
|
57
|
+
"listClientOrderId",
|
|
58
|
+
"transactionTime",
|
|
59
|
+
"symbol",
|
|
60
|
+
"orders",
|
|
61
|
+
"orderReports",
|
|
62
|
+
]
|
|
63
|
+
|
|
64
|
+
model_config = ConfigDict(
|
|
65
|
+
populate_by_name=True,
|
|
66
|
+
validate_assignment=True,
|
|
67
|
+
protected_namespaces=(),
|
|
68
|
+
)
|
|
69
|
+
|
|
70
|
+
def to_str(self) -> str:
|
|
71
|
+
"""Returns the string representation of the model using alias"""
|
|
72
|
+
return pprint.pformat(self.model_dump(by_alias=True))
|
|
73
|
+
|
|
74
|
+
def to_json(self) -> str:
|
|
75
|
+
"""Returns the JSON representation of the model using alias"""
|
|
76
|
+
# TODO: pydantic v2: use .model_dump_json(by_alias=True, exclude_unset=True) instead
|
|
77
|
+
return json.dumps(self.to_dict())
|
|
78
|
+
|
|
79
|
+
@classmethod
|
|
80
|
+
def is_array(cls) -> bool:
|
|
81
|
+
return False
|
|
82
|
+
|
|
83
|
+
@classmethod
|
|
84
|
+
def from_json(cls, json_str: str) -> Optional[Self]:
|
|
85
|
+
"""Create an instance of CancelMarginAccountOcoOrdersResponse from a JSON string"""
|
|
86
|
+
return cls.from_dict(json.loads(json_str))
|
|
87
|
+
|
|
88
|
+
def to_dict(self) -> Dict[str, Any]:
|
|
89
|
+
"""Return the dictionary representation of the model using alias.
|
|
90
|
+
|
|
91
|
+
This has the following differences from calling pydantic's
|
|
92
|
+
`self.model_dump(by_alias=True)`:
|
|
93
|
+
|
|
94
|
+
* `None` is only added to the output dict for nullable fields that
|
|
95
|
+
were set at model initialization. Other fields with value `None`
|
|
96
|
+
are ignored.
|
|
97
|
+
* Fields in `self.additional_properties` are added to the output dict.
|
|
98
|
+
"""
|
|
99
|
+
excluded_fields: Set[str] = set(
|
|
100
|
+
[
|
|
101
|
+
"additional_properties",
|
|
102
|
+
]
|
|
103
|
+
)
|
|
104
|
+
|
|
105
|
+
_dict = self.model_dump(
|
|
106
|
+
by_alias=True,
|
|
107
|
+
exclude=excluded_fields,
|
|
108
|
+
exclude_none=True,
|
|
109
|
+
)
|
|
110
|
+
# override the default output from pydantic by calling `to_dict()` of each item in orders (list)
|
|
111
|
+
_items = []
|
|
112
|
+
if self.orders:
|
|
113
|
+
for _item_orders in self.orders:
|
|
114
|
+
if _item_orders:
|
|
115
|
+
_items.append(_item_orders.to_dict())
|
|
116
|
+
_dict["orders"] = _items
|
|
117
|
+
# override the default output from pydantic by calling `to_dict()` of each item in order_reports (list)
|
|
118
|
+
_items = []
|
|
119
|
+
if self.order_reports:
|
|
120
|
+
for _item_order_reports in self.order_reports:
|
|
121
|
+
if _item_order_reports:
|
|
122
|
+
_items.append(_item_order_reports.to_dict())
|
|
123
|
+
_dict["orderReports"] = _items
|
|
124
|
+
# puts key-value pairs in additional_properties in the top level
|
|
125
|
+
if self.additional_properties is not None:
|
|
126
|
+
for _key, _value in self.additional_properties.items():
|
|
127
|
+
_dict[_key] = _value
|
|
128
|
+
|
|
129
|
+
return _dict
|
|
130
|
+
|
|
131
|
+
@classmethod
|
|
132
|
+
def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
|
|
133
|
+
"""Create an instance of CancelMarginAccountOcoOrdersResponse from a dict"""
|
|
134
|
+
if obj is None:
|
|
135
|
+
return None
|
|
136
|
+
|
|
137
|
+
if not isinstance(obj, dict):
|
|
138
|
+
return cls.model_validate(obj)
|
|
139
|
+
|
|
140
|
+
_obj = cls.model_validate(
|
|
141
|
+
{
|
|
142
|
+
"orderListId": obj.get("orderListId"),
|
|
143
|
+
"contingencyType": obj.get("contingencyType"),
|
|
144
|
+
"listStatusType": obj.get("listStatusType"),
|
|
145
|
+
"listOrderStatus": obj.get("listOrderStatus"),
|
|
146
|
+
"listClientOrderId": obj.get("listClientOrderId"),
|
|
147
|
+
"transactionTime": obj.get("transactionTime"),
|
|
148
|
+
"symbol": obj.get("symbol"),
|
|
149
|
+
"orders": (
|
|
150
|
+
[
|
|
151
|
+
CancelMarginAccountOcoOrdersResponseOrdersInner.from_dict(_item)
|
|
152
|
+
for _item in obj["orders"]
|
|
153
|
+
]
|
|
154
|
+
if obj.get("orders") is not None
|
|
155
|
+
else None
|
|
156
|
+
),
|
|
157
|
+
"orderReports": (
|
|
158
|
+
[
|
|
159
|
+
CancelMarginAccountOcoOrdersResponseOrderReportsInner.from_dict(
|
|
160
|
+
_item
|
|
161
|
+
)
|
|
162
|
+
for _item in obj["orderReports"]
|
|
163
|
+
]
|
|
164
|
+
if obj.get("orderReports") is not None
|
|
165
|
+
else None
|
|
166
|
+
),
|
|
167
|
+
}
|
|
168
|
+
)
|
|
169
|
+
# store additional fields in additional_properties
|
|
170
|
+
for _key in obj.keys():
|
|
171
|
+
if _key not in cls.__properties:
|
|
172
|
+
_obj.additional_properties[_key] = obj.get(_key)
|
|
173
|
+
|
|
174
|
+
return _obj
|
|
@@ -0,0 +1,151 @@
|
|
|
1
|
+
# coding: utf-8
|
|
2
|
+
|
|
3
|
+
"""
|
|
4
|
+
Binance Derivatives Trading Portfolio Margin REST API
|
|
5
|
+
|
|
6
|
+
OpenAPI Specification for the Binance Derivatives Trading Portfolio Margin REST API
|
|
7
|
+
The version of the OpenAPI document: 1.0.0
|
|
8
|
+
Generated by OpenAPI Generator (https://openapi-generator.tech)
|
|
9
|
+
|
|
10
|
+
Do not edit the class manually.
|
|
11
|
+
"""
|
|
12
|
+
|
|
13
|
+
|
|
14
|
+
from __future__ import annotations
|
|
15
|
+
import pprint
|
|
16
|
+
import re # noqa: F401
|
|
17
|
+
import json
|
|
18
|
+
|
|
19
|
+
from pydantic import BaseModel, ConfigDict, Field, StrictInt, StrictStr
|
|
20
|
+
from typing import Any, ClassVar, Dict, List, Optional
|
|
21
|
+
from typing import Set
|
|
22
|
+
from typing_extensions import Self
|
|
23
|
+
|
|
24
|
+
|
|
25
|
+
class CancelMarginAccountOcoOrdersResponseOrderReportsInner(BaseModel):
|
|
26
|
+
"""
|
|
27
|
+
CancelMarginAccountOcoOrdersResponseOrderReportsInner
|
|
28
|
+
""" # noqa: E501
|
|
29
|
+
|
|
30
|
+
symbol: Optional[StrictStr] = None
|
|
31
|
+
orig_client_order_id: Optional[StrictStr] = Field(
|
|
32
|
+
default=None, alias="origClientOrderId"
|
|
33
|
+
)
|
|
34
|
+
order_id: Optional[StrictInt] = Field(default=None, alias="orderId")
|
|
35
|
+
order_list_id: Optional[StrictInt] = Field(default=None, alias="orderListId")
|
|
36
|
+
client_order_id: Optional[StrictStr] = Field(default=None, alias="clientOrderId")
|
|
37
|
+
price: Optional[StrictStr] = None
|
|
38
|
+
orig_qty: Optional[StrictStr] = Field(default=None, alias="origQty")
|
|
39
|
+
executed_qty: Optional[StrictStr] = Field(default=None, alias="executedQty")
|
|
40
|
+
cummulative_quote_qty: Optional[StrictStr] = Field(
|
|
41
|
+
default=None, alias="cummulativeQuoteQty"
|
|
42
|
+
)
|
|
43
|
+
status: Optional[StrictStr] = None
|
|
44
|
+
time_in_force: Optional[StrictStr] = Field(default=None, alias="timeInForce")
|
|
45
|
+
type: Optional[StrictStr] = None
|
|
46
|
+
side: Optional[StrictStr] = None
|
|
47
|
+
stop_price: Optional[StrictStr] = Field(default=None, alias="stopPrice")
|
|
48
|
+
additional_properties: Dict[str, Any] = {}
|
|
49
|
+
__properties: ClassVar[List[str]] = [
|
|
50
|
+
"symbol",
|
|
51
|
+
"origClientOrderId",
|
|
52
|
+
"orderId",
|
|
53
|
+
"orderListId",
|
|
54
|
+
"clientOrderId",
|
|
55
|
+
"price",
|
|
56
|
+
"origQty",
|
|
57
|
+
"executedQty",
|
|
58
|
+
"cummulativeQuoteQty",
|
|
59
|
+
"status",
|
|
60
|
+
"timeInForce",
|
|
61
|
+
"type",
|
|
62
|
+
"side",
|
|
63
|
+
"stopPrice",
|
|
64
|
+
]
|
|
65
|
+
|
|
66
|
+
model_config = ConfigDict(
|
|
67
|
+
populate_by_name=True,
|
|
68
|
+
validate_assignment=True,
|
|
69
|
+
protected_namespaces=(),
|
|
70
|
+
)
|
|
71
|
+
|
|
72
|
+
def to_str(self) -> str:
|
|
73
|
+
"""Returns the string representation of the model using alias"""
|
|
74
|
+
return pprint.pformat(self.model_dump(by_alias=True))
|
|
75
|
+
|
|
76
|
+
def to_json(self) -> str:
|
|
77
|
+
"""Returns the JSON representation of the model using alias"""
|
|
78
|
+
# TODO: pydantic v2: use .model_dump_json(by_alias=True, exclude_unset=True) instead
|
|
79
|
+
return json.dumps(self.to_dict())
|
|
80
|
+
|
|
81
|
+
@classmethod
|
|
82
|
+
def is_array(cls) -> bool:
|
|
83
|
+
return False
|
|
84
|
+
|
|
85
|
+
@classmethod
|
|
86
|
+
def from_json(cls, json_str: str) -> Optional[Self]:
|
|
87
|
+
"""Create an instance of CancelMarginAccountOcoOrdersResponseOrderReportsInner from a JSON string"""
|
|
88
|
+
return cls.from_dict(json.loads(json_str))
|
|
89
|
+
|
|
90
|
+
def to_dict(self) -> Dict[str, Any]:
|
|
91
|
+
"""Return the dictionary representation of the model using alias.
|
|
92
|
+
|
|
93
|
+
This has the following differences from calling pydantic's
|
|
94
|
+
`self.model_dump(by_alias=True)`:
|
|
95
|
+
|
|
96
|
+
* `None` is only added to the output dict for nullable fields that
|
|
97
|
+
were set at model initialization. Other fields with value `None`
|
|
98
|
+
are ignored.
|
|
99
|
+
* Fields in `self.additional_properties` are added to the output dict.
|
|
100
|
+
"""
|
|
101
|
+
excluded_fields: Set[str] = set(
|
|
102
|
+
[
|
|
103
|
+
"additional_properties",
|
|
104
|
+
]
|
|
105
|
+
)
|
|
106
|
+
|
|
107
|
+
_dict = self.model_dump(
|
|
108
|
+
by_alias=True,
|
|
109
|
+
exclude=excluded_fields,
|
|
110
|
+
exclude_none=True,
|
|
111
|
+
)
|
|
112
|
+
# puts key-value pairs in additional_properties in the top level
|
|
113
|
+
if self.additional_properties is not None:
|
|
114
|
+
for _key, _value in self.additional_properties.items():
|
|
115
|
+
_dict[_key] = _value
|
|
116
|
+
|
|
117
|
+
return _dict
|
|
118
|
+
|
|
119
|
+
@classmethod
|
|
120
|
+
def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
|
|
121
|
+
"""Create an instance of CancelMarginAccountOcoOrdersResponseOrderReportsInner from a dict"""
|
|
122
|
+
if obj is None:
|
|
123
|
+
return None
|
|
124
|
+
|
|
125
|
+
if not isinstance(obj, dict):
|
|
126
|
+
return cls.model_validate(obj)
|
|
127
|
+
|
|
128
|
+
_obj = cls.model_validate(
|
|
129
|
+
{
|
|
130
|
+
"symbol": obj.get("symbol"),
|
|
131
|
+
"origClientOrderId": obj.get("origClientOrderId"),
|
|
132
|
+
"orderId": obj.get("orderId"),
|
|
133
|
+
"orderListId": obj.get("orderListId"),
|
|
134
|
+
"clientOrderId": obj.get("clientOrderId"),
|
|
135
|
+
"price": obj.get("price"),
|
|
136
|
+
"origQty": obj.get("origQty"),
|
|
137
|
+
"executedQty": obj.get("executedQty"),
|
|
138
|
+
"cummulativeQuoteQty": obj.get("cummulativeQuoteQty"),
|
|
139
|
+
"status": obj.get("status"),
|
|
140
|
+
"timeInForce": obj.get("timeInForce"),
|
|
141
|
+
"type": obj.get("type"),
|
|
142
|
+
"side": obj.get("side"),
|
|
143
|
+
"stopPrice": obj.get("stopPrice"),
|
|
144
|
+
}
|
|
145
|
+
)
|
|
146
|
+
# store additional fields in additional_properties
|
|
147
|
+
for _key in obj.keys():
|
|
148
|
+
if _key not in cls.__properties:
|
|
149
|
+
_obj.additional_properties[_key] = obj.get(_key)
|
|
150
|
+
|
|
151
|
+
return _obj
|
|
@@ -0,0 +1,110 @@
|
|
|
1
|
+
# coding: utf-8
|
|
2
|
+
|
|
3
|
+
"""
|
|
4
|
+
Binance Derivatives Trading Portfolio Margin REST API
|
|
5
|
+
|
|
6
|
+
OpenAPI Specification for the Binance Derivatives Trading Portfolio Margin REST API
|
|
7
|
+
The version of the OpenAPI document: 1.0.0
|
|
8
|
+
Generated by OpenAPI Generator (https://openapi-generator.tech)
|
|
9
|
+
|
|
10
|
+
Do not edit the class manually.
|
|
11
|
+
"""
|
|
12
|
+
|
|
13
|
+
|
|
14
|
+
from __future__ import annotations
|
|
15
|
+
import pprint
|
|
16
|
+
import re # noqa: F401
|
|
17
|
+
import json
|
|
18
|
+
|
|
19
|
+
from pydantic import BaseModel, ConfigDict, Field, StrictInt, StrictStr
|
|
20
|
+
from typing import Any, ClassVar, Dict, List, Optional
|
|
21
|
+
from typing import Set
|
|
22
|
+
from typing_extensions import Self
|
|
23
|
+
|
|
24
|
+
|
|
25
|
+
class CancelMarginAccountOcoOrdersResponseOrdersInner(BaseModel):
|
|
26
|
+
"""
|
|
27
|
+
CancelMarginAccountOcoOrdersResponseOrdersInner
|
|
28
|
+
""" # noqa: E501
|
|
29
|
+
|
|
30
|
+
symbol: Optional[StrictStr] = None
|
|
31
|
+
order_id: Optional[StrictInt] = Field(default=None, alias="orderId")
|
|
32
|
+
client_order_id: Optional[StrictStr] = Field(default=None, alias="clientOrderId")
|
|
33
|
+
additional_properties: Dict[str, Any] = {}
|
|
34
|
+
__properties: ClassVar[List[str]] = ["symbol", "orderId", "clientOrderId"]
|
|
35
|
+
|
|
36
|
+
model_config = ConfigDict(
|
|
37
|
+
populate_by_name=True,
|
|
38
|
+
validate_assignment=True,
|
|
39
|
+
protected_namespaces=(),
|
|
40
|
+
)
|
|
41
|
+
|
|
42
|
+
def to_str(self) -> str:
|
|
43
|
+
"""Returns the string representation of the model using alias"""
|
|
44
|
+
return pprint.pformat(self.model_dump(by_alias=True))
|
|
45
|
+
|
|
46
|
+
def to_json(self) -> str:
|
|
47
|
+
"""Returns the JSON representation of the model using alias"""
|
|
48
|
+
# TODO: pydantic v2: use .model_dump_json(by_alias=True, exclude_unset=True) instead
|
|
49
|
+
return json.dumps(self.to_dict())
|
|
50
|
+
|
|
51
|
+
@classmethod
|
|
52
|
+
def is_array(cls) -> bool:
|
|
53
|
+
return False
|
|
54
|
+
|
|
55
|
+
@classmethod
|
|
56
|
+
def from_json(cls, json_str: str) -> Optional[Self]:
|
|
57
|
+
"""Create an instance of CancelMarginAccountOcoOrdersResponseOrdersInner from a JSON string"""
|
|
58
|
+
return cls.from_dict(json.loads(json_str))
|
|
59
|
+
|
|
60
|
+
def to_dict(self) -> Dict[str, Any]:
|
|
61
|
+
"""Return the dictionary representation of the model using alias.
|
|
62
|
+
|
|
63
|
+
This has the following differences from calling pydantic's
|
|
64
|
+
`self.model_dump(by_alias=True)`:
|
|
65
|
+
|
|
66
|
+
* `None` is only added to the output dict for nullable fields that
|
|
67
|
+
were set at model initialization. Other fields with value `None`
|
|
68
|
+
are ignored.
|
|
69
|
+
* Fields in `self.additional_properties` are added to the output dict.
|
|
70
|
+
"""
|
|
71
|
+
excluded_fields: Set[str] = set(
|
|
72
|
+
[
|
|
73
|
+
"additional_properties",
|
|
74
|
+
]
|
|
75
|
+
)
|
|
76
|
+
|
|
77
|
+
_dict = self.model_dump(
|
|
78
|
+
by_alias=True,
|
|
79
|
+
exclude=excluded_fields,
|
|
80
|
+
exclude_none=True,
|
|
81
|
+
)
|
|
82
|
+
# puts key-value pairs in additional_properties in the top level
|
|
83
|
+
if self.additional_properties is not None:
|
|
84
|
+
for _key, _value in self.additional_properties.items():
|
|
85
|
+
_dict[_key] = _value
|
|
86
|
+
|
|
87
|
+
return _dict
|
|
88
|
+
|
|
89
|
+
@classmethod
|
|
90
|
+
def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
|
|
91
|
+
"""Create an instance of CancelMarginAccountOcoOrdersResponseOrdersInner from a dict"""
|
|
92
|
+
if obj is None:
|
|
93
|
+
return None
|
|
94
|
+
|
|
95
|
+
if not isinstance(obj, dict):
|
|
96
|
+
return cls.model_validate(obj)
|
|
97
|
+
|
|
98
|
+
_obj = cls.model_validate(
|
|
99
|
+
{
|
|
100
|
+
"symbol": obj.get("symbol"),
|
|
101
|
+
"orderId": obj.get("orderId"),
|
|
102
|
+
"clientOrderId": obj.get("clientOrderId"),
|
|
103
|
+
}
|
|
104
|
+
)
|
|
105
|
+
# store additional fields in additional_properties
|
|
106
|
+
for _key in obj.keys():
|
|
107
|
+
if _key not in cls.__properties:
|
|
108
|
+
_obj.additional_properties[_key] = obj.get(_key)
|
|
109
|
+
|
|
110
|
+
return _obj
|
|
@@ -0,0 +1,145 @@
|
|
|
1
|
+
# coding: utf-8
|
|
2
|
+
|
|
3
|
+
"""
|
|
4
|
+
Binance Derivatives Trading Portfolio Margin REST API
|
|
5
|
+
|
|
6
|
+
OpenAPI Specification for the Binance Derivatives Trading Portfolio Margin REST API
|
|
7
|
+
The version of the OpenAPI document: 1.0.0
|
|
8
|
+
Generated by OpenAPI Generator (https://openapi-generator.tech)
|
|
9
|
+
|
|
10
|
+
Do not edit the class manually.
|
|
11
|
+
"""
|
|
12
|
+
|
|
13
|
+
|
|
14
|
+
from __future__ import annotations
|
|
15
|
+
import pprint
|
|
16
|
+
import re # noqa: F401
|
|
17
|
+
import json
|
|
18
|
+
|
|
19
|
+
from pydantic import BaseModel, ConfigDict, Field, StrictInt, StrictStr
|
|
20
|
+
from typing import Any, ClassVar, Dict, List, Optional
|
|
21
|
+
from typing import Set
|
|
22
|
+
from typing_extensions import Self
|
|
23
|
+
|
|
24
|
+
|
|
25
|
+
class CancelMarginAccountOrderResponse(BaseModel):
|
|
26
|
+
"""
|
|
27
|
+
CancelMarginAccountOrderResponse
|
|
28
|
+
""" # noqa: E501
|
|
29
|
+
|
|
30
|
+
symbol: Optional[StrictStr] = None
|
|
31
|
+
order_id: Optional[StrictInt] = Field(default=None, alias="orderId")
|
|
32
|
+
orig_client_order_id: Optional[StrictStr] = Field(
|
|
33
|
+
default=None, alias="origClientOrderId"
|
|
34
|
+
)
|
|
35
|
+
client_order_id: Optional[StrictStr] = Field(default=None, alias="clientOrderId")
|
|
36
|
+
price: Optional[StrictStr] = None
|
|
37
|
+
orig_qty: Optional[StrictStr] = Field(default=None, alias="origQty")
|
|
38
|
+
executed_qty: Optional[StrictStr] = Field(default=None, alias="executedQty")
|
|
39
|
+
cummulative_quote_qty: Optional[StrictStr] = Field(
|
|
40
|
+
default=None, alias="cummulativeQuoteQty"
|
|
41
|
+
)
|
|
42
|
+
status: Optional[StrictStr] = None
|
|
43
|
+
time_in_force: Optional[StrictStr] = Field(default=None, alias="timeInForce")
|
|
44
|
+
type: Optional[StrictStr] = None
|
|
45
|
+
side: Optional[StrictStr] = None
|
|
46
|
+
additional_properties: Dict[str, Any] = {}
|
|
47
|
+
__properties: ClassVar[List[str]] = [
|
|
48
|
+
"symbol",
|
|
49
|
+
"orderId",
|
|
50
|
+
"origClientOrderId",
|
|
51
|
+
"clientOrderId",
|
|
52
|
+
"price",
|
|
53
|
+
"origQty",
|
|
54
|
+
"executedQty",
|
|
55
|
+
"cummulativeQuoteQty",
|
|
56
|
+
"status",
|
|
57
|
+
"timeInForce",
|
|
58
|
+
"type",
|
|
59
|
+
"side",
|
|
60
|
+
]
|
|
61
|
+
|
|
62
|
+
model_config = ConfigDict(
|
|
63
|
+
populate_by_name=True,
|
|
64
|
+
validate_assignment=True,
|
|
65
|
+
protected_namespaces=(),
|
|
66
|
+
)
|
|
67
|
+
|
|
68
|
+
def to_str(self) -> str:
|
|
69
|
+
"""Returns the string representation of the model using alias"""
|
|
70
|
+
return pprint.pformat(self.model_dump(by_alias=True))
|
|
71
|
+
|
|
72
|
+
def to_json(self) -> str:
|
|
73
|
+
"""Returns the JSON representation of the model using alias"""
|
|
74
|
+
# TODO: pydantic v2: use .model_dump_json(by_alias=True, exclude_unset=True) instead
|
|
75
|
+
return json.dumps(self.to_dict())
|
|
76
|
+
|
|
77
|
+
@classmethod
|
|
78
|
+
def is_array(cls) -> bool:
|
|
79
|
+
return False
|
|
80
|
+
|
|
81
|
+
@classmethod
|
|
82
|
+
def from_json(cls, json_str: str) -> Optional[Self]:
|
|
83
|
+
"""Create an instance of CancelMarginAccountOrderResponse from a JSON string"""
|
|
84
|
+
return cls.from_dict(json.loads(json_str))
|
|
85
|
+
|
|
86
|
+
def to_dict(self) -> Dict[str, Any]:
|
|
87
|
+
"""Return the dictionary representation of the model using alias.
|
|
88
|
+
|
|
89
|
+
This has the following differences from calling pydantic's
|
|
90
|
+
`self.model_dump(by_alias=True)`:
|
|
91
|
+
|
|
92
|
+
* `None` is only added to the output dict for nullable fields that
|
|
93
|
+
were set at model initialization. Other fields with value `None`
|
|
94
|
+
are ignored.
|
|
95
|
+
* Fields in `self.additional_properties` are added to the output dict.
|
|
96
|
+
"""
|
|
97
|
+
excluded_fields: Set[str] = set(
|
|
98
|
+
[
|
|
99
|
+
"additional_properties",
|
|
100
|
+
]
|
|
101
|
+
)
|
|
102
|
+
|
|
103
|
+
_dict = self.model_dump(
|
|
104
|
+
by_alias=True,
|
|
105
|
+
exclude=excluded_fields,
|
|
106
|
+
exclude_none=True,
|
|
107
|
+
)
|
|
108
|
+
# puts key-value pairs in additional_properties in the top level
|
|
109
|
+
if self.additional_properties is not None:
|
|
110
|
+
for _key, _value in self.additional_properties.items():
|
|
111
|
+
_dict[_key] = _value
|
|
112
|
+
|
|
113
|
+
return _dict
|
|
114
|
+
|
|
115
|
+
@classmethod
|
|
116
|
+
def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
|
|
117
|
+
"""Create an instance of CancelMarginAccountOrderResponse from a dict"""
|
|
118
|
+
if obj is None:
|
|
119
|
+
return None
|
|
120
|
+
|
|
121
|
+
if not isinstance(obj, dict):
|
|
122
|
+
return cls.model_validate(obj)
|
|
123
|
+
|
|
124
|
+
_obj = cls.model_validate(
|
|
125
|
+
{
|
|
126
|
+
"symbol": obj.get("symbol"),
|
|
127
|
+
"orderId": obj.get("orderId"),
|
|
128
|
+
"origClientOrderId": obj.get("origClientOrderId"),
|
|
129
|
+
"clientOrderId": obj.get("clientOrderId"),
|
|
130
|
+
"price": obj.get("price"),
|
|
131
|
+
"origQty": obj.get("origQty"),
|
|
132
|
+
"executedQty": obj.get("executedQty"),
|
|
133
|
+
"cummulativeQuoteQty": obj.get("cummulativeQuoteQty"),
|
|
134
|
+
"status": obj.get("status"),
|
|
135
|
+
"timeInForce": obj.get("timeInForce"),
|
|
136
|
+
"type": obj.get("type"),
|
|
137
|
+
"side": obj.get("side"),
|
|
138
|
+
}
|
|
139
|
+
)
|
|
140
|
+
# store additional fields in additional_properties
|
|
141
|
+
for _key in obj.keys():
|
|
142
|
+
if _key not in cls.__properties:
|
|
143
|
+
_obj.additional_properties[_key] = obj.get(_key)
|
|
144
|
+
|
|
145
|
+
return _obj
|