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
|
|
@@ -39,9 +39,8 @@ class TradingActionsApi:
|
|
39
39
|
api_client = ApiClient.get_default()
|
40
40
|
self.api_client = api_client
|
41
41
|
|
42
|
-
|
43
42
|
@validate_call
|
44
|
-
def get_actions(
|
43
|
+
async def get_actions(
|
45
44
|
self,
|
46
45
|
limit: Optional[StrictInt] = None,
|
47
46
|
offset: Optional[StrictInt] = None,
|
@@ -50,9 +49,8 @@ class TradingActionsApi:
|
|
50
49
|
None,
|
51
50
|
Annotated[StrictFloat, Field(gt=0)],
|
52
51
|
Tuple[
|
53
|
-
Annotated[StrictFloat, Field(gt=0)],
|
54
|
-
|
55
|
-
]
|
52
|
+
Annotated[StrictFloat, Field(gt=0)], Annotated[StrictFloat, Field(gt=0)]
|
53
|
+
],
|
56
54
|
] = None,
|
57
55
|
_request_auth: Optional[Dict[StrictStr, Any]] = None,
|
58
56
|
_content_type: Optional[StrictStr] = None,
|
@@ -88,7 +86,7 @@ class TradingActionsApi:
|
|
88
86
|
in the spec for a single request.
|
89
87
|
:type _host_index: int, optional
|
90
88
|
:return: Returns the result object.
|
91
|
-
"""
|
89
|
+
""" # noqa: E501
|
92
90
|
|
93
91
|
_param = self._get_actions_serialize(
|
94
92
|
limit=limit,
|
@@ -97,26 +95,24 @@ class TradingActionsApi:
|
|
97
95
|
_request_auth=_request_auth,
|
98
96
|
_content_type=_content_type,
|
99
97
|
_headers=_headers,
|
100
|
-
_host_index=_host_index
|
98
|
+
_host_index=_host_index,
|
101
99
|
)
|
102
100
|
|
103
101
|
_response_types_map: Dict[str, Optional[str]] = {
|
104
|
-
|
105
|
-
|
102
|
+
"200": "List[ActionModel]",
|
103
|
+
"422": "HTTPValidationError",
|
106
104
|
}
|
107
|
-
response_data = self.api_client.call_api(
|
108
|
-
*_param,
|
109
|
-
_request_timeout=_request_timeout
|
105
|
+
response_data = await self.api_client.call_api(
|
106
|
+
*_param, _request_timeout=_request_timeout
|
110
107
|
)
|
111
|
-
response_data.read()
|
108
|
+
await response_data.read()
|
112
109
|
return self.api_client.response_deserialize(
|
113
110
|
response_data=response_data,
|
114
111
|
response_types_map=_response_types_map,
|
115
112
|
).data
|
116
113
|
|
117
|
-
|
118
114
|
@validate_call
|
119
|
-
def get_actions_with_http_info(
|
115
|
+
async def get_actions_with_http_info(
|
120
116
|
self,
|
121
117
|
limit: Optional[StrictInt] = None,
|
122
118
|
offset: Optional[StrictInt] = None,
|
@@ -125,9 +121,8 @@ class TradingActionsApi:
|
|
125
121
|
None,
|
126
122
|
Annotated[StrictFloat, Field(gt=0)],
|
127
123
|
Tuple[
|
128
|
-
Annotated[StrictFloat, Field(gt=0)],
|
129
|
-
|
130
|
-
]
|
124
|
+
Annotated[StrictFloat, Field(gt=0)], Annotated[StrictFloat, Field(gt=0)]
|
125
|
+
],
|
131
126
|
] = None,
|
132
127
|
_request_auth: Optional[Dict[StrictStr, Any]] = None,
|
133
128
|
_content_type: Optional[StrictStr] = None,
|
@@ -163,7 +158,7 @@ class TradingActionsApi:
|
|
163
158
|
in the spec for a single request.
|
164
159
|
:type _host_index: int, optional
|
165
160
|
:return: Returns the result object.
|
166
|
-
"""
|
161
|
+
""" # noqa: E501
|
167
162
|
|
168
163
|
_param = self._get_actions_serialize(
|
169
164
|
limit=limit,
|
@@ -172,26 +167,24 @@ class TradingActionsApi:
|
|
172
167
|
_request_auth=_request_auth,
|
173
168
|
_content_type=_content_type,
|
174
169
|
_headers=_headers,
|
175
|
-
_host_index=_host_index
|
170
|
+
_host_index=_host_index,
|
176
171
|
)
|
177
172
|
|
178
173
|
_response_types_map: Dict[str, Optional[str]] = {
|
179
|
-
|
180
|
-
|
174
|
+
"200": "List[ActionModel]",
|
175
|
+
"422": "HTTPValidationError",
|
181
176
|
}
|
182
|
-
response_data = self.api_client.call_api(
|
183
|
-
*_param,
|
184
|
-
_request_timeout=_request_timeout
|
177
|
+
response_data = await self.api_client.call_api(
|
178
|
+
*_param, _request_timeout=_request_timeout
|
185
179
|
)
|
186
|
-
response_data.read()
|
180
|
+
await response_data.read()
|
187
181
|
return self.api_client.response_deserialize(
|
188
182
|
response_data=response_data,
|
189
183
|
response_types_map=_response_types_map,
|
190
184
|
)
|
191
185
|
|
192
|
-
|
193
186
|
@validate_call
|
194
|
-
def get_actions_without_preload_content(
|
187
|
+
async def get_actions_without_preload_content(
|
195
188
|
self,
|
196
189
|
limit: Optional[StrictInt] = None,
|
197
190
|
offset: Optional[StrictInt] = None,
|
@@ -200,9 +193,8 @@ class TradingActionsApi:
|
|
200
193
|
None,
|
201
194
|
Annotated[StrictFloat, Field(gt=0)],
|
202
195
|
Tuple[
|
203
|
-
Annotated[StrictFloat, Field(gt=0)],
|
204
|
-
|
205
|
-
]
|
196
|
+
Annotated[StrictFloat, Field(gt=0)], Annotated[StrictFloat, Field(gt=0)]
|
197
|
+
],
|
206
198
|
] = None,
|
207
199
|
_request_auth: Optional[Dict[StrictStr, Any]] = None,
|
208
200
|
_content_type: Optional[StrictStr] = None,
|
@@ -238,7 +230,7 @@ class TradingActionsApi:
|
|
238
230
|
in the spec for a single request.
|
239
231
|
:type _host_index: int, optional
|
240
232
|
:return: Returns the result object.
|
241
|
-
"""
|
233
|
+
""" # noqa: E501
|
242
234
|
|
243
235
|
_param = self._get_actions_serialize(
|
244
236
|
limit=limit,
|
@@ -247,20 +239,18 @@ class TradingActionsApi:
|
|
247
239
|
_request_auth=_request_auth,
|
248
240
|
_content_type=_content_type,
|
249
241
|
_headers=_headers,
|
250
|
-
_host_index=_host_index
|
242
|
+
_host_index=_host_index,
|
251
243
|
)
|
252
244
|
|
253
245
|
_response_types_map: Dict[str, Optional[str]] = {
|
254
|
-
|
255
|
-
|
246
|
+
"200": "List[ActionModel]",
|
247
|
+
"422": "HTTPValidationError",
|
256
248
|
}
|
257
|
-
response_data = self.api_client.call_api(
|
258
|
-
*_param,
|
259
|
-
_request_timeout=_request_timeout
|
249
|
+
response_data = await self.api_client.call_api(
|
250
|
+
*_param, _request_timeout=_request_timeout
|
260
251
|
)
|
261
252
|
return response_data.response
|
262
253
|
|
263
|
-
|
264
254
|
def _get_actions_serialize(
|
265
255
|
self,
|
266
256
|
limit,
|
@@ -274,8 +264,7 @@ class TradingActionsApi:
|
|
274
264
|
|
275
265
|
_host = None
|
276
266
|
|
277
|
-
_collection_formats: Dict[str, str] = {
|
278
|
-
}
|
267
|
+
_collection_formats: Dict[str, str] = {}
|
279
268
|
|
280
269
|
_path_params: Dict[str, str] = {}
|
281
270
|
_query_params: List[Tuple[str, str]] = []
|
@@ -289,35 +278,29 @@ class TradingActionsApi:
|
|
289
278
|
# process the path parameters
|
290
279
|
# process the query parameters
|
291
280
|
if limit is not None:
|
292
|
-
|
293
|
-
_query_params.append((
|
294
|
-
|
281
|
+
|
282
|
+
_query_params.append(("limit", limit))
|
283
|
+
|
295
284
|
if offset is not None:
|
296
|
-
|
297
|
-
_query_params.append((
|
298
|
-
|
285
|
+
|
286
|
+
_query_params.append(("offset", offset))
|
287
|
+
|
299
288
|
# process the header parameters
|
300
289
|
# process the form parameters
|
301
290
|
# process the body parameter
|
302
291
|
|
303
|
-
|
304
292
|
# set the HTTP header `Accept`
|
305
|
-
if
|
306
|
-
_header_params[
|
307
|
-
[
|
308
|
-
'application/json'
|
309
|
-
]
|
293
|
+
if "Accept" not in _header_params:
|
294
|
+
_header_params["Accept"] = self.api_client.select_header_accept(
|
295
|
+
["application/json"]
|
310
296
|
)
|
311
297
|
|
312
|
-
|
313
298
|
# authentication setting
|
314
|
-
_auth_settings: List[str] = [
|
315
|
-
'OAuth2PasswordBearer'
|
316
|
-
]
|
299
|
+
_auth_settings: List[str] = ["APIKeyHeader", "HTTPBearer"]
|
317
300
|
|
318
301
|
return self.api_client.param_serialize(
|
319
|
-
method=
|
320
|
-
resource_path=
|
302
|
+
method="GET",
|
303
|
+
resource_path="/actions",
|
321
304
|
path_params=_path_params,
|
322
305
|
query_params=_query_params,
|
323
306
|
header_params=_header_params,
|
@@ -327,24 +310,19 @@ class TradingActionsApi:
|
|
327
310
|
auth_settings=_auth_settings,
|
328
311
|
collection_formats=_collection_formats,
|
329
312
|
_host=_host,
|
330
|
-
_request_auth=_request_auth
|
313
|
+
_request_auth=_request_auth,
|
331
314
|
)
|
332
315
|
|
333
|
-
|
334
|
-
|
335
|
-
|
336
316
|
@validate_call
|
337
|
-
def post_futures_action(
|
317
|
+
async def post_futures_action(
|
338
318
|
self,
|
339
319
|
futures_trading_action: FuturesTradingAction,
|
340
|
-
authorization: Optional[StrictStr] = None,
|
341
320
|
_request_timeout: Union[
|
342
321
|
None,
|
343
322
|
Annotated[StrictFloat, Field(gt=0)],
|
344
323
|
Tuple[
|
345
|
-
Annotated[StrictFloat, Field(gt=0)],
|
346
|
-
|
347
|
-
]
|
324
|
+
Annotated[StrictFloat, Field(gt=0)], Annotated[StrictFloat, Field(gt=0)]
|
325
|
+
],
|
348
326
|
] = None,
|
349
327
|
_request_auth: Optional[Dict[StrictStr, Any]] = None,
|
350
328
|
_content_type: Optional[StrictStr] = None,
|
@@ -357,8 +335,6 @@ class TradingActionsApi:
|
|
357
335
|
|
358
336
|
:param futures_trading_action: (required)
|
359
337
|
:type futures_trading_action: FuturesTradingAction
|
360
|
-
:param authorization:
|
361
|
-
:type authorization: str
|
362
338
|
:param _request_timeout: timeout setting for this request. If one
|
363
339
|
number provided, it will be total request
|
364
340
|
timeout. It can also be a pair (tuple) of
|
@@ -379,44 +355,39 @@ class TradingActionsApi:
|
|
379
355
|
in the spec for a single request.
|
380
356
|
:type _host_index: int, optional
|
381
357
|
:return: Returns the result object.
|
382
|
-
"""
|
358
|
+
""" # noqa: E501
|
383
359
|
|
384
360
|
_param = self._post_futures_action_serialize(
|
385
361
|
futures_trading_action=futures_trading_action,
|
386
|
-
authorization=authorization,
|
387
362
|
_request_auth=_request_auth,
|
388
363
|
_content_type=_content_type,
|
389
364
|
_headers=_headers,
|
390
|
-
_host_index=_host_index
|
365
|
+
_host_index=_host_index,
|
391
366
|
)
|
392
367
|
|
393
368
|
_response_types_map: Dict[str, Optional[str]] = {
|
394
|
-
|
395
|
-
|
369
|
+
"200": "PostFuturesAction",
|
370
|
+
"422": "HTTPValidationError",
|
396
371
|
}
|
397
|
-
response_data = self.api_client.call_api(
|
398
|
-
*_param,
|
399
|
-
_request_timeout=_request_timeout
|
372
|
+
response_data = await self.api_client.call_api(
|
373
|
+
*_param, _request_timeout=_request_timeout
|
400
374
|
)
|
401
|
-
response_data.read()
|
375
|
+
await response_data.read()
|
402
376
|
return self.api_client.response_deserialize(
|
403
377
|
response_data=response_data,
|
404
378
|
response_types_map=_response_types_map,
|
405
379
|
).data
|
406
380
|
|
407
|
-
|
408
381
|
@validate_call
|
409
|
-
def post_futures_action_with_http_info(
|
382
|
+
async def post_futures_action_with_http_info(
|
410
383
|
self,
|
411
384
|
futures_trading_action: FuturesTradingAction,
|
412
|
-
authorization: Optional[StrictStr] = None,
|
413
385
|
_request_timeout: Union[
|
414
386
|
None,
|
415
387
|
Annotated[StrictFloat, Field(gt=0)],
|
416
388
|
Tuple[
|
417
|
-
Annotated[StrictFloat, Field(gt=0)],
|
418
|
-
|
419
|
-
]
|
389
|
+
Annotated[StrictFloat, Field(gt=0)], Annotated[StrictFloat, Field(gt=0)]
|
390
|
+
],
|
420
391
|
] = None,
|
421
392
|
_request_auth: Optional[Dict[StrictStr, Any]] = None,
|
422
393
|
_content_type: Optional[StrictStr] = None,
|
@@ -429,8 +400,6 @@ class TradingActionsApi:
|
|
429
400
|
|
430
401
|
:param futures_trading_action: (required)
|
431
402
|
:type futures_trading_action: FuturesTradingAction
|
432
|
-
:param authorization:
|
433
|
-
:type authorization: str
|
434
403
|
:param _request_timeout: timeout setting for this request. If one
|
435
404
|
number provided, it will be total request
|
436
405
|
timeout. It can also be a pair (tuple) of
|
@@ -451,44 +420,39 @@ class TradingActionsApi:
|
|
451
420
|
in the spec for a single request.
|
452
421
|
:type _host_index: int, optional
|
453
422
|
:return: Returns the result object.
|
454
|
-
"""
|
423
|
+
""" # noqa: E501
|
455
424
|
|
456
425
|
_param = self._post_futures_action_serialize(
|
457
426
|
futures_trading_action=futures_trading_action,
|
458
|
-
authorization=authorization,
|
459
427
|
_request_auth=_request_auth,
|
460
428
|
_content_type=_content_type,
|
461
429
|
_headers=_headers,
|
462
|
-
_host_index=_host_index
|
430
|
+
_host_index=_host_index,
|
463
431
|
)
|
464
432
|
|
465
433
|
_response_types_map: Dict[str, Optional[str]] = {
|
466
|
-
|
467
|
-
|
434
|
+
"200": "PostFuturesAction",
|
435
|
+
"422": "HTTPValidationError",
|
468
436
|
}
|
469
|
-
response_data = self.api_client.call_api(
|
470
|
-
*_param,
|
471
|
-
_request_timeout=_request_timeout
|
437
|
+
response_data = await self.api_client.call_api(
|
438
|
+
*_param, _request_timeout=_request_timeout
|
472
439
|
)
|
473
|
-
response_data.read()
|
440
|
+
await response_data.read()
|
474
441
|
return self.api_client.response_deserialize(
|
475
442
|
response_data=response_data,
|
476
443
|
response_types_map=_response_types_map,
|
477
444
|
)
|
478
445
|
|
479
|
-
|
480
446
|
@validate_call
|
481
|
-
def post_futures_action_without_preload_content(
|
447
|
+
async def post_futures_action_without_preload_content(
|
482
448
|
self,
|
483
449
|
futures_trading_action: FuturesTradingAction,
|
484
|
-
authorization: Optional[StrictStr] = None,
|
485
450
|
_request_timeout: Union[
|
486
451
|
None,
|
487
452
|
Annotated[StrictFloat, Field(gt=0)],
|
488
453
|
Tuple[
|
489
|
-
Annotated[StrictFloat, Field(gt=0)],
|
490
|
-
|
491
|
-
]
|
454
|
+
Annotated[StrictFloat, Field(gt=0)], Annotated[StrictFloat, Field(gt=0)]
|
455
|
+
],
|
492
456
|
] = None,
|
493
457
|
_request_auth: Optional[Dict[StrictStr, Any]] = None,
|
494
458
|
_content_type: Optional[StrictStr] = None,
|
@@ -501,8 +465,6 @@ class TradingActionsApi:
|
|
501
465
|
|
502
466
|
:param futures_trading_action: (required)
|
503
467
|
:type futures_trading_action: FuturesTradingAction
|
504
|
-
:param authorization:
|
505
|
-
:type authorization: str
|
506
468
|
:param _request_timeout: timeout setting for this request. If one
|
507
469
|
number provided, it will be total request
|
508
470
|
timeout. It can also be a pair (tuple) of
|
@@ -523,32 +485,28 @@ class TradingActionsApi:
|
|
523
485
|
in the spec for a single request.
|
524
486
|
:type _host_index: int, optional
|
525
487
|
:return: Returns the result object.
|
526
|
-
"""
|
488
|
+
""" # noqa: E501
|
527
489
|
|
528
490
|
_param = self._post_futures_action_serialize(
|
529
491
|
futures_trading_action=futures_trading_action,
|
530
|
-
authorization=authorization,
|
531
492
|
_request_auth=_request_auth,
|
532
493
|
_content_type=_content_type,
|
533
494
|
_headers=_headers,
|
534
|
-
_host_index=_host_index
|
495
|
+
_host_index=_host_index,
|
535
496
|
)
|
536
497
|
|
537
498
|
_response_types_map: Dict[str, Optional[str]] = {
|
538
|
-
|
539
|
-
|
499
|
+
"200": "PostFuturesAction",
|
500
|
+
"422": "HTTPValidationError",
|
540
501
|
}
|
541
|
-
response_data = self.api_client.call_api(
|
542
|
-
*_param,
|
543
|
-
_request_timeout=_request_timeout
|
502
|
+
response_data = await self.api_client.call_api(
|
503
|
+
*_param, _request_timeout=_request_timeout
|
544
504
|
)
|
545
505
|
return response_data.response
|
546
506
|
|
547
|
-
|
548
507
|
def _post_futures_action_serialize(
|
549
508
|
self,
|
550
509
|
futures_trading_action,
|
551
|
-
authorization,
|
552
510
|
_request_auth,
|
553
511
|
_content_type,
|
554
512
|
_headers,
|
@@ -557,8 +515,7 @@ class TradingActionsApi:
|
|
557
515
|
|
558
516
|
_host = None
|
559
517
|
|
560
|
-
_collection_formats: Dict[str, str] = {
|
561
|
-
}
|
518
|
+
_collection_formats: Dict[str, str] = {}
|
562
519
|
|
563
520
|
_path_params: Dict[str, str] = {}
|
564
521
|
_query_params: List[Tuple[str, str]] = []
|
@@ -572,43 +529,33 @@ class TradingActionsApi:
|
|
572
529
|
# process the path parameters
|
573
530
|
# process the query parameters
|
574
531
|
# process the header parameters
|
575
|
-
if authorization is not None:
|
576
|
-
_header_params['authorization'] = authorization
|
577
532
|
# process the form parameters
|
578
533
|
# process the body parameter
|
579
534
|
if futures_trading_action is not None:
|
580
535
|
_body_params = futures_trading_action
|
581
536
|
|
582
|
-
|
583
537
|
# set the HTTP header `Accept`
|
584
|
-
if
|
585
|
-
_header_params[
|
586
|
-
[
|
587
|
-
'application/json'
|
588
|
-
]
|
538
|
+
if "Accept" not in _header_params:
|
539
|
+
_header_params["Accept"] = self.api_client.select_header_accept(
|
540
|
+
["application/json"]
|
589
541
|
)
|
590
542
|
|
591
543
|
# set the HTTP header `Content-Type`
|
592
544
|
if _content_type:
|
593
|
-
_header_params[
|
545
|
+
_header_params["Content-Type"] = _content_type
|
594
546
|
else:
|
595
|
-
_default_content_type = (
|
596
|
-
|
597
|
-
[
|
598
|
-
'application/json'
|
599
|
-
]
|
600
|
-
)
|
547
|
+
_default_content_type = self.api_client.select_header_content_type(
|
548
|
+
["application/json"]
|
601
549
|
)
|
602
550
|
if _default_content_type is not None:
|
603
|
-
_header_params[
|
551
|
+
_header_params["Content-Type"] = _default_content_type
|
604
552
|
|
605
553
|
# authentication setting
|
606
|
-
_auth_settings: List[str] = [
|
607
|
-
]
|
554
|
+
_auth_settings: List[str] = ["APIKeyHeader"]
|
608
555
|
|
609
556
|
return self.api_client.param_serialize(
|
610
|
-
method=
|
611
|
-
resource_path=
|
557
|
+
method="POST",
|
558
|
+
resource_path="/actions/futures",
|
612
559
|
path_params=_path_params,
|
613
560
|
query_params=_query_params,
|
614
561
|
header_params=_header_params,
|
@@ -618,23 +565,19 @@ class TradingActionsApi:
|
|
618
565
|
auth_settings=_auth_settings,
|
619
566
|
collection_formats=_collection_formats,
|
620
567
|
_host=_host,
|
621
|
-
_request_auth=_request_auth
|
568
|
+
_request_auth=_request_auth,
|
622
569
|
)
|
623
570
|
|
624
|
-
|
625
|
-
|
626
|
-
|
627
571
|
@validate_call
|
628
|
-
def post_spot_action(
|
572
|
+
async def post_spot_action(
|
629
573
|
self,
|
630
574
|
futures_trading_action: FuturesTradingAction,
|
631
575
|
_request_timeout: Union[
|
632
576
|
None,
|
633
577
|
Annotated[StrictFloat, Field(gt=0)],
|
634
578
|
Tuple[
|
635
|
-
Annotated[StrictFloat, Field(gt=0)],
|
636
|
-
|
637
|
-
]
|
579
|
+
Annotated[StrictFloat, Field(gt=0)], Annotated[StrictFloat, Field(gt=0)]
|
580
|
+
],
|
638
581
|
] = None,
|
639
582
|
_request_auth: Optional[Dict[StrictStr, Any]] = None,
|
640
583
|
_content_type: Optional[StrictStr] = None,
|
@@ -666,42 +609,39 @@ class TradingActionsApi:
|
|
666
609
|
in the spec for a single request.
|
667
610
|
:type _host_index: int, optional
|
668
611
|
:return: Returns the result object.
|
669
|
-
"""
|
612
|
+
""" # noqa: E501
|
670
613
|
|
671
614
|
_param = self._post_spot_action_serialize(
|
672
615
|
futures_trading_action=futures_trading_action,
|
673
616
|
_request_auth=_request_auth,
|
674
617
|
_content_type=_content_type,
|
675
618
|
_headers=_headers,
|
676
|
-
_host_index=_host_index
|
619
|
+
_host_index=_host_index,
|
677
620
|
)
|
678
621
|
|
679
622
|
_response_types_map: Dict[str, Optional[str]] = {
|
680
|
-
|
681
|
-
|
623
|
+
"200": "object",
|
624
|
+
"422": "HTTPValidationError",
|
682
625
|
}
|
683
|
-
response_data = self.api_client.call_api(
|
684
|
-
*_param,
|
685
|
-
_request_timeout=_request_timeout
|
626
|
+
response_data = await self.api_client.call_api(
|
627
|
+
*_param, _request_timeout=_request_timeout
|
686
628
|
)
|
687
|
-
response_data.read()
|
629
|
+
await response_data.read()
|
688
630
|
return self.api_client.response_deserialize(
|
689
631
|
response_data=response_data,
|
690
632
|
response_types_map=_response_types_map,
|
691
633
|
).data
|
692
634
|
|
693
|
-
|
694
635
|
@validate_call
|
695
|
-
def post_spot_action_with_http_info(
|
636
|
+
async def post_spot_action_with_http_info(
|
696
637
|
self,
|
697
638
|
futures_trading_action: FuturesTradingAction,
|
698
639
|
_request_timeout: Union[
|
699
640
|
None,
|
700
641
|
Annotated[StrictFloat, Field(gt=0)],
|
701
642
|
Tuple[
|
702
|
-
Annotated[StrictFloat, Field(gt=0)],
|
703
|
-
|
704
|
-
]
|
643
|
+
Annotated[StrictFloat, Field(gt=0)], Annotated[StrictFloat, Field(gt=0)]
|
644
|
+
],
|
705
645
|
] = None,
|
706
646
|
_request_auth: Optional[Dict[StrictStr, Any]] = None,
|
707
647
|
_content_type: Optional[StrictStr] = None,
|
@@ -733,42 +673,39 @@ class TradingActionsApi:
|
|
733
673
|
in the spec for a single request.
|
734
674
|
:type _host_index: int, optional
|
735
675
|
:return: Returns the result object.
|
736
|
-
"""
|
676
|
+
""" # noqa: E501
|
737
677
|
|
738
678
|
_param = self._post_spot_action_serialize(
|
739
679
|
futures_trading_action=futures_trading_action,
|
740
680
|
_request_auth=_request_auth,
|
741
681
|
_content_type=_content_type,
|
742
682
|
_headers=_headers,
|
743
|
-
_host_index=_host_index
|
683
|
+
_host_index=_host_index,
|
744
684
|
)
|
745
685
|
|
746
686
|
_response_types_map: Dict[str, Optional[str]] = {
|
747
|
-
|
748
|
-
|
687
|
+
"200": "object",
|
688
|
+
"422": "HTTPValidationError",
|
749
689
|
}
|
750
|
-
response_data = self.api_client.call_api(
|
751
|
-
*_param,
|
752
|
-
_request_timeout=_request_timeout
|
690
|
+
response_data = await self.api_client.call_api(
|
691
|
+
*_param, _request_timeout=_request_timeout
|
753
692
|
)
|
754
|
-
response_data.read()
|
693
|
+
await response_data.read()
|
755
694
|
return self.api_client.response_deserialize(
|
756
695
|
response_data=response_data,
|
757
696
|
response_types_map=_response_types_map,
|
758
697
|
)
|
759
698
|
|
760
|
-
|
761
699
|
@validate_call
|
762
|
-
def post_spot_action_without_preload_content(
|
700
|
+
async def post_spot_action_without_preload_content(
|
763
701
|
self,
|
764
702
|
futures_trading_action: FuturesTradingAction,
|
765
703
|
_request_timeout: Union[
|
766
704
|
None,
|
767
705
|
Annotated[StrictFloat, Field(gt=0)],
|
768
706
|
Tuple[
|
769
|
-
Annotated[StrictFloat, Field(gt=0)],
|
770
|
-
|
771
|
-
]
|
707
|
+
Annotated[StrictFloat, Field(gt=0)], Annotated[StrictFloat, Field(gt=0)]
|
708
|
+
],
|
772
709
|
] = None,
|
773
710
|
_request_auth: Optional[Dict[StrictStr, Any]] = None,
|
774
711
|
_content_type: Optional[StrictStr] = None,
|
@@ -800,27 +737,25 @@ class TradingActionsApi:
|
|
800
737
|
in the spec for a single request.
|
801
738
|
:type _host_index: int, optional
|
802
739
|
:return: Returns the result object.
|
803
|
-
"""
|
740
|
+
""" # noqa: E501
|
804
741
|
|
805
742
|
_param = self._post_spot_action_serialize(
|
806
743
|
futures_trading_action=futures_trading_action,
|
807
744
|
_request_auth=_request_auth,
|
808
745
|
_content_type=_content_type,
|
809
746
|
_headers=_headers,
|
810
|
-
_host_index=_host_index
|
747
|
+
_host_index=_host_index,
|
811
748
|
)
|
812
749
|
|
813
750
|
_response_types_map: Dict[str, Optional[str]] = {
|
814
|
-
|
815
|
-
|
751
|
+
"200": "object",
|
752
|
+
"422": "HTTPValidationError",
|
816
753
|
}
|
817
|
-
response_data = self.api_client.call_api(
|
818
|
-
*_param,
|
819
|
-
_request_timeout=_request_timeout
|
754
|
+
response_data = await self.api_client.call_api(
|
755
|
+
*_param, _request_timeout=_request_timeout
|
820
756
|
)
|
821
757
|
return response_data.response
|
822
758
|
|
823
|
-
|
824
759
|
def _post_spot_action_serialize(
|
825
760
|
self,
|
826
761
|
futures_trading_action,
|
@@ -832,8 +767,7 @@ class TradingActionsApi:
|
|
832
767
|
|
833
768
|
_host = None
|
834
769
|
|
835
|
-
_collection_formats: Dict[str, str] = {
|
836
|
-
}
|
770
|
+
_collection_formats: Dict[str, str] = {}
|
837
771
|
|
838
772
|
_path_params: Dict[str, str] = {}
|
839
773
|
_query_params: List[Tuple[str, str]] = []
|
@@ -852,37 +786,28 @@ class TradingActionsApi:
|
|
852
786
|
if futures_trading_action is not None:
|
853
787
|
_body_params = futures_trading_action
|
854
788
|
|
855
|
-
|
856
789
|
# set the HTTP header `Accept`
|
857
|
-
if
|
858
|
-
_header_params[
|
859
|
-
[
|
860
|
-
'application/json'
|
861
|
-
]
|
790
|
+
if "Accept" not in _header_params:
|
791
|
+
_header_params["Accept"] = self.api_client.select_header_accept(
|
792
|
+
["application/json"]
|
862
793
|
)
|
863
794
|
|
864
795
|
# set the HTTP header `Content-Type`
|
865
796
|
if _content_type:
|
866
|
-
_header_params[
|
797
|
+
_header_params["Content-Type"] = _content_type
|
867
798
|
else:
|
868
|
-
_default_content_type = (
|
869
|
-
|
870
|
-
[
|
871
|
-
'application/json'
|
872
|
-
]
|
873
|
-
)
|
799
|
+
_default_content_type = self.api_client.select_header_content_type(
|
800
|
+
["application/json"]
|
874
801
|
)
|
875
802
|
if _default_content_type is not None:
|
876
|
-
_header_params[
|
803
|
+
_header_params["Content-Type"] = _default_content_type
|
877
804
|
|
878
805
|
# authentication setting
|
879
|
-
_auth_settings: List[str] = [
|
880
|
-
'OAuth2PasswordBearer'
|
881
|
-
]
|
806
|
+
_auth_settings: List[str] = ["APIKeyHeader"]
|
882
807
|
|
883
808
|
return self.api_client.param_serialize(
|
884
|
-
method=
|
885
|
-
resource_path=
|
809
|
+
method="POST",
|
810
|
+
resource_path="/actions/spot",
|
886
811
|
path_params=_path_params,
|
887
812
|
query_params=_query_params,
|
888
813
|
header_params=_header_params,
|
@@ -892,7 +817,5 @@ class TradingActionsApi:
|
|
892
817
|
auth_settings=_auth_settings,
|
893
818
|
collection_formats=_collection_formats,
|
894
819
|
_host=_host,
|
895
|
-
_request_auth=_request_auth
|
820
|
+
_request_auth=_request_auth,
|
896
821
|
)
|
897
|
-
|
898
|
-
|