crypticorn 2.16.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.
Files changed (164) hide show
  1. crypticorn/__init__.py +2 -2
  2. crypticorn/auth/client/api/admin_api.py +397 -13
  3. crypticorn/auth/client/api/auth_api.py +3610 -341
  4. crypticorn/auth/client/api/service_api.py +249 -7
  5. crypticorn/auth/client/api/user_api.py +2295 -179
  6. crypticorn/auth/client/api/wallet_api.py +1468 -81
  7. crypticorn/auth/client/configuration.py +2 -2
  8. crypticorn/auth/client/models/create_api_key_request.py +2 -1
  9. crypticorn/auth/client/models/get_api_keys200_response_inner.py +2 -1
  10. crypticorn/auth/client/rest.py +23 -4
  11. crypticorn/auth/main.py +8 -5
  12. crypticorn/cli/init.py +1 -1
  13. crypticorn/cli/templates/.env.docker.temp +3 -0
  14. crypticorn/cli/templates/.env.example.temp +4 -0
  15. crypticorn/cli/templates/Dockerfile +5 -2
  16. crypticorn/client.py +226 -59
  17. crypticorn/common/__init__.py +1 -0
  18. crypticorn/common/auth.py +45 -14
  19. crypticorn/common/decorators.py +1 -2
  20. crypticorn/common/enums.py +0 -2
  21. crypticorn/common/errors.py +10 -0
  22. crypticorn/common/metrics.py +30 -0
  23. crypticorn/common/middleware.py +94 -1
  24. crypticorn/common/pagination.py +252 -20
  25. crypticorn/common/router/admin_router.py +2 -2
  26. crypticorn/common/router/status_router.py +40 -2
  27. crypticorn/common/scopes.py +2 -2
  28. crypticorn/common/warnings.py +7 -0
  29. crypticorn/dex/__init__.py +6 -0
  30. crypticorn/dex/client/__init__.py +49 -0
  31. crypticorn/dex/client/api/__init__.py +6 -0
  32. crypticorn/dex/client/api/admin_api.py +2986 -0
  33. crypticorn/dex/client/api/signals_api.py +1798 -0
  34. crypticorn/dex/client/api/status_api.py +892 -0
  35. crypticorn/dex/client/api_client.py +758 -0
  36. crypticorn/dex/client/api_response.py +20 -0
  37. crypticorn/dex/client/configuration.py +620 -0
  38. crypticorn/dex/client/exceptions.py +220 -0
  39. crypticorn/dex/client/models/__init__.py +30 -0
  40. crypticorn/dex/client/models/api_error_identifier.py +121 -0
  41. crypticorn/dex/client/models/api_error_level.py +37 -0
  42. crypticorn/dex/client/models/api_error_type.py +37 -0
  43. crypticorn/dex/client/models/exception_detail.py +117 -0
  44. crypticorn/dex/client/models/log_level.py +38 -0
  45. crypticorn/dex/client/models/paginated_response_signal_with_token.py +134 -0
  46. crypticorn/dex/client/models/risk.py +86 -0
  47. crypticorn/dex/client/models/signal_overview_stats.py +158 -0
  48. crypticorn/dex/client/models/signal_volume.py +84 -0
  49. crypticorn/dex/client/models/signal_with_token.py +163 -0
  50. crypticorn/dex/client/models/token_data.py +127 -0
  51. crypticorn/dex/client/models/token_detail.py +116 -0
  52. crypticorn/dex/client/py.typed +0 -0
  53. crypticorn/dex/client/rest.py +217 -0
  54. crypticorn/dex/main.py +1 -0
  55. crypticorn/hive/client/api/admin_api.py +1173 -47
  56. crypticorn/hive/client/api/data_api.py +499 -17
  57. crypticorn/hive/client/api/models_api.py +1595 -87
  58. crypticorn/hive/client/api/status_api.py +397 -16
  59. crypticorn/hive/client/api_client.py +0 -5
  60. crypticorn/hive/client/models/api_error_identifier.py +1 -1
  61. crypticorn/hive/client/models/coin_info.py +1 -1
  62. crypticorn/hive/client/models/exception_detail.py +1 -1
  63. crypticorn/hive/client/models/target_info.py +1 -1
  64. crypticorn/hive/client/rest.py +23 -4
  65. crypticorn/hive/main.py +99 -25
  66. crypticorn/hive/utils.py +2 -2
  67. crypticorn/klines/client/api/admin_api.py +1173 -47
  68. crypticorn/klines/client/api/change_in_timeframe_api.py +269 -11
  69. crypticorn/klines/client/api/funding_rates_api.py +315 -11
  70. crypticorn/klines/client/api/ohlcv_data_api.py +390 -11
  71. crypticorn/klines/client/api/status_api.py +397 -16
  72. crypticorn/klines/client/api/symbols_api.py +216 -11
  73. crypticorn/klines/client/api/udf_api.py +1268 -51
  74. crypticorn/klines/client/api_client.py +0 -5
  75. crypticorn/klines/client/models/api_error_identifier.py +3 -1
  76. crypticorn/klines/client/models/exception_detail.py +1 -1
  77. crypticorn/klines/client/models/ohlcv.py +1 -1
  78. crypticorn/klines/client/models/symbol_group.py +1 -1
  79. crypticorn/klines/client/models/udf_config.py +1 -1
  80. crypticorn/klines/client/rest.py +23 -4
  81. crypticorn/klines/main.py +89 -12
  82. crypticorn/metrics/client/api/admin_api.py +1173 -47
  83. crypticorn/metrics/client/api/exchanges_api.py +1370 -145
  84. crypticorn/metrics/client/api/indicators_api.py +622 -17
  85. crypticorn/metrics/client/api/logs_api.py +296 -11
  86. crypticorn/metrics/client/api/marketcap_api.py +1207 -67
  87. crypticorn/metrics/client/api/markets_api.py +343 -11
  88. crypticorn/metrics/client/api/quote_currencies_api.py +228 -11
  89. crypticorn/metrics/client/api/status_api.py +397 -16
  90. crypticorn/metrics/client/api/tokens_api.py +382 -15
  91. crypticorn/metrics/client/api_client.py +0 -5
  92. crypticorn/metrics/client/configuration.py +4 -2
  93. crypticorn/metrics/client/models/exception_detail.py +1 -1
  94. crypticorn/metrics/client/models/exchange_mapping.py +1 -1
  95. crypticorn/metrics/client/models/marketcap_ranking.py +1 -1
  96. crypticorn/metrics/client/models/marketcap_symbol_ranking.py +1 -1
  97. crypticorn/metrics/client/models/ohlcv.py +1 -1
  98. crypticorn/metrics/client/rest.py +23 -4
  99. crypticorn/metrics/main.py +113 -19
  100. crypticorn/pay/client/api/admin_api.py +1585 -57
  101. crypticorn/pay/client/api/now_payments_api.py +961 -39
  102. crypticorn/pay/client/api/payments_api.py +562 -17
  103. crypticorn/pay/client/api/products_api.py +880 -30
  104. crypticorn/pay/client/api/status_api.py +397 -16
  105. crypticorn/pay/client/api_client.py +0 -5
  106. crypticorn/pay/client/configuration.py +2 -2
  107. crypticorn/pay/client/models/api_error_identifier.py +7 -7
  108. crypticorn/pay/client/models/exception_detail.py +1 -1
  109. crypticorn/pay/client/models/now_create_invoice_req.py +1 -1
  110. crypticorn/pay/client/models/now_create_invoice_res.py +1 -1
  111. crypticorn/pay/client/models/product.py +1 -1
  112. crypticorn/pay/client/models/product_create.py +1 -1
  113. crypticorn/pay/client/models/product_update.py +1 -1
  114. crypticorn/pay/client/models/scope.py +1 -0
  115. crypticorn/pay/client/rest.py +23 -4
  116. crypticorn/pay/main.py +10 -6
  117. crypticorn/trade/client/__init__.py +11 -1
  118. crypticorn/trade/client/api/__init__.py +0 -1
  119. crypticorn/trade/client/api/admin_api.py +1184 -55
  120. crypticorn/trade/client/api/api_keys_api.py +1678 -162
  121. crypticorn/trade/client/api/bots_api.py +7563 -187
  122. crypticorn/trade/client/api/exchanges_api.py +565 -19
  123. crypticorn/trade/client/api/notifications_api.py +1290 -116
  124. crypticorn/trade/client/api/orders_api.py +393 -55
  125. crypticorn/trade/client/api/status_api.py +397 -13
  126. crypticorn/trade/client/api/strategies_api.py +1133 -77
  127. crypticorn/trade/client/api/trading_actions_api.py +786 -65
  128. crypticorn/trade/client/models/__init__.py +11 -0
  129. crypticorn/trade/client/models/actions_count.py +88 -0
  130. crypticorn/trade/client/models/api_error_identifier.py +1 -0
  131. crypticorn/trade/client/models/bot.py +7 -18
  132. crypticorn/trade/client/models/bot_create.py +17 -1
  133. crypticorn/trade/client/models/bot_update.py +17 -1
  134. crypticorn/trade/client/models/exchange.py +6 -1
  135. crypticorn/trade/client/models/exchange_key.py +1 -1
  136. crypticorn/trade/client/models/exchange_key_balance.py +111 -0
  137. crypticorn/trade/client/models/exchange_key_create.py +17 -1
  138. crypticorn/trade/client/models/exchange_key_update.py +17 -1
  139. crypticorn/trade/client/models/execution_ids.py +1 -1
  140. crypticorn/trade/client/models/futures_balance.py +27 -25
  141. crypticorn/trade/client/models/notification.py +17 -1
  142. crypticorn/trade/client/models/notification_create.py +18 -2
  143. crypticorn/trade/client/models/notification_update.py +17 -1
  144. crypticorn/trade/client/models/orders_count.py +88 -0
  145. crypticorn/trade/client/models/paginated_response_futures_trading_action.py +134 -0
  146. crypticorn/trade/client/models/paginated_response_order.py +134 -0
  147. crypticorn/trade/client/models/pn_l.py +95 -0
  148. crypticorn/trade/client/models/post_futures_action.py +1 -1
  149. crypticorn/trade/client/models/spot_balance.py +109 -0
  150. crypticorn/trade/client/models/strategy.py +22 -4
  151. crypticorn/trade/client/models/strategy_create.py +23 -5
  152. crypticorn/trade/client/models/strategy_exchange_info.py +16 -4
  153. crypticorn/trade/client/models/strategy_update.py +19 -3
  154. crypticorn/trade/client/models/tpsl.py +4 -19
  155. crypticorn/trade/client/models/tpsl_create.py +6 -19
  156. crypticorn/trade/client/rest.py +23 -4
  157. crypticorn/trade/main.py +15 -12
  158. {crypticorn-2.16.0.dist-info → crypticorn-2.17.0.dist-info}/METADATA +65 -20
  159. {crypticorn-2.16.0.dist-info → crypticorn-2.17.0.dist-info}/RECORD +163 -128
  160. crypticorn/trade/client/api/futures_trading_panel_api.py +0 -1285
  161. {crypticorn-2.16.0.dist-info → crypticorn-2.17.0.dist-info}/WHEEL +0 -0
  162. {crypticorn-2.16.0.dist-info → crypticorn-2.17.0.dist-info}/entry_points.txt +0 -0
  163. {crypticorn-2.16.0.dist-info → crypticorn-2.17.0.dist-info}/licenses/LICENSE +0 -0
  164. {crypticorn-2.16.0.dist-info → crypticorn-2.17.0.dist-info}/top_level.txt +0 -0
@@ -27,6 +27,24 @@ from crypticorn.trade.client.api_client import ApiClient, RequestSerialized
27
27
  from crypticorn.trade.client.api_response import ApiResponse
28
28
  from crypticorn.trade.client.rest import RESTResponseType
29
29
 
30
+ # Import async_to_sync for sync methods
31
+ try:
32
+ from asgiref.sync import async_to_sync
33
+
34
+ _HAS_ASGIREF = True
35
+ except ImportError:
36
+ _HAS_ASGIREF = False
37
+
38
+ def async_to_sync(async_func):
39
+ """Fallback decorator that raises an error if asgiref is not available."""
40
+
41
+ def wrapper(*args, **kwargs):
42
+ raise ImportError(
43
+ "asgiref is required for sync methods. Install with: pip install asgiref"
44
+ )
45
+
46
+ return wrapper
47
+
30
48
 
31
49
  class StrategiesApi:
32
50
  """NOTE: This class is auto generated by OpenAPI Generator
@@ -35,13 +53,126 @@ class StrategiesApi:
35
53
  Do not edit the class manually.
36
54
  """
37
55
 
38
- def __init__(self, api_client=None) -> None:
56
+ def __init__(self, api_client=None, is_sync: bool = False) -> None:
39
57
  if api_client is None:
40
58
  api_client = ApiClient.get_default()
41
59
  self.api_client = api_client
60
+ self.is_sync = is_sync
61
+
62
+ @validate_call
63
+ def create_strategy(
64
+ self,
65
+ strategy_create: StrategyCreate,
66
+ _request_timeout: Union[
67
+ None,
68
+ Annotated[StrictFloat, Field(gt=0)],
69
+ Tuple[
70
+ Annotated[StrictFloat, Field(gt=0)], Annotated[StrictFloat, Field(gt=0)]
71
+ ],
72
+ ] = None,
73
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
74
+ _content_type: Optional[StrictStr] = None,
75
+ _headers: Optional[Dict[StrictStr, Any]] = None,
76
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
77
+ ) -> Strategy:
78
+ """Create Strategy"""
79
+ if self.is_sync:
80
+ return self._create_strategy_sync(
81
+ strategy_create=strategy_create,
82
+ _request_timeout=_request_timeout,
83
+ _request_auth=_request_auth,
84
+ _content_type=_content_type,
85
+ _headers=_headers,
86
+ _host_index=_host_index,
87
+ )
88
+
89
+ else:
90
+ return self._create_strategy_async(
91
+ strategy_create=strategy_create,
92
+ _request_timeout=_request_timeout,
93
+ _request_auth=_request_auth,
94
+ _content_type=_content_type,
95
+ _headers=_headers,
96
+ _host_index=_host_index,
97
+ )
98
+
99
+ @validate_call
100
+ def create_strategy_with_http_info(
101
+ self,
102
+ strategy_create: StrategyCreate,
103
+ _request_timeout: Union[
104
+ None,
105
+ Annotated[StrictFloat, Field(gt=0)],
106
+ Tuple[
107
+ Annotated[StrictFloat, Field(gt=0)], Annotated[StrictFloat, Field(gt=0)]
108
+ ],
109
+ ] = None,
110
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
111
+ _content_type: Optional[StrictStr] = None,
112
+ _headers: Optional[Dict[StrictStr, Any]] = None,
113
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
114
+ ) -> ApiResponse[Strategy]:
115
+ """Create Strategy with HTTP info"""
116
+ if self.is_sync:
117
+ return self._create_strategy_sync_with_http_info(
118
+ strategy_create=strategy_create,
119
+ _request_timeout=_request_timeout,
120
+ _request_auth=_request_auth,
121
+ _content_type=_content_type,
122
+ _headers=_headers,
123
+ _host_index=_host_index,
124
+ )
125
+
126
+ else:
127
+ return self._create_strategy_async_with_http_info(
128
+ strategy_create=strategy_create,
129
+ _request_timeout=_request_timeout,
130
+ _request_auth=_request_auth,
131
+ _content_type=_content_type,
132
+ _headers=_headers,
133
+ _host_index=_host_index,
134
+ )
135
+
136
+ @validate_call
137
+ def create_strategy_without_preload_content(
138
+ self,
139
+ strategy_create: StrategyCreate,
140
+ _request_timeout: Union[
141
+ None,
142
+ Annotated[StrictFloat, Field(gt=0)],
143
+ Tuple[
144
+ Annotated[StrictFloat, Field(gt=0)], Annotated[StrictFloat, Field(gt=0)]
145
+ ],
146
+ ] = None,
147
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
148
+ _content_type: Optional[StrictStr] = None,
149
+ _headers: Optional[Dict[StrictStr, Any]] = None,
150
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
151
+ ) -> RESTResponseType:
152
+ """Create Strategy without preloading content"""
153
+ if self.is_sync:
154
+ return self._create_strategy_sync_without_preload_content(
155
+ strategy_create=strategy_create,
156
+ _request_timeout=_request_timeout,
157
+ _request_auth=_request_auth,
158
+ _content_type=_content_type,
159
+ _headers=_headers,
160
+ _host_index=_host_index,
161
+ )
162
+
163
+ else:
164
+ return self._create_strategy_async_without_preload_content(
165
+ strategy_create=strategy_create,
166
+ _request_timeout=_request_timeout,
167
+ _request_auth=_request_auth,
168
+ _content_type=_content_type,
169
+ _headers=_headers,
170
+ _host_index=_host_index,
171
+ )
42
172
 
173
+ # Private async implementation methods
43
174
  @validate_call
44
- async def create_strategy(
175
+ async def _create_strategy_async(
45
176
  self,
46
177
  strategy_create: StrategyCreate,
47
178
  _request_timeout: Union[
@@ -105,7 +236,7 @@ class StrategiesApi:
105
236
  ).data
106
237
 
107
238
  @validate_call
108
- async def create_strategy_with_http_info(
239
+ async def _create_strategy_async_with_http_info(
109
240
  self,
110
241
  strategy_create: StrategyCreate,
111
242
  _request_timeout: Union[
@@ -164,12 +295,11 @@ class StrategiesApi:
164
295
  )
165
296
  await response_data.read()
166
297
  return self.api_client.response_deserialize(
167
- response_data=response_data,
168
- response_types_map=_response_types_map,
298
+ response_data=response_data, response_types_map=_response_types_map
169
299
  )
170
300
 
171
301
  @validate_call
172
- async def create_strategy_without_preload_content(
302
+ async def _create_strategy_async_without_preload_content(
173
303
  self,
174
304
  strategy_create: StrategyCreate,
175
305
  _request_timeout: Union[
@@ -226,7 +356,86 @@ class StrategiesApi:
226
356
  response_data = await self.api_client.call_api(
227
357
  *_param, _request_timeout=_request_timeout
228
358
  )
229
- return response_data.response
359
+ return response_data
360
+
361
+ # Private sync implementation methods
362
+ @validate_call
363
+ def _create_strategy_sync(
364
+ self,
365
+ strategy_create: StrategyCreate,
366
+ _request_timeout: Union[
367
+ None,
368
+ Annotated[StrictFloat, Field(gt=0)],
369
+ Tuple[
370
+ Annotated[StrictFloat, Field(gt=0)], Annotated[StrictFloat, Field(gt=0)]
371
+ ],
372
+ ] = None,
373
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
374
+ _content_type: Optional[StrictStr] = None,
375
+ _headers: Optional[Dict[StrictStr, Any]] = None,
376
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
377
+ ) -> Strategy:
378
+ """Synchronous version of create_strategy"""
379
+ return async_to_sync(self._create_strategy_async)(
380
+ strategy_create=strategy_create,
381
+ _request_timeout=_request_timeout,
382
+ _request_auth=_request_auth,
383
+ _content_type=_content_type,
384
+ _headers=_headers,
385
+ _host_index=_host_index,
386
+ )
387
+
388
+ @validate_call
389
+ def _create_strategy_sync_with_http_info(
390
+ self,
391
+ strategy_create: StrategyCreate,
392
+ _request_timeout: Union[
393
+ None,
394
+ Annotated[StrictFloat, Field(gt=0)],
395
+ Tuple[
396
+ Annotated[StrictFloat, Field(gt=0)], Annotated[StrictFloat, Field(gt=0)]
397
+ ],
398
+ ] = None,
399
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
400
+ _content_type: Optional[StrictStr] = None,
401
+ _headers: Optional[Dict[StrictStr, Any]] = None,
402
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
403
+ ) -> ApiResponse[Strategy]:
404
+ """Synchronous version of create_strategy_with_http_info"""
405
+ return async_to_sync(self._create_strategy_async_with_http_info)(
406
+ strategy_create=strategy_create,
407
+ _request_timeout=_request_timeout,
408
+ _request_auth=_request_auth,
409
+ _content_type=_content_type,
410
+ _headers=_headers,
411
+ _host_index=_host_index,
412
+ )
413
+
414
+ @validate_call
415
+ def _create_strategy_sync_without_preload_content(
416
+ self,
417
+ strategy_create: StrategyCreate,
418
+ _request_timeout: Union[
419
+ None,
420
+ Annotated[StrictFloat, Field(gt=0)],
421
+ Tuple[
422
+ Annotated[StrictFloat, Field(gt=0)], Annotated[StrictFloat, Field(gt=0)]
423
+ ],
424
+ ] = None,
425
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
426
+ _content_type: Optional[StrictStr] = None,
427
+ _headers: Optional[Dict[StrictStr, Any]] = None,
428
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
429
+ ) -> RESTResponseType:
430
+ """Synchronous version of create_strategy_without_preload_content"""
431
+ return async_to_sync(self._create_strategy_async_without_preload_content)(
432
+ strategy_create=strategy_create,
433
+ _request_timeout=_request_timeout,
434
+ _request_auth=_request_auth,
435
+ _content_type=_content_type,
436
+ _headers=_headers,
437
+ _host_index=_host_index,
438
+ )
230
439
 
231
440
  def _create_strategy_serialize(
232
441
  self,
@@ -293,7 +502,158 @@ class StrategiesApi:
293
502
  )
294
503
 
295
504
  @validate_call
296
- async def get_strategies(
505
+ def get_strategies(
506
+ self,
507
+ limit: Annotated[
508
+ Optional[StrictInt],
509
+ Field(
510
+ description="Limit the number of strategies returned. 0 means no limit."
511
+ ),
512
+ ] = None,
513
+ offset: Annotated[
514
+ Optional[StrictInt],
515
+ Field(
516
+ description="Offset the number of strategies returned. 0 means no offset."
517
+ ),
518
+ ] = None,
519
+ _request_timeout: Union[
520
+ None,
521
+ Annotated[StrictFloat, Field(gt=0)],
522
+ Tuple[
523
+ Annotated[StrictFloat, Field(gt=0)], Annotated[StrictFloat, Field(gt=0)]
524
+ ],
525
+ ] = None,
526
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
527
+ _content_type: Optional[StrictStr] = None,
528
+ _headers: Optional[Dict[StrictStr, Any]] = None,
529
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
530
+ ) -> List[Strategy]:
531
+ """Get Strategies"""
532
+ if self.is_sync:
533
+ return self._get_strategies_sync(
534
+ limit=limit,
535
+ offset=offset,
536
+ _request_timeout=_request_timeout,
537
+ _request_auth=_request_auth,
538
+ _content_type=_content_type,
539
+ _headers=_headers,
540
+ _host_index=_host_index,
541
+ )
542
+
543
+ else:
544
+ return self._get_strategies_async(
545
+ limit=limit,
546
+ offset=offset,
547
+ _request_timeout=_request_timeout,
548
+ _request_auth=_request_auth,
549
+ _content_type=_content_type,
550
+ _headers=_headers,
551
+ _host_index=_host_index,
552
+ )
553
+
554
+ @validate_call
555
+ def get_strategies_with_http_info(
556
+ self,
557
+ limit: Annotated[
558
+ Optional[StrictInt],
559
+ Field(
560
+ description="Limit the number of strategies returned. 0 means no limit."
561
+ ),
562
+ ] = None,
563
+ offset: Annotated[
564
+ Optional[StrictInt],
565
+ Field(
566
+ description="Offset the number of strategies returned. 0 means no offset."
567
+ ),
568
+ ] = None,
569
+ _request_timeout: Union[
570
+ None,
571
+ Annotated[StrictFloat, Field(gt=0)],
572
+ Tuple[
573
+ Annotated[StrictFloat, Field(gt=0)], Annotated[StrictFloat, Field(gt=0)]
574
+ ],
575
+ ] = None,
576
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
577
+ _content_type: Optional[StrictStr] = None,
578
+ _headers: Optional[Dict[StrictStr, Any]] = None,
579
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
580
+ ) -> ApiResponse[List[Strategy]]:
581
+ """Get Strategies with HTTP info"""
582
+ if self.is_sync:
583
+ return self._get_strategies_sync_with_http_info(
584
+ limit=limit,
585
+ offset=offset,
586
+ _request_timeout=_request_timeout,
587
+ _request_auth=_request_auth,
588
+ _content_type=_content_type,
589
+ _headers=_headers,
590
+ _host_index=_host_index,
591
+ )
592
+
593
+ else:
594
+ return self._get_strategies_async_with_http_info(
595
+ limit=limit,
596
+ offset=offset,
597
+ _request_timeout=_request_timeout,
598
+ _request_auth=_request_auth,
599
+ _content_type=_content_type,
600
+ _headers=_headers,
601
+ _host_index=_host_index,
602
+ )
603
+
604
+ @validate_call
605
+ def get_strategies_without_preload_content(
606
+ self,
607
+ limit: Annotated[
608
+ Optional[StrictInt],
609
+ Field(
610
+ description="Limit the number of strategies returned. 0 means no limit."
611
+ ),
612
+ ] = None,
613
+ offset: Annotated[
614
+ Optional[StrictInt],
615
+ Field(
616
+ description="Offset the number of strategies returned. 0 means no offset."
617
+ ),
618
+ ] = None,
619
+ _request_timeout: Union[
620
+ None,
621
+ Annotated[StrictFloat, Field(gt=0)],
622
+ Tuple[
623
+ Annotated[StrictFloat, Field(gt=0)], Annotated[StrictFloat, Field(gt=0)]
624
+ ],
625
+ ] = None,
626
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
627
+ _content_type: Optional[StrictStr] = None,
628
+ _headers: Optional[Dict[StrictStr, Any]] = None,
629
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
630
+ ) -> RESTResponseType:
631
+ """Get Strategies without preloading content"""
632
+ if self.is_sync:
633
+ return self._get_strategies_sync_without_preload_content(
634
+ limit=limit,
635
+ offset=offset,
636
+ _request_timeout=_request_timeout,
637
+ _request_auth=_request_auth,
638
+ _content_type=_content_type,
639
+ _headers=_headers,
640
+ _host_index=_host_index,
641
+ )
642
+
643
+ else:
644
+ return self._get_strategies_async_without_preload_content(
645
+ limit=limit,
646
+ offset=offset,
647
+ _request_timeout=_request_timeout,
648
+ _request_auth=_request_auth,
649
+ _content_type=_content_type,
650
+ _headers=_headers,
651
+ _host_index=_host_index,
652
+ )
653
+
654
+ # Private async implementation methods
655
+ @validate_call
656
+ async def _get_strategies_async(
297
657
  self,
298
658
  limit: Annotated[
299
659
  Optional[StrictInt],
@@ -371,7 +731,7 @@ class StrategiesApi:
371
731
  ).data
372
732
 
373
733
  @validate_call
374
- async def get_strategies_with_http_info(
734
+ async def _get_strategies_async_with_http_info(
375
735
  self,
376
736
  limit: Annotated[
377
737
  Optional[StrictInt],
@@ -444,12 +804,11 @@ class StrategiesApi:
444
804
  )
445
805
  await response_data.read()
446
806
  return self.api_client.response_deserialize(
447
- response_data=response_data,
448
- response_types_map=_response_types_map,
807
+ response_data=response_data, response_types_map=_response_types_map
449
808
  )
450
809
 
451
810
  @validate_call
452
- async def get_strategies_without_preload_content(
811
+ async def _get_strategies_async_without_preload_content(
453
812
  self,
454
813
  limit: Annotated[
455
814
  Optional[StrictInt],
@@ -520,35 +879,150 @@ class StrategiesApi:
520
879
  response_data = await self.api_client.call_api(
521
880
  *_param, _request_timeout=_request_timeout
522
881
  )
523
- return response_data.response
882
+ return response_data
524
883
 
525
- def _get_strategies_serialize(
884
+ # Private sync implementation methods
885
+ @validate_call
886
+ def _get_strategies_sync(
526
887
  self,
527
- limit,
528
- offset,
529
- _request_auth,
530
- _content_type,
531
- _headers,
532
- _host_index,
533
- ) -> RequestSerialized:
534
-
535
- _host = None
536
-
537
- _collection_formats: Dict[str, str] = {}
538
-
539
- _path_params: Dict[str, str] = {}
540
- _query_params: List[Tuple[str, str]] = []
541
- _header_params: Dict[str, Optional[str]] = _headers or {}
542
- _form_params: List[Tuple[str, str]] = []
543
- _files: Dict[
544
- str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
545
- ] = {}
546
- _body_params: Optional[bytes] = None
547
-
548
- # process the path parameters
549
- # process the query parameters
550
- if limit is not None:
551
-
888
+ limit: Annotated[
889
+ Optional[StrictInt],
890
+ Field(
891
+ description="Limit the number of strategies returned. 0 means no limit."
892
+ ),
893
+ ] = None,
894
+ offset: Annotated[
895
+ Optional[StrictInt],
896
+ Field(
897
+ description="Offset the number of strategies returned. 0 means no offset."
898
+ ),
899
+ ] = None,
900
+ _request_timeout: Union[
901
+ None,
902
+ Annotated[StrictFloat, Field(gt=0)],
903
+ Tuple[
904
+ Annotated[StrictFloat, Field(gt=0)], Annotated[StrictFloat, Field(gt=0)]
905
+ ],
906
+ ] = None,
907
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
908
+ _content_type: Optional[StrictStr] = None,
909
+ _headers: Optional[Dict[StrictStr, Any]] = None,
910
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
911
+ ) -> List[Strategy]:
912
+ """Synchronous version of get_strategies"""
913
+ return async_to_sync(self._get_strategies_async)(
914
+ limit=limit,
915
+ offset=offset,
916
+ _request_timeout=_request_timeout,
917
+ _request_auth=_request_auth,
918
+ _content_type=_content_type,
919
+ _headers=_headers,
920
+ _host_index=_host_index,
921
+ )
922
+
923
+ @validate_call
924
+ def _get_strategies_sync_with_http_info(
925
+ self,
926
+ limit: Annotated[
927
+ Optional[StrictInt],
928
+ Field(
929
+ description="Limit the number of strategies returned. 0 means no limit."
930
+ ),
931
+ ] = None,
932
+ offset: Annotated[
933
+ Optional[StrictInt],
934
+ Field(
935
+ description="Offset the number of strategies returned. 0 means no offset."
936
+ ),
937
+ ] = None,
938
+ _request_timeout: Union[
939
+ None,
940
+ Annotated[StrictFloat, Field(gt=0)],
941
+ Tuple[
942
+ Annotated[StrictFloat, Field(gt=0)], Annotated[StrictFloat, Field(gt=0)]
943
+ ],
944
+ ] = None,
945
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
946
+ _content_type: Optional[StrictStr] = None,
947
+ _headers: Optional[Dict[StrictStr, Any]] = None,
948
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
949
+ ) -> ApiResponse[List[Strategy]]:
950
+ """Synchronous version of get_strategies_with_http_info"""
951
+ return async_to_sync(self._get_strategies_async_with_http_info)(
952
+ limit=limit,
953
+ offset=offset,
954
+ _request_timeout=_request_timeout,
955
+ _request_auth=_request_auth,
956
+ _content_type=_content_type,
957
+ _headers=_headers,
958
+ _host_index=_host_index,
959
+ )
960
+
961
+ @validate_call
962
+ def _get_strategies_sync_without_preload_content(
963
+ self,
964
+ limit: Annotated[
965
+ Optional[StrictInt],
966
+ Field(
967
+ description="Limit the number of strategies returned. 0 means no limit."
968
+ ),
969
+ ] = None,
970
+ offset: Annotated[
971
+ Optional[StrictInt],
972
+ Field(
973
+ description="Offset the number of strategies returned. 0 means no offset."
974
+ ),
975
+ ] = None,
976
+ _request_timeout: Union[
977
+ None,
978
+ Annotated[StrictFloat, Field(gt=0)],
979
+ Tuple[
980
+ Annotated[StrictFloat, Field(gt=0)], Annotated[StrictFloat, Field(gt=0)]
981
+ ],
982
+ ] = None,
983
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
984
+ _content_type: Optional[StrictStr] = None,
985
+ _headers: Optional[Dict[StrictStr, Any]] = None,
986
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
987
+ ) -> RESTResponseType:
988
+ """Synchronous version of get_strategies_without_preload_content"""
989
+ return async_to_sync(self._get_strategies_async_without_preload_content)(
990
+ limit=limit,
991
+ offset=offset,
992
+ _request_timeout=_request_timeout,
993
+ _request_auth=_request_auth,
994
+ _content_type=_content_type,
995
+ _headers=_headers,
996
+ _host_index=_host_index,
997
+ )
998
+
999
+ def _get_strategies_serialize(
1000
+ self,
1001
+ limit,
1002
+ offset,
1003
+ _request_auth,
1004
+ _content_type,
1005
+ _headers,
1006
+ _host_index,
1007
+ ) -> RequestSerialized:
1008
+
1009
+ _host = None
1010
+
1011
+ _collection_formats: Dict[str, str] = {}
1012
+
1013
+ _path_params: Dict[str, str] = {}
1014
+ _query_params: List[Tuple[str, str]] = []
1015
+ _header_params: Dict[str, Optional[str]] = _headers or {}
1016
+ _form_params: List[Tuple[str, str]] = []
1017
+ _files: Dict[
1018
+ str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
1019
+ ] = {}
1020
+ _body_params: Optional[bytes] = None
1021
+
1022
+ # process the path parameters
1023
+ # process the query parameters
1024
+ if limit is not None:
1025
+
552
1026
  _query_params.append(("limit", limit))
553
1027
 
554
1028
  if offset is not None:
@@ -584,7 +1058,110 @@ class StrategiesApi:
584
1058
  )
585
1059
 
586
1060
  @validate_call
587
- async def get_strategy_usage(
1061
+ def get_strategy_usage(
1062
+ self,
1063
+ _request_timeout: Union[
1064
+ None,
1065
+ Annotated[StrictFloat, Field(gt=0)],
1066
+ Tuple[
1067
+ Annotated[StrictFloat, Field(gt=0)], Annotated[StrictFloat, Field(gt=0)]
1068
+ ],
1069
+ ] = None,
1070
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
1071
+ _content_type: Optional[StrictStr] = None,
1072
+ _headers: Optional[Dict[StrictStr, Any]] = None,
1073
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
1074
+ ) -> List[List[object]]:
1075
+ """Get Strategy Usage"""
1076
+ if self.is_sync:
1077
+ return self._get_strategy_usage_sync(
1078
+ _request_timeout=_request_timeout,
1079
+ _request_auth=_request_auth,
1080
+ _content_type=_content_type,
1081
+ _headers=_headers,
1082
+ _host_index=_host_index,
1083
+ )
1084
+
1085
+ else:
1086
+ return self._get_strategy_usage_async(
1087
+ _request_timeout=_request_timeout,
1088
+ _request_auth=_request_auth,
1089
+ _content_type=_content_type,
1090
+ _headers=_headers,
1091
+ _host_index=_host_index,
1092
+ )
1093
+
1094
+ @validate_call
1095
+ def get_strategy_usage_with_http_info(
1096
+ self,
1097
+ _request_timeout: Union[
1098
+ None,
1099
+ Annotated[StrictFloat, Field(gt=0)],
1100
+ Tuple[
1101
+ Annotated[StrictFloat, Field(gt=0)], Annotated[StrictFloat, Field(gt=0)]
1102
+ ],
1103
+ ] = None,
1104
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
1105
+ _content_type: Optional[StrictStr] = None,
1106
+ _headers: Optional[Dict[StrictStr, Any]] = None,
1107
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
1108
+ ) -> ApiResponse[List[List[object]]]:
1109
+ """Get Strategy Usage with HTTP info"""
1110
+ if self.is_sync:
1111
+ return self._get_strategy_usage_sync_with_http_info(
1112
+ _request_timeout=_request_timeout,
1113
+ _request_auth=_request_auth,
1114
+ _content_type=_content_type,
1115
+ _headers=_headers,
1116
+ _host_index=_host_index,
1117
+ )
1118
+
1119
+ else:
1120
+ return self._get_strategy_usage_async_with_http_info(
1121
+ _request_timeout=_request_timeout,
1122
+ _request_auth=_request_auth,
1123
+ _content_type=_content_type,
1124
+ _headers=_headers,
1125
+ _host_index=_host_index,
1126
+ )
1127
+
1128
+ @validate_call
1129
+ def get_strategy_usage_without_preload_content(
1130
+ self,
1131
+ _request_timeout: Union[
1132
+ None,
1133
+ Annotated[StrictFloat, Field(gt=0)],
1134
+ Tuple[
1135
+ Annotated[StrictFloat, Field(gt=0)], Annotated[StrictFloat, Field(gt=0)]
1136
+ ],
1137
+ ] = None,
1138
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
1139
+ _content_type: Optional[StrictStr] = None,
1140
+ _headers: Optional[Dict[StrictStr, Any]] = None,
1141
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
1142
+ ) -> RESTResponseType:
1143
+ """Get Strategy Usage without preloading content"""
1144
+ if self.is_sync:
1145
+ return self._get_strategy_usage_sync_without_preload_content(
1146
+ _request_timeout=_request_timeout,
1147
+ _request_auth=_request_auth,
1148
+ _content_type=_content_type,
1149
+ _headers=_headers,
1150
+ _host_index=_host_index,
1151
+ )
1152
+
1153
+ else:
1154
+ return self._get_strategy_usage_async_without_preload_content(
1155
+ _request_timeout=_request_timeout,
1156
+ _request_auth=_request_auth,
1157
+ _content_type=_content_type,
1158
+ _headers=_headers,
1159
+ _host_index=_host_index,
1160
+ )
1161
+
1162
+ # Private async implementation methods
1163
+ @validate_call
1164
+ async def _get_strategy_usage_async(
588
1165
  self,
589
1166
  _request_timeout: Union[
590
1167
  None,
@@ -644,7 +1221,7 @@ class StrategiesApi:
644
1221
  ).data
645
1222
 
646
1223
  @validate_call
647
- async def get_strategy_usage_with_http_info(
1224
+ async def _get_strategy_usage_async_with_http_info(
648
1225
  self,
649
1226
  _request_timeout: Union[
650
1227
  None,
@@ -699,12 +1276,11 @@ class StrategiesApi:
699
1276
  )
700
1277
  await response_data.read()
701
1278
  return self.api_client.response_deserialize(
702
- response_data=response_data,
703
- response_types_map=_response_types_map,
1279
+ response_data=response_data, response_types_map=_response_types_map
704
1280
  )
705
1281
 
706
1282
  @validate_call
707
- async def get_strategy_usage_without_preload_content(
1283
+ async def _get_strategy_usage_async_without_preload_content(
708
1284
  self,
709
1285
  _request_timeout: Union[
710
1286
  None,
@@ -757,7 +1333,80 @@ class StrategiesApi:
757
1333
  response_data = await self.api_client.call_api(
758
1334
  *_param, _request_timeout=_request_timeout
759
1335
  )
760
- return response_data.response
1336
+ return response_data
1337
+
1338
+ # Private sync implementation methods
1339
+ @validate_call
1340
+ def _get_strategy_usage_sync(
1341
+ self,
1342
+ _request_timeout: Union[
1343
+ None,
1344
+ Annotated[StrictFloat, Field(gt=0)],
1345
+ Tuple[
1346
+ Annotated[StrictFloat, Field(gt=0)], Annotated[StrictFloat, Field(gt=0)]
1347
+ ],
1348
+ ] = None,
1349
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
1350
+ _content_type: Optional[StrictStr] = None,
1351
+ _headers: Optional[Dict[StrictStr, Any]] = None,
1352
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
1353
+ ) -> List[List[object]]:
1354
+ """Synchronous version of get_strategy_usage"""
1355
+ return async_to_sync(self._get_strategy_usage_async)(
1356
+ _request_timeout=_request_timeout,
1357
+ _request_auth=_request_auth,
1358
+ _content_type=_content_type,
1359
+ _headers=_headers,
1360
+ _host_index=_host_index,
1361
+ )
1362
+
1363
+ @validate_call
1364
+ def _get_strategy_usage_sync_with_http_info(
1365
+ self,
1366
+ _request_timeout: Union[
1367
+ None,
1368
+ Annotated[StrictFloat, Field(gt=0)],
1369
+ Tuple[
1370
+ Annotated[StrictFloat, Field(gt=0)], Annotated[StrictFloat, Field(gt=0)]
1371
+ ],
1372
+ ] = None,
1373
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
1374
+ _content_type: Optional[StrictStr] = None,
1375
+ _headers: Optional[Dict[StrictStr, Any]] = None,
1376
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
1377
+ ) -> ApiResponse[List[List[object]]]:
1378
+ """Synchronous version of get_strategy_usage_with_http_info"""
1379
+ return async_to_sync(self._get_strategy_usage_async_with_http_info)(
1380
+ _request_timeout=_request_timeout,
1381
+ _request_auth=_request_auth,
1382
+ _content_type=_content_type,
1383
+ _headers=_headers,
1384
+ _host_index=_host_index,
1385
+ )
1386
+
1387
+ @validate_call
1388
+ def _get_strategy_usage_sync_without_preload_content(
1389
+ self,
1390
+ _request_timeout: Union[
1391
+ None,
1392
+ Annotated[StrictFloat, Field(gt=0)],
1393
+ Tuple[
1394
+ Annotated[StrictFloat, Field(gt=0)], Annotated[StrictFloat, Field(gt=0)]
1395
+ ],
1396
+ ] = None,
1397
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
1398
+ _content_type: Optional[StrictStr] = None,
1399
+ _headers: Optional[Dict[StrictStr, Any]] = None,
1400
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
1401
+ ) -> RESTResponseType:
1402
+ """Synchronous version of get_strategy_usage_without_preload_content"""
1403
+ return async_to_sync(self._get_strategy_usage_async_without_preload_content)(
1404
+ _request_timeout=_request_timeout,
1405
+ _request_auth=_request_auth,
1406
+ _content_type=_content_type,
1407
+ _headers=_headers,
1408
+ _host_index=_host_index,
1409
+ )
761
1410
 
762
1411
  def _get_strategy_usage_serialize(
763
1412
  self,
@@ -786,32 +1435,144 @@ class StrategiesApi:
786
1435
  # process the form parameters
787
1436
  # process the body parameter
788
1437
 
789
- # set the HTTP header `Accept`
790
- if "Accept" not in _header_params:
791
- _header_params["Accept"] = self.api_client.select_header_accept(
792
- ["application/json"]
1438
+ # set the HTTP header `Accept`
1439
+ if "Accept" not in _header_params:
1440
+ _header_params["Accept"] = self.api_client.select_header_accept(
1441
+ ["application/json"]
1442
+ )
1443
+
1444
+ # authentication setting
1445
+ _auth_settings: List[str] = ["APIKeyHeader", "HTTPBearer"]
1446
+
1447
+ return self.api_client.param_serialize(
1448
+ method="GET",
1449
+ resource_path="/strategies/usage",
1450
+ path_params=_path_params,
1451
+ query_params=_query_params,
1452
+ header_params=_header_params,
1453
+ body=_body_params,
1454
+ post_params=_form_params,
1455
+ files=_files,
1456
+ auth_settings=_auth_settings,
1457
+ collection_formats=_collection_formats,
1458
+ _host=_host,
1459
+ _request_auth=_request_auth,
1460
+ )
1461
+
1462
+ @validate_call
1463
+ def kill_strategy(
1464
+ self,
1465
+ id: Annotated[StrictStr, Field(description="The ID of the strategy to kill.")],
1466
+ _request_timeout: Union[
1467
+ None,
1468
+ Annotated[StrictFloat, Field(gt=0)],
1469
+ Tuple[
1470
+ Annotated[StrictFloat, Field(gt=0)], Annotated[StrictFloat, Field(gt=0)]
1471
+ ],
1472
+ ] = None,
1473
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
1474
+ _content_type: Optional[StrictStr] = None,
1475
+ _headers: Optional[Dict[StrictStr, Any]] = None,
1476
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
1477
+ ) -> None:
1478
+ """Kill Strategy"""
1479
+ if self.is_sync:
1480
+ return self._kill_strategy_sync(
1481
+ id=id,
1482
+ _request_timeout=_request_timeout,
1483
+ _request_auth=_request_auth,
1484
+ _content_type=_content_type,
1485
+ _headers=_headers,
1486
+ _host_index=_host_index,
1487
+ )
1488
+
1489
+ else:
1490
+ return self._kill_strategy_async(
1491
+ id=id,
1492
+ _request_timeout=_request_timeout,
1493
+ _request_auth=_request_auth,
1494
+ _content_type=_content_type,
1495
+ _headers=_headers,
1496
+ _host_index=_host_index,
1497
+ )
1498
+
1499
+ @validate_call
1500
+ def kill_strategy_with_http_info(
1501
+ self,
1502
+ id: Annotated[StrictStr, Field(description="The ID of the strategy to kill.")],
1503
+ _request_timeout: Union[
1504
+ None,
1505
+ Annotated[StrictFloat, Field(gt=0)],
1506
+ Tuple[
1507
+ Annotated[StrictFloat, Field(gt=0)], Annotated[StrictFloat, Field(gt=0)]
1508
+ ],
1509
+ ] = None,
1510
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
1511
+ _content_type: Optional[StrictStr] = None,
1512
+ _headers: Optional[Dict[StrictStr, Any]] = None,
1513
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
1514
+ ) -> ApiResponse[None]:
1515
+ """Kill Strategy with HTTP info"""
1516
+ if self.is_sync:
1517
+ return self._kill_strategy_sync_with_http_info(
1518
+ id=id,
1519
+ _request_timeout=_request_timeout,
1520
+ _request_auth=_request_auth,
1521
+ _content_type=_content_type,
1522
+ _headers=_headers,
1523
+ _host_index=_host_index,
1524
+ )
1525
+
1526
+ else:
1527
+ return self._kill_strategy_async_with_http_info(
1528
+ id=id,
1529
+ _request_timeout=_request_timeout,
1530
+ _request_auth=_request_auth,
1531
+ _content_type=_content_type,
1532
+ _headers=_headers,
1533
+ _host_index=_host_index,
793
1534
  )
794
1535
 
795
- # authentication setting
796
- _auth_settings: List[str] = ["APIKeyHeader", "HTTPBearer"]
1536
+ @validate_call
1537
+ def kill_strategy_without_preload_content(
1538
+ self,
1539
+ id: Annotated[StrictStr, Field(description="The ID of the strategy to kill.")],
1540
+ _request_timeout: Union[
1541
+ None,
1542
+ Annotated[StrictFloat, Field(gt=0)],
1543
+ Tuple[
1544
+ Annotated[StrictFloat, Field(gt=0)], Annotated[StrictFloat, Field(gt=0)]
1545
+ ],
1546
+ ] = None,
1547
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
1548
+ _content_type: Optional[StrictStr] = None,
1549
+ _headers: Optional[Dict[StrictStr, Any]] = None,
1550
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
1551
+ ) -> RESTResponseType:
1552
+ """Kill Strategy without preloading content"""
1553
+ if self.is_sync:
1554
+ return self._kill_strategy_sync_without_preload_content(
1555
+ id=id,
1556
+ _request_timeout=_request_timeout,
1557
+ _request_auth=_request_auth,
1558
+ _content_type=_content_type,
1559
+ _headers=_headers,
1560
+ _host_index=_host_index,
1561
+ )
797
1562
 
798
- return self.api_client.param_serialize(
799
- method="GET",
800
- resource_path="/strategies/usage",
801
- path_params=_path_params,
802
- query_params=_query_params,
803
- header_params=_header_params,
804
- body=_body_params,
805
- post_params=_form_params,
806
- files=_files,
807
- auth_settings=_auth_settings,
808
- collection_formats=_collection_formats,
809
- _host=_host,
810
- _request_auth=_request_auth,
811
- )
1563
+ else:
1564
+ return self._kill_strategy_async_without_preload_content(
1565
+ id=id,
1566
+ _request_timeout=_request_timeout,
1567
+ _request_auth=_request_auth,
1568
+ _content_type=_content_type,
1569
+ _headers=_headers,
1570
+ _host_index=_host_index,
1571
+ )
812
1572
 
1573
+ # Private async implementation methods
813
1574
  @validate_call
814
- async def kill_strategy(
1575
+ async def _kill_strategy_async(
815
1576
  self,
816
1577
  id: Annotated[StrictStr, Field(description="The ID of the strategy to kill.")],
817
1578
  _request_timeout: Union[
@@ -875,7 +1636,7 @@ class StrategiesApi:
875
1636
  ).data
876
1637
 
877
1638
  @validate_call
878
- async def kill_strategy_with_http_info(
1639
+ async def _kill_strategy_async_with_http_info(
879
1640
  self,
880
1641
  id: Annotated[StrictStr, Field(description="The ID of the strategy to kill.")],
881
1642
  _request_timeout: Union[
@@ -934,12 +1695,11 @@ class StrategiesApi:
934
1695
  )
935
1696
  await response_data.read()
936
1697
  return self.api_client.response_deserialize(
937
- response_data=response_data,
938
- response_types_map=_response_types_map,
1698
+ response_data=response_data, response_types_map=_response_types_map
939
1699
  )
940
1700
 
941
1701
  @validate_call
942
- async def kill_strategy_without_preload_content(
1702
+ async def _kill_strategy_async_without_preload_content(
943
1703
  self,
944
1704
  id: Annotated[StrictStr, Field(description="The ID of the strategy to kill.")],
945
1705
  _request_timeout: Union[
@@ -996,7 +1756,86 @@ class StrategiesApi:
996
1756
  response_data = await self.api_client.call_api(
997
1757
  *_param, _request_timeout=_request_timeout
998
1758
  )
999
- return response_data.response
1759
+ return response_data
1760
+
1761
+ # Private sync implementation methods
1762
+ @validate_call
1763
+ def _kill_strategy_sync(
1764
+ self,
1765
+ id: Annotated[StrictStr, Field(description="The ID of the strategy to kill.")],
1766
+ _request_timeout: Union[
1767
+ None,
1768
+ Annotated[StrictFloat, Field(gt=0)],
1769
+ Tuple[
1770
+ Annotated[StrictFloat, Field(gt=0)], Annotated[StrictFloat, Field(gt=0)]
1771
+ ],
1772
+ ] = None,
1773
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
1774
+ _content_type: Optional[StrictStr] = None,
1775
+ _headers: Optional[Dict[StrictStr, Any]] = None,
1776
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
1777
+ ) -> None:
1778
+ """Synchronous version of kill_strategy"""
1779
+ return async_to_sync(self._kill_strategy_async)(
1780
+ id=id,
1781
+ _request_timeout=_request_timeout,
1782
+ _request_auth=_request_auth,
1783
+ _content_type=_content_type,
1784
+ _headers=_headers,
1785
+ _host_index=_host_index,
1786
+ )
1787
+
1788
+ @validate_call
1789
+ def _kill_strategy_sync_with_http_info(
1790
+ self,
1791
+ id: Annotated[StrictStr, Field(description="The ID of the strategy to kill.")],
1792
+ _request_timeout: Union[
1793
+ None,
1794
+ Annotated[StrictFloat, Field(gt=0)],
1795
+ Tuple[
1796
+ Annotated[StrictFloat, Field(gt=0)], Annotated[StrictFloat, Field(gt=0)]
1797
+ ],
1798
+ ] = None,
1799
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
1800
+ _content_type: Optional[StrictStr] = None,
1801
+ _headers: Optional[Dict[StrictStr, Any]] = None,
1802
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
1803
+ ) -> ApiResponse[None]:
1804
+ """Synchronous version of kill_strategy_with_http_info"""
1805
+ return async_to_sync(self._kill_strategy_async_with_http_info)(
1806
+ id=id,
1807
+ _request_timeout=_request_timeout,
1808
+ _request_auth=_request_auth,
1809
+ _content_type=_content_type,
1810
+ _headers=_headers,
1811
+ _host_index=_host_index,
1812
+ )
1813
+
1814
+ @validate_call
1815
+ def _kill_strategy_sync_without_preload_content(
1816
+ self,
1817
+ id: Annotated[StrictStr, Field(description="The ID of the strategy to kill.")],
1818
+ _request_timeout: Union[
1819
+ None,
1820
+ Annotated[StrictFloat, Field(gt=0)],
1821
+ Tuple[
1822
+ Annotated[StrictFloat, Field(gt=0)], Annotated[StrictFloat, Field(gt=0)]
1823
+ ],
1824
+ ] = None,
1825
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
1826
+ _content_type: Optional[StrictStr] = None,
1827
+ _headers: Optional[Dict[StrictStr, Any]] = None,
1828
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
1829
+ ) -> RESTResponseType:
1830
+ """Synchronous version of kill_strategy_without_preload_content"""
1831
+ return async_to_sync(self._kill_strategy_async_without_preload_content)(
1832
+ id=id,
1833
+ _request_timeout=_request_timeout,
1834
+ _request_auth=_request_auth,
1835
+ _content_type=_content_type,
1836
+ _headers=_headers,
1837
+ _host_index=_host_index,
1838
+ )
1000
1839
 
1001
1840
  def _kill_strategy_serialize(
1002
1841
  self,
@@ -1053,7 +1892,134 @@ class StrategiesApi:
1053
1892
  )
1054
1893
 
1055
1894
  @validate_call
1056
- async def update_strategy(
1895
+ def update_strategy(
1896
+ self,
1897
+ id: Annotated[
1898
+ StrictStr, Field(description="The ID of the strategy to update.")
1899
+ ],
1900
+ strategy_update: StrategyUpdate,
1901
+ _request_timeout: Union[
1902
+ None,
1903
+ Annotated[StrictFloat, Field(gt=0)],
1904
+ Tuple[
1905
+ Annotated[StrictFloat, Field(gt=0)], Annotated[StrictFloat, Field(gt=0)]
1906
+ ],
1907
+ ] = None,
1908
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
1909
+ _content_type: Optional[StrictStr] = None,
1910
+ _headers: Optional[Dict[StrictStr, Any]] = None,
1911
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
1912
+ ) -> Strategy:
1913
+ """Update Strategy"""
1914
+ if self.is_sync:
1915
+ return self._update_strategy_sync(
1916
+ id=id,
1917
+ strategy_update=strategy_update,
1918
+ _request_timeout=_request_timeout,
1919
+ _request_auth=_request_auth,
1920
+ _content_type=_content_type,
1921
+ _headers=_headers,
1922
+ _host_index=_host_index,
1923
+ )
1924
+
1925
+ else:
1926
+ return self._update_strategy_async(
1927
+ id=id,
1928
+ strategy_update=strategy_update,
1929
+ _request_timeout=_request_timeout,
1930
+ _request_auth=_request_auth,
1931
+ _content_type=_content_type,
1932
+ _headers=_headers,
1933
+ _host_index=_host_index,
1934
+ )
1935
+
1936
+ @validate_call
1937
+ def update_strategy_with_http_info(
1938
+ self,
1939
+ id: Annotated[
1940
+ StrictStr, Field(description="The ID of the strategy to update.")
1941
+ ],
1942
+ strategy_update: StrategyUpdate,
1943
+ _request_timeout: Union[
1944
+ None,
1945
+ Annotated[StrictFloat, Field(gt=0)],
1946
+ Tuple[
1947
+ Annotated[StrictFloat, Field(gt=0)], Annotated[StrictFloat, Field(gt=0)]
1948
+ ],
1949
+ ] = None,
1950
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
1951
+ _content_type: Optional[StrictStr] = None,
1952
+ _headers: Optional[Dict[StrictStr, Any]] = None,
1953
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
1954
+ ) -> ApiResponse[Strategy]:
1955
+ """Update Strategy with HTTP info"""
1956
+ if self.is_sync:
1957
+ return self._update_strategy_sync_with_http_info(
1958
+ id=id,
1959
+ strategy_update=strategy_update,
1960
+ _request_timeout=_request_timeout,
1961
+ _request_auth=_request_auth,
1962
+ _content_type=_content_type,
1963
+ _headers=_headers,
1964
+ _host_index=_host_index,
1965
+ )
1966
+
1967
+ else:
1968
+ return self._update_strategy_async_with_http_info(
1969
+ id=id,
1970
+ strategy_update=strategy_update,
1971
+ _request_timeout=_request_timeout,
1972
+ _request_auth=_request_auth,
1973
+ _content_type=_content_type,
1974
+ _headers=_headers,
1975
+ _host_index=_host_index,
1976
+ )
1977
+
1978
+ @validate_call
1979
+ def update_strategy_without_preload_content(
1980
+ self,
1981
+ id: Annotated[
1982
+ StrictStr, Field(description="The ID of the strategy to update.")
1983
+ ],
1984
+ strategy_update: StrategyUpdate,
1985
+ _request_timeout: Union[
1986
+ None,
1987
+ Annotated[StrictFloat, Field(gt=0)],
1988
+ Tuple[
1989
+ Annotated[StrictFloat, Field(gt=0)], Annotated[StrictFloat, Field(gt=0)]
1990
+ ],
1991
+ ] = None,
1992
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
1993
+ _content_type: Optional[StrictStr] = None,
1994
+ _headers: Optional[Dict[StrictStr, Any]] = None,
1995
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
1996
+ ) -> RESTResponseType:
1997
+ """Update Strategy without preloading content"""
1998
+ if self.is_sync:
1999
+ return self._update_strategy_sync_without_preload_content(
2000
+ id=id,
2001
+ strategy_update=strategy_update,
2002
+ _request_timeout=_request_timeout,
2003
+ _request_auth=_request_auth,
2004
+ _content_type=_content_type,
2005
+ _headers=_headers,
2006
+ _host_index=_host_index,
2007
+ )
2008
+
2009
+ else:
2010
+ return self._update_strategy_async_without_preload_content(
2011
+ id=id,
2012
+ strategy_update=strategy_update,
2013
+ _request_timeout=_request_timeout,
2014
+ _request_auth=_request_auth,
2015
+ _content_type=_content_type,
2016
+ _headers=_headers,
2017
+ _host_index=_host_index,
2018
+ )
2019
+
2020
+ # Private async implementation methods
2021
+ @validate_call
2022
+ async def _update_strategy_async(
1057
2023
  self,
1058
2024
  id: Annotated[
1059
2025
  StrictStr, Field(description="The ID of the strategy to update.")
@@ -1123,7 +2089,7 @@ class StrategiesApi:
1123
2089
  ).data
1124
2090
 
1125
2091
  @validate_call
1126
- async def update_strategy_with_http_info(
2092
+ async def _update_strategy_async_with_http_info(
1127
2093
  self,
1128
2094
  id: Annotated[
1129
2095
  StrictStr, Field(description="The ID of the strategy to update.")
@@ -1188,12 +2154,11 @@ class StrategiesApi:
1188
2154
  )
1189
2155
  await response_data.read()
1190
2156
  return self.api_client.response_deserialize(
1191
- response_data=response_data,
1192
- response_types_map=_response_types_map,
2157
+ response_data=response_data, response_types_map=_response_types_map
1193
2158
  )
1194
2159
 
1195
2160
  @validate_call
1196
- async def update_strategy_without_preload_content(
2161
+ async def _update_strategy_async_without_preload_content(
1197
2162
  self,
1198
2163
  id: Annotated[
1199
2164
  StrictStr, Field(description="The ID of the strategy to update.")
@@ -1256,7 +2221,98 @@ class StrategiesApi:
1256
2221
  response_data = await self.api_client.call_api(
1257
2222
  *_param, _request_timeout=_request_timeout
1258
2223
  )
1259
- return response_data.response
2224
+ return response_data
2225
+
2226
+ # Private sync implementation methods
2227
+ @validate_call
2228
+ def _update_strategy_sync(
2229
+ self,
2230
+ id: Annotated[
2231
+ StrictStr, Field(description="The ID of the strategy to update.")
2232
+ ],
2233
+ strategy_update: StrategyUpdate,
2234
+ _request_timeout: Union[
2235
+ None,
2236
+ Annotated[StrictFloat, Field(gt=0)],
2237
+ Tuple[
2238
+ Annotated[StrictFloat, Field(gt=0)], Annotated[StrictFloat, Field(gt=0)]
2239
+ ],
2240
+ ] = None,
2241
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
2242
+ _content_type: Optional[StrictStr] = None,
2243
+ _headers: Optional[Dict[StrictStr, Any]] = None,
2244
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
2245
+ ) -> Strategy:
2246
+ """Synchronous version of update_strategy"""
2247
+ return async_to_sync(self._update_strategy_async)(
2248
+ id=id,
2249
+ strategy_update=strategy_update,
2250
+ _request_timeout=_request_timeout,
2251
+ _request_auth=_request_auth,
2252
+ _content_type=_content_type,
2253
+ _headers=_headers,
2254
+ _host_index=_host_index,
2255
+ )
2256
+
2257
+ @validate_call
2258
+ def _update_strategy_sync_with_http_info(
2259
+ self,
2260
+ id: Annotated[
2261
+ StrictStr, Field(description="The ID of the strategy to update.")
2262
+ ],
2263
+ strategy_update: StrategyUpdate,
2264
+ _request_timeout: Union[
2265
+ None,
2266
+ Annotated[StrictFloat, Field(gt=0)],
2267
+ Tuple[
2268
+ Annotated[StrictFloat, Field(gt=0)], Annotated[StrictFloat, Field(gt=0)]
2269
+ ],
2270
+ ] = None,
2271
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
2272
+ _content_type: Optional[StrictStr] = None,
2273
+ _headers: Optional[Dict[StrictStr, Any]] = None,
2274
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
2275
+ ) -> ApiResponse[Strategy]:
2276
+ """Synchronous version of update_strategy_with_http_info"""
2277
+ return async_to_sync(self._update_strategy_async_with_http_info)(
2278
+ id=id,
2279
+ strategy_update=strategy_update,
2280
+ _request_timeout=_request_timeout,
2281
+ _request_auth=_request_auth,
2282
+ _content_type=_content_type,
2283
+ _headers=_headers,
2284
+ _host_index=_host_index,
2285
+ )
2286
+
2287
+ @validate_call
2288
+ def _update_strategy_sync_without_preload_content(
2289
+ self,
2290
+ id: Annotated[
2291
+ StrictStr, Field(description="The ID of the strategy to update.")
2292
+ ],
2293
+ strategy_update: StrategyUpdate,
2294
+ _request_timeout: Union[
2295
+ None,
2296
+ Annotated[StrictFloat, Field(gt=0)],
2297
+ Tuple[
2298
+ Annotated[StrictFloat, Field(gt=0)], Annotated[StrictFloat, Field(gt=0)]
2299
+ ],
2300
+ ] = None,
2301
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
2302
+ _content_type: Optional[StrictStr] = None,
2303
+ _headers: Optional[Dict[StrictStr, Any]] = None,
2304
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
2305
+ ) -> RESTResponseType:
2306
+ """Synchronous version of update_strategy_without_preload_content"""
2307
+ return async_to_sync(self._update_strategy_async_without_preload_content)(
2308
+ id=id,
2309
+ strategy_update=strategy_update,
2310
+ _request_timeout=_request_timeout,
2311
+ _request_auth=_request_auth,
2312
+ _content_type=_content_type,
2313
+ _headers=_headers,
2314
+ _host_index=_host_index,
2315
+ )
1260
2316
 
1261
2317
  def _update_strategy_serialize(
1262
2318
  self,