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
@@ -11,14 +11,10 @@ Generated by OpenAPI Generator (https://openapi-generator.tech)
|
|
11
11
|
Do not edit the class manually.
|
12
12
|
""" # noqa: E501
|
13
13
|
|
14
|
-
import warnings
|
15
14
|
from pydantic import validate_call, Field, StrictFloat, StrictStr, StrictInt
|
16
15
|
from typing import Any, Dict, List, Optional, Tuple, Union
|
17
16
|
from typing_extensions import Annotated
|
18
17
|
|
19
|
-
from pydantic import Field, StrictInt, StrictStr, field_validator
|
20
|
-
from typing import Any, Dict, List, Optional
|
21
|
-
from typing_extensions import Annotated
|
22
18
|
from crypticorn.metrics.client.models.market_type import MarketType
|
23
19
|
from crypticorn.metrics.client.models.marketcap_ranking import MarketcapRanking
|
24
20
|
from crypticorn.metrics.client.models.marketcap_symbol_ranking import (
|
@@ -30,6 +26,24 @@ from crypticorn.metrics.client.api_client import ApiClient, RequestSerialized
|
|
30
26
|
from crypticorn.metrics.client.api_response import ApiResponse
|
31
27
|
from crypticorn.metrics.client.rest import RESTResponseType
|
32
28
|
|
29
|
+
# Import async_to_sync for sync methods
|
30
|
+
try:
|
31
|
+
from asgiref.sync import async_to_sync
|
32
|
+
|
33
|
+
_HAS_ASGIREF = True
|
34
|
+
except ImportError:
|
35
|
+
_HAS_ASGIREF = False
|
36
|
+
|
37
|
+
def async_to_sync(async_func):
|
38
|
+
"""Fallback decorator that raises an error if asgiref is not available."""
|
39
|
+
|
40
|
+
def wrapper(*args, **kwargs):
|
41
|
+
raise ImportError(
|
42
|
+
"asgiref is required for sync methods. Install with: pip install asgiref"
|
43
|
+
)
|
44
|
+
|
45
|
+
return wrapper
|
46
|
+
|
33
47
|
|
34
48
|
class MarketcapApi:
|
35
49
|
"""NOTE: This class is auto generated by OpenAPI Generator
|
@@ -38,13 +52,135 @@ class MarketcapApi:
|
|
38
52
|
Do not edit the class manually.
|
39
53
|
"""
|
40
54
|
|
41
|
-
def __init__(self, api_client=None) -> None:
|
55
|
+
def __init__(self, api_client=None, is_sync: bool = False) -> None:
|
42
56
|
if api_client is None:
|
43
57
|
api_client = ApiClient.get_default()
|
44
58
|
self.api_client = api_client
|
59
|
+
self.is_sync = is_sync
|
60
|
+
|
61
|
+
@validate_call
|
62
|
+
def get_current_marketcap(
|
63
|
+
self,
|
64
|
+
limit: Annotated[
|
65
|
+
Optional[Annotated[int, Field(le=100, strict=True, ge=1)]],
|
66
|
+
Field(description="Number of top symbols to fetch (1-100)"),
|
67
|
+
] = None,
|
68
|
+
_request_timeout: Union[
|
69
|
+
None,
|
70
|
+
Annotated[StrictFloat, Field(gt=0)],
|
71
|
+
Tuple[
|
72
|
+
Annotated[StrictFloat, Field(gt=0)], Annotated[StrictFloat, Field(gt=0)]
|
73
|
+
],
|
74
|
+
] = None,
|
75
|
+
_request_auth: Optional[Dict[StrictStr, Any]] = None,
|
76
|
+
_content_type: Optional[StrictStr] = None,
|
77
|
+
_headers: Optional[Dict[StrictStr, Any]] = None,
|
78
|
+
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
|
79
|
+
) -> List[Dict[str, object]]:
|
80
|
+
"""Get Current Marketcap"""
|
81
|
+
if self.is_sync:
|
82
|
+
return self._get_current_marketcap_sync(
|
83
|
+
limit=limit,
|
84
|
+
_request_timeout=_request_timeout,
|
85
|
+
_request_auth=_request_auth,
|
86
|
+
_content_type=_content_type,
|
87
|
+
_headers=_headers,
|
88
|
+
_host_index=_host_index,
|
89
|
+
)
|
90
|
+
|
91
|
+
else:
|
92
|
+
return self._get_current_marketcap_async(
|
93
|
+
limit=limit,
|
94
|
+
_request_timeout=_request_timeout,
|
95
|
+
_request_auth=_request_auth,
|
96
|
+
_content_type=_content_type,
|
97
|
+
_headers=_headers,
|
98
|
+
_host_index=_host_index,
|
99
|
+
)
|
100
|
+
|
101
|
+
@validate_call
|
102
|
+
def get_current_marketcap_with_http_info(
|
103
|
+
self,
|
104
|
+
limit: Annotated[
|
105
|
+
Optional[Annotated[int, Field(le=100, strict=True, ge=1)]],
|
106
|
+
Field(description="Number of top symbols to fetch (1-100)"),
|
107
|
+
] = None,
|
108
|
+
_request_timeout: Union[
|
109
|
+
None,
|
110
|
+
Annotated[StrictFloat, Field(gt=0)],
|
111
|
+
Tuple[
|
112
|
+
Annotated[StrictFloat, Field(gt=0)], Annotated[StrictFloat, Field(gt=0)]
|
113
|
+
],
|
114
|
+
] = None,
|
115
|
+
_request_auth: Optional[Dict[StrictStr, Any]] = None,
|
116
|
+
_content_type: Optional[StrictStr] = None,
|
117
|
+
_headers: Optional[Dict[StrictStr, Any]] = None,
|
118
|
+
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
|
119
|
+
) -> ApiResponse[List[Dict[str, object]]]:
|
120
|
+
"""Get Current Marketcap with HTTP info"""
|
121
|
+
if self.is_sync:
|
122
|
+
return self._get_current_marketcap_sync_with_http_info(
|
123
|
+
limit=limit,
|
124
|
+
_request_timeout=_request_timeout,
|
125
|
+
_request_auth=_request_auth,
|
126
|
+
_content_type=_content_type,
|
127
|
+
_headers=_headers,
|
128
|
+
_host_index=_host_index,
|
129
|
+
)
|
130
|
+
|
131
|
+
else:
|
132
|
+
return self._get_current_marketcap_async_with_http_info(
|
133
|
+
limit=limit,
|
134
|
+
_request_timeout=_request_timeout,
|
135
|
+
_request_auth=_request_auth,
|
136
|
+
_content_type=_content_type,
|
137
|
+
_headers=_headers,
|
138
|
+
_host_index=_host_index,
|
139
|
+
)
|
140
|
+
|
141
|
+
@validate_call
|
142
|
+
def get_current_marketcap_without_preload_content(
|
143
|
+
self,
|
144
|
+
limit: Annotated[
|
145
|
+
Optional[Annotated[int, Field(le=100, strict=True, ge=1)]],
|
146
|
+
Field(description="Number of top symbols to fetch (1-100)"),
|
147
|
+
] = None,
|
148
|
+
_request_timeout: Union[
|
149
|
+
None,
|
150
|
+
Annotated[StrictFloat, Field(gt=0)],
|
151
|
+
Tuple[
|
152
|
+
Annotated[StrictFloat, Field(gt=0)], Annotated[StrictFloat, Field(gt=0)]
|
153
|
+
],
|
154
|
+
] = None,
|
155
|
+
_request_auth: Optional[Dict[StrictStr, Any]] = None,
|
156
|
+
_content_type: Optional[StrictStr] = None,
|
157
|
+
_headers: Optional[Dict[StrictStr, Any]] = None,
|
158
|
+
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
|
159
|
+
) -> RESTResponseType:
|
160
|
+
"""Get Current Marketcap without preloading content"""
|
161
|
+
if self.is_sync:
|
162
|
+
return self._get_current_marketcap_sync_without_preload_content(
|
163
|
+
limit=limit,
|
164
|
+
_request_timeout=_request_timeout,
|
165
|
+
_request_auth=_request_auth,
|
166
|
+
_content_type=_content_type,
|
167
|
+
_headers=_headers,
|
168
|
+
_host_index=_host_index,
|
169
|
+
)
|
170
|
+
|
171
|
+
else:
|
172
|
+
return self._get_current_marketcap_async_without_preload_content(
|
173
|
+
limit=limit,
|
174
|
+
_request_timeout=_request_timeout,
|
175
|
+
_request_auth=_request_auth,
|
176
|
+
_content_type=_content_type,
|
177
|
+
_headers=_headers,
|
178
|
+
_host_index=_host_index,
|
179
|
+
)
|
45
180
|
|
181
|
+
# Private async implementation methods
|
46
182
|
@validate_call
|
47
|
-
async def
|
183
|
+
async def _get_current_marketcap_async(
|
48
184
|
self,
|
49
185
|
limit: Annotated[
|
50
186
|
Optional[Annotated[int, Field(le=100, strict=True, ge=1)]],
|
@@ -111,7 +247,7 @@ class MarketcapApi:
|
|
111
247
|
).data
|
112
248
|
|
113
249
|
@validate_call
|
114
|
-
async def
|
250
|
+
async def _get_current_marketcap_async_with_http_info(
|
115
251
|
self,
|
116
252
|
limit: Annotated[
|
117
253
|
Optional[Annotated[int, Field(le=100, strict=True, ge=1)]],
|
@@ -173,12 +309,11 @@ class MarketcapApi:
|
|
173
309
|
)
|
174
310
|
await response_data.read()
|
175
311
|
return self.api_client.response_deserialize(
|
176
|
-
response_data=response_data,
|
177
|
-
response_types_map=_response_types_map,
|
312
|
+
response_data=response_data, response_types_map=_response_types_map
|
178
313
|
)
|
179
314
|
|
180
315
|
@validate_call
|
181
|
-
async def
|
316
|
+
async def _get_current_marketcap_async_without_preload_content(
|
182
317
|
self,
|
183
318
|
limit: Annotated[
|
184
319
|
Optional[Annotated[int, Field(le=100, strict=True, ge=1)]],
|
@@ -238,7 +373,95 @@ class MarketcapApi:
|
|
238
373
|
response_data = await self.api_client.call_api(
|
239
374
|
*_param, _request_timeout=_request_timeout
|
240
375
|
)
|
241
|
-
return response_data
|
376
|
+
return response_data
|
377
|
+
|
378
|
+
# Private sync implementation methods
|
379
|
+
@validate_call
|
380
|
+
def _get_current_marketcap_sync(
|
381
|
+
self,
|
382
|
+
limit: Annotated[
|
383
|
+
Optional[Annotated[int, Field(le=100, strict=True, ge=1)]],
|
384
|
+
Field(description="Number of top symbols to fetch (1-100)"),
|
385
|
+
] = None,
|
386
|
+
_request_timeout: Union[
|
387
|
+
None,
|
388
|
+
Annotated[StrictFloat, Field(gt=0)],
|
389
|
+
Tuple[
|
390
|
+
Annotated[StrictFloat, Field(gt=0)], Annotated[StrictFloat, Field(gt=0)]
|
391
|
+
],
|
392
|
+
] = None,
|
393
|
+
_request_auth: Optional[Dict[StrictStr, Any]] = None,
|
394
|
+
_content_type: Optional[StrictStr] = None,
|
395
|
+
_headers: Optional[Dict[StrictStr, Any]] = None,
|
396
|
+
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
|
397
|
+
) -> List[Dict[str, object]]:
|
398
|
+
"""Synchronous version of get_current_marketcap"""
|
399
|
+
return async_to_sync(self._get_current_marketcap_async)(
|
400
|
+
limit=limit,
|
401
|
+
_request_timeout=_request_timeout,
|
402
|
+
_request_auth=_request_auth,
|
403
|
+
_content_type=_content_type,
|
404
|
+
_headers=_headers,
|
405
|
+
_host_index=_host_index,
|
406
|
+
)
|
407
|
+
|
408
|
+
@validate_call
|
409
|
+
def _get_current_marketcap_sync_with_http_info(
|
410
|
+
self,
|
411
|
+
limit: Annotated[
|
412
|
+
Optional[Annotated[int, Field(le=100, strict=True, ge=1)]],
|
413
|
+
Field(description="Number of top symbols to fetch (1-100)"),
|
414
|
+
] = None,
|
415
|
+
_request_timeout: Union[
|
416
|
+
None,
|
417
|
+
Annotated[StrictFloat, Field(gt=0)],
|
418
|
+
Tuple[
|
419
|
+
Annotated[StrictFloat, Field(gt=0)], Annotated[StrictFloat, Field(gt=0)]
|
420
|
+
],
|
421
|
+
] = None,
|
422
|
+
_request_auth: Optional[Dict[StrictStr, Any]] = None,
|
423
|
+
_content_type: Optional[StrictStr] = None,
|
424
|
+
_headers: Optional[Dict[StrictStr, Any]] = None,
|
425
|
+
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
|
426
|
+
) -> ApiResponse[List[Dict[str, object]]]:
|
427
|
+
"""Synchronous version of get_current_marketcap_with_http_info"""
|
428
|
+
return async_to_sync(self._get_current_marketcap_async_with_http_info)(
|
429
|
+
limit=limit,
|
430
|
+
_request_timeout=_request_timeout,
|
431
|
+
_request_auth=_request_auth,
|
432
|
+
_content_type=_content_type,
|
433
|
+
_headers=_headers,
|
434
|
+
_host_index=_host_index,
|
435
|
+
)
|
436
|
+
|
437
|
+
@validate_call
|
438
|
+
def _get_current_marketcap_sync_without_preload_content(
|
439
|
+
self,
|
440
|
+
limit: Annotated[
|
441
|
+
Optional[Annotated[int, Field(le=100, strict=True, ge=1)]],
|
442
|
+
Field(description="Number of top symbols to fetch (1-100)"),
|
443
|
+
] = None,
|
444
|
+
_request_timeout: Union[
|
445
|
+
None,
|
446
|
+
Annotated[StrictFloat, Field(gt=0)],
|
447
|
+
Tuple[
|
448
|
+
Annotated[StrictFloat, Field(gt=0)], Annotated[StrictFloat, Field(gt=0)]
|
449
|
+
],
|
450
|
+
] = None,
|
451
|
+
_request_auth: Optional[Dict[StrictStr, Any]] = None,
|
452
|
+
_content_type: Optional[StrictStr] = None,
|
453
|
+
_headers: Optional[Dict[StrictStr, Any]] = None,
|
454
|
+
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
|
455
|
+
) -> RESTResponseType:
|
456
|
+
"""Synchronous version of get_current_marketcap_without_preload_content"""
|
457
|
+
return async_to_sync(self._get_current_marketcap_async_without_preload_content)(
|
458
|
+
limit=limit,
|
459
|
+
_request_timeout=_request_timeout,
|
460
|
+
_request_auth=_request_auth,
|
461
|
+
_content_type=_content_type,
|
462
|
+
_headers=_headers,
|
463
|
+
_host_index=_host_index,
|
464
|
+
)
|
242
465
|
|
243
466
|
def _get_current_marketcap_serialize(
|
244
467
|
self,
|
@@ -297,7 +520,140 @@ class MarketcapApi:
|
|
297
520
|
)
|
298
521
|
|
299
522
|
@validate_call
|
300
|
-
|
523
|
+
def get_marketcap_between_timestamps(
|
524
|
+
self,
|
525
|
+
start_timestamp: Annotated[
|
526
|
+
Optional[StrictInt], Field(description="Start timestamp")
|
527
|
+
] = None,
|
528
|
+
end_timestamp: Annotated[
|
529
|
+
Optional[StrictInt], Field(description="End timestamp")
|
530
|
+
] = None,
|
531
|
+
_request_timeout: Union[
|
532
|
+
None,
|
533
|
+
Annotated[StrictFloat, Field(gt=0)],
|
534
|
+
Tuple[
|
535
|
+
Annotated[StrictFloat, Field(gt=0)], Annotated[StrictFloat, Field(gt=0)]
|
536
|
+
],
|
537
|
+
] = None,
|
538
|
+
_request_auth: Optional[Dict[StrictStr, Any]] = None,
|
539
|
+
_content_type: Optional[StrictStr] = None,
|
540
|
+
_headers: Optional[Dict[StrictStr, Any]] = None,
|
541
|
+
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
|
542
|
+
) -> List[MarketcapRanking]:
|
543
|
+
"""Get Marketcap Between Timestamps"""
|
544
|
+
if self.is_sync:
|
545
|
+
return self._get_marketcap_between_timestamps_sync(
|
546
|
+
start_timestamp=start_timestamp,
|
547
|
+
end_timestamp=end_timestamp,
|
548
|
+
_request_timeout=_request_timeout,
|
549
|
+
_request_auth=_request_auth,
|
550
|
+
_content_type=_content_type,
|
551
|
+
_headers=_headers,
|
552
|
+
_host_index=_host_index,
|
553
|
+
)
|
554
|
+
|
555
|
+
else:
|
556
|
+
return self._get_marketcap_between_timestamps_async(
|
557
|
+
start_timestamp=start_timestamp,
|
558
|
+
end_timestamp=end_timestamp,
|
559
|
+
_request_timeout=_request_timeout,
|
560
|
+
_request_auth=_request_auth,
|
561
|
+
_content_type=_content_type,
|
562
|
+
_headers=_headers,
|
563
|
+
_host_index=_host_index,
|
564
|
+
)
|
565
|
+
|
566
|
+
@validate_call
|
567
|
+
def get_marketcap_between_timestamps_with_http_info(
|
568
|
+
self,
|
569
|
+
start_timestamp: Annotated[
|
570
|
+
Optional[StrictInt], Field(description="Start timestamp")
|
571
|
+
] = None,
|
572
|
+
end_timestamp: Annotated[
|
573
|
+
Optional[StrictInt], Field(description="End timestamp")
|
574
|
+
] = None,
|
575
|
+
_request_timeout: Union[
|
576
|
+
None,
|
577
|
+
Annotated[StrictFloat, Field(gt=0)],
|
578
|
+
Tuple[
|
579
|
+
Annotated[StrictFloat, Field(gt=0)], Annotated[StrictFloat, Field(gt=0)]
|
580
|
+
],
|
581
|
+
] = None,
|
582
|
+
_request_auth: Optional[Dict[StrictStr, Any]] = None,
|
583
|
+
_content_type: Optional[StrictStr] = None,
|
584
|
+
_headers: Optional[Dict[StrictStr, Any]] = None,
|
585
|
+
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
|
586
|
+
) -> ApiResponse[List[MarketcapRanking]]:
|
587
|
+
"""Get Marketcap Between Timestamps with HTTP info"""
|
588
|
+
if self.is_sync:
|
589
|
+
return self._get_marketcap_between_timestamps_sync_with_http_info(
|
590
|
+
start_timestamp=start_timestamp,
|
591
|
+
end_timestamp=end_timestamp,
|
592
|
+
_request_timeout=_request_timeout,
|
593
|
+
_request_auth=_request_auth,
|
594
|
+
_content_type=_content_type,
|
595
|
+
_headers=_headers,
|
596
|
+
_host_index=_host_index,
|
597
|
+
)
|
598
|
+
|
599
|
+
else:
|
600
|
+
return self._get_marketcap_between_timestamps_async_with_http_info(
|
601
|
+
start_timestamp=start_timestamp,
|
602
|
+
end_timestamp=end_timestamp,
|
603
|
+
_request_timeout=_request_timeout,
|
604
|
+
_request_auth=_request_auth,
|
605
|
+
_content_type=_content_type,
|
606
|
+
_headers=_headers,
|
607
|
+
_host_index=_host_index,
|
608
|
+
)
|
609
|
+
|
610
|
+
@validate_call
|
611
|
+
def get_marketcap_between_timestamps_without_preload_content(
|
612
|
+
self,
|
613
|
+
start_timestamp: Annotated[
|
614
|
+
Optional[StrictInt], Field(description="Start timestamp")
|
615
|
+
] = None,
|
616
|
+
end_timestamp: Annotated[
|
617
|
+
Optional[StrictInt], Field(description="End timestamp")
|
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 Marketcap Between Timestamps without preloading content"""
|
632
|
+
if self.is_sync:
|
633
|
+
return self._get_marketcap_between_timestamps_sync_without_preload_content(
|
634
|
+
start_timestamp=start_timestamp,
|
635
|
+
end_timestamp=end_timestamp,
|
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_marketcap_between_timestamps_async_without_preload_content(
|
645
|
+
start_timestamp=start_timestamp,
|
646
|
+
end_timestamp=end_timestamp,
|
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_marketcap_between_timestamps_async(
|
301
657
|
self,
|
302
658
|
start_timestamp: Annotated[
|
303
659
|
Optional[StrictInt], Field(description="Start timestamp")
|
@@ -369,7 +725,7 @@ class MarketcapApi:
|
|
369
725
|
).data
|
370
726
|
|
371
727
|
@validate_call
|
372
|
-
async def
|
728
|
+
async def _get_marketcap_between_timestamps_async_with_http_info(
|
373
729
|
self,
|
374
730
|
start_timestamp: Annotated[
|
375
731
|
Optional[StrictInt], Field(description="Start timestamp")
|
@@ -436,12 +792,11 @@ class MarketcapApi:
|
|
436
792
|
)
|
437
793
|
await response_data.read()
|
438
794
|
return self.api_client.response_deserialize(
|
439
|
-
response_data=response_data,
|
440
|
-
response_types_map=_response_types_map,
|
795
|
+
response_data=response_data, response_types_map=_response_types_map
|
441
796
|
)
|
442
797
|
|
443
798
|
@validate_call
|
444
|
-
async def
|
799
|
+
async def _get_marketcap_between_timestamps_async_without_preload_content(
|
445
800
|
self,
|
446
801
|
start_timestamp: Annotated[
|
447
802
|
Optional[StrictInt], Field(description="Start timestamp")
|
@@ -506,40 +861,141 @@ class MarketcapApi:
|
|
506
861
|
response_data = await self.api_client.call_api(
|
507
862
|
*_param, _request_timeout=_request_timeout
|
508
863
|
)
|
509
|
-
return response_data
|
864
|
+
return response_data
|
510
865
|
|
511
|
-
|
866
|
+
# Private sync implementation methods
|
867
|
+
@validate_call
|
868
|
+
def _get_marketcap_between_timestamps_sync(
|
512
869
|
self,
|
513
|
-
start_timestamp
|
514
|
-
|
515
|
-
|
516
|
-
|
517
|
-
|
518
|
-
|
519
|
-
|
520
|
-
|
521
|
-
|
522
|
-
|
523
|
-
|
524
|
-
|
525
|
-
|
526
|
-
|
527
|
-
|
528
|
-
|
529
|
-
|
530
|
-
|
531
|
-
|
532
|
-
|
533
|
-
|
534
|
-
|
535
|
-
|
536
|
-
|
537
|
-
|
538
|
-
|
539
|
-
|
540
|
-
|
541
|
-
|
542
|
-
|
870
|
+
start_timestamp: Annotated[
|
871
|
+
Optional[StrictInt], Field(description="Start timestamp")
|
872
|
+
] = None,
|
873
|
+
end_timestamp: Annotated[
|
874
|
+
Optional[StrictInt], Field(description="End timestamp")
|
875
|
+
] = None,
|
876
|
+
_request_timeout: Union[
|
877
|
+
None,
|
878
|
+
Annotated[StrictFloat, Field(gt=0)],
|
879
|
+
Tuple[
|
880
|
+
Annotated[StrictFloat, Field(gt=0)], Annotated[StrictFloat, Field(gt=0)]
|
881
|
+
],
|
882
|
+
] = None,
|
883
|
+
_request_auth: Optional[Dict[StrictStr, Any]] = None,
|
884
|
+
_content_type: Optional[StrictStr] = None,
|
885
|
+
_headers: Optional[Dict[StrictStr, Any]] = None,
|
886
|
+
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
|
887
|
+
) -> List[MarketcapRanking]:
|
888
|
+
"""Synchronous version of get_marketcap_between_timestamps"""
|
889
|
+
return async_to_sync(self._get_marketcap_between_timestamps_async)(
|
890
|
+
start_timestamp=start_timestamp,
|
891
|
+
end_timestamp=end_timestamp,
|
892
|
+
_request_timeout=_request_timeout,
|
893
|
+
_request_auth=_request_auth,
|
894
|
+
_content_type=_content_type,
|
895
|
+
_headers=_headers,
|
896
|
+
_host_index=_host_index,
|
897
|
+
)
|
898
|
+
|
899
|
+
@validate_call
|
900
|
+
def _get_marketcap_between_timestamps_sync_with_http_info(
|
901
|
+
self,
|
902
|
+
start_timestamp: Annotated[
|
903
|
+
Optional[StrictInt], Field(description="Start timestamp")
|
904
|
+
] = None,
|
905
|
+
end_timestamp: Annotated[
|
906
|
+
Optional[StrictInt], Field(description="End timestamp")
|
907
|
+
] = None,
|
908
|
+
_request_timeout: Union[
|
909
|
+
None,
|
910
|
+
Annotated[StrictFloat, Field(gt=0)],
|
911
|
+
Tuple[
|
912
|
+
Annotated[StrictFloat, Field(gt=0)], Annotated[StrictFloat, Field(gt=0)]
|
913
|
+
],
|
914
|
+
] = None,
|
915
|
+
_request_auth: Optional[Dict[StrictStr, Any]] = None,
|
916
|
+
_content_type: Optional[StrictStr] = None,
|
917
|
+
_headers: Optional[Dict[StrictStr, Any]] = None,
|
918
|
+
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
|
919
|
+
) -> ApiResponse[List[MarketcapRanking]]:
|
920
|
+
"""Synchronous version of get_marketcap_between_timestamps_with_http_info"""
|
921
|
+
return async_to_sync(
|
922
|
+
self._get_marketcap_between_timestamps_async_with_http_info
|
923
|
+
)(
|
924
|
+
start_timestamp=start_timestamp,
|
925
|
+
end_timestamp=end_timestamp,
|
926
|
+
_request_timeout=_request_timeout,
|
927
|
+
_request_auth=_request_auth,
|
928
|
+
_content_type=_content_type,
|
929
|
+
_headers=_headers,
|
930
|
+
_host_index=_host_index,
|
931
|
+
)
|
932
|
+
|
933
|
+
@validate_call
|
934
|
+
def _get_marketcap_between_timestamps_sync_without_preload_content(
|
935
|
+
self,
|
936
|
+
start_timestamp: Annotated[
|
937
|
+
Optional[StrictInt], Field(description="Start timestamp")
|
938
|
+
] = None,
|
939
|
+
end_timestamp: Annotated[
|
940
|
+
Optional[StrictInt], Field(description="End timestamp")
|
941
|
+
] = None,
|
942
|
+
_request_timeout: Union[
|
943
|
+
None,
|
944
|
+
Annotated[StrictFloat, Field(gt=0)],
|
945
|
+
Tuple[
|
946
|
+
Annotated[StrictFloat, Field(gt=0)], Annotated[StrictFloat, Field(gt=0)]
|
947
|
+
],
|
948
|
+
] = None,
|
949
|
+
_request_auth: Optional[Dict[StrictStr, Any]] = None,
|
950
|
+
_content_type: Optional[StrictStr] = None,
|
951
|
+
_headers: Optional[Dict[StrictStr, Any]] = None,
|
952
|
+
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
|
953
|
+
) -> RESTResponseType:
|
954
|
+
"""Synchronous version of get_marketcap_between_timestamps_without_preload_content"""
|
955
|
+
return async_to_sync(
|
956
|
+
self._get_marketcap_between_timestamps_async_without_preload_content
|
957
|
+
)(
|
958
|
+
start_timestamp=start_timestamp,
|
959
|
+
end_timestamp=end_timestamp,
|
960
|
+
_request_timeout=_request_timeout,
|
961
|
+
_request_auth=_request_auth,
|
962
|
+
_content_type=_content_type,
|
963
|
+
_headers=_headers,
|
964
|
+
_host_index=_host_index,
|
965
|
+
)
|
966
|
+
|
967
|
+
def _get_marketcap_between_timestamps_serialize(
|
968
|
+
self,
|
969
|
+
start_timestamp,
|
970
|
+
end_timestamp,
|
971
|
+
_request_auth,
|
972
|
+
_content_type,
|
973
|
+
_headers,
|
974
|
+
_host_index,
|
975
|
+
) -> RequestSerialized:
|
976
|
+
|
977
|
+
_host = None
|
978
|
+
|
979
|
+
_collection_formats: Dict[str, str] = {}
|
980
|
+
|
981
|
+
_path_params: Dict[str, str] = {}
|
982
|
+
_query_params: List[Tuple[str, str]] = []
|
983
|
+
_header_params: Dict[str, Optional[str]] = _headers or {}
|
984
|
+
_form_params: List[Tuple[str, str]] = []
|
985
|
+
_files: Dict[
|
986
|
+
str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
|
987
|
+
] = {}
|
988
|
+
_body_params: Optional[bytes] = None
|
989
|
+
|
990
|
+
# process the path parameters
|
991
|
+
# process the query parameters
|
992
|
+
if start_timestamp is not None:
|
993
|
+
|
994
|
+
_query_params.append(("start_timestamp", start_timestamp))
|
995
|
+
|
996
|
+
if end_timestamp is not None:
|
997
|
+
|
998
|
+
_query_params.append(("end_timestamp", end_timestamp))
|
543
999
|
|
544
1000
|
# process the header parameters
|
545
1001
|
# process the form parameters
|
@@ -570,7 +1026,206 @@ class MarketcapApi:
|
|
570
1026
|
)
|
571
1027
|
|
572
1028
|
@validate_call
|
573
|
-
|
1029
|
+
def get_marketcap_symbols(
|
1030
|
+
self,
|
1031
|
+
start_timestamp: Annotated[
|
1032
|
+
Optional[StrictInt], Field(description="Start timestamp")
|
1033
|
+
] = None,
|
1034
|
+
end_timestamp: Annotated[
|
1035
|
+
Optional[StrictInt], Field(description="End timestamp")
|
1036
|
+
] = None,
|
1037
|
+
interval: Annotated[
|
1038
|
+
Optional[StrictStr],
|
1039
|
+
Field(description="Interval for which to fetch symbols and marketcap data"),
|
1040
|
+
] = None,
|
1041
|
+
market: Annotated[
|
1042
|
+
Optional[MarketType],
|
1043
|
+
Field(
|
1044
|
+
description="Market for which to fetch symbols and marketcap data. Defaults to futures."
|
1045
|
+
),
|
1046
|
+
] = None,
|
1047
|
+
exchange: Annotated[
|
1048
|
+
Optional[StrictStr],
|
1049
|
+
Field(
|
1050
|
+
description="Exchange for which to fetch symbols and marketcap data. If not provided, all exchanges will be returned."
|
1051
|
+
),
|
1052
|
+
] = None,
|
1053
|
+
_request_timeout: Union[
|
1054
|
+
None,
|
1055
|
+
Annotated[StrictFloat, Field(gt=0)],
|
1056
|
+
Tuple[
|
1057
|
+
Annotated[StrictFloat, Field(gt=0)], Annotated[StrictFloat, Field(gt=0)]
|
1058
|
+
],
|
1059
|
+
] = None,
|
1060
|
+
_request_auth: Optional[Dict[StrictStr, Any]] = None,
|
1061
|
+
_content_type: Optional[StrictStr] = None,
|
1062
|
+
_headers: Optional[Dict[StrictStr, Any]] = None,
|
1063
|
+
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
|
1064
|
+
) -> List[MarketcapSymbolRanking]:
|
1065
|
+
"""Get Symbols Marketcap Between Timestamps"""
|
1066
|
+
if self.is_sync:
|
1067
|
+
return self._get_marketcap_symbols_sync(
|
1068
|
+
start_timestamp=start_timestamp,
|
1069
|
+
end_timestamp=end_timestamp,
|
1070
|
+
interval=interval,
|
1071
|
+
market=market,
|
1072
|
+
exchange=exchange,
|
1073
|
+
_request_timeout=_request_timeout,
|
1074
|
+
_request_auth=_request_auth,
|
1075
|
+
_content_type=_content_type,
|
1076
|
+
_headers=_headers,
|
1077
|
+
_host_index=_host_index,
|
1078
|
+
)
|
1079
|
+
|
1080
|
+
else:
|
1081
|
+
return self._get_marketcap_symbols_async(
|
1082
|
+
start_timestamp=start_timestamp,
|
1083
|
+
end_timestamp=end_timestamp,
|
1084
|
+
interval=interval,
|
1085
|
+
market=market,
|
1086
|
+
exchange=exchange,
|
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_marketcap_symbols_with_http_info(
|
1096
|
+
self,
|
1097
|
+
start_timestamp: Annotated[
|
1098
|
+
Optional[StrictInt], Field(description="Start timestamp")
|
1099
|
+
] = None,
|
1100
|
+
end_timestamp: Annotated[
|
1101
|
+
Optional[StrictInt], Field(description="End timestamp")
|
1102
|
+
] = None,
|
1103
|
+
interval: Annotated[
|
1104
|
+
Optional[StrictStr],
|
1105
|
+
Field(description="Interval for which to fetch symbols and marketcap data"),
|
1106
|
+
] = None,
|
1107
|
+
market: Annotated[
|
1108
|
+
Optional[MarketType],
|
1109
|
+
Field(
|
1110
|
+
description="Market for which to fetch symbols and marketcap data. Defaults to futures."
|
1111
|
+
),
|
1112
|
+
] = None,
|
1113
|
+
exchange: Annotated[
|
1114
|
+
Optional[StrictStr],
|
1115
|
+
Field(
|
1116
|
+
description="Exchange for which to fetch symbols and marketcap data. If not provided, all exchanges will be returned."
|
1117
|
+
),
|
1118
|
+
] = None,
|
1119
|
+
_request_timeout: Union[
|
1120
|
+
None,
|
1121
|
+
Annotated[StrictFloat, Field(gt=0)],
|
1122
|
+
Tuple[
|
1123
|
+
Annotated[StrictFloat, Field(gt=0)], Annotated[StrictFloat, Field(gt=0)]
|
1124
|
+
],
|
1125
|
+
] = None,
|
1126
|
+
_request_auth: Optional[Dict[StrictStr, Any]] = None,
|
1127
|
+
_content_type: Optional[StrictStr] = None,
|
1128
|
+
_headers: Optional[Dict[StrictStr, Any]] = None,
|
1129
|
+
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
|
1130
|
+
) -> ApiResponse[List[MarketcapSymbolRanking]]:
|
1131
|
+
"""Get Symbols Marketcap Between Timestamps with HTTP info"""
|
1132
|
+
if self.is_sync:
|
1133
|
+
return self._get_marketcap_symbols_sync_with_http_info(
|
1134
|
+
start_timestamp=start_timestamp,
|
1135
|
+
end_timestamp=end_timestamp,
|
1136
|
+
interval=interval,
|
1137
|
+
market=market,
|
1138
|
+
exchange=exchange,
|
1139
|
+
_request_timeout=_request_timeout,
|
1140
|
+
_request_auth=_request_auth,
|
1141
|
+
_content_type=_content_type,
|
1142
|
+
_headers=_headers,
|
1143
|
+
_host_index=_host_index,
|
1144
|
+
)
|
1145
|
+
|
1146
|
+
else:
|
1147
|
+
return self._get_marketcap_symbols_async_with_http_info(
|
1148
|
+
start_timestamp=start_timestamp,
|
1149
|
+
end_timestamp=end_timestamp,
|
1150
|
+
interval=interval,
|
1151
|
+
market=market,
|
1152
|
+
exchange=exchange,
|
1153
|
+
_request_timeout=_request_timeout,
|
1154
|
+
_request_auth=_request_auth,
|
1155
|
+
_content_type=_content_type,
|
1156
|
+
_headers=_headers,
|
1157
|
+
_host_index=_host_index,
|
1158
|
+
)
|
1159
|
+
|
1160
|
+
@validate_call
|
1161
|
+
def get_marketcap_symbols_without_preload_content(
|
1162
|
+
self,
|
1163
|
+
start_timestamp: Annotated[
|
1164
|
+
Optional[StrictInt], Field(description="Start timestamp")
|
1165
|
+
] = None,
|
1166
|
+
end_timestamp: Annotated[
|
1167
|
+
Optional[StrictInt], Field(description="End timestamp")
|
1168
|
+
] = None,
|
1169
|
+
interval: Annotated[
|
1170
|
+
Optional[StrictStr],
|
1171
|
+
Field(description="Interval for which to fetch symbols and marketcap data"),
|
1172
|
+
] = None,
|
1173
|
+
market: Annotated[
|
1174
|
+
Optional[MarketType],
|
1175
|
+
Field(
|
1176
|
+
description="Market for which to fetch symbols and marketcap data. Defaults to futures."
|
1177
|
+
),
|
1178
|
+
] = None,
|
1179
|
+
exchange: Annotated[
|
1180
|
+
Optional[StrictStr],
|
1181
|
+
Field(
|
1182
|
+
description="Exchange for which to fetch symbols and marketcap data. If not provided, all exchanges will be returned."
|
1183
|
+
),
|
1184
|
+
] = None,
|
1185
|
+
_request_timeout: Union[
|
1186
|
+
None,
|
1187
|
+
Annotated[StrictFloat, Field(gt=0)],
|
1188
|
+
Tuple[
|
1189
|
+
Annotated[StrictFloat, Field(gt=0)], Annotated[StrictFloat, Field(gt=0)]
|
1190
|
+
],
|
1191
|
+
] = None,
|
1192
|
+
_request_auth: Optional[Dict[StrictStr, Any]] = None,
|
1193
|
+
_content_type: Optional[StrictStr] = None,
|
1194
|
+
_headers: Optional[Dict[StrictStr, Any]] = None,
|
1195
|
+
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
|
1196
|
+
) -> RESTResponseType:
|
1197
|
+
"""Get Symbols Marketcap Between Timestamps without preloading content"""
|
1198
|
+
if self.is_sync:
|
1199
|
+
return self._get_marketcap_symbols_sync_without_preload_content(
|
1200
|
+
start_timestamp=start_timestamp,
|
1201
|
+
end_timestamp=end_timestamp,
|
1202
|
+
interval=interval,
|
1203
|
+
market=market,
|
1204
|
+
exchange=exchange,
|
1205
|
+
_request_timeout=_request_timeout,
|
1206
|
+
_request_auth=_request_auth,
|
1207
|
+
_content_type=_content_type,
|
1208
|
+
_headers=_headers,
|
1209
|
+
_host_index=_host_index,
|
1210
|
+
)
|
1211
|
+
|
1212
|
+
else:
|
1213
|
+
return self._get_marketcap_symbols_async_without_preload_content(
|
1214
|
+
start_timestamp=start_timestamp,
|
1215
|
+
end_timestamp=end_timestamp,
|
1216
|
+
interval=interval,
|
1217
|
+
market=market,
|
1218
|
+
exchange=exchange,
|
1219
|
+
_request_timeout=_request_timeout,
|
1220
|
+
_request_auth=_request_auth,
|
1221
|
+
_content_type=_content_type,
|
1222
|
+
_headers=_headers,
|
1223
|
+
_host_index=_host_index,
|
1224
|
+
)
|
1225
|
+
|
1226
|
+
# Private async implementation methods
|
1227
|
+
@validate_call
|
1228
|
+
async def _get_marketcap_symbols_async(
|
574
1229
|
self,
|
575
1230
|
start_timestamp: Annotated[
|
576
1231
|
Optional[StrictInt], Field(description="Start timestamp")
|
@@ -667,7 +1322,7 @@ class MarketcapApi:
|
|
667
1322
|
).data
|
668
1323
|
|
669
1324
|
@validate_call
|
670
|
-
async def
|
1325
|
+
async def _get_marketcap_symbols_async_with_http_info(
|
671
1326
|
self,
|
672
1327
|
start_timestamp: Annotated[
|
673
1328
|
Optional[StrictInt], Field(description="Start timestamp")
|
@@ -759,12 +1414,11 @@ class MarketcapApi:
|
|
759
1414
|
)
|
760
1415
|
await response_data.read()
|
761
1416
|
return self.api_client.response_deserialize(
|
762
|
-
response_data=response_data,
|
763
|
-
response_types_map=_response_types_map,
|
1417
|
+
response_data=response_data, response_types_map=_response_types_map
|
764
1418
|
)
|
765
1419
|
|
766
1420
|
@validate_call
|
767
|
-
async def
|
1421
|
+
async def _get_marketcap_symbols_async_without_preload_content(
|
768
1422
|
self,
|
769
1423
|
start_timestamp: Annotated[
|
770
1424
|
Optional[StrictInt], Field(description="Start timestamp")
|
@@ -848,14 +1502,168 @@ class MarketcapApi:
|
|
848
1502
|
_host_index=_host_index,
|
849
1503
|
)
|
850
1504
|
|
851
|
-
_response_types_map: Dict[str, Optional[str]] = {
|
852
|
-
"200": "List[MarketcapSymbolRanking]",
|
853
|
-
}
|
854
|
-
response_data = await self.api_client.call_api(
|
855
|
-
*_param, _request_timeout=_request_timeout
|
856
|
-
)
|
857
|
-
return response_data
|
858
|
-
|
1505
|
+
_response_types_map: Dict[str, Optional[str]] = {
|
1506
|
+
"200": "List[MarketcapSymbolRanking]",
|
1507
|
+
}
|
1508
|
+
response_data = await self.api_client.call_api(
|
1509
|
+
*_param, _request_timeout=_request_timeout
|
1510
|
+
)
|
1511
|
+
return response_data
|
1512
|
+
|
1513
|
+
# Private sync implementation methods
|
1514
|
+
@validate_call
|
1515
|
+
def _get_marketcap_symbols_sync(
|
1516
|
+
self,
|
1517
|
+
start_timestamp: Annotated[
|
1518
|
+
Optional[StrictInt], Field(description="Start timestamp")
|
1519
|
+
] = None,
|
1520
|
+
end_timestamp: Annotated[
|
1521
|
+
Optional[StrictInt], Field(description="End timestamp")
|
1522
|
+
] = None,
|
1523
|
+
interval: Annotated[
|
1524
|
+
Optional[StrictStr],
|
1525
|
+
Field(description="Interval for which to fetch symbols and marketcap data"),
|
1526
|
+
] = None,
|
1527
|
+
market: Annotated[
|
1528
|
+
Optional[MarketType],
|
1529
|
+
Field(
|
1530
|
+
description="Market for which to fetch symbols and marketcap data. Defaults to futures."
|
1531
|
+
),
|
1532
|
+
] = None,
|
1533
|
+
exchange: Annotated[
|
1534
|
+
Optional[StrictStr],
|
1535
|
+
Field(
|
1536
|
+
description="Exchange for which to fetch symbols and marketcap data. If not provided, all exchanges will be returned."
|
1537
|
+
),
|
1538
|
+
] = None,
|
1539
|
+
_request_timeout: Union[
|
1540
|
+
None,
|
1541
|
+
Annotated[StrictFloat, Field(gt=0)],
|
1542
|
+
Tuple[
|
1543
|
+
Annotated[StrictFloat, Field(gt=0)], Annotated[StrictFloat, Field(gt=0)]
|
1544
|
+
],
|
1545
|
+
] = None,
|
1546
|
+
_request_auth: Optional[Dict[StrictStr, Any]] = None,
|
1547
|
+
_content_type: Optional[StrictStr] = None,
|
1548
|
+
_headers: Optional[Dict[StrictStr, Any]] = None,
|
1549
|
+
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
|
1550
|
+
) -> List[MarketcapSymbolRanking]:
|
1551
|
+
"""Synchronous version of get_marketcap_symbols"""
|
1552
|
+
return async_to_sync(self._get_marketcap_symbols_async)(
|
1553
|
+
start_timestamp=start_timestamp,
|
1554
|
+
end_timestamp=end_timestamp,
|
1555
|
+
interval=interval,
|
1556
|
+
market=market,
|
1557
|
+
exchange=exchange,
|
1558
|
+
_request_timeout=_request_timeout,
|
1559
|
+
_request_auth=_request_auth,
|
1560
|
+
_content_type=_content_type,
|
1561
|
+
_headers=_headers,
|
1562
|
+
_host_index=_host_index,
|
1563
|
+
)
|
1564
|
+
|
1565
|
+
@validate_call
|
1566
|
+
def _get_marketcap_symbols_sync_with_http_info(
|
1567
|
+
self,
|
1568
|
+
start_timestamp: Annotated[
|
1569
|
+
Optional[StrictInt], Field(description="Start timestamp")
|
1570
|
+
] = None,
|
1571
|
+
end_timestamp: Annotated[
|
1572
|
+
Optional[StrictInt], Field(description="End timestamp")
|
1573
|
+
] = None,
|
1574
|
+
interval: Annotated[
|
1575
|
+
Optional[StrictStr],
|
1576
|
+
Field(description="Interval for which to fetch symbols and marketcap data"),
|
1577
|
+
] = None,
|
1578
|
+
market: Annotated[
|
1579
|
+
Optional[MarketType],
|
1580
|
+
Field(
|
1581
|
+
description="Market for which to fetch symbols and marketcap data. Defaults to futures."
|
1582
|
+
),
|
1583
|
+
] = None,
|
1584
|
+
exchange: Annotated[
|
1585
|
+
Optional[StrictStr],
|
1586
|
+
Field(
|
1587
|
+
description="Exchange for which to fetch symbols and marketcap data. If not provided, all exchanges will be returned."
|
1588
|
+
),
|
1589
|
+
] = None,
|
1590
|
+
_request_timeout: Union[
|
1591
|
+
None,
|
1592
|
+
Annotated[StrictFloat, Field(gt=0)],
|
1593
|
+
Tuple[
|
1594
|
+
Annotated[StrictFloat, Field(gt=0)], Annotated[StrictFloat, Field(gt=0)]
|
1595
|
+
],
|
1596
|
+
] = None,
|
1597
|
+
_request_auth: Optional[Dict[StrictStr, Any]] = None,
|
1598
|
+
_content_type: Optional[StrictStr] = None,
|
1599
|
+
_headers: Optional[Dict[StrictStr, Any]] = None,
|
1600
|
+
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
|
1601
|
+
) -> ApiResponse[List[MarketcapSymbolRanking]]:
|
1602
|
+
"""Synchronous version of get_marketcap_symbols_with_http_info"""
|
1603
|
+
return async_to_sync(self._get_marketcap_symbols_async_with_http_info)(
|
1604
|
+
start_timestamp=start_timestamp,
|
1605
|
+
end_timestamp=end_timestamp,
|
1606
|
+
interval=interval,
|
1607
|
+
market=market,
|
1608
|
+
exchange=exchange,
|
1609
|
+
_request_timeout=_request_timeout,
|
1610
|
+
_request_auth=_request_auth,
|
1611
|
+
_content_type=_content_type,
|
1612
|
+
_headers=_headers,
|
1613
|
+
_host_index=_host_index,
|
1614
|
+
)
|
1615
|
+
|
1616
|
+
@validate_call
|
1617
|
+
def _get_marketcap_symbols_sync_without_preload_content(
|
1618
|
+
self,
|
1619
|
+
start_timestamp: Annotated[
|
1620
|
+
Optional[StrictInt], Field(description="Start timestamp")
|
1621
|
+
] = None,
|
1622
|
+
end_timestamp: Annotated[
|
1623
|
+
Optional[StrictInt], Field(description="End timestamp")
|
1624
|
+
] = None,
|
1625
|
+
interval: Annotated[
|
1626
|
+
Optional[StrictStr],
|
1627
|
+
Field(description="Interval for which to fetch symbols and marketcap data"),
|
1628
|
+
] = None,
|
1629
|
+
market: Annotated[
|
1630
|
+
Optional[MarketType],
|
1631
|
+
Field(
|
1632
|
+
description="Market for which to fetch symbols and marketcap data. Defaults to futures."
|
1633
|
+
),
|
1634
|
+
] = None,
|
1635
|
+
exchange: Annotated[
|
1636
|
+
Optional[StrictStr],
|
1637
|
+
Field(
|
1638
|
+
description="Exchange for which to fetch symbols and marketcap data. If not provided, all exchanges will be returned."
|
1639
|
+
),
|
1640
|
+
] = None,
|
1641
|
+
_request_timeout: Union[
|
1642
|
+
None,
|
1643
|
+
Annotated[StrictFloat, Field(gt=0)],
|
1644
|
+
Tuple[
|
1645
|
+
Annotated[StrictFloat, Field(gt=0)], Annotated[StrictFloat, Field(gt=0)]
|
1646
|
+
],
|
1647
|
+
] = None,
|
1648
|
+
_request_auth: Optional[Dict[StrictStr, Any]] = None,
|
1649
|
+
_content_type: Optional[StrictStr] = None,
|
1650
|
+
_headers: Optional[Dict[StrictStr, Any]] = None,
|
1651
|
+
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
|
1652
|
+
) -> RESTResponseType:
|
1653
|
+
"""Synchronous version of get_marketcap_symbols_without_preload_content"""
|
1654
|
+
return async_to_sync(self._get_marketcap_symbols_async_without_preload_content)(
|
1655
|
+
start_timestamp=start_timestamp,
|
1656
|
+
end_timestamp=end_timestamp,
|
1657
|
+
interval=interval,
|
1658
|
+
market=market,
|
1659
|
+
exchange=exchange,
|
1660
|
+
_request_timeout=_request_timeout,
|
1661
|
+
_request_auth=_request_auth,
|
1662
|
+
_content_type=_content_type,
|
1663
|
+
_headers=_headers,
|
1664
|
+
_host_index=_host_index,
|
1665
|
+
)
|
1666
|
+
|
859
1667
|
def _get_marketcap_symbols_serialize(
|
860
1668
|
self,
|
861
1669
|
start_timestamp,
|
@@ -933,7 +1741,194 @@ class MarketcapApi:
|
|
933
1741
|
)
|
934
1742
|
|
935
1743
|
@validate_call
|
936
|
-
|
1744
|
+
def get_marketcap_symbols_with_ohlcv(
|
1745
|
+
self,
|
1746
|
+
timestamp: Annotated[
|
1747
|
+
Optional[StrictInt],
|
1748
|
+
Field(description="Timestamp for which to fetch symbols and OHLCV data"),
|
1749
|
+
] = None,
|
1750
|
+
timeframe: Annotated[
|
1751
|
+
Optional[StrictStr], Field(description="Timeframe for OHLCV data")
|
1752
|
+
] = None,
|
1753
|
+
market: Annotated[
|
1754
|
+
Optional[MarketType],
|
1755
|
+
Field(description="Market for OHLCV data. Defaults to futures."),
|
1756
|
+
] = None,
|
1757
|
+
top_n: Annotated[
|
1758
|
+
Optional[StrictInt], Field(description="Number of symbols to fetch")
|
1759
|
+
] = None,
|
1760
|
+
ohlcv_limit: Annotated[
|
1761
|
+
Optional[StrictInt],
|
1762
|
+
Field(description="Number of OHLCV data points to fetch"),
|
1763
|
+
] = None,
|
1764
|
+
_request_timeout: Union[
|
1765
|
+
None,
|
1766
|
+
Annotated[StrictFloat, Field(gt=0)],
|
1767
|
+
Tuple[
|
1768
|
+
Annotated[StrictFloat, Field(gt=0)], Annotated[StrictFloat, Field(gt=0)]
|
1769
|
+
],
|
1770
|
+
] = None,
|
1771
|
+
_request_auth: Optional[Dict[StrictStr, Any]] = None,
|
1772
|
+
_content_type: Optional[StrictStr] = None,
|
1773
|
+
_headers: Optional[Dict[StrictStr, Any]] = None,
|
1774
|
+
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
|
1775
|
+
) -> Dict[str, List[OHLCV]]:
|
1776
|
+
"""Get Symbols Marketcap With Ohlcv"""
|
1777
|
+
if self.is_sync:
|
1778
|
+
return self._get_marketcap_symbols_with_ohlcv_sync(
|
1779
|
+
timestamp=timestamp,
|
1780
|
+
timeframe=timeframe,
|
1781
|
+
market=market,
|
1782
|
+
top_n=top_n,
|
1783
|
+
ohlcv_limit=ohlcv_limit,
|
1784
|
+
_request_timeout=_request_timeout,
|
1785
|
+
_request_auth=_request_auth,
|
1786
|
+
_content_type=_content_type,
|
1787
|
+
_headers=_headers,
|
1788
|
+
_host_index=_host_index,
|
1789
|
+
)
|
1790
|
+
|
1791
|
+
else:
|
1792
|
+
return self._get_marketcap_symbols_with_ohlcv_async(
|
1793
|
+
timestamp=timestamp,
|
1794
|
+
timeframe=timeframe,
|
1795
|
+
market=market,
|
1796
|
+
top_n=top_n,
|
1797
|
+
ohlcv_limit=ohlcv_limit,
|
1798
|
+
_request_timeout=_request_timeout,
|
1799
|
+
_request_auth=_request_auth,
|
1800
|
+
_content_type=_content_type,
|
1801
|
+
_headers=_headers,
|
1802
|
+
_host_index=_host_index,
|
1803
|
+
)
|
1804
|
+
|
1805
|
+
@validate_call
|
1806
|
+
def get_marketcap_symbols_with_ohlcv_with_http_info(
|
1807
|
+
self,
|
1808
|
+
timestamp: Annotated[
|
1809
|
+
Optional[StrictInt],
|
1810
|
+
Field(description="Timestamp for which to fetch symbols and OHLCV data"),
|
1811
|
+
] = None,
|
1812
|
+
timeframe: Annotated[
|
1813
|
+
Optional[StrictStr], Field(description="Timeframe for OHLCV data")
|
1814
|
+
] = None,
|
1815
|
+
market: Annotated[
|
1816
|
+
Optional[MarketType],
|
1817
|
+
Field(description="Market for OHLCV data. Defaults to futures."),
|
1818
|
+
] = None,
|
1819
|
+
top_n: Annotated[
|
1820
|
+
Optional[StrictInt], Field(description="Number of symbols to fetch")
|
1821
|
+
] = None,
|
1822
|
+
ohlcv_limit: Annotated[
|
1823
|
+
Optional[StrictInt],
|
1824
|
+
Field(description="Number of OHLCV data points to fetch"),
|
1825
|
+
] = None,
|
1826
|
+
_request_timeout: Union[
|
1827
|
+
None,
|
1828
|
+
Annotated[StrictFloat, Field(gt=0)],
|
1829
|
+
Tuple[
|
1830
|
+
Annotated[StrictFloat, Field(gt=0)], Annotated[StrictFloat, Field(gt=0)]
|
1831
|
+
],
|
1832
|
+
] = None,
|
1833
|
+
_request_auth: Optional[Dict[StrictStr, Any]] = None,
|
1834
|
+
_content_type: Optional[StrictStr] = None,
|
1835
|
+
_headers: Optional[Dict[StrictStr, Any]] = None,
|
1836
|
+
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
|
1837
|
+
) -> ApiResponse[Dict[str, List[OHLCV]]]:
|
1838
|
+
"""Get Symbols Marketcap With Ohlcv with HTTP info"""
|
1839
|
+
if self.is_sync:
|
1840
|
+
return self._get_marketcap_symbols_with_ohlcv_sync_with_http_info(
|
1841
|
+
timestamp=timestamp,
|
1842
|
+
timeframe=timeframe,
|
1843
|
+
market=market,
|
1844
|
+
top_n=top_n,
|
1845
|
+
ohlcv_limit=ohlcv_limit,
|
1846
|
+
_request_timeout=_request_timeout,
|
1847
|
+
_request_auth=_request_auth,
|
1848
|
+
_content_type=_content_type,
|
1849
|
+
_headers=_headers,
|
1850
|
+
_host_index=_host_index,
|
1851
|
+
)
|
1852
|
+
|
1853
|
+
else:
|
1854
|
+
return self._get_marketcap_symbols_with_ohlcv_async_with_http_info(
|
1855
|
+
timestamp=timestamp,
|
1856
|
+
timeframe=timeframe,
|
1857
|
+
market=market,
|
1858
|
+
top_n=top_n,
|
1859
|
+
ohlcv_limit=ohlcv_limit,
|
1860
|
+
_request_timeout=_request_timeout,
|
1861
|
+
_request_auth=_request_auth,
|
1862
|
+
_content_type=_content_type,
|
1863
|
+
_headers=_headers,
|
1864
|
+
_host_index=_host_index,
|
1865
|
+
)
|
1866
|
+
|
1867
|
+
@validate_call
|
1868
|
+
def get_marketcap_symbols_with_ohlcv_without_preload_content(
|
1869
|
+
self,
|
1870
|
+
timestamp: Annotated[
|
1871
|
+
Optional[StrictInt],
|
1872
|
+
Field(description="Timestamp for which to fetch symbols and OHLCV data"),
|
1873
|
+
] = None,
|
1874
|
+
timeframe: Annotated[
|
1875
|
+
Optional[StrictStr], Field(description="Timeframe for OHLCV data")
|
1876
|
+
] = None,
|
1877
|
+
market: Annotated[
|
1878
|
+
Optional[MarketType],
|
1879
|
+
Field(description="Market for OHLCV data. Defaults to futures."),
|
1880
|
+
] = None,
|
1881
|
+
top_n: Annotated[
|
1882
|
+
Optional[StrictInt], Field(description="Number of symbols to fetch")
|
1883
|
+
] = None,
|
1884
|
+
ohlcv_limit: Annotated[
|
1885
|
+
Optional[StrictInt],
|
1886
|
+
Field(description="Number of OHLCV data points to fetch"),
|
1887
|
+
] = None,
|
1888
|
+
_request_timeout: Union[
|
1889
|
+
None,
|
1890
|
+
Annotated[StrictFloat, Field(gt=0)],
|
1891
|
+
Tuple[
|
1892
|
+
Annotated[StrictFloat, Field(gt=0)], Annotated[StrictFloat, Field(gt=0)]
|
1893
|
+
],
|
1894
|
+
] = None,
|
1895
|
+
_request_auth: Optional[Dict[StrictStr, Any]] = None,
|
1896
|
+
_content_type: Optional[StrictStr] = None,
|
1897
|
+
_headers: Optional[Dict[StrictStr, Any]] = None,
|
1898
|
+
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
|
1899
|
+
) -> RESTResponseType:
|
1900
|
+
"""Get Symbols Marketcap With Ohlcv without preloading content"""
|
1901
|
+
if self.is_sync:
|
1902
|
+
return self._get_marketcap_symbols_with_ohlcv_sync_without_preload_content(
|
1903
|
+
timestamp=timestamp,
|
1904
|
+
timeframe=timeframe,
|
1905
|
+
market=market,
|
1906
|
+
top_n=top_n,
|
1907
|
+
ohlcv_limit=ohlcv_limit,
|
1908
|
+
_request_timeout=_request_timeout,
|
1909
|
+
_request_auth=_request_auth,
|
1910
|
+
_content_type=_content_type,
|
1911
|
+
_headers=_headers,
|
1912
|
+
_host_index=_host_index,
|
1913
|
+
)
|
1914
|
+
|
1915
|
+
else:
|
1916
|
+
return self._get_marketcap_symbols_with_ohlcv_async_without_preload_content(
|
1917
|
+
timestamp=timestamp,
|
1918
|
+
timeframe=timeframe,
|
1919
|
+
market=market,
|
1920
|
+
top_n=top_n,
|
1921
|
+
ohlcv_limit=ohlcv_limit,
|
1922
|
+
_request_timeout=_request_timeout,
|
1923
|
+
_request_auth=_request_auth,
|
1924
|
+
_content_type=_content_type,
|
1925
|
+
_headers=_headers,
|
1926
|
+
_host_index=_host_index,
|
1927
|
+
)
|
1928
|
+
|
1929
|
+
# Private async implementation methods
|
1930
|
+
@validate_call
|
1931
|
+
async def _get_marketcap_symbols_with_ohlcv_async(
|
937
1932
|
self,
|
938
1933
|
timestamp: Annotated[
|
939
1934
|
Optional[StrictInt],
|
@@ -1026,7 +2021,7 @@ class MarketcapApi:
|
|
1026
2021
|
).data
|
1027
2022
|
|
1028
2023
|
@validate_call
|
1029
|
-
async def
|
2024
|
+
async def _get_marketcap_symbols_with_ohlcv_async_with_http_info(
|
1030
2025
|
self,
|
1031
2026
|
timestamp: Annotated[
|
1032
2027
|
Optional[StrictInt],
|
@@ -1114,12 +2109,11 @@ class MarketcapApi:
|
|
1114
2109
|
)
|
1115
2110
|
await response_data.read()
|
1116
2111
|
return self.api_client.response_deserialize(
|
1117
|
-
response_data=response_data,
|
1118
|
-
response_types_map=_response_types_map,
|
2112
|
+
response_data=response_data, response_types_map=_response_types_map
|
1119
2113
|
)
|
1120
2114
|
|
1121
2115
|
@validate_call
|
1122
|
-
async def
|
2116
|
+
async def _get_marketcap_symbols_with_ohlcv_async_without_preload_content(
|
1123
2117
|
self,
|
1124
2118
|
timestamp: Annotated[
|
1125
2119
|
Optional[StrictInt],
|
@@ -1205,7 +2199,153 @@ class MarketcapApi:
|
|
1205
2199
|
response_data = await self.api_client.call_api(
|
1206
2200
|
*_param, _request_timeout=_request_timeout
|
1207
2201
|
)
|
1208
|
-
return response_data
|
2202
|
+
return response_data
|
2203
|
+
|
2204
|
+
# Private sync implementation methods
|
2205
|
+
@validate_call
|
2206
|
+
def _get_marketcap_symbols_with_ohlcv_sync(
|
2207
|
+
self,
|
2208
|
+
timestamp: Annotated[
|
2209
|
+
Optional[StrictInt],
|
2210
|
+
Field(description="Timestamp for which to fetch symbols and OHLCV data"),
|
2211
|
+
] = None,
|
2212
|
+
timeframe: Annotated[
|
2213
|
+
Optional[StrictStr], Field(description="Timeframe for OHLCV data")
|
2214
|
+
] = None,
|
2215
|
+
market: Annotated[
|
2216
|
+
Optional[MarketType],
|
2217
|
+
Field(description="Market for OHLCV data. Defaults to futures."),
|
2218
|
+
] = None,
|
2219
|
+
top_n: Annotated[
|
2220
|
+
Optional[StrictInt], Field(description="Number of symbols to fetch")
|
2221
|
+
] = None,
|
2222
|
+
ohlcv_limit: Annotated[
|
2223
|
+
Optional[StrictInt],
|
2224
|
+
Field(description="Number of OHLCV data points to fetch"),
|
2225
|
+
] = None,
|
2226
|
+
_request_timeout: Union[
|
2227
|
+
None,
|
2228
|
+
Annotated[StrictFloat, Field(gt=0)],
|
2229
|
+
Tuple[
|
2230
|
+
Annotated[StrictFloat, Field(gt=0)], Annotated[StrictFloat, Field(gt=0)]
|
2231
|
+
],
|
2232
|
+
] = None,
|
2233
|
+
_request_auth: Optional[Dict[StrictStr, Any]] = None,
|
2234
|
+
_content_type: Optional[StrictStr] = None,
|
2235
|
+
_headers: Optional[Dict[StrictStr, Any]] = None,
|
2236
|
+
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
|
2237
|
+
) -> Dict[str, List[OHLCV]]:
|
2238
|
+
"""Synchronous version of get_marketcap_symbols_with_ohlcv"""
|
2239
|
+
return async_to_sync(self._get_marketcap_symbols_with_ohlcv_async)(
|
2240
|
+
timestamp=timestamp,
|
2241
|
+
timeframe=timeframe,
|
2242
|
+
market=market,
|
2243
|
+
top_n=top_n,
|
2244
|
+
ohlcv_limit=ohlcv_limit,
|
2245
|
+
_request_timeout=_request_timeout,
|
2246
|
+
_request_auth=_request_auth,
|
2247
|
+
_content_type=_content_type,
|
2248
|
+
_headers=_headers,
|
2249
|
+
_host_index=_host_index,
|
2250
|
+
)
|
2251
|
+
|
2252
|
+
@validate_call
|
2253
|
+
def _get_marketcap_symbols_with_ohlcv_sync_with_http_info(
|
2254
|
+
self,
|
2255
|
+
timestamp: Annotated[
|
2256
|
+
Optional[StrictInt],
|
2257
|
+
Field(description="Timestamp for which to fetch symbols and OHLCV data"),
|
2258
|
+
] = None,
|
2259
|
+
timeframe: Annotated[
|
2260
|
+
Optional[StrictStr], Field(description="Timeframe for OHLCV data")
|
2261
|
+
] = None,
|
2262
|
+
market: Annotated[
|
2263
|
+
Optional[MarketType],
|
2264
|
+
Field(description="Market for OHLCV data. Defaults to futures."),
|
2265
|
+
] = None,
|
2266
|
+
top_n: Annotated[
|
2267
|
+
Optional[StrictInt], Field(description="Number of symbols to fetch")
|
2268
|
+
] = None,
|
2269
|
+
ohlcv_limit: Annotated[
|
2270
|
+
Optional[StrictInt],
|
2271
|
+
Field(description="Number of OHLCV data points to fetch"),
|
2272
|
+
] = None,
|
2273
|
+
_request_timeout: Union[
|
2274
|
+
None,
|
2275
|
+
Annotated[StrictFloat, Field(gt=0)],
|
2276
|
+
Tuple[
|
2277
|
+
Annotated[StrictFloat, Field(gt=0)], Annotated[StrictFloat, Field(gt=0)]
|
2278
|
+
],
|
2279
|
+
] = None,
|
2280
|
+
_request_auth: Optional[Dict[StrictStr, Any]] = None,
|
2281
|
+
_content_type: Optional[StrictStr] = None,
|
2282
|
+
_headers: Optional[Dict[StrictStr, Any]] = None,
|
2283
|
+
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
|
2284
|
+
) -> ApiResponse[Dict[str, List[OHLCV]]]:
|
2285
|
+
"""Synchronous version of get_marketcap_symbols_with_ohlcv_with_http_info"""
|
2286
|
+
return async_to_sync(
|
2287
|
+
self._get_marketcap_symbols_with_ohlcv_async_with_http_info
|
2288
|
+
)(
|
2289
|
+
timestamp=timestamp,
|
2290
|
+
timeframe=timeframe,
|
2291
|
+
market=market,
|
2292
|
+
top_n=top_n,
|
2293
|
+
ohlcv_limit=ohlcv_limit,
|
2294
|
+
_request_timeout=_request_timeout,
|
2295
|
+
_request_auth=_request_auth,
|
2296
|
+
_content_type=_content_type,
|
2297
|
+
_headers=_headers,
|
2298
|
+
_host_index=_host_index,
|
2299
|
+
)
|
2300
|
+
|
2301
|
+
@validate_call
|
2302
|
+
def _get_marketcap_symbols_with_ohlcv_sync_without_preload_content(
|
2303
|
+
self,
|
2304
|
+
timestamp: Annotated[
|
2305
|
+
Optional[StrictInt],
|
2306
|
+
Field(description="Timestamp for which to fetch symbols and OHLCV data"),
|
2307
|
+
] = None,
|
2308
|
+
timeframe: Annotated[
|
2309
|
+
Optional[StrictStr], Field(description="Timeframe for OHLCV data")
|
2310
|
+
] = None,
|
2311
|
+
market: Annotated[
|
2312
|
+
Optional[MarketType],
|
2313
|
+
Field(description="Market for OHLCV data. Defaults to futures."),
|
2314
|
+
] = None,
|
2315
|
+
top_n: Annotated[
|
2316
|
+
Optional[StrictInt], Field(description="Number of symbols to fetch")
|
2317
|
+
] = None,
|
2318
|
+
ohlcv_limit: Annotated[
|
2319
|
+
Optional[StrictInt],
|
2320
|
+
Field(description="Number of OHLCV data points to fetch"),
|
2321
|
+
] = None,
|
2322
|
+
_request_timeout: Union[
|
2323
|
+
None,
|
2324
|
+
Annotated[StrictFloat, Field(gt=0)],
|
2325
|
+
Tuple[
|
2326
|
+
Annotated[StrictFloat, Field(gt=0)], Annotated[StrictFloat, Field(gt=0)]
|
2327
|
+
],
|
2328
|
+
] = None,
|
2329
|
+
_request_auth: Optional[Dict[StrictStr, Any]] = None,
|
2330
|
+
_content_type: Optional[StrictStr] = None,
|
2331
|
+
_headers: Optional[Dict[StrictStr, Any]] = None,
|
2332
|
+
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
|
2333
|
+
) -> RESTResponseType:
|
2334
|
+
"""Synchronous version of get_marketcap_symbols_with_ohlcv_without_preload_content"""
|
2335
|
+
return async_to_sync(
|
2336
|
+
self._get_marketcap_symbols_with_ohlcv_async_without_preload_content
|
2337
|
+
)(
|
2338
|
+
timestamp=timestamp,
|
2339
|
+
timeframe=timeframe,
|
2340
|
+
market=market,
|
2341
|
+
top_n=top_n,
|
2342
|
+
ohlcv_limit=ohlcv_limit,
|
2343
|
+
_request_timeout=_request_timeout,
|
2344
|
+
_request_auth=_request_auth,
|
2345
|
+
_content_type=_content_type,
|
2346
|
+
_headers=_headers,
|
2347
|
+
_host_index=_host_index,
|
2348
|
+
)
|
1209
2349
|
|
1210
2350
|
def _get_marketcap_symbols_with_ohlcv_serialize(
|
1211
2351
|
self,
|