crypticorn 2.11.6__py3-none-any.whl → 2.11.7__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/common/errors.py +3 -3
- crypticorn/trade/client/__init__.py +27 -9
- crypticorn/trade/client/api/__init__.py +1 -0
- crypticorn/trade/client/api/admin_api.py +1455 -0
- crypticorn/trade/client/api/api_keys_api.py +60 -58
- crypticorn/trade/client/api/bots_api.py +289 -48
- crypticorn/trade/client/api/exchanges_api.py +474 -17
- crypticorn/trade/client/api/futures_trading_panel_api.py +1 -1
- crypticorn/trade/client/api/notifications_api.py +80 -96
- crypticorn/trade/client/api/orders_api.py +7 -7
- crypticorn/trade/client/api/status_api.py +5 -232
- crypticorn/trade/client/api/strategies_api.py +49 -48
- crypticorn/trade/client/api/trading_actions_api.py +42 -38
- crypticorn/trade/client/api_client.py +1 -1
- crypticorn/trade/client/configuration.py +1 -1
- crypticorn/trade/client/exceptions.py +1 -1
- crypticorn/trade/client/models/__init__.py +26 -9
- crypticorn/trade/client/models/api_error_identifier.py +116 -0
- crypticorn/trade/client/models/api_error_level.py +37 -0
- crypticorn/trade/client/models/api_error_type.py +37 -0
- crypticorn/trade/client/models/{bot_model.py → bot.py} +59 -60
- crypticorn/trade/client/models/bot_create.py +104 -0
- crypticorn/trade/client/models/bot_status.py +1 -1
- crypticorn/trade/client/models/bot_update.py +107 -0
- crypticorn/trade/client/models/exception_detail.py +8 -5
- crypticorn/trade/client/models/exchange.py +36 -0
- crypticorn/trade/client/models/exchange_key.py +111 -0
- crypticorn/trade/client/models/exchange_key_create.py +107 -0
- crypticorn/trade/client/models/{exchange_key_model.py → exchange_key_update.py} +12 -47
- crypticorn/trade/client/models/execution_ids.py +1 -1
- crypticorn/trade/client/models/futures_balance.py +1 -1
- crypticorn/trade/client/models/futures_trading_action.py +24 -16
- crypticorn/trade/client/models/{spot_trading_action.py → futures_trading_action_create.py} +24 -28
- crypticorn/trade/client/models/log_level.py +38 -0
- crypticorn/trade/client/models/margin_mode.py +1 -1
- crypticorn/trade/client/models/market_type.py +35 -0
- crypticorn/trade/client/models/{notification_model.py → notification.py} +35 -40
- crypticorn/trade/client/models/notification_create.py +114 -0
- crypticorn/trade/client/models/notification_update.py +96 -0
- crypticorn/trade/client/models/{order_model.py → order.py} +36 -31
- crypticorn/trade/client/models/order_status.py +1 -1
- crypticorn/trade/client/models/post_futures_action.py +1 -1
- crypticorn/trade/client/models/{action_model.py → spot_trading_action_create.py} +7 -65
- crypticorn/trade/client/models/{strategy_model_input.py → strategy.py} +25 -33
- crypticorn/trade/client/models/{strategy_model_output.py → strategy_create.py} +16 -39
- crypticorn/trade/client/models/strategy_exchange_info.py +4 -3
- crypticorn/trade/client/models/strategy_update.py +147 -0
- crypticorn/trade/client/models/tpsl.py +1 -1
- crypticorn/trade/client/models/trading_action_type.py +1 -1
- crypticorn/trade/client/rest.py +1 -1
- {crypticorn-2.11.6.dist-info → crypticorn-2.11.7.dist-info}/METADATA +1 -1
- {crypticorn-2.11.6.dist-info → crypticorn-2.11.7.dist-info}/RECORD +56 -42
- {crypticorn-2.11.6.dist-info → crypticorn-2.11.7.dist-info}/WHEEL +0 -0
- {crypticorn-2.11.6.dist-info → crypticorn-2.11.7.dist-info}/entry_points.txt +0 -0
- {crypticorn-2.11.6.dist-info → crypticorn-2.11.7.dist-info}/licenses/LICENSE +0 -0
- {crypticorn-2.11.6.dist-info → crypticorn-2.11.7.dist-info}/top_level.txt +0 -0
@@ -3,7 +3,7 @@
|
|
3
3
|
"""
|
4
4
|
Trading API
|
5
5
|
|
6
|
-
API for automated trading and exchange interface
|
6
|
+
API for automated trading and exchange interface. This API is used to trade on the exchange and manage bots, API keys, orders, and more.
|
7
7
|
|
8
8
|
The version of the OpenAPI document: 1.0.0
|
9
9
|
Generated by OpenAPI Generator (https://openapi-generator.tech)
|
@@ -16,9 +16,11 @@ from pydantic import validate_call, Field, StrictFloat, StrictStr, StrictInt
|
|
16
16
|
from typing import Any, Dict, List, Optional, Tuple, Union
|
17
17
|
from typing_extensions import Annotated
|
18
18
|
|
19
|
-
from pydantic import
|
19
|
+
from pydantic import StrictInt, StrictStr
|
20
20
|
from typing import Any, List, Optional
|
21
|
-
from crypticorn.trade.client.models.
|
21
|
+
from crypticorn.trade.client.models.notification import Notification
|
22
|
+
from crypticorn.trade.client.models.notification_create import NotificationCreate
|
23
|
+
from crypticorn.trade.client.models.notification_update import NotificationUpdate
|
22
24
|
|
23
25
|
from crypticorn.trade.client.api_client import ApiClient, RequestSerialized
|
24
26
|
from crypticorn.trade.client.api_response import ApiResponse
|
@@ -40,7 +42,7 @@ class NotificationsApi:
|
|
40
42
|
@validate_call
|
41
43
|
async def create_notification(
|
42
44
|
self,
|
43
|
-
|
45
|
+
notification_create: NotificationCreate,
|
44
46
|
_request_timeout: Union[
|
45
47
|
None,
|
46
48
|
Annotated[StrictFloat, Field(gt=0)],
|
@@ -57,8 +59,8 @@ class NotificationsApi:
|
|
57
59
|
|
58
60
|
Create a new notification
|
59
61
|
|
60
|
-
:param
|
61
|
-
:type
|
62
|
+
:param notification_create: (required)
|
63
|
+
:type notification_create: NotificationCreate
|
62
64
|
:param _request_timeout: timeout setting for this request. If one
|
63
65
|
number provided, it will be total request
|
64
66
|
timeout. It can also be a pair (tuple) of
|
@@ -82,7 +84,7 @@ class NotificationsApi:
|
|
82
84
|
""" # noqa: E501
|
83
85
|
|
84
86
|
_param = self._create_notification_serialize(
|
85
|
-
|
87
|
+
notification_create=notification_create,
|
86
88
|
_request_auth=_request_auth,
|
87
89
|
_content_type=_content_type,
|
88
90
|
_headers=_headers,
|
@@ -104,7 +106,7 @@ class NotificationsApi:
|
|
104
106
|
@validate_call
|
105
107
|
async def create_notification_with_http_info(
|
106
108
|
self,
|
107
|
-
|
109
|
+
notification_create: NotificationCreate,
|
108
110
|
_request_timeout: Union[
|
109
111
|
None,
|
110
112
|
Annotated[StrictFloat, Field(gt=0)],
|
@@ -121,8 +123,8 @@ class NotificationsApi:
|
|
121
123
|
|
122
124
|
Create a new notification
|
123
125
|
|
124
|
-
:param
|
125
|
-
:type
|
126
|
+
:param notification_create: (required)
|
127
|
+
:type notification_create: NotificationCreate
|
126
128
|
:param _request_timeout: timeout setting for this request. If one
|
127
129
|
number provided, it will be total request
|
128
130
|
timeout. It can also be a pair (tuple) of
|
@@ -146,7 +148,7 @@ class NotificationsApi:
|
|
146
148
|
""" # noqa: E501
|
147
149
|
|
148
150
|
_param = self._create_notification_serialize(
|
149
|
-
|
151
|
+
notification_create=notification_create,
|
150
152
|
_request_auth=_request_auth,
|
151
153
|
_content_type=_content_type,
|
152
154
|
_headers=_headers,
|
@@ -168,7 +170,7 @@ class NotificationsApi:
|
|
168
170
|
@validate_call
|
169
171
|
async def create_notification_without_preload_content(
|
170
172
|
self,
|
171
|
-
|
173
|
+
notification_create: NotificationCreate,
|
172
174
|
_request_timeout: Union[
|
173
175
|
None,
|
174
176
|
Annotated[StrictFloat, Field(gt=0)],
|
@@ -185,8 +187,8 @@ class NotificationsApi:
|
|
185
187
|
|
186
188
|
Create a new notification
|
187
189
|
|
188
|
-
:param
|
189
|
-
:type
|
190
|
+
:param notification_create: (required)
|
191
|
+
:type notification_create: NotificationCreate
|
190
192
|
:param _request_timeout: timeout setting for this request. If one
|
191
193
|
number provided, it will be total request
|
192
194
|
timeout. It can also be a pair (tuple) of
|
@@ -210,7 +212,7 @@ class NotificationsApi:
|
|
210
212
|
""" # noqa: E501
|
211
213
|
|
212
214
|
_param = self._create_notification_serialize(
|
213
|
-
|
215
|
+
notification_create=notification_create,
|
214
216
|
_request_auth=_request_auth,
|
215
217
|
_content_type=_content_type,
|
216
218
|
_headers=_headers,
|
@@ -227,7 +229,7 @@ class NotificationsApi:
|
|
227
229
|
|
228
230
|
def _create_notification_serialize(
|
229
231
|
self,
|
230
|
-
|
232
|
+
notification_create,
|
231
233
|
_request_auth,
|
232
234
|
_content_type,
|
233
235
|
_headers,
|
@@ -252,8 +254,8 @@ class NotificationsApi:
|
|
252
254
|
# process the header parameters
|
253
255
|
# process the form parameters
|
254
256
|
# process the body parameter
|
255
|
-
if
|
256
|
-
_body_params =
|
257
|
+
if notification_create is not None:
|
258
|
+
_body_params = notification_create
|
257
259
|
|
258
260
|
# set the HTTP header `Accept`
|
259
261
|
if "Accept" not in _header_params:
|
@@ -771,7 +773,7 @@ class NotificationsApi:
|
|
771
773
|
_content_type: Optional[StrictStr] = None,
|
772
774
|
_headers: Optional[Dict[StrictStr, Any]] = None,
|
773
775
|
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
|
774
|
-
) -> List[
|
776
|
+
) -> List[Notification]:
|
775
777
|
"""Get Notifications
|
776
778
|
|
777
779
|
Get all notifications for the authenticated user
|
@@ -812,7 +814,7 @@ class NotificationsApi:
|
|
812
814
|
)
|
813
815
|
|
814
816
|
_response_types_map: Dict[str, Optional[str]] = {
|
815
|
-
"200": "List[
|
817
|
+
"200": "List[Notification]",
|
816
818
|
}
|
817
819
|
response_data = await self.api_client.call_api(
|
818
820
|
*_param, _request_timeout=_request_timeout
|
@@ -839,7 +841,7 @@ class NotificationsApi:
|
|
839
841
|
_content_type: Optional[StrictStr] = None,
|
840
842
|
_headers: Optional[Dict[StrictStr, Any]] = None,
|
841
843
|
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
|
842
|
-
) -> ApiResponse[List[
|
844
|
+
) -> ApiResponse[List[Notification]]:
|
843
845
|
"""Get Notifications
|
844
846
|
|
845
847
|
Get all notifications for the authenticated user
|
@@ -880,7 +882,7 @@ class NotificationsApi:
|
|
880
882
|
)
|
881
883
|
|
882
884
|
_response_types_map: Dict[str, Optional[str]] = {
|
883
|
-
"200": "List[
|
885
|
+
"200": "List[Notification]",
|
884
886
|
}
|
885
887
|
response_data = await self.api_client.call_api(
|
886
888
|
*_param, _request_timeout=_request_timeout
|
@@ -948,7 +950,7 @@ class NotificationsApi:
|
|
948
950
|
)
|
949
951
|
|
950
952
|
_response_types_map: Dict[str, Optional[str]] = {
|
951
|
-
"200": "List[
|
953
|
+
"200": "List[Notification]",
|
952
954
|
}
|
953
955
|
response_data = await self.api_client.call_api(
|
954
956
|
*_param, _request_timeout=_request_timeout
|
@@ -1020,8 +1022,7 @@ class NotificationsApi:
|
|
1020
1022
|
async def update_notification(
|
1021
1023
|
self,
|
1022
1024
|
id: StrictStr,
|
1023
|
-
|
1024
|
-
sent: StrictBool,
|
1025
|
+
notification_update: NotificationUpdate,
|
1025
1026
|
_request_timeout: Union[
|
1026
1027
|
None,
|
1027
1028
|
Annotated[StrictFloat, Field(gt=0)],
|
@@ -1033,17 +1034,15 @@ class NotificationsApi:
|
|
1033
1034
|
_content_type: Optional[StrictStr] = None,
|
1034
1035
|
_headers: Optional[Dict[StrictStr, Any]] = None,
|
1035
1036
|
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
|
1036
|
-
) ->
|
1037
|
+
) -> Notification:
|
1037
1038
|
"""Update Notification
|
1038
1039
|
|
1039
1040
|
Update a notification's viewed status
|
1040
1041
|
|
1041
1042
|
:param id: (required)
|
1042
1043
|
:type id: str
|
1043
|
-
:param
|
1044
|
-
:type
|
1045
|
-
:param sent: (required)
|
1046
|
-
:type sent: bool
|
1044
|
+
:param notification_update: (required)
|
1045
|
+
:type notification_update: NotificationUpdate
|
1047
1046
|
:param _request_timeout: timeout setting for this request. If one
|
1048
1047
|
number provided, it will be total request
|
1049
1048
|
timeout. It can also be a pair (tuple) of
|
@@ -1068,8 +1067,7 @@ class NotificationsApi:
|
|
1068
1067
|
|
1069
1068
|
_param = self._update_notification_serialize(
|
1070
1069
|
id=id,
|
1071
|
-
|
1072
|
-
sent=sent,
|
1070
|
+
notification_update=notification_update,
|
1073
1071
|
_request_auth=_request_auth,
|
1074
1072
|
_content_type=_content_type,
|
1075
1073
|
_headers=_headers,
|
@@ -1077,7 +1075,7 @@ class NotificationsApi:
|
|
1077
1075
|
)
|
1078
1076
|
|
1079
1077
|
_response_types_map: Dict[str, Optional[str]] = {
|
1080
|
-
"200": "
|
1078
|
+
"200": "Notification",
|
1081
1079
|
}
|
1082
1080
|
response_data = await self.api_client.call_api(
|
1083
1081
|
*_param, _request_timeout=_request_timeout
|
@@ -1092,8 +1090,7 @@ class NotificationsApi:
|
|
1092
1090
|
async def update_notification_with_http_info(
|
1093
1091
|
self,
|
1094
1092
|
id: StrictStr,
|
1095
|
-
|
1096
|
-
sent: StrictBool,
|
1093
|
+
notification_update: NotificationUpdate,
|
1097
1094
|
_request_timeout: Union[
|
1098
1095
|
None,
|
1099
1096
|
Annotated[StrictFloat, Field(gt=0)],
|
@@ -1105,17 +1102,15 @@ class NotificationsApi:
|
|
1105
1102
|
_content_type: Optional[StrictStr] = None,
|
1106
1103
|
_headers: Optional[Dict[StrictStr, Any]] = None,
|
1107
1104
|
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
|
1108
|
-
) -> ApiResponse[
|
1105
|
+
) -> ApiResponse[Notification]:
|
1109
1106
|
"""Update Notification
|
1110
1107
|
|
1111
1108
|
Update a notification's viewed status
|
1112
1109
|
|
1113
1110
|
:param id: (required)
|
1114
1111
|
:type id: str
|
1115
|
-
:param
|
1116
|
-
:type
|
1117
|
-
:param sent: (required)
|
1118
|
-
:type sent: bool
|
1112
|
+
:param notification_update: (required)
|
1113
|
+
:type notification_update: NotificationUpdate
|
1119
1114
|
:param _request_timeout: timeout setting for this request. If one
|
1120
1115
|
number provided, it will be total request
|
1121
1116
|
timeout. It can also be a pair (tuple) of
|
@@ -1140,8 +1135,7 @@ class NotificationsApi:
|
|
1140
1135
|
|
1141
1136
|
_param = self._update_notification_serialize(
|
1142
1137
|
id=id,
|
1143
|
-
|
1144
|
-
sent=sent,
|
1138
|
+
notification_update=notification_update,
|
1145
1139
|
_request_auth=_request_auth,
|
1146
1140
|
_content_type=_content_type,
|
1147
1141
|
_headers=_headers,
|
@@ -1149,7 +1143,7 @@ class NotificationsApi:
|
|
1149
1143
|
)
|
1150
1144
|
|
1151
1145
|
_response_types_map: Dict[str, Optional[str]] = {
|
1152
|
-
"200": "
|
1146
|
+
"200": "Notification",
|
1153
1147
|
}
|
1154
1148
|
response_data = await self.api_client.call_api(
|
1155
1149
|
*_param, _request_timeout=_request_timeout
|
@@ -1164,8 +1158,7 @@ class NotificationsApi:
|
|
1164
1158
|
async def update_notification_without_preload_content(
|
1165
1159
|
self,
|
1166
1160
|
id: StrictStr,
|
1167
|
-
|
1168
|
-
sent: StrictBool,
|
1161
|
+
notification_update: NotificationUpdate,
|
1169
1162
|
_request_timeout: Union[
|
1170
1163
|
None,
|
1171
1164
|
Annotated[StrictFloat, Field(gt=0)],
|
@@ -1184,10 +1177,8 @@ class NotificationsApi:
|
|
1184
1177
|
|
1185
1178
|
:param id: (required)
|
1186
1179
|
:type id: str
|
1187
|
-
:param
|
1188
|
-
:type
|
1189
|
-
:param sent: (required)
|
1190
|
-
:type sent: bool
|
1180
|
+
:param notification_update: (required)
|
1181
|
+
:type notification_update: NotificationUpdate
|
1191
1182
|
:param _request_timeout: timeout setting for this request. If one
|
1192
1183
|
number provided, it will be total request
|
1193
1184
|
timeout. It can also be a pair (tuple) of
|
@@ -1212,8 +1203,7 @@ class NotificationsApi:
|
|
1212
1203
|
|
1213
1204
|
_param = self._update_notification_serialize(
|
1214
1205
|
id=id,
|
1215
|
-
|
1216
|
-
sent=sent,
|
1206
|
+
notification_update=notification_update,
|
1217
1207
|
_request_auth=_request_auth,
|
1218
1208
|
_content_type=_content_type,
|
1219
1209
|
_headers=_headers,
|
@@ -1221,7 +1211,7 @@ class NotificationsApi:
|
|
1221
1211
|
)
|
1222
1212
|
|
1223
1213
|
_response_types_map: Dict[str, Optional[str]] = {
|
1224
|
-
"200": "
|
1214
|
+
"200": "Notification",
|
1225
1215
|
}
|
1226
1216
|
response_data = await self.api_client.call_api(
|
1227
1217
|
*_param, _request_timeout=_request_timeout
|
@@ -1231,8 +1221,7 @@ class NotificationsApi:
|
|
1231
1221
|
def _update_notification_serialize(
|
1232
1222
|
self,
|
1233
1223
|
id,
|
1234
|
-
|
1235
|
-
sent,
|
1224
|
+
notification_update,
|
1236
1225
|
_request_auth,
|
1237
1226
|
_content_type,
|
1238
1227
|
_headers,
|
@@ -1256,17 +1245,11 @@ class NotificationsApi:
|
|
1256
1245
|
if id is not None:
|
1257
1246
|
_path_params["id"] = id
|
1258
1247
|
# process the query parameters
|
1259
|
-
if viewed is not None:
|
1260
|
-
|
1261
|
-
_query_params.append(("viewed", viewed))
|
1262
|
-
|
1263
|
-
if sent is not None:
|
1264
|
-
|
1265
|
-
_query_params.append(("sent", sent))
|
1266
|
-
|
1267
1248
|
# process the header parameters
|
1268
1249
|
# process the form parameters
|
1269
1250
|
# process the body parameter
|
1251
|
+
if notification_update is not None:
|
1252
|
+
_body_params = notification_update
|
1270
1253
|
|
1271
1254
|
# set the HTTP header `Accept`
|
1272
1255
|
if "Accept" not in _header_params:
|
@@ -1274,6 +1257,16 @@ class NotificationsApi:
|
|
1274
1257
|
["application/json"]
|
1275
1258
|
)
|
1276
1259
|
|
1260
|
+
# set the HTTP header `Content-Type`
|
1261
|
+
if _content_type:
|
1262
|
+
_header_params["Content-Type"] = _content_type
|
1263
|
+
else:
|
1264
|
+
_default_content_type = self.api_client.select_header_content_type(
|
1265
|
+
["application/json"]
|
1266
|
+
)
|
1267
|
+
if _default_content_type is not None:
|
1268
|
+
_header_params["Content-Type"] = _default_content_type
|
1269
|
+
|
1277
1270
|
# authentication setting
|
1278
1271
|
_auth_settings: List[str] = ["APIKeyHeader", "HTTPBearer"]
|
1279
1272
|
|
@@ -1295,8 +1288,7 @@ class NotificationsApi:
|
|
1295
1288
|
@validate_call
|
1296
1289
|
async def update_notifications(
|
1297
1290
|
self,
|
1298
|
-
|
1299
|
-
sent: StrictBool,
|
1291
|
+
notification_update: NotificationUpdate,
|
1300
1292
|
_request_timeout: Union[
|
1301
1293
|
None,
|
1302
1294
|
Annotated[StrictFloat, Field(gt=0)],
|
@@ -1313,10 +1305,8 @@ class NotificationsApi:
|
|
1313
1305
|
|
1314
1306
|
Bulk update notifications
|
1315
1307
|
|
1316
|
-
:param
|
1317
|
-
:type
|
1318
|
-
:param sent: (required)
|
1319
|
-
:type sent: bool
|
1308
|
+
:param notification_update: (required)
|
1309
|
+
:type notification_update: NotificationUpdate
|
1320
1310
|
:param _request_timeout: timeout setting for this request. If one
|
1321
1311
|
number provided, it will be total request
|
1322
1312
|
timeout. It can also be a pair (tuple) of
|
@@ -1340,8 +1330,7 @@ class NotificationsApi:
|
|
1340
1330
|
""" # noqa: E501
|
1341
1331
|
|
1342
1332
|
_param = self._update_notifications_serialize(
|
1343
|
-
|
1344
|
-
sent=sent,
|
1333
|
+
notification_update=notification_update,
|
1345
1334
|
_request_auth=_request_auth,
|
1346
1335
|
_content_type=_content_type,
|
1347
1336
|
_headers=_headers,
|
@@ -1363,8 +1352,7 @@ class NotificationsApi:
|
|
1363
1352
|
@validate_call
|
1364
1353
|
async def update_notifications_with_http_info(
|
1365
1354
|
self,
|
1366
|
-
|
1367
|
-
sent: StrictBool,
|
1355
|
+
notification_update: NotificationUpdate,
|
1368
1356
|
_request_timeout: Union[
|
1369
1357
|
None,
|
1370
1358
|
Annotated[StrictFloat, Field(gt=0)],
|
@@ -1381,10 +1369,8 @@ class NotificationsApi:
|
|
1381
1369
|
|
1382
1370
|
Bulk update notifications
|
1383
1371
|
|
1384
|
-
:param
|
1385
|
-
:type
|
1386
|
-
:param sent: (required)
|
1387
|
-
:type sent: bool
|
1372
|
+
:param notification_update: (required)
|
1373
|
+
:type notification_update: NotificationUpdate
|
1388
1374
|
:param _request_timeout: timeout setting for this request. If one
|
1389
1375
|
number provided, it will be total request
|
1390
1376
|
timeout. It can also be a pair (tuple) of
|
@@ -1408,8 +1394,7 @@ class NotificationsApi:
|
|
1408
1394
|
""" # noqa: E501
|
1409
1395
|
|
1410
1396
|
_param = self._update_notifications_serialize(
|
1411
|
-
|
1412
|
-
sent=sent,
|
1397
|
+
notification_update=notification_update,
|
1413
1398
|
_request_auth=_request_auth,
|
1414
1399
|
_content_type=_content_type,
|
1415
1400
|
_headers=_headers,
|
@@ -1431,8 +1416,7 @@ class NotificationsApi:
|
|
1431
1416
|
@validate_call
|
1432
1417
|
async def update_notifications_without_preload_content(
|
1433
1418
|
self,
|
1434
|
-
|
1435
|
-
sent: StrictBool,
|
1419
|
+
notification_update: NotificationUpdate,
|
1436
1420
|
_request_timeout: Union[
|
1437
1421
|
None,
|
1438
1422
|
Annotated[StrictFloat, Field(gt=0)],
|
@@ -1449,10 +1433,8 @@ class NotificationsApi:
|
|
1449
1433
|
|
1450
1434
|
Bulk update notifications
|
1451
1435
|
|
1452
|
-
:param
|
1453
|
-
:type
|
1454
|
-
:param sent: (required)
|
1455
|
-
:type sent: bool
|
1436
|
+
:param notification_update: (required)
|
1437
|
+
:type notification_update: NotificationUpdate
|
1456
1438
|
:param _request_timeout: timeout setting for this request. If one
|
1457
1439
|
number provided, it will be total request
|
1458
1440
|
timeout. It can also be a pair (tuple) of
|
@@ -1476,8 +1458,7 @@ class NotificationsApi:
|
|
1476
1458
|
""" # noqa: E501
|
1477
1459
|
|
1478
1460
|
_param = self._update_notifications_serialize(
|
1479
|
-
|
1480
|
-
sent=sent,
|
1461
|
+
notification_update=notification_update,
|
1481
1462
|
_request_auth=_request_auth,
|
1482
1463
|
_content_type=_content_type,
|
1483
1464
|
_headers=_headers,
|
@@ -1494,8 +1475,7 @@ class NotificationsApi:
|
|
1494
1475
|
|
1495
1476
|
def _update_notifications_serialize(
|
1496
1477
|
self,
|
1497
|
-
|
1498
|
-
sent,
|
1478
|
+
notification_update,
|
1499
1479
|
_request_auth,
|
1500
1480
|
_content_type,
|
1501
1481
|
_headers,
|
@@ -1517,17 +1497,11 @@ class NotificationsApi:
|
|
1517
1497
|
|
1518
1498
|
# process the path parameters
|
1519
1499
|
# process the query parameters
|
1520
|
-
if viewed is not None:
|
1521
|
-
|
1522
|
-
_query_params.append(("viewed", viewed))
|
1523
|
-
|
1524
|
-
if sent is not None:
|
1525
|
-
|
1526
|
-
_query_params.append(("sent", sent))
|
1527
|
-
|
1528
1500
|
# process the header parameters
|
1529
1501
|
# process the form parameters
|
1530
1502
|
# process the body parameter
|
1503
|
+
if notification_update is not None:
|
1504
|
+
_body_params = notification_update
|
1531
1505
|
|
1532
1506
|
# set the HTTP header `Accept`
|
1533
1507
|
if "Accept" not in _header_params:
|
@@ -1535,6 +1509,16 @@ class NotificationsApi:
|
|
1535
1509
|
["application/json"]
|
1536
1510
|
)
|
1537
1511
|
|
1512
|
+
# set the HTTP header `Content-Type`
|
1513
|
+
if _content_type:
|
1514
|
+
_header_params["Content-Type"] = _content_type
|
1515
|
+
else:
|
1516
|
+
_default_content_type = self.api_client.select_header_content_type(
|
1517
|
+
["application/json"]
|
1518
|
+
)
|
1519
|
+
if _default_content_type is not None:
|
1520
|
+
_header_params["Content-Type"] = _default_content_type
|
1521
|
+
|
1538
1522
|
# authentication setting
|
1539
1523
|
_auth_settings: List[str] = ["APIKeyHeader", "HTTPBearer"]
|
1540
1524
|
|
@@ -3,7 +3,7 @@
|
|
3
3
|
"""
|
4
4
|
Trading API
|
5
5
|
|
6
|
-
API for automated trading and exchange interface
|
6
|
+
API for automated trading and exchange interface. This API is used to trade on the exchange and manage bots, API keys, orders, and more.
|
7
7
|
|
8
8
|
The version of the OpenAPI document: 1.0.0
|
9
9
|
Generated by OpenAPI Generator (https://openapi-generator.tech)
|
@@ -18,7 +18,7 @@ from typing_extensions import Annotated
|
|
18
18
|
|
19
19
|
from pydantic import StrictInt
|
20
20
|
from typing import List, Optional
|
21
|
-
from crypticorn.trade.client.models.
|
21
|
+
from crypticorn.trade.client.models.order import Order
|
22
22
|
|
23
23
|
from crypticorn.trade.client.api_client import ApiClient, RequestSerialized
|
24
24
|
from crypticorn.trade.client.api_response import ApiResponse
|
@@ -53,7 +53,7 @@ class OrdersApi:
|
|
53
53
|
_content_type: Optional[StrictStr] = None,
|
54
54
|
_headers: Optional[Dict[StrictStr, Any]] = None,
|
55
55
|
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
|
56
|
-
) -> List[
|
56
|
+
) -> List[Order]:
|
57
57
|
"""Get Orders
|
58
58
|
|
59
59
|
|
@@ -93,7 +93,7 @@ class OrdersApi:
|
|
93
93
|
)
|
94
94
|
|
95
95
|
_response_types_map: Dict[str, Optional[str]] = {
|
96
|
-
"200": "List[
|
96
|
+
"200": "List[Order]",
|
97
97
|
}
|
98
98
|
response_data = await self.api_client.call_api(
|
99
99
|
*_param, _request_timeout=_request_timeout
|
@@ -120,7 +120,7 @@ class OrdersApi:
|
|
120
120
|
_content_type: Optional[StrictStr] = None,
|
121
121
|
_headers: Optional[Dict[StrictStr, Any]] = None,
|
122
122
|
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
|
123
|
-
) -> ApiResponse[List[
|
123
|
+
) -> ApiResponse[List[Order]]:
|
124
124
|
"""Get Orders
|
125
125
|
|
126
126
|
|
@@ -160,7 +160,7 @@ class OrdersApi:
|
|
160
160
|
)
|
161
161
|
|
162
162
|
_response_types_map: Dict[str, Optional[str]] = {
|
163
|
-
"200": "List[
|
163
|
+
"200": "List[Order]",
|
164
164
|
}
|
165
165
|
response_data = await self.api_client.call_api(
|
166
166
|
*_param, _request_timeout=_request_timeout
|
@@ -227,7 +227,7 @@ class OrdersApi:
|
|
227
227
|
)
|
228
228
|
|
229
229
|
_response_types_map: Dict[str, Optional[str]] = {
|
230
|
-
"200": "List[
|
230
|
+
"200": "List[Order]",
|
231
231
|
}
|
232
232
|
response_data = await self.api_client.call_api(
|
233
233
|
*_param, _request_timeout=_request_timeout
|