crypticorn 2.15.0__py3-none-any.whl → 2.17.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 +2 -2
- crypticorn/auth/client/api/admin_api.py +397 -13
- crypticorn/auth/client/api/auth_api.py +3610 -341
- crypticorn/auth/client/api/service_api.py +249 -7
- crypticorn/auth/client/api/user_api.py +2295 -179
- crypticorn/auth/client/api/wallet_api.py +1468 -81
- crypticorn/auth/client/configuration.py +2 -2
- crypticorn/auth/client/models/create_api_key_request.py +2 -1
- crypticorn/auth/client/models/get_api_keys200_response_inner.py +2 -1
- crypticorn/auth/client/rest.py +23 -4
- crypticorn/auth/main.py +8 -5
- crypticorn/cli/init.py +1 -1
- crypticorn/cli/templates/.env.docker.temp +3 -0
- crypticorn/cli/templates/.env.example.temp +4 -0
- crypticorn/cli/templates/Dockerfile +5 -2
- crypticorn/client.py +226 -59
- crypticorn/common/__init__.py +1 -0
- crypticorn/common/auth.py +45 -14
- crypticorn/common/decorators.py +1 -2
- crypticorn/common/enums.py +0 -2
- crypticorn/common/errors.py +10 -0
- crypticorn/common/metrics.py +30 -0
- crypticorn/common/middleware.py +94 -1
- crypticorn/common/pagination.py +252 -18
- crypticorn/common/router/admin_router.py +2 -2
- crypticorn/common/router/status_router.py +40 -2
- crypticorn/common/scopes.py +2 -0
- crypticorn/common/warnings.py +8 -0
- crypticorn/dex/__init__.py +6 -0
- crypticorn/dex/client/__init__.py +49 -0
- crypticorn/dex/client/api/__init__.py +6 -0
- crypticorn/dex/client/api/admin_api.py +2986 -0
- crypticorn/dex/client/api/signals_api.py +1798 -0
- crypticorn/dex/client/api/status_api.py +892 -0
- crypticorn/dex/client/api_client.py +758 -0
- crypticorn/dex/client/api_response.py +20 -0
- crypticorn/dex/client/configuration.py +620 -0
- crypticorn/dex/client/exceptions.py +220 -0
- crypticorn/dex/client/models/__init__.py +30 -0
- crypticorn/dex/client/models/api_error_identifier.py +121 -0
- crypticorn/dex/client/models/api_error_level.py +37 -0
- crypticorn/dex/client/models/api_error_type.py +37 -0
- crypticorn/dex/client/models/exception_detail.py +117 -0
- crypticorn/dex/client/models/log_level.py +38 -0
- crypticorn/dex/client/models/paginated_response_signal_with_token.py +134 -0
- crypticorn/dex/client/models/risk.py +86 -0
- crypticorn/dex/client/models/signal_overview_stats.py +158 -0
- crypticorn/dex/client/models/signal_volume.py +84 -0
- crypticorn/dex/client/models/signal_with_token.py +163 -0
- crypticorn/dex/client/models/token_data.py +127 -0
- crypticorn/dex/client/models/token_detail.py +116 -0
- crypticorn/dex/client/py.typed +0 -0
- crypticorn/dex/client/rest.py +217 -0
- crypticorn/dex/main.py +1 -0
- crypticorn/hive/client/api/admin_api.py +1173 -47
- crypticorn/hive/client/api/data_api.py +499 -17
- crypticorn/hive/client/api/models_api.py +1595 -87
- crypticorn/hive/client/api/status_api.py +397 -16
- crypticorn/hive/client/api_client.py +0 -5
- crypticorn/hive/client/models/api_error_identifier.py +1 -1
- crypticorn/hive/client/models/coin_info.py +1 -1
- crypticorn/hive/client/models/exception_detail.py +1 -1
- crypticorn/hive/client/models/target_info.py +1 -1
- crypticorn/hive/client/rest.py +23 -4
- crypticorn/hive/main.py +99 -25
- crypticorn/hive/utils.py +2 -2
- crypticorn/klines/client/api/admin_api.py +1173 -47
- crypticorn/klines/client/api/change_in_timeframe_api.py +269 -11
- crypticorn/klines/client/api/funding_rates_api.py +315 -11
- crypticorn/klines/client/api/ohlcv_data_api.py +390 -11
- crypticorn/klines/client/api/status_api.py +397 -16
- crypticorn/klines/client/api/symbols_api.py +216 -11
- crypticorn/klines/client/api/udf_api.py +1268 -51
- crypticorn/klines/client/api_client.py +0 -5
- crypticorn/klines/client/models/api_error_identifier.py +3 -1
- crypticorn/klines/client/models/exception_detail.py +1 -1
- crypticorn/klines/client/models/ohlcv.py +1 -1
- crypticorn/klines/client/models/symbol_group.py +1 -1
- crypticorn/klines/client/models/udf_config.py +1 -1
- crypticorn/klines/client/rest.py +23 -4
- crypticorn/klines/main.py +89 -12
- crypticorn/metrics/client/api/admin_api.py +1173 -47
- crypticorn/metrics/client/api/exchanges_api.py +1370 -145
- crypticorn/metrics/client/api/indicators_api.py +622 -17
- crypticorn/metrics/client/api/logs_api.py +296 -11
- crypticorn/metrics/client/api/marketcap_api.py +1207 -67
- crypticorn/metrics/client/api/markets_api.py +343 -11
- crypticorn/metrics/client/api/quote_currencies_api.py +228 -11
- crypticorn/metrics/client/api/status_api.py +397 -16
- crypticorn/metrics/client/api/tokens_api.py +382 -15
- crypticorn/metrics/client/api_client.py +0 -5
- crypticorn/metrics/client/configuration.py +4 -2
- crypticorn/metrics/client/models/exception_detail.py +1 -1
- crypticorn/metrics/client/models/exchange_mapping.py +1 -1
- crypticorn/metrics/client/models/marketcap_ranking.py +1 -1
- crypticorn/metrics/client/models/marketcap_symbol_ranking.py +1 -1
- crypticorn/metrics/client/models/ohlcv.py +1 -1
- crypticorn/metrics/client/rest.py +23 -4
- crypticorn/metrics/main.py +113 -19
- crypticorn/pay/client/api/admin_api.py +1585 -57
- crypticorn/pay/client/api/now_payments_api.py +961 -39
- crypticorn/pay/client/api/payments_api.py +562 -17
- crypticorn/pay/client/api/products_api.py +880 -30
- crypticorn/pay/client/api/status_api.py +397 -16
- crypticorn/pay/client/api_client.py +0 -5
- crypticorn/pay/client/configuration.py +2 -2
- crypticorn/pay/client/models/api_error_identifier.py +7 -7
- crypticorn/pay/client/models/exception_detail.py +1 -1
- crypticorn/pay/client/models/now_create_invoice_req.py +1 -1
- crypticorn/pay/client/models/now_create_invoice_res.py +1 -1
- crypticorn/pay/client/models/product.py +1 -1
- crypticorn/pay/client/models/product_create.py +1 -1
- crypticorn/pay/client/models/product_update.py +1 -1
- crypticorn/pay/client/models/scope.py +1 -0
- crypticorn/pay/client/rest.py +23 -4
- crypticorn/pay/main.py +10 -6
- crypticorn/trade/client/__init__.py +11 -1
- crypticorn/trade/client/api/__init__.py +0 -1
- crypticorn/trade/client/api/admin_api.py +1184 -55
- crypticorn/trade/client/api/api_keys_api.py +1678 -162
- crypticorn/trade/client/api/bots_api.py +7563 -187
- crypticorn/trade/client/api/exchanges_api.py +565 -19
- crypticorn/trade/client/api/notifications_api.py +1290 -116
- crypticorn/trade/client/api/orders_api.py +393 -55
- crypticorn/trade/client/api/status_api.py +397 -13
- crypticorn/trade/client/api/strategies_api.py +1133 -77
- crypticorn/trade/client/api/trading_actions_api.py +786 -65
- crypticorn/trade/client/models/__init__.py +11 -0
- crypticorn/trade/client/models/actions_count.py +88 -0
- crypticorn/trade/client/models/api_error_identifier.py +8 -7
- crypticorn/trade/client/models/bot.py +7 -18
- crypticorn/trade/client/models/bot_create.py +17 -1
- crypticorn/trade/client/models/bot_update.py +17 -1
- crypticorn/trade/client/models/exchange.py +6 -1
- crypticorn/trade/client/models/exchange_key.py +1 -1
- crypticorn/trade/client/models/exchange_key_balance.py +111 -0
- crypticorn/trade/client/models/exchange_key_create.py +17 -1
- crypticorn/trade/client/models/exchange_key_update.py +17 -1
- crypticorn/trade/client/models/execution_ids.py +1 -1
- crypticorn/trade/client/models/futures_balance.py +27 -25
- crypticorn/trade/client/models/futures_trading_action.py +6 -28
- crypticorn/trade/client/models/futures_trading_action_create.py +10 -13
- crypticorn/trade/client/models/notification.py +17 -1
- crypticorn/trade/client/models/notification_create.py +18 -2
- crypticorn/trade/client/models/notification_update.py +17 -1
- crypticorn/trade/client/models/order.py +2 -14
- crypticorn/trade/client/models/orders_count.py +88 -0
- crypticorn/trade/client/models/paginated_response_futures_trading_action.py +134 -0
- crypticorn/trade/client/models/paginated_response_order.py +134 -0
- crypticorn/trade/client/models/pn_l.py +95 -0
- crypticorn/trade/client/models/post_futures_action.py +1 -1
- crypticorn/trade/client/models/spot_balance.py +109 -0
- crypticorn/trade/client/models/spot_trading_action_create.py +4 -1
- crypticorn/trade/client/models/strategy.py +22 -4
- crypticorn/trade/client/models/strategy_create.py +23 -5
- crypticorn/trade/client/models/strategy_exchange_info.py +16 -4
- crypticorn/trade/client/models/strategy_update.py +19 -3
- crypticorn/trade/client/models/tpsl.py +4 -27
- crypticorn/trade/client/models/tpsl_create.py +6 -19
- crypticorn/trade/client/rest.py +23 -4
- crypticorn/trade/main.py +15 -12
- {crypticorn-2.15.0.dist-info → crypticorn-2.17.0.dist-info}/METADATA +65 -20
- {crypticorn-2.15.0.dist-info → crypticorn-2.17.0.dist-info}/RECORD +167 -132
- crypticorn/trade/client/api/futures_trading_panel_api.py +0 -1285
- {crypticorn-2.15.0.dist-info → crypticorn-2.17.0.dist-info}/WHEEL +0 -0
- {crypticorn-2.15.0.dist-info → crypticorn-2.17.0.dist-info}/entry_points.txt +0 -0
- {crypticorn-2.15.0.dist-info → crypticorn-2.17.0.dist-info}/licenses/LICENSE +0 -0
- {crypticorn-2.15.0.dist-info → crypticorn-2.17.0.dist-info}/top_level.txt +0 -0
@@ -23,6 +23,24 @@ from crypticorn.trade.client.api_client import ApiClient, RequestSerialized
|
|
23
23
|
from crypticorn.trade.client.api_response import ApiResponse
|
24
24
|
from crypticorn.trade.client.rest import RESTResponseType
|
25
25
|
|
26
|
+
# Import async_to_sync for sync methods
|
27
|
+
try:
|
28
|
+
from asgiref.sync import async_to_sync
|
29
|
+
|
30
|
+
_HAS_ASGIREF = True
|
31
|
+
except ImportError:
|
32
|
+
_HAS_ASGIREF = False
|
33
|
+
|
34
|
+
def async_to_sync(async_func):
|
35
|
+
"""Fallback decorator that raises an error if asgiref is not available."""
|
36
|
+
|
37
|
+
def wrapper(*args, **kwargs):
|
38
|
+
raise ImportError(
|
39
|
+
"asgiref is required for sync methods. Install with: pip install asgiref"
|
40
|
+
)
|
41
|
+
|
42
|
+
return wrapper
|
43
|
+
|
26
44
|
|
27
45
|
class StatusApi:
|
28
46
|
"""NOTE: This class is auto generated by OpenAPI Generator
|
@@ -31,13 +49,126 @@ class StatusApi:
|
|
31
49
|
Do not edit the class manually.
|
32
50
|
"""
|
33
51
|
|
34
|
-
def __init__(self, api_client=None) -> None:
|
52
|
+
def __init__(self, api_client=None, is_sync: bool = False) -> None:
|
35
53
|
if api_client is None:
|
36
54
|
api_client = ApiClient.get_default()
|
37
55
|
self.api_client = api_client
|
56
|
+
self.is_sync = is_sync
|
57
|
+
|
58
|
+
@validate_call
|
59
|
+
def get_time(
|
60
|
+
self,
|
61
|
+
type: Optional[StrictStr] = None,
|
62
|
+
_request_timeout: Union[
|
63
|
+
None,
|
64
|
+
Annotated[StrictFloat, Field(gt=0)],
|
65
|
+
Tuple[
|
66
|
+
Annotated[StrictFloat, Field(gt=0)], Annotated[StrictFloat, Field(gt=0)]
|
67
|
+
],
|
68
|
+
] = None,
|
69
|
+
_request_auth: Optional[Dict[StrictStr, Any]] = None,
|
70
|
+
_content_type: Optional[StrictStr] = None,
|
71
|
+
_headers: Optional[Dict[StrictStr, Any]] = None,
|
72
|
+
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
|
73
|
+
) -> str:
|
74
|
+
"""Time"""
|
75
|
+
if self.is_sync:
|
76
|
+
return self._get_time_sync(
|
77
|
+
type=type,
|
78
|
+
_request_timeout=_request_timeout,
|
79
|
+
_request_auth=_request_auth,
|
80
|
+
_content_type=_content_type,
|
81
|
+
_headers=_headers,
|
82
|
+
_host_index=_host_index,
|
83
|
+
)
|
84
|
+
|
85
|
+
else:
|
86
|
+
return self._get_time_async(
|
87
|
+
type=type,
|
88
|
+
_request_timeout=_request_timeout,
|
89
|
+
_request_auth=_request_auth,
|
90
|
+
_content_type=_content_type,
|
91
|
+
_headers=_headers,
|
92
|
+
_host_index=_host_index,
|
93
|
+
)
|
94
|
+
|
95
|
+
@validate_call
|
96
|
+
def get_time_with_http_info(
|
97
|
+
self,
|
98
|
+
type: Optional[StrictStr] = None,
|
99
|
+
_request_timeout: Union[
|
100
|
+
None,
|
101
|
+
Annotated[StrictFloat, Field(gt=0)],
|
102
|
+
Tuple[
|
103
|
+
Annotated[StrictFloat, Field(gt=0)], Annotated[StrictFloat, Field(gt=0)]
|
104
|
+
],
|
105
|
+
] = None,
|
106
|
+
_request_auth: Optional[Dict[StrictStr, Any]] = None,
|
107
|
+
_content_type: Optional[StrictStr] = None,
|
108
|
+
_headers: Optional[Dict[StrictStr, Any]] = None,
|
109
|
+
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
|
110
|
+
) -> ApiResponse[str]:
|
111
|
+
"""Time with HTTP info"""
|
112
|
+
if self.is_sync:
|
113
|
+
return self._get_time_sync_with_http_info(
|
114
|
+
type=type,
|
115
|
+
_request_timeout=_request_timeout,
|
116
|
+
_request_auth=_request_auth,
|
117
|
+
_content_type=_content_type,
|
118
|
+
_headers=_headers,
|
119
|
+
_host_index=_host_index,
|
120
|
+
)
|
121
|
+
|
122
|
+
else:
|
123
|
+
return self._get_time_async_with_http_info(
|
124
|
+
type=type,
|
125
|
+
_request_timeout=_request_timeout,
|
126
|
+
_request_auth=_request_auth,
|
127
|
+
_content_type=_content_type,
|
128
|
+
_headers=_headers,
|
129
|
+
_host_index=_host_index,
|
130
|
+
)
|
131
|
+
|
132
|
+
@validate_call
|
133
|
+
def get_time_without_preload_content(
|
134
|
+
self,
|
135
|
+
type: Optional[StrictStr] = None,
|
136
|
+
_request_timeout: Union[
|
137
|
+
None,
|
138
|
+
Annotated[StrictFloat, Field(gt=0)],
|
139
|
+
Tuple[
|
140
|
+
Annotated[StrictFloat, Field(gt=0)], Annotated[StrictFloat, Field(gt=0)]
|
141
|
+
],
|
142
|
+
] = None,
|
143
|
+
_request_auth: Optional[Dict[StrictStr, Any]] = None,
|
144
|
+
_content_type: Optional[StrictStr] = None,
|
145
|
+
_headers: Optional[Dict[StrictStr, Any]] = None,
|
146
|
+
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
|
147
|
+
) -> RESTResponseType:
|
148
|
+
"""Time without preloading content"""
|
149
|
+
if self.is_sync:
|
150
|
+
return self._get_time_sync_without_preload_content(
|
151
|
+
type=type,
|
152
|
+
_request_timeout=_request_timeout,
|
153
|
+
_request_auth=_request_auth,
|
154
|
+
_content_type=_content_type,
|
155
|
+
_headers=_headers,
|
156
|
+
_host_index=_host_index,
|
157
|
+
)
|
158
|
+
|
159
|
+
else:
|
160
|
+
return self._get_time_async_without_preload_content(
|
161
|
+
type=type,
|
162
|
+
_request_timeout=_request_timeout,
|
163
|
+
_request_auth=_request_auth,
|
164
|
+
_content_type=_content_type,
|
165
|
+
_headers=_headers,
|
166
|
+
_host_index=_host_index,
|
167
|
+
)
|
38
168
|
|
169
|
+
# Private async implementation methods
|
39
170
|
@validate_call
|
40
|
-
async def
|
171
|
+
async def _get_time_async(
|
41
172
|
self,
|
42
173
|
type: Optional[StrictStr] = None,
|
43
174
|
_request_timeout: Union[
|
@@ -101,7 +232,7 @@ class StatusApi:
|
|
101
232
|
).data
|
102
233
|
|
103
234
|
@validate_call
|
104
|
-
async def
|
235
|
+
async def _get_time_async_with_http_info(
|
105
236
|
self,
|
106
237
|
type: Optional[StrictStr] = None,
|
107
238
|
_request_timeout: Union[
|
@@ -160,12 +291,11 @@ class StatusApi:
|
|
160
291
|
)
|
161
292
|
await response_data.read()
|
162
293
|
return self.api_client.response_deserialize(
|
163
|
-
response_data=response_data,
|
164
|
-
response_types_map=_response_types_map,
|
294
|
+
response_data=response_data, response_types_map=_response_types_map
|
165
295
|
)
|
166
296
|
|
167
297
|
@validate_call
|
168
|
-
async def
|
298
|
+
async def _get_time_async_without_preload_content(
|
169
299
|
self,
|
170
300
|
type: Optional[StrictStr] = None,
|
171
301
|
_request_timeout: Union[
|
@@ -222,7 +352,86 @@ class StatusApi:
|
|
222
352
|
response_data = await self.api_client.call_api(
|
223
353
|
*_param, _request_timeout=_request_timeout
|
224
354
|
)
|
225
|
-
return response_data
|
355
|
+
return response_data
|
356
|
+
|
357
|
+
# Private sync implementation methods
|
358
|
+
@validate_call
|
359
|
+
def _get_time_sync(
|
360
|
+
self,
|
361
|
+
type: Optional[StrictStr] = None,
|
362
|
+
_request_timeout: Union[
|
363
|
+
None,
|
364
|
+
Annotated[StrictFloat, Field(gt=0)],
|
365
|
+
Tuple[
|
366
|
+
Annotated[StrictFloat, Field(gt=0)], Annotated[StrictFloat, Field(gt=0)]
|
367
|
+
],
|
368
|
+
] = None,
|
369
|
+
_request_auth: Optional[Dict[StrictStr, Any]] = None,
|
370
|
+
_content_type: Optional[StrictStr] = None,
|
371
|
+
_headers: Optional[Dict[StrictStr, Any]] = None,
|
372
|
+
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
|
373
|
+
) -> str:
|
374
|
+
"""Synchronous version of get_time"""
|
375
|
+
return async_to_sync(self._get_time_async)(
|
376
|
+
type=type,
|
377
|
+
_request_timeout=_request_timeout,
|
378
|
+
_request_auth=_request_auth,
|
379
|
+
_content_type=_content_type,
|
380
|
+
_headers=_headers,
|
381
|
+
_host_index=_host_index,
|
382
|
+
)
|
383
|
+
|
384
|
+
@validate_call
|
385
|
+
def _get_time_sync_with_http_info(
|
386
|
+
self,
|
387
|
+
type: Optional[StrictStr] = None,
|
388
|
+
_request_timeout: Union[
|
389
|
+
None,
|
390
|
+
Annotated[StrictFloat, Field(gt=0)],
|
391
|
+
Tuple[
|
392
|
+
Annotated[StrictFloat, Field(gt=0)], Annotated[StrictFloat, Field(gt=0)]
|
393
|
+
],
|
394
|
+
] = None,
|
395
|
+
_request_auth: Optional[Dict[StrictStr, Any]] = None,
|
396
|
+
_content_type: Optional[StrictStr] = None,
|
397
|
+
_headers: Optional[Dict[StrictStr, Any]] = None,
|
398
|
+
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
|
399
|
+
) -> ApiResponse[str]:
|
400
|
+
"""Synchronous version of get_time_with_http_info"""
|
401
|
+
return async_to_sync(self._get_time_async_with_http_info)(
|
402
|
+
type=type,
|
403
|
+
_request_timeout=_request_timeout,
|
404
|
+
_request_auth=_request_auth,
|
405
|
+
_content_type=_content_type,
|
406
|
+
_headers=_headers,
|
407
|
+
_host_index=_host_index,
|
408
|
+
)
|
409
|
+
|
410
|
+
@validate_call
|
411
|
+
def _get_time_sync_without_preload_content(
|
412
|
+
self,
|
413
|
+
type: Optional[StrictStr] = None,
|
414
|
+
_request_timeout: Union[
|
415
|
+
None,
|
416
|
+
Annotated[StrictFloat, Field(gt=0)],
|
417
|
+
Tuple[
|
418
|
+
Annotated[StrictFloat, Field(gt=0)], Annotated[StrictFloat, Field(gt=0)]
|
419
|
+
],
|
420
|
+
] = None,
|
421
|
+
_request_auth: Optional[Dict[StrictStr, Any]] = None,
|
422
|
+
_content_type: Optional[StrictStr] = None,
|
423
|
+
_headers: Optional[Dict[StrictStr, Any]] = None,
|
424
|
+
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
|
425
|
+
) -> RESTResponseType:
|
426
|
+
"""Synchronous version of get_time_without_preload_content"""
|
427
|
+
return async_to_sync(self._get_time_async_without_preload_content)(
|
428
|
+
type=type,
|
429
|
+
_request_timeout=_request_timeout,
|
430
|
+
_request_auth=_request_auth,
|
431
|
+
_content_type=_content_type,
|
432
|
+
_headers=_headers,
|
433
|
+
_host_index=_host_index,
|
434
|
+
)
|
226
435
|
|
227
436
|
def _get_time_serialize(
|
228
437
|
self,
|
@@ -281,7 +490,110 @@ class StatusApi:
|
|
281
490
|
)
|
282
491
|
|
283
492
|
@validate_call
|
284
|
-
|
493
|
+
def ping(
|
494
|
+
self,
|
495
|
+
_request_timeout: Union[
|
496
|
+
None,
|
497
|
+
Annotated[StrictFloat, Field(gt=0)],
|
498
|
+
Tuple[
|
499
|
+
Annotated[StrictFloat, Field(gt=0)], Annotated[StrictFloat, Field(gt=0)]
|
500
|
+
],
|
501
|
+
] = None,
|
502
|
+
_request_auth: Optional[Dict[StrictStr, Any]] = None,
|
503
|
+
_content_type: Optional[StrictStr] = None,
|
504
|
+
_headers: Optional[Dict[StrictStr, Any]] = None,
|
505
|
+
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
|
506
|
+
) -> str:
|
507
|
+
"""Ping"""
|
508
|
+
if self.is_sync:
|
509
|
+
return self._ping_sync(
|
510
|
+
_request_timeout=_request_timeout,
|
511
|
+
_request_auth=_request_auth,
|
512
|
+
_content_type=_content_type,
|
513
|
+
_headers=_headers,
|
514
|
+
_host_index=_host_index,
|
515
|
+
)
|
516
|
+
|
517
|
+
else:
|
518
|
+
return self._ping_async(
|
519
|
+
_request_timeout=_request_timeout,
|
520
|
+
_request_auth=_request_auth,
|
521
|
+
_content_type=_content_type,
|
522
|
+
_headers=_headers,
|
523
|
+
_host_index=_host_index,
|
524
|
+
)
|
525
|
+
|
526
|
+
@validate_call
|
527
|
+
def ping_with_http_info(
|
528
|
+
self,
|
529
|
+
_request_timeout: Union[
|
530
|
+
None,
|
531
|
+
Annotated[StrictFloat, Field(gt=0)],
|
532
|
+
Tuple[
|
533
|
+
Annotated[StrictFloat, Field(gt=0)], Annotated[StrictFloat, Field(gt=0)]
|
534
|
+
],
|
535
|
+
] = None,
|
536
|
+
_request_auth: Optional[Dict[StrictStr, Any]] = None,
|
537
|
+
_content_type: Optional[StrictStr] = None,
|
538
|
+
_headers: Optional[Dict[StrictStr, Any]] = None,
|
539
|
+
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
|
540
|
+
) -> ApiResponse[str]:
|
541
|
+
"""Ping with HTTP info"""
|
542
|
+
if self.is_sync:
|
543
|
+
return self._ping_sync_with_http_info(
|
544
|
+
_request_timeout=_request_timeout,
|
545
|
+
_request_auth=_request_auth,
|
546
|
+
_content_type=_content_type,
|
547
|
+
_headers=_headers,
|
548
|
+
_host_index=_host_index,
|
549
|
+
)
|
550
|
+
|
551
|
+
else:
|
552
|
+
return self._ping_async_with_http_info(
|
553
|
+
_request_timeout=_request_timeout,
|
554
|
+
_request_auth=_request_auth,
|
555
|
+
_content_type=_content_type,
|
556
|
+
_headers=_headers,
|
557
|
+
_host_index=_host_index,
|
558
|
+
)
|
559
|
+
|
560
|
+
@validate_call
|
561
|
+
def ping_without_preload_content(
|
562
|
+
self,
|
563
|
+
_request_timeout: Union[
|
564
|
+
None,
|
565
|
+
Annotated[StrictFloat, Field(gt=0)],
|
566
|
+
Tuple[
|
567
|
+
Annotated[StrictFloat, Field(gt=0)], Annotated[StrictFloat, Field(gt=0)]
|
568
|
+
],
|
569
|
+
] = None,
|
570
|
+
_request_auth: Optional[Dict[StrictStr, Any]] = None,
|
571
|
+
_content_type: Optional[StrictStr] = None,
|
572
|
+
_headers: Optional[Dict[StrictStr, Any]] = None,
|
573
|
+
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
|
574
|
+
) -> RESTResponseType:
|
575
|
+
"""Ping without preloading content"""
|
576
|
+
if self.is_sync:
|
577
|
+
return self._ping_sync_without_preload_content(
|
578
|
+
_request_timeout=_request_timeout,
|
579
|
+
_request_auth=_request_auth,
|
580
|
+
_content_type=_content_type,
|
581
|
+
_headers=_headers,
|
582
|
+
_host_index=_host_index,
|
583
|
+
)
|
584
|
+
|
585
|
+
else:
|
586
|
+
return self._ping_async_without_preload_content(
|
587
|
+
_request_timeout=_request_timeout,
|
588
|
+
_request_auth=_request_auth,
|
589
|
+
_content_type=_content_type,
|
590
|
+
_headers=_headers,
|
591
|
+
_host_index=_host_index,
|
592
|
+
)
|
593
|
+
|
594
|
+
# Private async implementation methods
|
595
|
+
@validate_call
|
596
|
+
async def _ping_async(
|
285
597
|
self,
|
286
598
|
_request_timeout: Union[
|
287
599
|
None,
|
@@ -341,7 +653,7 @@ class StatusApi:
|
|
341
653
|
).data
|
342
654
|
|
343
655
|
@validate_call
|
344
|
-
async def
|
656
|
+
async def _ping_async_with_http_info(
|
345
657
|
self,
|
346
658
|
_request_timeout: Union[
|
347
659
|
None,
|
@@ -396,12 +708,11 @@ class StatusApi:
|
|
396
708
|
)
|
397
709
|
await response_data.read()
|
398
710
|
return self.api_client.response_deserialize(
|
399
|
-
response_data=response_data,
|
400
|
-
response_types_map=_response_types_map,
|
711
|
+
response_data=response_data, response_types_map=_response_types_map
|
401
712
|
)
|
402
713
|
|
403
714
|
@validate_call
|
404
|
-
async def
|
715
|
+
async def _ping_async_without_preload_content(
|
405
716
|
self,
|
406
717
|
_request_timeout: Union[
|
407
718
|
None,
|
@@ -454,7 +765,80 @@ class StatusApi:
|
|
454
765
|
response_data = await self.api_client.call_api(
|
455
766
|
*_param, _request_timeout=_request_timeout
|
456
767
|
)
|
457
|
-
return response_data
|
768
|
+
return response_data
|
769
|
+
|
770
|
+
# Private sync implementation methods
|
771
|
+
@validate_call
|
772
|
+
def _ping_sync(
|
773
|
+
self,
|
774
|
+
_request_timeout: Union[
|
775
|
+
None,
|
776
|
+
Annotated[StrictFloat, Field(gt=0)],
|
777
|
+
Tuple[
|
778
|
+
Annotated[StrictFloat, Field(gt=0)], Annotated[StrictFloat, Field(gt=0)]
|
779
|
+
],
|
780
|
+
] = None,
|
781
|
+
_request_auth: Optional[Dict[StrictStr, Any]] = None,
|
782
|
+
_content_type: Optional[StrictStr] = None,
|
783
|
+
_headers: Optional[Dict[StrictStr, Any]] = None,
|
784
|
+
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
|
785
|
+
) -> str:
|
786
|
+
"""Synchronous version of ping"""
|
787
|
+
return async_to_sync(self._ping_async)(
|
788
|
+
_request_timeout=_request_timeout,
|
789
|
+
_request_auth=_request_auth,
|
790
|
+
_content_type=_content_type,
|
791
|
+
_headers=_headers,
|
792
|
+
_host_index=_host_index,
|
793
|
+
)
|
794
|
+
|
795
|
+
@validate_call
|
796
|
+
def _ping_sync_with_http_info(
|
797
|
+
self,
|
798
|
+
_request_timeout: Union[
|
799
|
+
None,
|
800
|
+
Annotated[StrictFloat, Field(gt=0)],
|
801
|
+
Tuple[
|
802
|
+
Annotated[StrictFloat, Field(gt=0)], Annotated[StrictFloat, Field(gt=0)]
|
803
|
+
],
|
804
|
+
] = None,
|
805
|
+
_request_auth: Optional[Dict[StrictStr, Any]] = None,
|
806
|
+
_content_type: Optional[StrictStr] = None,
|
807
|
+
_headers: Optional[Dict[StrictStr, Any]] = None,
|
808
|
+
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
|
809
|
+
) -> ApiResponse[str]:
|
810
|
+
"""Synchronous version of ping_with_http_info"""
|
811
|
+
return async_to_sync(self._ping_async_with_http_info)(
|
812
|
+
_request_timeout=_request_timeout,
|
813
|
+
_request_auth=_request_auth,
|
814
|
+
_content_type=_content_type,
|
815
|
+
_headers=_headers,
|
816
|
+
_host_index=_host_index,
|
817
|
+
)
|
818
|
+
|
819
|
+
@validate_call
|
820
|
+
def _ping_sync_without_preload_content(
|
821
|
+
self,
|
822
|
+
_request_timeout: Union[
|
823
|
+
None,
|
824
|
+
Annotated[StrictFloat, Field(gt=0)],
|
825
|
+
Tuple[
|
826
|
+
Annotated[StrictFloat, Field(gt=0)], Annotated[StrictFloat, Field(gt=0)]
|
827
|
+
],
|
828
|
+
] = None,
|
829
|
+
_request_auth: Optional[Dict[StrictStr, Any]] = None,
|
830
|
+
_content_type: Optional[StrictStr] = None,
|
831
|
+
_headers: Optional[Dict[StrictStr, Any]] = None,
|
832
|
+
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
|
833
|
+
) -> RESTResponseType:
|
834
|
+
"""Synchronous version of ping_without_preload_content"""
|
835
|
+
return async_to_sync(self._ping_async_without_preload_content)(
|
836
|
+
_request_timeout=_request_timeout,
|
837
|
+
_request_auth=_request_auth,
|
838
|
+
_content_type=_content_type,
|
839
|
+
_headers=_headers,
|
840
|
+
_host_index=_host_index,
|
841
|
+
)
|
458
842
|
|
459
843
|
def _ping_serialize(
|
460
844
|
self,
|