crypticorn 1.0.2rc3__py3-none-any.whl → 2.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.
- crypticorn/__init__.py +3 -3
- crypticorn/auth/__init__.py +2 -0
- crypticorn/auth/client/__init__.py +112 -0
- crypticorn/auth/client/api/__init__.py +8 -0
- crypticorn/auth/client/api/admin_api.py +522 -0
- crypticorn/auth/client/api/auth_api.py +2089 -0
- crypticorn/auth/client/api/service_api.py +309 -0
- crypticorn/auth/client/api/user_api.py +2540 -0
- crypticorn/auth/client/api/wallet_api.py +1698 -0
- crypticorn/auth/client/api_client.py +758 -0
- crypticorn/auth/client/api_response.py +20 -0
- crypticorn/auth/client/configuration.py +584 -0
- crypticorn/auth/client/exceptions.py +220 -0
- crypticorn/auth/client/models/__init__.py +91 -0
- crypticorn/auth/client/models/add_wallet200_response.py +86 -0
- crypticorn/auth/client/models/add_wallet_request.py +107 -0
- crypticorn/auth/client/models/authorize_user200_response.py +107 -0
- crypticorn/auth/client/models/authorize_user200_response_auth.py +101 -0
- crypticorn/auth/client/models/authorize_user_request.py +96 -0
- crypticorn/auth/client/models/create_user_request.py +114 -0
- crypticorn/auth/client/models/list_wallets200_response.py +137 -0
- crypticorn/auth/client/models/list_wallets200_response_balances_inner.py +115 -0
- crypticorn/auth/client/models/list_wallets200_response_balances_inner_sale_round.py +115 -0
- crypticorn/auth/client/models/list_wallets200_response_balances_inner_wallet.py +168 -0
- crypticorn/auth/client/models/list_wallets200_response_balances_inner_wallet_vesting_wallets_inner.py +191 -0
- crypticorn/auth/client/models/list_wallets200_response_data_inner.py +102 -0
- crypticorn/auth/client/models/list_wallets200_response_user_value.py +118 -0
- crypticorn/auth/client/models/logout_default_response.py +108 -0
- crypticorn/auth/client/models/logout_default_response_issues_inner.py +83 -0
- crypticorn/auth/client/models/refresh_token_info200_response.py +97 -0
- crypticorn/auth/client/models/refresh_token_info200_response_user_session.py +105 -0
- crypticorn/auth/client/models/resend_verification_email_request.py +84 -0
- crypticorn/auth/client/models/revoke_user_tokens_request.py +83 -0
- crypticorn/auth/client/models/rotate_tokens200_response.py +110 -0
- crypticorn/auth/client/models/token_info200_response.py +97 -0
- crypticorn/auth/client/models/unlink_wallet_request.py +83 -0
- crypticorn/auth/client/models/update_user_request.py +93 -0
- crypticorn/auth/client/models/user_reset_password_request.py +87 -0
- crypticorn/auth/client/models/user_set_password_request.py +89 -0
- crypticorn/auth/client/models/verify200_response.py +110 -0
- crypticorn/auth/client/models/verify_email200_response.py +107 -0
- crypticorn/auth/client/models/verify_email200_response_auth.py +101 -0
- crypticorn/auth/client/models/verify_email200_response_auth_auth.py +110 -0
- crypticorn/auth/client/models/verify_email_request.py +83 -0
- crypticorn/auth/client/models/verify_wallet_request.py +91 -0
- crypticorn/auth/client/models/wallet_verified200_response.py +83 -0
- crypticorn/auth/client/models/whoami200_response.py +104 -0
- crypticorn/auth/client/rest.py +195 -0
- crypticorn/auth/main.py +45 -0
- crypticorn/client.py +46 -8
- crypticorn/common/__init__.py +5 -0
- crypticorn/common/auth.py +43 -0
- crypticorn/common/auth_client.py +163 -0
- crypticorn/common/errors.py +432 -0
- crypticorn/common/scopes.py +29 -0
- crypticorn/common/urls.py +25 -0
- crypticorn/hive/__init__.py +2 -1
- crypticorn/hive/client/__init__.py +57 -0
- crypticorn/hive/client/api/__init__.py +6 -0
- crypticorn/hive/client/api/data_api.py +594 -0
- crypticorn/hive/client/api/models_api.py +1680 -0
- crypticorn/hive/client/api/status_api.py +263 -0
- crypticorn/hive/client/api_client.py +758 -0
- crypticorn/hive/client/api_response.py +20 -0
- crypticorn/hive/client/configuration.py +612 -0
- crypticorn/hive/client/exceptions.py +220 -0
- crypticorn/hive/client/models/__init__.py +38 -0
- crypticorn/hive/client/models/coins.py +44 -0
- crypticorn/hive/client/models/data_download_response.py +113 -0
- crypticorn/hive/client/models/data_info.py +115 -0
- crypticorn/hive/client/models/data_value_value_value_inner.py +154 -0
- crypticorn/hive/client/models/data_version.py +35 -0
- crypticorn/hive/client/models/download_links.py +91 -0
- crypticorn/hive/client/models/evaluation.py +86 -0
- crypticorn/hive/client/models/evaluation_response.py +85 -0
- crypticorn/hive/client/models/feature_size.py +36 -0
- crypticorn/hive/client/models/http_validation_error.py +99 -0
- crypticorn/hive/client/models/model.py +133 -0
- crypticorn/hive/client/models/model_create.py +93 -0
- crypticorn/hive/client/models/model_status.py +35 -0
- crypticorn/hive/client/models/model_update.py +83 -0
- crypticorn/hive/client/models/target.py +36 -0
- crypticorn/hive/client/models/target_type.py +35 -0
- crypticorn/hive/client/models/validation_error.py +105 -0
- crypticorn/hive/client/models/validation_error_loc_inner.py +159 -0
- crypticorn/hive/client/py.typed +0 -0
- crypticorn/hive/client/rest.py +195 -0
- crypticorn/hive/main.py +27 -100
- crypticorn/klines/client/__init__.py +21 -7
- crypticorn/klines/client/api/__init__.py +0 -1
- crypticorn/klines/client/api/funding_rates_api.py +90 -79
- crypticorn/klines/client/api/health_check_api.py +29 -45
- crypticorn/klines/client/api/ohlcv_data_api.py +104 -87
- crypticorn/klines/client/api/symbols_api.py +36 -54
- crypticorn/klines/client/api/udf_api.py +228 -352
- crypticorn/klines/client/api_client.py +106 -148
- crypticorn/klines/client/api_response.py +2 -3
- crypticorn/klines/client/configuration.py +64 -50
- crypticorn/klines/client/exceptions.py +20 -16
- crypticorn/klines/client/models/__init__.py +21 -7
- crypticorn/klines/client/models/base_response_health_check_response.py +21 -15
- crypticorn/klines/client/models/base_response_list_funding_rate_response.py +21 -15
- crypticorn/klines/client/models/base_response_list_str.py +16 -14
- crypticorn/klines/client/models/base_response_ohlcv_response.py +21 -15
- crypticorn/klines/client/models/error_response.py +23 -15
- crypticorn/klines/client/models/exchange.py +11 -11
- crypticorn/klines/client/models/funding_rate_response.py +11 -11
- crypticorn/klines/client/models/health_check_response.py +14 -12
- crypticorn/klines/client/models/history_error_response.py +11 -11
- crypticorn/klines/client/models/history_no_data_response.py +16 -16
- crypticorn/klines/client/models/history_success_response.py +16 -16
- crypticorn/klines/client/models/http_validation_error.py +14 -10
- crypticorn/klines/client/models/market.py +2 -4
- crypticorn/klines/client/models/ohlcv_response.py +22 -15
- crypticorn/klines/client/models/resolution.py +5 -7
- crypticorn/klines/client/models/response_get_history_udf_history_get.py +71 -22
- crypticorn/klines/client/models/search_symbol_response.py +22 -15
- crypticorn/klines/client/models/sort_direction.py +2 -4
- crypticorn/klines/client/models/symbol_group_response.py +5 -9
- crypticorn/klines/client/models/symbol_info_response.py +40 -24
- crypticorn/klines/client/models/symbol_type.py +5 -10
- crypticorn/klines/client/models/timeframe.py +5 -7
- crypticorn/klines/client/models/udf_config_response.py +60 -21
- crypticorn/klines/client/models/validation_error.py +19 -13
- crypticorn/klines/client/models/validation_error_loc_inner.py +32 -11
- crypticorn/klines/client/rest.py +30 -41
- crypticorn/klines/main.py +52 -15
- crypticorn/pay/__init__.py +2 -0
- crypticorn/pay/client/__init__.py +52 -0
- crypticorn/pay/client/api/__init__.py +7 -0
- crypticorn/pay/client/api/now_payments_api.py +813 -0
- crypticorn/pay/client/api/payments_api.py +799 -0
- crypticorn/pay/client/api/products_api.py +891 -0
- crypticorn/pay/client/api/status_api.py +260 -0
- crypticorn/pay/client/api_client.py +758 -0
- crypticorn/pay/client/api_response.py +20 -0
- crypticorn/pay/client/configuration.py +612 -0
- crypticorn/pay/client/exceptions.py +220 -0
- crypticorn/pay/client/models/__init__.py +32 -0
- crypticorn/pay/client/models/api_status_res.py +83 -0
- crypticorn/pay/client/models/combined_payment_history.py +101 -0
- crypticorn/pay/client/models/create_invoice_req.py +188 -0
- crypticorn/pay/client/models/create_invoice_res.py +188 -0
- crypticorn/pay/client/models/currency.py +165 -0
- crypticorn/pay/client/models/estimate_price_req.py +91 -0
- crypticorn/pay/client/models/estimate_price_res.py +102 -0
- crypticorn/pay/client/models/get_currencies_res.py +99 -0
- crypticorn/pay/client/models/get_payment_status_res.py +222 -0
- crypticorn/pay/client/models/get_payments_list_res.py +109 -0
- crypticorn/pay/client/models/http_validation_error.py +99 -0
- crypticorn/pay/client/models/min_amount_req.py +124 -0
- crypticorn/pay/client/models/min_amount_res.py +105 -0
- crypticorn/pay/client/models/now_api_status_res.py +83 -0
- crypticorn/pay/client/models/now_create_invoice_req.py +188 -0
- crypticorn/pay/client/models/now_create_invoice_res.py +188 -0
- crypticorn/pay/client/models/now_fee_structure.py +104 -0
- crypticorn/pay/client/models/now_payment_model.py +124 -0
- crypticorn/pay/client/models/now_payment_status.py +42 -0
- crypticorn/pay/client/models/now_webhook_payload.py +181 -0
- crypticorn/pay/client/models/payment.py +231 -0
- crypticorn/pay/client/models/payment_status.py +40 -0
- crypticorn/pay/client/models/product.py +87 -0
- crypticorn/pay/client/models/product_model.py +119 -0
- crypticorn/pay/client/models/product_subs_model.py +108 -0
- crypticorn/pay/client/models/services.py +34 -0
- crypticorn/pay/client/models/unified_payment_model.py +112 -0
- crypticorn/pay/client/models/validation_error.py +105 -0
- crypticorn/pay/client/models/validation_error_loc_inner.py +159 -0
- crypticorn/pay/client/py.typed +0 -0
- crypticorn/pay/client/rest.py +195 -0
- crypticorn/pay/main.py +35 -0
- crypticorn/trade/client/__init__.py +9 -4
- crypticorn/trade/client/api/__init__.py +0 -1
- crypticorn/trade/client/api/api_keys_api.py +203 -304
- crypticorn/trade/client/api/bots_api.py +177 -250
- crypticorn/trade/client/api/exchanges_api.py +38 -57
- crypticorn/trade/client/api/futures_trading_panel_api.py +223 -321
- crypticorn/trade/client/api/notifications_api.py +247 -364
- crypticorn/trade/client/api/orders_api.py +44 -63
- crypticorn/trade/client/api/status_api.py +35 -53
- crypticorn/trade/client/api/strategies_api.py +852 -64
- crypticorn/trade/client/api/trading_actions_api.py +126 -203
- crypticorn/trade/client/api_client.py +115 -154
- crypticorn/trade/client/api_response.py +2 -3
- crypticorn/trade/client/configuration.py +128 -90
- crypticorn/trade/client/exceptions.py +21 -17
- crypticorn/trade/client/models/__init__.py +9 -4
- crypticorn/trade/client/models/action_model.py +114 -50
- crypticorn/trade/client/models/api_error_identifier.py +60 -51
- crypticorn/trade/client/models/api_error_level.py +37 -0
- crypticorn/trade/client/models/api_error_type.py +37 -0
- crypticorn/trade/client/models/api_key_model.py +49 -28
- crypticorn/trade/client/models/bot_model.py +76 -31
- crypticorn/trade/client/models/bot_status.py +37 -0
- crypticorn/trade/client/models/exchange.py +3 -5
- crypticorn/trade/client/models/execution_ids.py +14 -14
- crypticorn/trade/client/models/futures_balance.py +39 -23
- crypticorn/trade/client/models/futures_trading_action.py +98 -46
- crypticorn/trade/client/models/http_validation_error.py +15 -11
- crypticorn/trade/client/models/margin_mode.py +3 -5
- crypticorn/trade/client/models/market_type.py +3 -5
- crypticorn/trade/client/models/notification_model.py +60 -27
- crypticorn/trade/client/models/notification_type.py +4 -6
- crypticorn/trade/client/models/order_model.py +125 -65
- crypticorn/trade/client/models/order_status.py +6 -8
- crypticorn/trade/client/models/post_futures_action.py +16 -12
- crypticorn/trade/client/models/strategy_exchange_info.py +11 -12
- crypticorn/trade/client/models/strategy_model.py +66 -27
- crypticorn/trade/client/models/strategy_model_input.py +160 -0
- crypticorn/trade/client/models/strategy_model_output.py +160 -0
- crypticorn/trade/client/models/tpsl.py +35 -21
- crypticorn/trade/client/models/trading_action_type.py +5 -7
- crypticorn/trade/client/models/update_notification.py +17 -13
- crypticorn/trade/client/models/validation_error.py +20 -14
- crypticorn/trade/client/models/validation_error_loc_inner.py +33 -12
- crypticorn/trade/client/rest.py +108 -170
- crypticorn/trade/main.py +26 -19
- crypticorn-2.0.0.dist-info/METADATA +74 -0
- crypticorn-2.0.0.dist-info/RECORD +226 -0
- {crypticorn-1.0.2rc3.dist-info → crypticorn-2.0.0.dist-info}/WHEEL +1 -1
- crypticorn/hive/requirements.txt +0 -4
- crypticorn/hive/utils.py +0 -109
- crypticorn/klines/requirements.txt +0 -4
- crypticorn/klines/test/test_base_response_health_check_response.py +0 -56
- crypticorn/klines/test/test_base_response_list_funding_rate_response.py +0 -59
- crypticorn/klines/test/test_base_response_list_str.py +0 -56
- crypticorn/klines/test/test_base_response_ohlcv_response.py +0 -72
- crypticorn/klines/test/test_error_response.py +0 -57
- crypticorn/klines/test/test_exchange.py +0 -56
- crypticorn/klines/test/test_funding_rate_response.py +0 -56
- crypticorn/klines/test/test_funding_rates_api.py +0 -38
- crypticorn/klines/test/test_health_check_api.py +0 -38
- crypticorn/klines/test/test_health_check_response.py +0 -52
- crypticorn/klines/test/test_history_error_response.py +0 -53
- crypticorn/klines/test/test_history_no_data_response.py +0 -69
- crypticorn/klines/test/test_history_success_response.py +0 -87
- crypticorn/klines/test/test_http_validation_error.py +0 -58
- crypticorn/klines/test/test_market.py +0 -33
- crypticorn/klines/test/test_ohlcv_data_api.py +0 -38
- crypticorn/klines/test/test_ohlcv_response.py +0 -86
- crypticorn/klines/test/test_resolution.py +0 -33
- crypticorn/klines/test/test_response_get_history_udf_history_get.py +0 -89
- crypticorn/klines/test/test_search_symbol_response.py +0 -62
- crypticorn/klines/test/test_sort_direction.py +0 -33
- crypticorn/klines/test/test_symbol_group_response.py +0 -53
- crypticorn/klines/test/test_symbol_info_response.py +0 -84
- crypticorn/klines/test/test_symbol_type.py +0 -54
- crypticorn/klines/test/test_symbols_api.py +0 -38
- crypticorn/klines/test/test_timeframe.py +0 -33
- crypticorn/klines/test/test_udf_api.py +0 -80
- crypticorn/klines/test/test_udf_config_response.py +0 -95
- crypticorn/klines/test/test_validation_error.py +0 -60
- crypticorn/klines/test/test_validation_error_loc_inner.py +0 -50
- crypticorn/trade/requirements.txt +0 -4
- crypticorn-1.0.2rc3.dist-info/LICENSE.md +0 -19
- crypticorn-1.0.2rc3.dist-info/METADATA +0 -47
- crypticorn-1.0.2rc3.dist-info/RECORD +0 -128
- /crypticorn/{klines/test/__init__.py → auth/client/py.typed} +0 -0
- {crypticorn-1.0.2rc3.dist-info → crypticorn-2.0.0.dist-info}/top_level.txt +0 -0
@@ -1,7 +1,7 @@
|
|
1
1
|
# coding: utf-8
|
2
2
|
|
3
3
|
"""
|
4
|
-
|
4
|
+
Trading API
|
5
5
|
|
6
6
|
No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator)
|
7
7
|
|
@@ -37,9 +37,8 @@ class FuturesTradingPanelApi:
|
|
37
37
|
api_client = ApiClient.get_default()
|
38
38
|
self.api_client = api_client
|
39
39
|
|
40
|
-
|
41
40
|
@validate_call
|
42
|
-
def cancel_futures_order(
|
41
|
+
async def cancel_futures_order(
|
43
42
|
self,
|
44
43
|
order_id: StrictStr,
|
45
44
|
symbol: StrictStr,
|
@@ -49,9 +48,8 @@ class FuturesTradingPanelApi:
|
|
49
48
|
None,
|
50
49
|
Annotated[StrictFloat, Field(gt=0)],
|
51
50
|
Tuple[
|
52
|
-
Annotated[StrictFloat, Field(gt=0)],
|
53
|
-
|
54
|
-
]
|
51
|
+
Annotated[StrictFloat, Field(gt=0)], Annotated[StrictFloat, Field(gt=0)]
|
52
|
+
],
|
55
53
|
] = None,
|
56
54
|
_request_auth: Optional[Dict[StrictStr, Any]] = None,
|
57
55
|
_content_type: Optional[StrictStr] = None,
|
@@ -89,7 +87,7 @@ class FuturesTradingPanelApi:
|
|
89
87
|
in the spec for a single request.
|
90
88
|
:type _host_index: int, optional
|
91
89
|
:return: Returns the result object.
|
92
|
-
"""
|
90
|
+
""" # noqa: E501
|
93
91
|
|
94
92
|
_param = self._cancel_futures_order_serialize(
|
95
93
|
order_id=order_id,
|
@@ -99,26 +97,24 @@ class FuturesTradingPanelApi:
|
|
99
97
|
_request_auth=_request_auth,
|
100
98
|
_content_type=_content_type,
|
101
99
|
_headers=_headers,
|
102
|
-
_host_index=_host_index
|
100
|
+
_host_index=_host_index,
|
103
101
|
)
|
104
102
|
|
105
103
|
_response_types_map: Dict[str, Optional[str]] = {
|
106
|
-
|
107
|
-
|
104
|
+
"200": "object",
|
105
|
+
"422": "HTTPValidationError",
|
108
106
|
}
|
109
|
-
response_data = self.api_client.call_api(
|
110
|
-
*_param,
|
111
|
-
_request_timeout=_request_timeout
|
107
|
+
response_data = await self.api_client.call_api(
|
108
|
+
*_param, _request_timeout=_request_timeout
|
112
109
|
)
|
113
|
-
response_data.read()
|
110
|
+
await response_data.read()
|
114
111
|
return self.api_client.response_deserialize(
|
115
112
|
response_data=response_data,
|
116
113
|
response_types_map=_response_types_map,
|
117
114
|
).data
|
118
115
|
|
119
|
-
|
120
116
|
@validate_call
|
121
|
-
def cancel_futures_order_with_http_info(
|
117
|
+
async def cancel_futures_order_with_http_info(
|
122
118
|
self,
|
123
119
|
order_id: StrictStr,
|
124
120
|
symbol: StrictStr,
|
@@ -128,9 +124,8 @@ class FuturesTradingPanelApi:
|
|
128
124
|
None,
|
129
125
|
Annotated[StrictFloat, Field(gt=0)],
|
130
126
|
Tuple[
|
131
|
-
Annotated[StrictFloat, Field(gt=0)],
|
132
|
-
|
133
|
-
]
|
127
|
+
Annotated[StrictFloat, Field(gt=0)], Annotated[StrictFloat, Field(gt=0)]
|
128
|
+
],
|
134
129
|
] = None,
|
135
130
|
_request_auth: Optional[Dict[StrictStr, Any]] = None,
|
136
131
|
_content_type: Optional[StrictStr] = None,
|
@@ -168,7 +163,7 @@ class FuturesTradingPanelApi:
|
|
168
163
|
in the spec for a single request.
|
169
164
|
:type _host_index: int, optional
|
170
165
|
:return: Returns the result object.
|
171
|
-
"""
|
166
|
+
""" # noqa: E501
|
172
167
|
|
173
168
|
_param = self._cancel_futures_order_serialize(
|
174
169
|
order_id=order_id,
|
@@ -178,26 +173,24 @@ class FuturesTradingPanelApi:
|
|
178
173
|
_request_auth=_request_auth,
|
179
174
|
_content_type=_content_type,
|
180
175
|
_headers=_headers,
|
181
|
-
_host_index=_host_index
|
176
|
+
_host_index=_host_index,
|
182
177
|
)
|
183
178
|
|
184
179
|
_response_types_map: Dict[str, Optional[str]] = {
|
185
|
-
|
186
|
-
|
180
|
+
"200": "object",
|
181
|
+
"422": "HTTPValidationError",
|
187
182
|
}
|
188
|
-
response_data = self.api_client.call_api(
|
189
|
-
*_param,
|
190
|
-
_request_timeout=_request_timeout
|
183
|
+
response_data = await self.api_client.call_api(
|
184
|
+
*_param, _request_timeout=_request_timeout
|
191
185
|
)
|
192
|
-
response_data.read()
|
186
|
+
await response_data.read()
|
193
187
|
return self.api_client.response_deserialize(
|
194
188
|
response_data=response_data,
|
195
189
|
response_types_map=_response_types_map,
|
196
190
|
)
|
197
191
|
|
198
|
-
|
199
192
|
@validate_call
|
200
|
-
def cancel_futures_order_without_preload_content(
|
193
|
+
async def cancel_futures_order_without_preload_content(
|
201
194
|
self,
|
202
195
|
order_id: StrictStr,
|
203
196
|
symbol: StrictStr,
|
@@ -207,9 +200,8 @@ class FuturesTradingPanelApi:
|
|
207
200
|
None,
|
208
201
|
Annotated[StrictFloat, Field(gt=0)],
|
209
202
|
Tuple[
|
210
|
-
Annotated[StrictFloat, Field(gt=0)],
|
211
|
-
|
212
|
-
]
|
203
|
+
Annotated[StrictFloat, Field(gt=0)], Annotated[StrictFloat, Field(gt=0)]
|
204
|
+
],
|
213
205
|
] = None,
|
214
206
|
_request_auth: Optional[Dict[StrictStr, Any]] = None,
|
215
207
|
_content_type: Optional[StrictStr] = None,
|
@@ -247,7 +239,7 @@ class FuturesTradingPanelApi:
|
|
247
239
|
in the spec for a single request.
|
248
240
|
:type _host_index: int, optional
|
249
241
|
:return: Returns the result object.
|
250
|
-
"""
|
242
|
+
""" # noqa: E501
|
251
243
|
|
252
244
|
_param = self._cancel_futures_order_serialize(
|
253
245
|
order_id=order_id,
|
@@ -257,20 +249,18 @@ class FuturesTradingPanelApi:
|
|
257
249
|
_request_auth=_request_auth,
|
258
250
|
_content_type=_content_type,
|
259
251
|
_headers=_headers,
|
260
|
-
_host_index=_host_index
|
252
|
+
_host_index=_host_index,
|
261
253
|
)
|
262
254
|
|
263
255
|
_response_types_map: Dict[str, Optional[str]] = {
|
264
|
-
|
265
|
-
|
256
|
+
"200": "object",
|
257
|
+
"422": "HTTPValidationError",
|
266
258
|
}
|
267
|
-
response_data = self.api_client.call_api(
|
268
|
-
*_param,
|
269
|
-
_request_timeout=_request_timeout
|
259
|
+
response_data = await self.api_client.call_api(
|
260
|
+
*_param, _request_timeout=_request_timeout
|
270
261
|
)
|
271
262
|
return response_data.response
|
272
263
|
|
273
|
-
|
274
264
|
def _cancel_futures_order_serialize(
|
275
265
|
self,
|
276
266
|
order_id,
|
@@ -285,8 +275,7 @@ class FuturesTradingPanelApi:
|
|
285
275
|
|
286
276
|
_host = None
|
287
277
|
|
288
|
-
_collection_formats: Dict[str, str] = {
|
289
|
-
}
|
278
|
+
_collection_formats: Dict[str, str] = {}
|
290
279
|
|
291
280
|
_path_params: Dict[str, str] = {}
|
292
281
|
_query_params: List[Tuple[str, str]] = []
|
@@ -300,39 +289,33 @@ class FuturesTradingPanelApi:
|
|
300
289
|
# process the path parameters
|
301
290
|
# process the query parameters
|
302
291
|
if order_id is not None:
|
303
|
-
|
304
|
-
_query_params.append((
|
305
|
-
|
292
|
+
|
293
|
+
_query_params.append(("orderId", order_id))
|
294
|
+
|
306
295
|
if symbol is not None:
|
307
|
-
|
308
|
-
_query_params.append((
|
309
|
-
|
296
|
+
|
297
|
+
_query_params.append(("symbol", symbol))
|
298
|
+
|
310
299
|
if key is not None:
|
311
|
-
|
312
|
-
_query_params.append((
|
313
|
-
|
300
|
+
|
301
|
+
_query_params.append(("key", key))
|
302
|
+
|
314
303
|
# process the header parameters
|
315
304
|
# process the form parameters
|
316
305
|
# process the body parameter
|
317
306
|
|
318
|
-
|
319
307
|
# set the HTTP header `Accept`
|
320
|
-
if
|
321
|
-
_header_params[
|
322
|
-
[
|
323
|
-
'application/json'
|
324
|
-
]
|
308
|
+
if "Accept" not in _header_params:
|
309
|
+
_header_params["Accept"] = self.api_client.select_header_accept(
|
310
|
+
["application/json"]
|
325
311
|
)
|
326
312
|
|
327
|
-
|
328
313
|
# authentication setting
|
329
|
-
_auth_settings: List[str] = [
|
330
|
-
'OAuth2PasswordBearer'
|
331
|
-
]
|
314
|
+
_auth_settings: List[str] = ["HTTPBearer"]
|
332
315
|
|
333
316
|
return self.api_client.param_serialize(
|
334
|
-
method=
|
335
|
-
resource_path=
|
317
|
+
method="DELETE",
|
318
|
+
resource_path="/futures/orders",
|
336
319
|
path_params=_path_params,
|
337
320
|
query_params=_query_params,
|
338
321
|
header_params=_header_params,
|
@@ -342,23 +325,19 @@ class FuturesTradingPanelApi:
|
|
342
325
|
auth_settings=_auth_settings,
|
343
326
|
collection_formats=_collection_formats,
|
344
327
|
_host=_host,
|
345
|
-
_request_auth=_request_auth
|
328
|
+
_request_auth=_request_auth,
|
346
329
|
)
|
347
330
|
|
348
|
-
|
349
|
-
|
350
|
-
|
351
331
|
@validate_call
|
352
|
-
def get_futures_balance(
|
332
|
+
async def get_futures_balance(
|
353
333
|
self,
|
354
334
|
access_token: Optional[StrictStr] = None,
|
355
335
|
_request_timeout: Union[
|
356
336
|
None,
|
357
337
|
Annotated[StrictFloat, Field(gt=0)],
|
358
338
|
Tuple[
|
359
|
-
Annotated[StrictFloat, Field(gt=0)],
|
360
|
-
|
361
|
-
]
|
339
|
+
Annotated[StrictFloat, Field(gt=0)], Annotated[StrictFloat, Field(gt=0)]
|
340
|
+
],
|
362
341
|
] = None,
|
363
342
|
_request_auth: Optional[Dict[StrictStr, Any]] = None,
|
364
343
|
_content_type: Optional[StrictStr] = None,
|
@@ -390,42 +369,39 @@ class FuturesTradingPanelApi:
|
|
390
369
|
in the spec for a single request.
|
391
370
|
:type _host_index: int, optional
|
392
371
|
:return: Returns the result object.
|
393
|
-
"""
|
372
|
+
""" # noqa: E501
|
394
373
|
|
395
374
|
_param = self._get_futures_balance_serialize(
|
396
375
|
access_token=access_token,
|
397
376
|
_request_auth=_request_auth,
|
398
377
|
_content_type=_content_type,
|
399
378
|
_headers=_headers,
|
400
|
-
_host_index=_host_index
|
379
|
+
_host_index=_host_index,
|
401
380
|
)
|
402
381
|
|
403
382
|
_response_types_map: Dict[str, Optional[str]] = {
|
404
|
-
|
405
|
-
|
383
|
+
"200": "List[FuturesBalance]",
|
384
|
+
"422": "HTTPValidationError",
|
406
385
|
}
|
407
|
-
response_data = self.api_client.call_api(
|
408
|
-
*_param,
|
409
|
-
_request_timeout=_request_timeout
|
386
|
+
response_data = await self.api_client.call_api(
|
387
|
+
*_param, _request_timeout=_request_timeout
|
410
388
|
)
|
411
|
-
response_data.read()
|
389
|
+
await response_data.read()
|
412
390
|
return self.api_client.response_deserialize(
|
413
391
|
response_data=response_data,
|
414
392
|
response_types_map=_response_types_map,
|
415
393
|
).data
|
416
394
|
|
417
|
-
|
418
395
|
@validate_call
|
419
|
-
def get_futures_balance_with_http_info(
|
396
|
+
async def get_futures_balance_with_http_info(
|
420
397
|
self,
|
421
398
|
access_token: Optional[StrictStr] = None,
|
422
399
|
_request_timeout: Union[
|
423
400
|
None,
|
424
401
|
Annotated[StrictFloat, Field(gt=0)],
|
425
402
|
Tuple[
|
426
|
-
Annotated[StrictFloat, Field(gt=0)],
|
427
|
-
|
428
|
-
]
|
403
|
+
Annotated[StrictFloat, Field(gt=0)], Annotated[StrictFloat, Field(gt=0)]
|
404
|
+
],
|
429
405
|
] = None,
|
430
406
|
_request_auth: Optional[Dict[StrictStr, Any]] = None,
|
431
407
|
_content_type: Optional[StrictStr] = None,
|
@@ -457,42 +433,39 @@ class FuturesTradingPanelApi:
|
|
457
433
|
in the spec for a single request.
|
458
434
|
:type _host_index: int, optional
|
459
435
|
:return: Returns the result object.
|
460
|
-
"""
|
436
|
+
""" # noqa: E501
|
461
437
|
|
462
438
|
_param = self._get_futures_balance_serialize(
|
463
439
|
access_token=access_token,
|
464
440
|
_request_auth=_request_auth,
|
465
441
|
_content_type=_content_type,
|
466
442
|
_headers=_headers,
|
467
|
-
_host_index=_host_index
|
443
|
+
_host_index=_host_index,
|
468
444
|
)
|
469
445
|
|
470
446
|
_response_types_map: Dict[str, Optional[str]] = {
|
471
|
-
|
472
|
-
|
447
|
+
"200": "List[FuturesBalance]",
|
448
|
+
"422": "HTTPValidationError",
|
473
449
|
}
|
474
|
-
response_data = self.api_client.call_api(
|
475
|
-
*_param,
|
476
|
-
_request_timeout=_request_timeout
|
450
|
+
response_data = await self.api_client.call_api(
|
451
|
+
*_param, _request_timeout=_request_timeout
|
477
452
|
)
|
478
|
-
response_data.read()
|
453
|
+
await response_data.read()
|
479
454
|
return self.api_client.response_deserialize(
|
480
455
|
response_data=response_data,
|
481
456
|
response_types_map=_response_types_map,
|
482
457
|
)
|
483
458
|
|
484
|
-
|
485
459
|
@validate_call
|
486
|
-
def get_futures_balance_without_preload_content(
|
460
|
+
async def get_futures_balance_without_preload_content(
|
487
461
|
self,
|
488
462
|
access_token: Optional[StrictStr] = None,
|
489
463
|
_request_timeout: Union[
|
490
464
|
None,
|
491
465
|
Annotated[StrictFloat, Field(gt=0)],
|
492
466
|
Tuple[
|
493
|
-
Annotated[StrictFloat, Field(gt=0)],
|
494
|
-
|
495
|
-
]
|
467
|
+
Annotated[StrictFloat, Field(gt=0)], Annotated[StrictFloat, Field(gt=0)]
|
468
|
+
],
|
496
469
|
] = None,
|
497
470
|
_request_auth: Optional[Dict[StrictStr, Any]] = None,
|
498
471
|
_content_type: Optional[StrictStr] = None,
|
@@ -524,27 +497,25 @@ class FuturesTradingPanelApi:
|
|
524
497
|
in the spec for a single request.
|
525
498
|
:type _host_index: int, optional
|
526
499
|
:return: Returns the result object.
|
527
|
-
"""
|
500
|
+
""" # noqa: E501
|
528
501
|
|
529
502
|
_param = self._get_futures_balance_serialize(
|
530
503
|
access_token=access_token,
|
531
504
|
_request_auth=_request_auth,
|
532
505
|
_content_type=_content_type,
|
533
506
|
_headers=_headers,
|
534
|
-
_host_index=_host_index
|
507
|
+
_host_index=_host_index,
|
535
508
|
)
|
536
509
|
|
537
510
|
_response_types_map: Dict[str, Optional[str]] = {
|
538
|
-
|
539
|
-
|
511
|
+
"200": "List[FuturesBalance]",
|
512
|
+
"422": "HTTPValidationError",
|
540
513
|
}
|
541
|
-
response_data = self.api_client.call_api(
|
542
|
-
*_param,
|
543
|
-
_request_timeout=_request_timeout
|
514
|
+
response_data = await self.api_client.call_api(
|
515
|
+
*_param, _request_timeout=_request_timeout
|
544
516
|
)
|
545
517
|
return response_data.response
|
546
518
|
|
547
|
-
|
548
519
|
def _get_futures_balance_serialize(
|
549
520
|
self,
|
550
521
|
access_token,
|
@@ -556,8 +527,7 @@ class FuturesTradingPanelApi:
|
|
556
527
|
|
557
528
|
_host = None
|
558
529
|
|
559
|
-
_collection_formats: Dict[str, str] = {
|
560
|
-
}
|
530
|
+
_collection_formats: Dict[str, str] = {}
|
561
531
|
|
562
532
|
_path_params: Dict[str, str] = {}
|
563
533
|
_query_params: List[Tuple[str, str]] = []
|
@@ -574,24 +544,18 @@ class FuturesTradingPanelApi:
|
|
574
544
|
# process the form parameters
|
575
545
|
# process the body parameter
|
576
546
|
|
577
|
-
|
578
547
|
# set the HTTP header `Accept`
|
579
|
-
if
|
580
|
-
_header_params[
|
581
|
-
[
|
582
|
-
'application/json'
|
583
|
-
]
|
548
|
+
if "Accept" not in _header_params:
|
549
|
+
_header_params["Accept"] = self.api_client.select_header_accept(
|
550
|
+
["application/json"]
|
584
551
|
)
|
585
552
|
|
586
|
-
|
587
553
|
# authentication setting
|
588
|
-
_auth_settings: List[str] = [
|
589
|
-
'OAuth2PasswordBearer'
|
590
|
-
]
|
554
|
+
_auth_settings: List[str] = ["HTTPBearer"]
|
591
555
|
|
592
556
|
return self.api_client.param_serialize(
|
593
|
-
method=
|
594
|
-
resource_path=
|
557
|
+
method="GET",
|
558
|
+
resource_path="/futures/balance",
|
595
559
|
path_params=_path_params,
|
596
560
|
query_params=_query_params,
|
597
561
|
header_params=_header_params,
|
@@ -601,14 +565,11 @@ class FuturesTradingPanelApi:
|
|
601
565
|
auth_settings=_auth_settings,
|
602
566
|
collection_formats=_collection_formats,
|
603
567
|
_host=_host,
|
604
|
-
_request_auth=_request_auth
|
568
|
+
_request_auth=_request_auth,
|
605
569
|
)
|
606
570
|
|
607
|
-
|
608
|
-
|
609
|
-
|
610
571
|
@validate_call
|
611
|
-
def get_futures_ledger(
|
572
|
+
async def get_futures_ledger(
|
612
573
|
self,
|
613
574
|
key: StrictStr,
|
614
575
|
access_token: Optional[StrictStr] = None,
|
@@ -616,9 +577,8 @@ class FuturesTradingPanelApi:
|
|
616
577
|
None,
|
617
578
|
Annotated[StrictFloat, Field(gt=0)],
|
618
579
|
Tuple[
|
619
|
-
Annotated[StrictFloat, Field(gt=0)],
|
620
|
-
|
621
|
-
]
|
580
|
+
Annotated[StrictFloat, Field(gt=0)], Annotated[StrictFloat, Field(gt=0)]
|
581
|
+
],
|
622
582
|
] = None,
|
623
583
|
_request_auth: Optional[Dict[StrictStr, Any]] = None,
|
624
584
|
_content_type: Optional[StrictStr] = None,
|
@@ -652,7 +612,7 @@ class FuturesTradingPanelApi:
|
|
652
612
|
in the spec for a single request.
|
653
613
|
:type _host_index: int, optional
|
654
614
|
:return: Returns the result object.
|
655
|
-
"""
|
615
|
+
""" # noqa: E501
|
656
616
|
|
657
617
|
_param = self._get_futures_ledger_serialize(
|
658
618
|
key=key,
|
@@ -660,26 +620,24 @@ class FuturesTradingPanelApi:
|
|
660
620
|
_request_auth=_request_auth,
|
661
621
|
_content_type=_content_type,
|
662
622
|
_headers=_headers,
|
663
|
-
_host_index=_host_index
|
623
|
+
_host_index=_host_index,
|
664
624
|
)
|
665
625
|
|
666
626
|
_response_types_map: Dict[str, Optional[str]] = {
|
667
|
-
|
668
|
-
|
627
|
+
"200": "object",
|
628
|
+
"422": "HTTPValidationError",
|
669
629
|
}
|
670
|
-
response_data = self.api_client.call_api(
|
671
|
-
*_param,
|
672
|
-
_request_timeout=_request_timeout
|
630
|
+
response_data = await self.api_client.call_api(
|
631
|
+
*_param, _request_timeout=_request_timeout
|
673
632
|
)
|
674
|
-
response_data.read()
|
633
|
+
await response_data.read()
|
675
634
|
return self.api_client.response_deserialize(
|
676
635
|
response_data=response_data,
|
677
636
|
response_types_map=_response_types_map,
|
678
637
|
).data
|
679
638
|
|
680
|
-
|
681
639
|
@validate_call
|
682
|
-
def get_futures_ledger_with_http_info(
|
640
|
+
async def get_futures_ledger_with_http_info(
|
683
641
|
self,
|
684
642
|
key: StrictStr,
|
685
643
|
access_token: Optional[StrictStr] = None,
|
@@ -687,9 +645,8 @@ class FuturesTradingPanelApi:
|
|
687
645
|
None,
|
688
646
|
Annotated[StrictFloat, Field(gt=0)],
|
689
647
|
Tuple[
|
690
|
-
Annotated[StrictFloat, Field(gt=0)],
|
691
|
-
|
692
|
-
]
|
648
|
+
Annotated[StrictFloat, Field(gt=0)], Annotated[StrictFloat, Field(gt=0)]
|
649
|
+
],
|
693
650
|
] = None,
|
694
651
|
_request_auth: Optional[Dict[StrictStr, Any]] = None,
|
695
652
|
_content_type: Optional[StrictStr] = None,
|
@@ -723,7 +680,7 @@ class FuturesTradingPanelApi:
|
|
723
680
|
in the spec for a single request.
|
724
681
|
:type _host_index: int, optional
|
725
682
|
:return: Returns the result object.
|
726
|
-
"""
|
683
|
+
""" # noqa: E501
|
727
684
|
|
728
685
|
_param = self._get_futures_ledger_serialize(
|
729
686
|
key=key,
|
@@ -731,26 +688,24 @@ class FuturesTradingPanelApi:
|
|
731
688
|
_request_auth=_request_auth,
|
732
689
|
_content_type=_content_type,
|
733
690
|
_headers=_headers,
|
734
|
-
_host_index=_host_index
|
691
|
+
_host_index=_host_index,
|
735
692
|
)
|
736
693
|
|
737
694
|
_response_types_map: Dict[str, Optional[str]] = {
|
738
|
-
|
739
|
-
|
695
|
+
"200": "object",
|
696
|
+
"422": "HTTPValidationError",
|
740
697
|
}
|
741
|
-
response_data = self.api_client.call_api(
|
742
|
-
*_param,
|
743
|
-
_request_timeout=_request_timeout
|
698
|
+
response_data = await self.api_client.call_api(
|
699
|
+
*_param, _request_timeout=_request_timeout
|
744
700
|
)
|
745
|
-
response_data.read()
|
701
|
+
await response_data.read()
|
746
702
|
return self.api_client.response_deserialize(
|
747
703
|
response_data=response_data,
|
748
704
|
response_types_map=_response_types_map,
|
749
705
|
)
|
750
706
|
|
751
|
-
|
752
707
|
@validate_call
|
753
|
-
def get_futures_ledger_without_preload_content(
|
708
|
+
async def get_futures_ledger_without_preload_content(
|
754
709
|
self,
|
755
710
|
key: StrictStr,
|
756
711
|
access_token: Optional[StrictStr] = None,
|
@@ -758,9 +713,8 @@ class FuturesTradingPanelApi:
|
|
758
713
|
None,
|
759
714
|
Annotated[StrictFloat, Field(gt=0)],
|
760
715
|
Tuple[
|
761
|
-
Annotated[StrictFloat, Field(gt=0)],
|
762
|
-
|
763
|
-
]
|
716
|
+
Annotated[StrictFloat, Field(gt=0)], Annotated[StrictFloat, Field(gt=0)]
|
717
|
+
],
|
764
718
|
] = None,
|
765
719
|
_request_auth: Optional[Dict[StrictStr, Any]] = None,
|
766
720
|
_content_type: Optional[StrictStr] = None,
|
@@ -794,7 +748,7 @@ class FuturesTradingPanelApi:
|
|
794
748
|
in the spec for a single request.
|
795
749
|
:type _host_index: int, optional
|
796
750
|
:return: Returns the result object.
|
797
|
-
"""
|
751
|
+
""" # noqa: E501
|
798
752
|
|
799
753
|
_param = self._get_futures_ledger_serialize(
|
800
754
|
key=key,
|
@@ -802,20 +756,18 @@ class FuturesTradingPanelApi:
|
|
802
756
|
_request_auth=_request_auth,
|
803
757
|
_content_type=_content_type,
|
804
758
|
_headers=_headers,
|
805
|
-
_host_index=_host_index
|
759
|
+
_host_index=_host_index,
|
806
760
|
)
|
807
761
|
|
808
762
|
_response_types_map: Dict[str, Optional[str]] = {
|
809
|
-
|
810
|
-
|
763
|
+
"200": "object",
|
764
|
+
"422": "HTTPValidationError",
|
811
765
|
}
|
812
|
-
response_data = self.api_client.call_api(
|
813
|
-
*_param,
|
814
|
-
_request_timeout=_request_timeout
|
766
|
+
response_data = await self.api_client.call_api(
|
767
|
+
*_param, _request_timeout=_request_timeout
|
815
768
|
)
|
816
769
|
return response_data.response
|
817
770
|
|
818
|
-
|
819
771
|
def _get_futures_ledger_serialize(
|
820
772
|
self,
|
821
773
|
key,
|
@@ -828,8 +780,7 @@ class FuturesTradingPanelApi:
|
|
828
780
|
|
829
781
|
_host = None
|
830
782
|
|
831
|
-
_collection_formats: Dict[str, str] = {
|
832
|
-
}
|
783
|
+
_collection_formats: Dict[str, str] = {}
|
833
784
|
|
834
785
|
_path_params: Dict[str, str] = {}
|
835
786
|
_query_params: List[Tuple[str, str]] = []
|
@@ -843,31 +794,25 @@ class FuturesTradingPanelApi:
|
|
843
794
|
# process the path parameters
|
844
795
|
# process the query parameters
|
845
796
|
if key is not None:
|
846
|
-
|
847
|
-
_query_params.append((
|
848
|
-
|
797
|
+
|
798
|
+
_query_params.append(("key", key))
|
799
|
+
|
849
800
|
# process the header parameters
|
850
801
|
# process the form parameters
|
851
802
|
# process the body parameter
|
852
803
|
|
853
|
-
|
854
804
|
# set the HTTP header `Accept`
|
855
|
-
if
|
856
|
-
_header_params[
|
857
|
-
[
|
858
|
-
'application/json'
|
859
|
-
]
|
805
|
+
if "Accept" not in _header_params:
|
806
|
+
_header_params["Accept"] = self.api_client.select_header_accept(
|
807
|
+
["application/json"]
|
860
808
|
)
|
861
809
|
|
862
|
-
|
863
810
|
# authentication setting
|
864
|
-
_auth_settings: List[str] = [
|
865
|
-
'OAuth2PasswordBearer'
|
866
|
-
]
|
811
|
+
_auth_settings: List[str] = ["HTTPBearer"]
|
867
812
|
|
868
813
|
return self.api_client.param_serialize(
|
869
|
-
method=
|
870
|
-
resource_path=
|
814
|
+
method="GET",
|
815
|
+
resource_path="/futures/ledger",
|
871
816
|
path_params=_path_params,
|
872
817
|
query_params=_query_params,
|
873
818
|
header_params=_header_params,
|
@@ -877,14 +822,11 @@ class FuturesTradingPanelApi:
|
|
877
822
|
auth_settings=_auth_settings,
|
878
823
|
collection_formats=_collection_formats,
|
879
824
|
_host=_host,
|
880
|
-
_request_auth=_request_auth
|
825
|
+
_request_auth=_request_auth,
|
881
826
|
)
|
882
827
|
|
883
|
-
|
884
|
-
|
885
|
-
|
886
828
|
@validate_call
|
887
|
-
def get_historical_futures_orders(
|
829
|
+
async def get_historical_futures_orders(
|
888
830
|
self,
|
889
831
|
key: StrictStr,
|
890
832
|
access_token: Optional[StrictStr] = None,
|
@@ -892,9 +834,8 @@ class FuturesTradingPanelApi:
|
|
892
834
|
None,
|
893
835
|
Annotated[StrictFloat, Field(gt=0)],
|
894
836
|
Tuple[
|
895
|
-
Annotated[StrictFloat, Field(gt=0)],
|
896
|
-
|
897
|
-
]
|
837
|
+
Annotated[StrictFloat, Field(gt=0)], Annotated[StrictFloat, Field(gt=0)]
|
838
|
+
],
|
898
839
|
] = None,
|
899
840
|
_request_auth: Optional[Dict[StrictStr, Any]] = None,
|
900
841
|
_content_type: Optional[StrictStr] = None,
|
@@ -928,7 +869,7 @@ class FuturesTradingPanelApi:
|
|
928
869
|
in the spec for a single request.
|
929
870
|
:type _host_index: int, optional
|
930
871
|
:return: Returns the result object.
|
931
|
-
"""
|
872
|
+
""" # noqa: E501
|
932
873
|
|
933
874
|
_param = self._get_historical_futures_orders_serialize(
|
934
875
|
key=key,
|
@@ -936,26 +877,24 @@ class FuturesTradingPanelApi:
|
|
936
877
|
_request_auth=_request_auth,
|
937
878
|
_content_type=_content_type,
|
938
879
|
_headers=_headers,
|
939
|
-
_host_index=_host_index
|
880
|
+
_host_index=_host_index,
|
940
881
|
)
|
941
882
|
|
942
883
|
_response_types_map: Dict[str, Optional[str]] = {
|
943
|
-
|
944
|
-
|
884
|
+
"200": "object",
|
885
|
+
"422": "HTTPValidationError",
|
945
886
|
}
|
946
|
-
response_data = self.api_client.call_api(
|
947
|
-
*_param,
|
948
|
-
_request_timeout=_request_timeout
|
887
|
+
response_data = await self.api_client.call_api(
|
888
|
+
*_param, _request_timeout=_request_timeout
|
949
889
|
)
|
950
|
-
response_data.read()
|
890
|
+
await response_data.read()
|
951
891
|
return self.api_client.response_deserialize(
|
952
892
|
response_data=response_data,
|
953
893
|
response_types_map=_response_types_map,
|
954
894
|
).data
|
955
895
|
|
956
|
-
|
957
896
|
@validate_call
|
958
|
-
def get_historical_futures_orders_with_http_info(
|
897
|
+
async def get_historical_futures_orders_with_http_info(
|
959
898
|
self,
|
960
899
|
key: StrictStr,
|
961
900
|
access_token: Optional[StrictStr] = None,
|
@@ -963,9 +902,8 @@ class FuturesTradingPanelApi:
|
|
963
902
|
None,
|
964
903
|
Annotated[StrictFloat, Field(gt=0)],
|
965
904
|
Tuple[
|
966
|
-
Annotated[StrictFloat, Field(gt=0)],
|
967
|
-
|
968
|
-
]
|
905
|
+
Annotated[StrictFloat, Field(gt=0)], Annotated[StrictFloat, Field(gt=0)]
|
906
|
+
],
|
969
907
|
] = None,
|
970
908
|
_request_auth: Optional[Dict[StrictStr, Any]] = None,
|
971
909
|
_content_type: Optional[StrictStr] = None,
|
@@ -999,7 +937,7 @@ class FuturesTradingPanelApi:
|
|
999
937
|
in the spec for a single request.
|
1000
938
|
:type _host_index: int, optional
|
1001
939
|
:return: Returns the result object.
|
1002
|
-
"""
|
940
|
+
""" # noqa: E501
|
1003
941
|
|
1004
942
|
_param = self._get_historical_futures_orders_serialize(
|
1005
943
|
key=key,
|
@@ -1007,26 +945,24 @@ class FuturesTradingPanelApi:
|
|
1007
945
|
_request_auth=_request_auth,
|
1008
946
|
_content_type=_content_type,
|
1009
947
|
_headers=_headers,
|
1010
|
-
_host_index=_host_index
|
948
|
+
_host_index=_host_index,
|
1011
949
|
)
|
1012
950
|
|
1013
951
|
_response_types_map: Dict[str, Optional[str]] = {
|
1014
|
-
|
1015
|
-
|
952
|
+
"200": "object",
|
953
|
+
"422": "HTTPValidationError",
|
1016
954
|
}
|
1017
|
-
response_data = self.api_client.call_api(
|
1018
|
-
*_param,
|
1019
|
-
_request_timeout=_request_timeout
|
955
|
+
response_data = await self.api_client.call_api(
|
956
|
+
*_param, _request_timeout=_request_timeout
|
1020
957
|
)
|
1021
|
-
response_data.read()
|
958
|
+
await response_data.read()
|
1022
959
|
return self.api_client.response_deserialize(
|
1023
960
|
response_data=response_data,
|
1024
961
|
response_types_map=_response_types_map,
|
1025
962
|
)
|
1026
963
|
|
1027
|
-
|
1028
964
|
@validate_call
|
1029
|
-
def get_historical_futures_orders_without_preload_content(
|
965
|
+
async def get_historical_futures_orders_without_preload_content(
|
1030
966
|
self,
|
1031
967
|
key: StrictStr,
|
1032
968
|
access_token: Optional[StrictStr] = None,
|
@@ -1034,9 +970,8 @@ class FuturesTradingPanelApi:
|
|
1034
970
|
None,
|
1035
971
|
Annotated[StrictFloat, Field(gt=0)],
|
1036
972
|
Tuple[
|
1037
|
-
Annotated[StrictFloat, Field(gt=0)],
|
1038
|
-
|
1039
|
-
]
|
973
|
+
Annotated[StrictFloat, Field(gt=0)], Annotated[StrictFloat, Field(gt=0)]
|
974
|
+
],
|
1040
975
|
] = None,
|
1041
976
|
_request_auth: Optional[Dict[StrictStr, Any]] = None,
|
1042
977
|
_content_type: Optional[StrictStr] = None,
|
@@ -1070,7 +1005,7 @@ class FuturesTradingPanelApi:
|
|
1070
1005
|
in the spec for a single request.
|
1071
1006
|
:type _host_index: int, optional
|
1072
1007
|
:return: Returns the result object.
|
1073
|
-
"""
|
1008
|
+
""" # noqa: E501
|
1074
1009
|
|
1075
1010
|
_param = self._get_historical_futures_orders_serialize(
|
1076
1011
|
key=key,
|
@@ -1078,20 +1013,18 @@ class FuturesTradingPanelApi:
|
|
1078
1013
|
_request_auth=_request_auth,
|
1079
1014
|
_content_type=_content_type,
|
1080
1015
|
_headers=_headers,
|
1081
|
-
_host_index=_host_index
|
1016
|
+
_host_index=_host_index,
|
1082
1017
|
)
|
1083
1018
|
|
1084
1019
|
_response_types_map: Dict[str, Optional[str]] = {
|
1085
|
-
|
1086
|
-
|
1020
|
+
"200": "object",
|
1021
|
+
"422": "HTTPValidationError",
|
1087
1022
|
}
|
1088
|
-
response_data = self.api_client.call_api(
|
1089
|
-
*_param,
|
1090
|
-
_request_timeout=_request_timeout
|
1023
|
+
response_data = await self.api_client.call_api(
|
1024
|
+
*_param, _request_timeout=_request_timeout
|
1091
1025
|
)
|
1092
1026
|
return response_data.response
|
1093
1027
|
|
1094
|
-
|
1095
1028
|
def _get_historical_futures_orders_serialize(
|
1096
1029
|
self,
|
1097
1030
|
key,
|
@@ -1104,8 +1037,7 @@ class FuturesTradingPanelApi:
|
|
1104
1037
|
|
1105
1038
|
_host = None
|
1106
1039
|
|
1107
|
-
_collection_formats: Dict[str, str] = {
|
1108
|
-
}
|
1040
|
+
_collection_formats: Dict[str, str] = {}
|
1109
1041
|
|
1110
1042
|
_path_params: Dict[str, str] = {}
|
1111
1043
|
_query_params: List[Tuple[str, str]] = []
|
@@ -1119,31 +1051,25 @@ class FuturesTradingPanelApi:
|
|
1119
1051
|
# process the path parameters
|
1120
1052
|
# process the query parameters
|
1121
1053
|
if key is not None:
|
1122
|
-
|
1123
|
-
_query_params.append((
|
1124
|
-
|
1054
|
+
|
1055
|
+
_query_params.append(("key", key))
|
1056
|
+
|
1125
1057
|
# process the header parameters
|
1126
1058
|
# process the form parameters
|
1127
1059
|
# process the body parameter
|
1128
1060
|
|
1129
|
-
|
1130
1061
|
# set the HTTP header `Accept`
|
1131
|
-
if
|
1132
|
-
_header_params[
|
1133
|
-
[
|
1134
|
-
'application/json'
|
1135
|
-
]
|
1062
|
+
if "Accept" not in _header_params:
|
1063
|
+
_header_params["Accept"] = self.api_client.select_header_accept(
|
1064
|
+
["application/json"]
|
1136
1065
|
)
|
1137
1066
|
|
1138
|
-
|
1139
1067
|
# authentication setting
|
1140
|
-
_auth_settings: List[str] = [
|
1141
|
-
'OAuth2PasswordBearer'
|
1142
|
-
]
|
1068
|
+
_auth_settings: List[str] = ["HTTPBearer"]
|
1143
1069
|
|
1144
1070
|
return self.api_client.param_serialize(
|
1145
|
-
method=
|
1146
|
-
resource_path=
|
1071
|
+
method="GET",
|
1072
|
+
resource_path="/futures/orders",
|
1147
1073
|
path_params=_path_params,
|
1148
1074
|
query_params=_query_params,
|
1149
1075
|
header_params=_header_params,
|
@@ -1153,25 +1079,21 @@ class FuturesTradingPanelApi:
|
|
1153
1079
|
auth_settings=_auth_settings,
|
1154
1080
|
collection_formats=_collection_formats,
|
1155
1081
|
_host=_host,
|
1156
|
-
_request_auth=_request_auth
|
1082
|
+
_request_auth=_request_auth,
|
1157
1083
|
)
|
1158
1084
|
|
1159
|
-
|
1160
|
-
|
1161
|
-
|
1162
1085
|
@validate_call
|
1163
|
-
def place_futures_order(
|
1086
|
+
async def place_futures_order(
|
1164
1087
|
self,
|
1165
1088
|
key: StrictStr,
|
1166
|
-
|
1089
|
+
request_body: Dict[str, Any],
|
1167
1090
|
access_token: Optional[StrictStr] = None,
|
1168
1091
|
_request_timeout: Union[
|
1169
1092
|
None,
|
1170
1093
|
Annotated[StrictFloat, Field(gt=0)],
|
1171
1094
|
Tuple[
|
1172
|
-
Annotated[StrictFloat, Field(gt=0)],
|
1173
|
-
|
1174
|
-
]
|
1095
|
+
Annotated[StrictFloat, Field(gt=0)], Annotated[StrictFloat, Field(gt=0)]
|
1096
|
+
],
|
1175
1097
|
] = None,
|
1176
1098
|
_request_auth: Optional[Dict[StrictStr, Any]] = None,
|
1177
1099
|
_content_type: Optional[StrictStr] = None,
|
@@ -1183,8 +1105,8 @@ class FuturesTradingPanelApi:
|
|
1183
1105
|
|
1184
1106
|
:param key: (required)
|
1185
1107
|
:type key: str
|
1186
|
-
:param
|
1187
|
-
:type
|
1108
|
+
:param request_body: (required)
|
1109
|
+
:type request_body: Dict[str, object]
|
1188
1110
|
:param access_token:
|
1189
1111
|
:type access_token: str
|
1190
1112
|
:param _request_timeout: timeout setting for this request. If one
|
@@ -1207,46 +1129,43 @@ class FuturesTradingPanelApi:
|
|
1207
1129
|
in the spec for a single request.
|
1208
1130
|
:type _host_index: int, optional
|
1209
1131
|
:return: Returns the result object.
|
1210
|
-
"""
|
1132
|
+
""" # noqa: E501
|
1211
1133
|
|
1212
1134
|
_param = self._place_futures_order_serialize(
|
1213
1135
|
key=key,
|
1214
|
-
|
1136
|
+
request_body=request_body,
|
1215
1137
|
access_token=access_token,
|
1216
1138
|
_request_auth=_request_auth,
|
1217
1139
|
_content_type=_content_type,
|
1218
1140
|
_headers=_headers,
|
1219
|
-
_host_index=_host_index
|
1141
|
+
_host_index=_host_index,
|
1220
1142
|
)
|
1221
1143
|
|
1222
1144
|
_response_types_map: Dict[str, Optional[str]] = {
|
1223
|
-
|
1224
|
-
|
1145
|
+
"200": "object",
|
1146
|
+
"422": "HTTPValidationError",
|
1225
1147
|
}
|
1226
|
-
response_data = self.api_client.call_api(
|
1227
|
-
*_param,
|
1228
|
-
_request_timeout=_request_timeout
|
1148
|
+
response_data = await self.api_client.call_api(
|
1149
|
+
*_param, _request_timeout=_request_timeout
|
1229
1150
|
)
|
1230
|
-
response_data.read()
|
1151
|
+
await response_data.read()
|
1231
1152
|
return self.api_client.response_deserialize(
|
1232
1153
|
response_data=response_data,
|
1233
1154
|
response_types_map=_response_types_map,
|
1234
1155
|
).data
|
1235
1156
|
|
1236
|
-
|
1237
1157
|
@validate_call
|
1238
|
-
def place_futures_order_with_http_info(
|
1158
|
+
async def place_futures_order_with_http_info(
|
1239
1159
|
self,
|
1240
1160
|
key: StrictStr,
|
1241
|
-
|
1161
|
+
request_body: Dict[str, Any],
|
1242
1162
|
access_token: Optional[StrictStr] = None,
|
1243
1163
|
_request_timeout: Union[
|
1244
1164
|
None,
|
1245
1165
|
Annotated[StrictFloat, Field(gt=0)],
|
1246
1166
|
Tuple[
|
1247
|
-
Annotated[StrictFloat, Field(gt=0)],
|
1248
|
-
|
1249
|
-
]
|
1167
|
+
Annotated[StrictFloat, Field(gt=0)], Annotated[StrictFloat, Field(gt=0)]
|
1168
|
+
],
|
1250
1169
|
] = None,
|
1251
1170
|
_request_auth: Optional[Dict[StrictStr, Any]] = None,
|
1252
1171
|
_content_type: Optional[StrictStr] = None,
|
@@ -1258,8 +1177,8 @@ class FuturesTradingPanelApi:
|
|
1258
1177
|
|
1259
1178
|
:param key: (required)
|
1260
1179
|
:type key: str
|
1261
|
-
:param
|
1262
|
-
:type
|
1180
|
+
:param request_body: (required)
|
1181
|
+
:type request_body: Dict[str, object]
|
1263
1182
|
:param access_token:
|
1264
1183
|
:type access_token: str
|
1265
1184
|
:param _request_timeout: timeout setting for this request. If one
|
@@ -1282,46 +1201,43 @@ class FuturesTradingPanelApi:
|
|
1282
1201
|
in the spec for a single request.
|
1283
1202
|
:type _host_index: int, optional
|
1284
1203
|
:return: Returns the result object.
|
1285
|
-
"""
|
1204
|
+
""" # noqa: E501
|
1286
1205
|
|
1287
1206
|
_param = self._place_futures_order_serialize(
|
1288
1207
|
key=key,
|
1289
|
-
|
1208
|
+
request_body=request_body,
|
1290
1209
|
access_token=access_token,
|
1291
1210
|
_request_auth=_request_auth,
|
1292
1211
|
_content_type=_content_type,
|
1293
1212
|
_headers=_headers,
|
1294
|
-
_host_index=_host_index
|
1213
|
+
_host_index=_host_index,
|
1295
1214
|
)
|
1296
1215
|
|
1297
1216
|
_response_types_map: Dict[str, Optional[str]] = {
|
1298
|
-
|
1299
|
-
|
1217
|
+
"200": "object",
|
1218
|
+
"422": "HTTPValidationError",
|
1300
1219
|
}
|
1301
|
-
response_data = self.api_client.call_api(
|
1302
|
-
*_param,
|
1303
|
-
_request_timeout=_request_timeout
|
1220
|
+
response_data = await self.api_client.call_api(
|
1221
|
+
*_param, _request_timeout=_request_timeout
|
1304
1222
|
)
|
1305
|
-
response_data.read()
|
1223
|
+
await response_data.read()
|
1306
1224
|
return self.api_client.response_deserialize(
|
1307
1225
|
response_data=response_data,
|
1308
1226
|
response_types_map=_response_types_map,
|
1309
1227
|
)
|
1310
1228
|
|
1311
|
-
|
1312
1229
|
@validate_call
|
1313
|
-
def place_futures_order_without_preload_content(
|
1230
|
+
async def place_futures_order_without_preload_content(
|
1314
1231
|
self,
|
1315
1232
|
key: StrictStr,
|
1316
|
-
|
1233
|
+
request_body: Dict[str, Any],
|
1317
1234
|
access_token: Optional[StrictStr] = None,
|
1318
1235
|
_request_timeout: Union[
|
1319
1236
|
None,
|
1320
1237
|
Annotated[StrictFloat, Field(gt=0)],
|
1321
1238
|
Tuple[
|
1322
|
-
Annotated[StrictFloat, Field(gt=0)],
|
1323
|
-
|
1324
|
-
]
|
1239
|
+
Annotated[StrictFloat, Field(gt=0)], Annotated[StrictFloat, Field(gt=0)]
|
1240
|
+
],
|
1325
1241
|
] = None,
|
1326
1242
|
_request_auth: Optional[Dict[StrictStr, Any]] = None,
|
1327
1243
|
_content_type: Optional[StrictStr] = None,
|
@@ -1333,8 +1249,8 @@ class FuturesTradingPanelApi:
|
|
1333
1249
|
|
1334
1250
|
:param key: (required)
|
1335
1251
|
:type key: str
|
1336
|
-
:param
|
1337
|
-
:type
|
1252
|
+
:param request_body: (required)
|
1253
|
+
:type request_body: Dict[str, object]
|
1338
1254
|
:param access_token:
|
1339
1255
|
:type access_token: str
|
1340
1256
|
:param _request_timeout: timeout setting for this request. If one
|
@@ -1357,33 +1273,31 @@ class FuturesTradingPanelApi:
|
|
1357
1273
|
in the spec for a single request.
|
1358
1274
|
:type _host_index: int, optional
|
1359
1275
|
:return: Returns the result object.
|
1360
|
-
"""
|
1276
|
+
""" # noqa: E501
|
1361
1277
|
|
1362
1278
|
_param = self._place_futures_order_serialize(
|
1363
1279
|
key=key,
|
1364
|
-
|
1280
|
+
request_body=request_body,
|
1365
1281
|
access_token=access_token,
|
1366
1282
|
_request_auth=_request_auth,
|
1367
1283
|
_content_type=_content_type,
|
1368
1284
|
_headers=_headers,
|
1369
|
-
_host_index=_host_index
|
1285
|
+
_host_index=_host_index,
|
1370
1286
|
)
|
1371
1287
|
|
1372
1288
|
_response_types_map: Dict[str, Optional[str]] = {
|
1373
|
-
|
1374
|
-
|
1289
|
+
"200": "object",
|
1290
|
+
"422": "HTTPValidationError",
|
1375
1291
|
}
|
1376
|
-
response_data = self.api_client.call_api(
|
1377
|
-
*_param,
|
1378
|
-
_request_timeout=_request_timeout
|
1292
|
+
response_data = await self.api_client.call_api(
|
1293
|
+
*_param, _request_timeout=_request_timeout
|
1379
1294
|
)
|
1380
1295
|
return response_data.response
|
1381
1296
|
|
1382
|
-
|
1383
1297
|
def _place_futures_order_serialize(
|
1384
1298
|
self,
|
1385
1299
|
key,
|
1386
|
-
|
1300
|
+
request_body,
|
1387
1301
|
access_token,
|
1388
1302
|
_request_auth,
|
1389
1303
|
_content_type,
|
@@ -1393,8 +1307,7 @@ class FuturesTradingPanelApi:
|
|
1393
1307
|
|
1394
1308
|
_host = None
|
1395
1309
|
|
1396
|
-
_collection_formats: Dict[str, str] = {
|
1397
|
-
}
|
1310
|
+
_collection_formats: Dict[str, str] = {}
|
1398
1311
|
|
1399
1312
|
_path_params: Dict[str, str] = {}
|
1400
1313
|
_query_params: List[Tuple[str, str]] = []
|
@@ -1408,46 +1321,37 @@ class FuturesTradingPanelApi:
|
|
1408
1321
|
# process the path parameters
|
1409
1322
|
# process the query parameters
|
1410
1323
|
if key is not None:
|
1411
|
-
|
1412
|
-
_query_params.append((
|
1413
|
-
|
1324
|
+
|
1325
|
+
_query_params.append(("key", key))
|
1326
|
+
|
1414
1327
|
# process the header parameters
|
1415
1328
|
# process the form parameters
|
1416
1329
|
# process the body parameter
|
1417
|
-
if
|
1418
|
-
_body_params =
|
1419
|
-
|
1330
|
+
if request_body is not None:
|
1331
|
+
_body_params = request_body
|
1420
1332
|
|
1421
1333
|
# set the HTTP header `Accept`
|
1422
|
-
if
|
1423
|
-
_header_params[
|
1424
|
-
[
|
1425
|
-
'application/json'
|
1426
|
-
]
|
1334
|
+
if "Accept" not in _header_params:
|
1335
|
+
_header_params["Accept"] = self.api_client.select_header_accept(
|
1336
|
+
["application/json"]
|
1427
1337
|
)
|
1428
1338
|
|
1429
1339
|
# set the HTTP header `Content-Type`
|
1430
1340
|
if _content_type:
|
1431
|
-
_header_params[
|
1341
|
+
_header_params["Content-Type"] = _content_type
|
1432
1342
|
else:
|
1433
|
-
_default_content_type = (
|
1434
|
-
|
1435
|
-
[
|
1436
|
-
'application/json'
|
1437
|
-
]
|
1438
|
-
)
|
1343
|
+
_default_content_type = self.api_client.select_header_content_type(
|
1344
|
+
["application/json"]
|
1439
1345
|
)
|
1440
1346
|
if _default_content_type is not None:
|
1441
|
-
_header_params[
|
1347
|
+
_header_params["Content-Type"] = _default_content_type
|
1442
1348
|
|
1443
1349
|
# authentication setting
|
1444
|
-
_auth_settings: List[str] = [
|
1445
|
-
'OAuth2PasswordBearer'
|
1446
|
-
]
|
1350
|
+
_auth_settings: List[str] = ["HTTPBearer"]
|
1447
1351
|
|
1448
1352
|
return self.api_client.param_serialize(
|
1449
|
-
method=
|
1450
|
-
resource_path=
|
1353
|
+
method="POST",
|
1354
|
+
resource_path="/futures/orders",
|
1451
1355
|
path_params=_path_params,
|
1452
1356
|
query_params=_query_params,
|
1453
1357
|
header_params=_header_params,
|
@@ -1457,7 +1361,5 @@ class FuturesTradingPanelApi:
|
|
1457
1361
|
auth_settings=_auth_settings,
|
1458
1362
|
collection_formats=_collection_formats,
|
1459
1363
|
_host=_host,
|
1460
|
-
_request_auth=_request_auth
|
1364
|
+
_request_auth=_request_auth,
|
1461
1365
|
)
|
1462
|
-
|
1463
|
-
|