crypticorn 2.4.7__py3-none-any.whl → 2.5.0rc2__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 (74) hide show
  1. crypticorn/cli/init.py +7 -4
  2. crypticorn/common/__init__.py +1 -0
  3. crypticorn/common/auth.py +7 -3
  4. crypticorn/common/exceptions.py +27 -0
  5. crypticorn/common/utils.py +7 -2
  6. crypticorn/klines/client/__init__.py +10 -3
  7. crypticorn/klines/client/api/__init__.py +1 -0
  8. crypticorn/klines/client/api/change_in_timeframe_api.py +331 -0
  9. crypticorn/klines/client/api/funding_rates_api.py +13 -13
  10. crypticorn/klines/client/api/health_check_api.py +8 -8
  11. crypticorn/klines/client/api/ohlcv_data_api.py +38 -26
  12. crypticorn/klines/client/api/symbols_api.py +26 -20
  13. crypticorn/klines/client/api/udf_api.py +229 -229
  14. crypticorn/klines/client/api_client.py +8 -5
  15. crypticorn/klines/client/configuration.py +80 -37
  16. crypticorn/klines/client/models/__init__.py +9 -3
  17. crypticorn/klines/client/models/base_response_list_change_in_timeframe_response.py +123 -0
  18. crypticorn/klines/client/models/change_in_timeframe_response.py +86 -0
  19. crypticorn/klines/client/models/market_type.py +35 -0
  20. crypticorn/klines/client/models/response_get_udf_history.py +198 -0
  21. crypticorn/klines/client/rest.py +111 -159
  22. crypticorn/metrics/main.py +1 -0
  23. crypticorn/pay/client/__init__.py +0 -3
  24. crypticorn/pay/client/api/now_payments_api.py +1 -53
  25. crypticorn/pay/client/models/__init__.py +0 -3
  26. crypticorn/pay/client/models/payment.py +3 -3
  27. crypticorn/pay/client/models/scope.py +6 -1
  28. crypticorn/trade/client/__init__.py +8 -6
  29. crypticorn/trade/client/api/__init__.py +0 -1
  30. crypticorn/trade/client/api/api_keys_api.py +167 -273
  31. crypticorn/trade/client/api/bots_api.py +140 -226
  32. crypticorn/trade/client/api/exchanges_api.py +31 -51
  33. crypticorn/trade/client/api/futures_trading_panel_api.py +169 -272
  34. crypticorn/trade/client/api/notifications_api.py +200 -323
  35. crypticorn/trade/client/api/orders_api.py +40 -60
  36. crypticorn/trade/client/api/status_api.py +31 -49
  37. crypticorn/trade/client/api/strategies_api.py +137 -223
  38. crypticorn/trade/client/api/trading_actions_api.py +106 -170
  39. crypticorn/trade/client/api_client.py +111 -153
  40. crypticorn/trade/client/api_response.py +2 -3
  41. crypticorn/trade/client/configuration.py +128 -115
  42. crypticorn/trade/client/exceptions.py +25 -21
  43. crypticorn/trade/client/models/__init__.py +8 -6
  44. crypticorn/trade/client/models/action_model.py +108 -54
  45. crypticorn/trade/client/models/api_error_identifier.py +76 -72
  46. crypticorn/trade/client/models/api_error_level.py +9 -11
  47. crypticorn/trade/client/models/api_error_type.py +9 -11
  48. crypticorn/trade/client/models/bot_model.py +57 -36
  49. crypticorn/trade/client/models/bot_status.py +9 -11
  50. crypticorn/trade/client/models/exchange.py +7 -9
  51. crypticorn/trade/client/models/exchange_key_model.py +43 -32
  52. crypticorn/trade/client/models/execution_ids.py +18 -18
  53. crypticorn/trade/client/models/futures_balance.py +43 -27
  54. crypticorn/trade/client/models/futures_trading_action.py +102 -50
  55. crypticorn/trade/client/models/http_validation_error.py +19 -15
  56. crypticorn/trade/client/models/margin_mode.py +7 -9
  57. crypticorn/trade/client/models/market_type.py +7 -9
  58. crypticorn/trade/client/models/notification_model.py +52 -32
  59. crypticorn/trade/client/models/order_model.py +112 -72
  60. crypticorn/trade/client/models/order_status.py +10 -12
  61. crypticorn/trade/client/models/post_futures_action.py +20 -16
  62. crypticorn/trade/client/models/strategy_exchange_info.py +15 -16
  63. crypticorn/trade/client/models/strategy_model_input.py +61 -33
  64. crypticorn/trade/client/models/strategy_model_output.py +61 -33
  65. crypticorn/trade/client/models/tpsl.py +39 -25
  66. crypticorn/trade/client/models/trading_action_type.py +9 -11
  67. crypticorn/trade/client/models/validation_error.py +24 -18
  68. crypticorn/trade/client/models/validation_error_loc_inner.py +37 -16
  69. crypticorn/trade/client/rest.py +23 -38
  70. {crypticorn-2.4.7.dist-info → crypticorn-2.5.0rc2.dist-info}/METADATA +1 -1
  71. {crypticorn-2.4.7.dist-info → crypticorn-2.5.0rc2.dist-info}/RECORD +74 -68
  72. {crypticorn-2.4.7.dist-info → crypticorn-2.5.0rc2.dist-info}/WHEEL +1 -1
  73. {crypticorn-2.4.7.dist-info → crypticorn-2.5.0rc2.dist-info}/entry_points.txt +0 -0
  74. {crypticorn-2.4.7.dist-info → crypticorn-2.5.0rc2.dist-info}/top_level.txt +0 -0
@@ -1,14 +1,14 @@
1
1
  # coding: utf-8
2
2
 
3
3
  """
4
- Trading API
4
+ Trading API
5
5
 
6
- No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator)
6
+ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator)
7
7
 
8
- The version of the OpenAPI document: 0.1.0
9
- Generated by OpenAPI Generator (https://openapi-generator.tech)
8
+ The version of the OpenAPI document: 0.1.0
9
+ Generated by OpenAPI Generator (https://openapi-generator.tech)
10
10
 
11
- Do not edit the class manually.
11
+ Do not edit the class manually.
12
12
  """ # noqa: E501
13
13
 
14
14
  import warnings
@@ -36,7 +36,6 @@ class ExchangesApi:
36
36
  api_client = ApiClient.get_default()
37
37
  self.api_client = api_client
38
38
 
39
-
40
39
  @validate_call
41
40
  async def get_exchanges(
42
41
  self,
@@ -44,9 +43,8 @@ class ExchangesApi:
44
43
  None,
45
44
  Annotated[StrictFloat, Field(gt=0)],
46
45
  Tuple[
47
- Annotated[StrictFloat, Field(gt=0)],
48
- Annotated[StrictFloat, Field(gt=0)]
49
- ]
46
+ Annotated[StrictFloat, Field(gt=0)], Annotated[StrictFloat, Field(gt=0)]
47
+ ],
50
48
  ] = None,
51
49
  _request_auth: Optional[Dict[StrictStr, Any]] = None,
52
50
  _content_type: Optional[StrictStr] = None,
@@ -76,21 +74,20 @@ class ExchangesApi:
76
74
  in the spec for a single request.
77
75
  :type _host_index: int, optional
78
76
  :return: Returns the result object.
79
- """ # noqa: E501
77
+ """ # noqa: E501
80
78
 
81
79
  _param = self._get_exchanges_serialize(
82
80
  _request_auth=_request_auth,
83
81
  _content_type=_content_type,
84
82
  _headers=_headers,
85
- _host_index=_host_index
83
+ _host_index=_host_index,
86
84
  )
87
85
 
88
86
  _response_types_map: Dict[str, Optional[str]] = {
89
- '200': "List[Exchange]",
87
+ "200": "List[Exchange]",
90
88
  }
91
89
  response_data = await self.api_client.call_api(
92
- *_param,
93
- _request_timeout=_request_timeout
90
+ *_param, _request_timeout=_request_timeout
94
91
  )
95
92
  await response_data.read()
96
93
  return self.api_client.response_deserialize(
@@ -98,7 +95,6 @@ class ExchangesApi:
98
95
  response_types_map=_response_types_map,
99
96
  ).data
100
97
 
101
-
102
98
  @validate_call
103
99
  async def get_exchanges_with_http_info(
104
100
  self,
@@ -106,9 +102,8 @@ class ExchangesApi:
106
102
  None,
107
103
  Annotated[StrictFloat, Field(gt=0)],
108
104
  Tuple[
109
- Annotated[StrictFloat, Field(gt=0)],
110
- Annotated[StrictFloat, Field(gt=0)]
111
- ]
105
+ Annotated[StrictFloat, Field(gt=0)], Annotated[StrictFloat, Field(gt=0)]
106
+ ],
112
107
  ] = None,
113
108
  _request_auth: Optional[Dict[StrictStr, Any]] = None,
114
109
  _content_type: Optional[StrictStr] = None,
@@ -138,21 +133,20 @@ class ExchangesApi:
138
133
  in the spec for a single request.
139
134
  :type _host_index: int, optional
140
135
  :return: Returns the result object.
141
- """ # noqa: E501
136
+ """ # noqa: E501
142
137
 
143
138
  _param = self._get_exchanges_serialize(
144
139
  _request_auth=_request_auth,
145
140
  _content_type=_content_type,
146
141
  _headers=_headers,
147
- _host_index=_host_index
142
+ _host_index=_host_index,
148
143
  )
149
144
 
150
145
  _response_types_map: Dict[str, Optional[str]] = {
151
- '200': "List[Exchange]",
146
+ "200": "List[Exchange]",
152
147
  }
153
148
  response_data = await self.api_client.call_api(
154
- *_param,
155
- _request_timeout=_request_timeout
149
+ *_param, _request_timeout=_request_timeout
156
150
  )
157
151
  await response_data.read()
158
152
  return self.api_client.response_deserialize(
@@ -160,7 +154,6 @@ class ExchangesApi:
160
154
  response_types_map=_response_types_map,
161
155
  )
162
156
 
163
-
164
157
  @validate_call
165
158
  async def get_exchanges_without_preload_content(
166
159
  self,
@@ -168,9 +161,8 @@ class ExchangesApi:
168
161
  None,
169
162
  Annotated[StrictFloat, Field(gt=0)],
170
163
  Tuple[
171
- Annotated[StrictFloat, Field(gt=0)],
172
- Annotated[StrictFloat, Field(gt=0)]
173
- ]
164
+ Annotated[StrictFloat, Field(gt=0)], Annotated[StrictFloat, Field(gt=0)]
165
+ ],
174
166
  ] = None,
175
167
  _request_auth: Optional[Dict[StrictStr, Any]] = None,
176
168
  _content_type: Optional[StrictStr] = None,
@@ -200,25 +192,23 @@ class ExchangesApi:
200
192
  in the spec for a single request.
201
193
  :type _host_index: int, optional
202
194
  :return: Returns the result object.
203
- """ # noqa: E501
195
+ """ # noqa: E501
204
196
 
205
197
  _param = self._get_exchanges_serialize(
206
198
  _request_auth=_request_auth,
207
199
  _content_type=_content_type,
208
200
  _headers=_headers,
209
- _host_index=_host_index
201
+ _host_index=_host_index,
210
202
  )
211
203
 
212
204
  _response_types_map: Dict[str, Optional[str]] = {
213
- '200': "List[Exchange]",
205
+ "200": "List[Exchange]",
214
206
  }
215
207
  response_data = await self.api_client.call_api(
216
- *_param,
217
- _request_timeout=_request_timeout
208
+ *_param, _request_timeout=_request_timeout
218
209
  )
219
210
  return response_data.response
220
211
 
221
-
222
212
  def _get_exchanges_serialize(
223
213
  self,
224
214
  _request_auth,
@@ -229,8 +219,7 @@ class ExchangesApi:
229
219
 
230
220
  _host = None
231
221
 
232
- _collection_formats: Dict[str, str] = {
233
- }
222
+ _collection_formats: Dict[str, str] = {}
234
223
 
235
224
  _path_params: Dict[str, str] = {}
236
225
  _query_params: List[Tuple[str, str]] = []
@@ -247,25 +236,18 @@ class ExchangesApi:
247
236
  # process the form parameters
248
237
  # process the body parameter
249
238
 
250
-
251
239
  # set the HTTP header `Accept`
252
- if 'Accept' not in _header_params:
253
- _header_params['Accept'] = self.api_client.select_header_accept(
254
- [
255
- 'application/json'
256
- ]
240
+ if "Accept" not in _header_params:
241
+ _header_params["Accept"] = self.api_client.select_header_accept(
242
+ ["application/json"]
257
243
  )
258
244
 
259
-
260
245
  # authentication setting
261
- _auth_settings: List[str] = [
262
- 'APIKeyHeader',
263
- 'HTTPBearer'
264
- ]
246
+ _auth_settings: List[str] = ["APIKeyHeader", "HTTPBearer"]
265
247
 
266
248
  return self.api_client.param_serialize(
267
- method='GET',
268
- resource_path='/exchanges',
249
+ method="GET",
250
+ resource_path="/exchanges",
269
251
  path_params=_path_params,
270
252
  query_params=_query_params,
271
253
  header_params=_header_params,
@@ -275,7 +257,5 @@ class ExchangesApi:
275
257
  auth_settings=_auth_settings,
276
258
  collection_formats=_collection_formats,
277
259
  _host=_host,
278
- _request_auth=_request_auth
260
+ _request_auth=_request_auth,
279
261
  )
280
-
281
-