hyperstack 1.41.2a0__py3-none-any.whl → 1.42.1a0__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.
- hyperstack/__init__.py +2 -1
- hyperstack/api/__init__.py +1 -0
- hyperstack/api/admin_api.py +297 -0
- hyperstack/api/firewall_attachment_api.py +7 -7
- hyperstack/api/firewalls_api.py +330 -330
- hyperstack/api/snapshots_api.py +160 -160
- hyperstack/api/virtual_machine_api.py +734 -734
- hyperstack/api/vnc_url_api.py +46 -46
- hyperstack/api_client.py +1 -1
- hyperstack/configuration.py +1 -1
- {hyperstack-1.41.2a0.dist-info → hyperstack-1.42.1a0.dist-info}/METADATA +1 -1
- {hyperstack-1.41.2a0.dist-info → hyperstack-1.42.1a0.dist-info}/RECORD +14 -13
- {hyperstack-1.41.2a0.dist-info → hyperstack-1.42.1a0.dist-info}/WHEEL +0 -0
- {hyperstack-1.41.2a0.dist-info → hyperstack-1.42.1a0.dist-info}/top_level.txt +0 -0
hyperstack/__init__.py
CHANGED
|
@@ -14,13 +14,14 @@
|
|
|
14
14
|
""" # noqa: E501
|
|
15
15
|
|
|
16
16
|
|
|
17
|
-
__version__ = "v1.
|
|
17
|
+
__version__ = "v1.42.1-alpha"
|
|
18
18
|
|
|
19
19
|
# import apis into sdk package
|
|
20
20
|
from .api.calculate_api import CalculateApi
|
|
21
21
|
from .api.customer_contract_api import CustomerContractApi
|
|
22
22
|
from .api.pricebook_api import PricebookApi
|
|
23
23
|
from .api.snapshots_api import SnapshotsApi
|
|
24
|
+
from .api.admin_api import AdminApi
|
|
24
25
|
from .api.alive_api import AliveApi
|
|
25
26
|
from .api.api_key_api import ApiKeyApi
|
|
26
27
|
from .api.assigning_member_role_api import AssigningMemberRoleApi
|
hyperstack/api/__init__.py
CHANGED
|
@@ -5,6 +5,7 @@ from .calculate_api import CalculateApi
|
|
|
5
5
|
from .customer_contract_api import CustomerContractApi
|
|
6
6
|
from .pricebook_api import PricebookApi
|
|
7
7
|
from .snapshots_api import SnapshotsApi
|
|
8
|
+
from .admin_api import AdminApi
|
|
8
9
|
from .alive_api import AliveApi
|
|
9
10
|
from .api_key_api import ApiKeyApi
|
|
10
11
|
from .assigning_member_role_api import AssigningMemberRoleApi
|
|
@@ -0,0 +1,297 @@
|
|
|
1
|
+
# coding: utf-8
|
|
2
|
+
|
|
3
|
+
"""
|
|
4
|
+
Infrahub-API
|
|
5
|
+
|
|
6
|
+
Leverage the Infrahub API and Hyperstack platform to easily create, manage, and scale powerful GPU virtual machines and their associated resources. Access this SDK to automate the deployment of your workloads and streamline your infrastructure management. To contribute, please raise an issue with a bug report, feature request, feedback, or general inquiry.
|
|
7
|
+
|
|
8
|
+
The version of the OpenAPI document: 1.0
|
|
9
|
+
Generated by OpenAPI Generator (https://openapi-generator.tech)
|
|
10
|
+
|
|
11
|
+
Do not edit the class manually.
|
|
12
|
+
""" # noqa: E501
|
|
13
|
+
|
|
14
|
+
import warnings
|
|
15
|
+
from pydantic import validate_call, Field, StrictFloat, StrictStr, StrictInt
|
|
16
|
+
from typing import Any, Dict, List, Optional, Tuple, Union
|
|
17
|
+
from typing_extensions import Annotated
|
|
18
|
+
|
|
19
|
+
from ..models.common_response_model import CommonResponseModel
|
|
20
|
+
|
|
21
|
+
from ..api_client import ApiClient, RequestSerialized
|
|
22
|
+
from ..api_response import ApiResponse
|
|
23
|
+
from ..rest import RESTResponseType
|
|
24
|
+
|
|
25
|
+
|
|
26
|
+
class AdminApi:
|
|
27
|
+
"""NOTE: This class is auto generated by OpenAPI Generator
|
|
28
|
+
Ref: https://openapi-generator.tech
|
|
29
|
+
|
|
30
|
+
Do not edit the class manually.
|
|
31
|
+
"""
|
|
32
|
+
|
|
33
|
+
def __init__(self, api_client=None) -> None:
|
|
34
|
+
if api_client is None:
|
|
35
|
+
api_client = ApiClient.get_default()
|
|
36
|
+
self.api_client = api_client
|
|
37
|
+
|
|
38
|
+
|
|
39
|
+
@validate_call
|
|
40
|
+
def send_password_change_notification_email(
|
|
41
|
+
self,
|
|
42
|
+
_request_timeout: Union[
|
|
43
|
+
None,
|
|
44
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
45
|
+
Tuple[
|
|
46
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
47
|
+
Annotated[StrictFloat, Field(gt=0)]
|
|
48
|
+
]
|
|
49
|
+
] = None,
|
|
50
|
+
_request_auth: Optional[Dict[StrictStr, Any]] = None,
|
|
51
|
+
_content_type: Optional[StrictStr] = None,
|
|
52
|
+
_headers: Optional[Dict[StrictStr, Any]] = None,
|
|
53
|
+
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
|
|
54
|
+
) -> CommonResponseModel:
|
|
55
|
+
"""Send Password Change Notification Email
|
|
56
|
+
|
|
57
|
+
Send a password change notification email to a user
|
|
58
|
+
|
|
59
|
+
:param _request_timeout: timeout setting for this request. If one
|
|
60
|
+
number provided, it will be total request
|
|
61
|
+
timeout. It can also be a pair (tuple) of
|
|
62
|
+
(connection, read) timeouts.
|
|
63
|
+
:type _request_timeout: int, tuple(int, int), optional
|
|
64
|
+
:param _request_auth: set to override the auth_settings for an a single
|
|
65
|
+
request; this effectively ignores the
|
|
66
|
+
authentication in the spec for a single request.
|
|
67
|
+
:type _request_auth: dict, optional
|
|
68
|
+
:param _content_type: force content-type for the request.
|
|
69
|
+
:type _content_type: str, Optional
|
|
70
|
+
:param _headers: set to override the headers for a single
|
|
71
|
+
request; this effectively ignores the headers
|
|
72
|
+
in the spec for a single request.
|
|
73
|
+
:type _headers: dict, optional
|
|
74
|
+
:param _host_index: set to override the host_index for a single
|
|
75
|
+
request; this effectively ignores the host_index
|
|
76
|
+
in the spec for a single request.
|
|
77
|
+
:type _host_index: int, optional
|
|
78
|
+
:return: Returns the result object.
|
|
79
|
+
""" # noqa: E501
|
|
80
|
+
|
|
81
|
+
_param = self._send_password_change_notification_email_serialize(
|
|
82
|
+
_request_auth=_request_auth,
|
|
83
|
+
_content_type=_content_type,
|
|
84
|
+
_headers=_headers,
|
|
85
|
+
_host_index=_host_index
|
|
86
|
+
)
|
|
87
|
+
|
|
88
|
+
_response_types_map: Dict[str, Optional[str]] = {
|
|
89
|
+
'200': "CommonResponseModel",
|
|
90
|
+
'400': "ErrorResponseModel",
|
|
91
|
+
'401': "ErrorResponseModel",
|
|
92
|
+
'404': "ErrorResponseModel",
|
|
93
|
+
'405': "ErrorResponseModel",
|
|
94
|
+
'500': "ErrorResponseModel",
|
|
95
|
+
}
|
|
96
|
+
response_data = self.api_client.call_api(
|
|
97
|
+
*_param,
|
|
98
|
+
_request_timeout=_request_timeout
|
|
99
|
+
)
|
|
100
|
+
response_data.read()
|
|
101
|
+
return self.api_client.response_deserialize(
|
|
102
|
+
response_data=response_data,
|
|
103
|
+
response_types_map=_response_types_map,
|
|
104
|
+
).data
|
|
105
|
+
|
|
106
|
+
|
|
107
|
+
@validate_call
|
|
108
|
+
def send_password_change_notification_email_with_http_info(
|
|
109
|
+
self,
|
|
110
|
+
_request_timeout: Union[
|
|
111
|
+
None,
|
|
112
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
113
|
+
Tuple[
|
|
114
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
115
|
+
Annotated[StrictFloat, Field(gt=0)]
|
|
116
|
+
]
|
|
117
|
+
] = None,
|
|
118
|
+
_request_auth: Optional[Dict[StrictStr, Any]] = None,
|
|
119
|
+
_content_type: Optional[StrictStr] = None,
|
|
120
|
+
_headers: Optional[Dict[StrictStr, Any]] = None,
|
|
121
|
+
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
|
|
122
|
+
) -> ApiResponse[CommonResponseModel]:
|
|
123
|
+
"""Send Password Change Notification Email
|
|
124
|
+
|
|
125
|
+
Send a password change notification email to a user
|
|
126
|
+
|
|
127
|
+
:param _request_timeout: timeout setting for this request. If one
|
|
128
|
+
number provided, it will be total request
|
|
129
|
+
timeout. It can also be a pair (tuple) of
|
|
130
|
+
(connection, read) timeouts.
|
|
131
|
+
:type _request_timeout: int, tuple(int, int), optional
|
|
132
|
+
:param _request_auth: set to override the auth_settings for an a single
|
|
133
|
+
request; this effectively ignores the
|
|
134
|
+
authentication in the spec for a single request.
|
|
135
|
+
:type _request_auth: dict, optional
|
|
136
|
+
:param _content_type: force content-type for the request.
|
|
137
|
+
:type _content_type: str, Optional
|
|
138
|
+
:param _headers: set to override the headers for a single
|
|
139
|
+
request; this effectively ignores the headers
|
|
140
|
+
in the spec for a single request.
|
|
141
|
+
:type _headers: dict, optional
|
|
142
|
+
:param _host_index: set to override the host_index for a single
|
|
143
|
+
request; this effectively ignores the host_index
|
|
144
|
+
in the spec for a single request.
|
|
145
|
+
:type _host_index: int, optional
|
|
146
|
+
:return: Returns the result object.
|
|
147
|
+
""" # noqa: E501
|
|
148
|
+
|
|
149
|
+
_param = self._send_password_change_notification_email_serialize(
|
|
150
|
+
_request_auth=_request_auth,
|
|
151
|
+
_content_type=_content_type,
|
|
152
|
+
_headers=_headers,
|
|
153
|
+
_host_index=_host_index
|
|
154
|
+
)
|
|
155
|
+
|
|
156
|
+
_response_types_map: Dict[str, Optional[str]] = {
|
|
157
|
+
'200': "CommonResponseModel",
|
|
158
|
+
'400': "ErrorResponseModel",
|
|
159
|
+
'401': "ErrorResponseModel",
|
|
160
|
+
'404': "ErrorResponseModel",
|
|
161
|
+
'405': "ErrorResponseModel",
|
|
162
|
+
'500': "ErrorResponseModel",
|
|
163
|
+
}
|
|
164
|
+
response_data = self.api_client.call_api(
|
|
165
|
+
*_param,
|
|
166
|
+
_request_timeout=_request_timeout
|
|
167
|
+
)
|
|
168
|
+
response_data.read()
|
|
169
|
+
return self.api_client.response_deserialize(
|
|
170
|
+
response_data=response_data,
|
|
171
|
+
response_types_map=_response_types_map,
|
|
172
|
+
)
|
|
173
|
+
|
|
174
|
+
|
|
175
|
+
@validate_call
|
|
176
|
+
def send_password_change_notification_email_without_preload_content(
|
|
177
|
+
self,
|
|
178
|
+
_request_timeout: Union[
|
|
179
|
+
None,
|
|
180
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
181
|
+
Tuple[
|
|
182
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
183
|
+
Annotated[StrictFloat, Field(gt=0)]
|
|
184
|
+
]
|
|
185
|
+
] = None,
|
|
186
|
+
_request_auth: Optional[Dict[StrictStr, Any]] = None,
|
|
187
|
+
_content_type: Optional[StrictStr] = None,
|
|
188
|
+
_headers: Optional[Dict[StrictStr, Any]] = None,
|
|
189
|
+
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
|
|
190
|
+
) -> RESTResponseType:
|
|
191
|
+
"""Send Password Change Notification Email
|
|
192
|
+
|
|
193
|
+
Send a password change notification email to a user
|
|
194
|
+
|
|
195
|
+
:param _request_timeout: timeout setting for this request. If one
|
|
196
|
+
number provided, it will be total request
|
|
197
|
+
timeout. It can also be a pair (tuple) of
|
|
198
|
+
(connection, read) timeouts.
|
|
199
|
+
:type _request_timeout: int, tuple(int, int), optional
|
|
200
|
+
:param _request_auth: set to override the auth_settings for an a single
|
|
201
|
+
request; this effectively ignores the
|
|
202
|
+
authentication in the spec for a single request.
|
|
203
|
+
:type _request_auth: dict, optional
|
|
204
|
+
:param _content_type: force content-type for the request.
|
|
205
|
+
:type _content_type: str, Optional
|
|
206
|
+
:param _headers: set to override the headers for a single
|
|
207
|
+
request; this effectively ignores the headers
|
|
208
|
+
in the spec for a single request.
|
|
209
|
+
:type _headers: dict, optional
|
|
210
|
+
:param _host_index: set to override the host_index for a single
|
|
211
|
+
request; this effectively ignores the host_index
|
|
212
|
+
in the spec for a single request.
|
|
213
|
+
:type _host_index: int, optional
|
|
214
|
+
:return: Returns the result object.
|
|
215
|
+
""" # noqa: E501
|
|
216
|
+
|
|
217
|
+
_param = self._send_password_change_notification_email_serialize(
|
|
218
|
+
_request_auth=_request_auth,
|
|
219
|
+
_content_type=_content_type,
|
|
220
|
+
_headers=_headers,
|
|
221
|
+
_host_index=_host_index
|
|
222
|
+
)
|
|
223
|
+
|
|
224
|
+
_response_types_map: Dict[str, Optional[str]] = {
|
|
225
|
+
'200': "CommonResponseModel",
|
|
226
|
+
'400': "ErrorResponseModel",
|
|
227
|
+
'401': "ErrorResponseModel",
|
|
228
|
+
'404': "ErrorResponseModel",
|
|
229
|
+
'405': "ErrorResponseModel",
|
|
230
|
+
'500': "ErrorResponseModel",
|
|
231
|
+
}
|
|
232
|
+
response_data = self.api_client.call_api(
|
|
233
|
+
*_param,
|
|
234
|
+
_request_timeout=_request_timeout
|
|
235
|
+
)
|
|
236
|
+
return response_data.response
|
|
237
|
+
|
|
238
|
+
|
|
239
|
+
def _send_password_change_notification_email_serialize(
|
|
240
|
+
self,
|
|
241
|
+
_request_auth,
|
|
242
|
+
_content_type,
|
|
243
|
+
_headers,
|
|
244
|
+
_host_index,
|
|
245
|
+
) -> RequestSerialized:
|
|
246
|
+
|
|
247
|
+
_host = None
|
|
248
|
+
|
|
249
|
+
_collection_formats: Dict[str, str] = {
|
|
250
|
+
}
|
|
251
|
+
|
|
252
|
+
_path_params: Dict[str, str] = {}
|
|
253
|
+
_query_params: List[Tuple[str, str]] = []
|
|
254
|
+
_header_params: Dict[str, Optional[str]] = _headers or {}
|
|
255
|
+
_form_params: List[Tuple[str, str]] = []
|
|
256
|
+
_files: Dict[
|
|
257
|
+
str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
|
|
258
|
+
] = {}
|
|
259
|
+
_body_params: Optional[bytes] = None
|
|
260
|
+
|
|
261
|
+
# process the path parameters
|
|
262
|
+
# process the query parameters
|
|
263
|
+
# process the header parameters
|
|
264
|
+
# process the form parameters
|
|
265
|
+
# process the body parameter
|
|
266
|
+
|
|
267
|
+
|
|
268
|
+
# set the HTTP header `Accept`
|
|
269
|
+
if 'Accept' not in _header_params:
|
|
270
|
+
_header_params['Accept'] = self.api_client.select_header_accept(
|
|
271
|
+
[
|
|
272
|
+
'application/json'
|
|
273
|
+
]
|
|
274
|
+
)
|
|
275
|
+
|
|
276
|
+
|
|
277
|
+
# authentication setting
|
|
278
|
+
_auth_settings: List[str] = [
|
|
279
|
+
'apiKey'
|
|
280
|
+
]
|
|
281
|
+
|
|
282
|
+
return self.api_client.param_serialize(
|
|
283
|
+
method='POST',
|
|
284
|
+
resource_path='/auth/admin/password-change-mail',
|
|
285
|
+
path_params=_path_params,
|
|
286
|
+
query_params=_query_params,
|
|
287
|
+
header_params=_header_params,
|
|
288
|
+
body=_body_params,
|
|
289
|
+
post_params=_form_params,
|
|
290
|
+
files=_files,
|
|
291
|
+
auth_settings=_auth_settings,
|
|
292
|
+
collection_formats=_collection_formats,
|
|
293
|
+
_host=_host,
|
|
294
|
+
_request_auth=_request_auth
|
|
295
|
+
)
|
|
296
|
+
|
|
297
|
+
|
|
@@ -39,7 +39,7 @@ class FirewallAttachmentApi:
|
|
|
39
39
|
|
|
40
40
|
|
|
41
41
|
@validate_call
|
|
42
|
-
def
|
|
42
|
+
def attach_firewall_to_virtual_machines(
|
|
43
43
|
self,
|
|
44
44
|
firewall_id: StrictInt,
|
|
45
45
|
payload: AttachFirewallWithVM,
|
|
@@ -86,7 +86,7 @@ class FirewallAttachmentApi:
|
|
|
86
86
|
:return: Returns the result object.
|
|
87
87
|
""" # noqa: E501
|
|
88
88
|
|
|
89
|
-
_param = self.
|
|
89
|
+
_param = self._attach_firewall_to_virtual_machines_serialize(
|
|
90
90
|
firewall_id=firewall_id,
|
|
91
91
|
payload=payload,
|
|
92
92
|
_request_auth=_request_auth,
|
|
@@ -116,7 +116,7 @@ class FirewallAttachmentApi:
|
|
|
116
116
|
|
|
117
117
|
|
|
118
118
|
@validate_call
|
|
119
|
-
def
|
|
119
|
+
def attach_firewall_to_virtual_machines_with_http_info(
|
|
120
120
|
self,
|
|
121
121
|
firewall_id: StrictInt,
|
|
122
122
|
payload: AttachFirewallWithVM,
|
|
@@ -163,7 +163,7 @@ class FirewallAttachmentApi:
|
|
|
163
163
|
:return: Returns the result object.
|
|
164
164
|
""" # noqa: E501
|
|
165
165
|
|
|
166
|
-
_param = self.
|
|
166
|
+
_param = self._attach_firewall_to_virtual_machines_serialize(
|
|
167
167
|
firewall_id=firewall_id,
|
|
168
168
|
payload=payload,
|
|
169
169
|
_request_auth=_request_auth,
|
|
@@ -193,7 +193,7 @@ class FirewallAttachmentApi:
|
|
|
193
193
|
|
|
194
194
|
|
|
195
195
|
@validate_call
|
|
196
|
-
def
|
|
196
|
+
def attach_firewall_to_virtual_machines_without_preload_content(
|
|
197
197
|
self,
|
|
198
198
|
firewall_id: StrictInt,
|
|
199
199
|
payload: AttachFirewallWithVM,
|
|
@@ -240,7 +240,7 @@ class FirewallAttachmentApi:
|
|
|
240
240
|
:return: Returns the result object.
|
|
241
241
|
""" # noqa: E501
|
|
242
242
|
|
|
243
|
-
_param = self.
|
|
243
|
+
_param = self._attach_firewall_to_virtual_machines_serialize(
|
|
244
244
|
firewall_id=firewall_id,
|
|
245
245
|
payload=payload,
|
|
246
246
|
_request_auth=_request_auth,
|
|
@@ -265,7 +265,7 @@ class FirewallAttachmentApi:
|
|
|
265
265
|
return response_data.response
|
|
266
266
|
|
|
267
267
|
|
|
268
|
-
def
|
|
268
|
+
def _attach_firewall_to_virtual_machines_serialize(
|
|
269
269
|
self,
|
|
270
270
|
firewall_id,
|
|
271
271
|
payload,
|