stackit-serviceenablement 0.0.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.
- stackit/serviceenablement/__init__.py +44 -0
- stackit/serviceenablement/api/__init__.py +4 -0
- stackit/serviceenablement/api/default_api.py +1007 -0
- stackit/serviceenablement/api_client.py +626 -0
- stackit/serviceenablement/api_response.py +23 -0
- stackit/serviceenablement/configuration.py +111 -0
- stackit/serviceenablement/exceptions.py +198 -0
- stackit/serviceenablement/models/__init__.py +25 -0
- stackit/serviceenablement/models/action_error.py +93 -0
- stackit/serviceenablement/models/cloud_service.py +121 -0
- stackit/serviceenablement/models/dependencies.py +88 -0
- stackit/serviceenablement/models/list_service_status200_response.py +98 -0
- stackit/serviceenablement/models/parameters.py +104 -0
- stackit/serviceenablement/models/parameters_general.py +99 -0
- stackit/serviceenablement/models/service_status.py +179 -0
- stackit/serviceenablement/py.typed +0 -0
- stackit/serviceenablement/rest.py +148 -0
- stackit_serviceenablement-0.0.1a0.dist-info/METADATA +44 -0
- stackit_serviceenablement-0.0.1a0.dist-info/RECORD +20 -0
- stackit_serviceenablement-0.0.1a0.dist-info/WHEEL +4 -0
|
@@ -0,0 +1,1007 @@
|
|
|
1
|
+
# coding: utf-8
|
|
2
|
+
|
|
3
|
+
"""
|
|
4
|
+
STACKIT Service Enablement API
|
|
5
|
+
|
|
6
|
+
STACKIT Service Enablement API
|
|
7
|
+
|
|
8
|
+
The version of the OpenAPI document: 1.1
|
|
9
|
+
Generated by OpenAPI Generator (https://openapi-generator.tech)
|
|
10
|
+
|
|
11
|
+
Do not edit the class manually.
|
|
12
|
+
""" # noqa: E501 docstring might be too long
|
|
13
|
+
|
|
14
|
+
from typing import Any, Dict, List, Optional, Tuple, Union
|
|
15
|
+
|
|
16
|
+
from pydantic import Field, StrictFloat, StrictInt, StrictStr, validate_call
|
|
17
|
+
from stackit.core.configuration import Configuration
|
|
18
|
+
from typing_extensions import Annotated
|
|
19
|
+
|
|
20
|
+
from stackit.serviceenablement.api_client import ApiClient, RequestSerialized
|
|
21
|
+
from stackit.serviceenablement.api_response import ApiResponse
|
|
22
|
+
from stackit.serviceenablement.models.list_service_status200_response import (
|
|
23
|
+
ListServiceStatus200Response,
|
|
24
|
+
)
|
|
25
|
+
from stackit.serviceenablement.models.service_status import ServiceStatus
|
|
26
|
+
from stackit.serviceenablement.rest import RESTResponseType
|
|
27
|
+
|
|
28
|
+
|
|
29
|
+
class DefaultApi:
|
|
30
|
+
"""NOTE: This class is auto generated by OpenAPI Generator
|
|
31
|
+
Ref: https://openapi-generator.tech
|
|
32
|
+
|
|
33
|
+
Do not edit the class manually.
|
|
34
|
+
"""
|
|
35
|
+
|
|
36
|
+
def __init__(self, configuration: Configuration = None) -> None:
|
|
37
|
+
if configuration is None:
|
|
38
|
+
configuration = Configuration()
|
|
39
|
+
self.configuration = configuration
|
|
40
|
+
self.api_client = ApiClient(self.configuration)
|
|
41
|
+
|
|
42
|
+
@validate_call
|
|
43
|
+
def disable_service(
|
|
44
|
+
self,
|
|
45
|
+
project_id: StrictStr,
|
|
46
|
+
service_id: StrictStr,
|
|
47
|
+
_request_timeout: Union[
|
|
48
|
+
None,
|
|
49
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
50
|
+
Tuple[Annotated[StrictFloat, Field(gt=0)], Annotated[StrictFloat, Field(gt=0)]],
|
|
51
|
+
] = None,
|
|
52
|
+
_request_auth: Optional[Dict[StrictStr, Any]] = None,
|
|
53
|
+
_content_type: Optional[StrictStr] = None,
|
|
54
|
+
_headers: Optional[Dict[StrictStr, Any]] = None,
|
|
55
|
+
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
|
|
56
|
+
) -> None:
|
|
57
|
+
"""disable_service
|
|
58
|
+
|
|
59
|
+
disables the service in a project.
|
|
60
|
+
|
|
61
|
+
:param project_id: (required)
|
|
62
|
+
:type project_id: str
|
|
63
|
+
:param service_id: (required)
|
|
64
|
+
:type service_id: str
|
|
65
|
+
:param _request_timeout: timeout setting for this request. If one
|
|
66
|
+
number provided, it will be total request
|
|
67
|
+
timeout. It can also be a pair (tuple) of
|
|
68
|
+
(connection, read) timeouts.
|
|
69
|
+
:type _request_timeout: int, tuple(int, int), optional
|
|
70
|
+
:param _request_auth: set to override the auth_settings for an a single
|
|
71
|
+
request; this effectively ignores the
|
|
72
|
+
authentication in the spec for a single request.
|
|
73
|
+
:type _request_auth: dict, optional
|
|
74
|
+
:param _content_type: force content-type for the request.
|
|
75
|
+
:type _content_type: str, Optional
|
|
76
|
+
:param _headers: set to override the headers for a single
|
|
77
|
+
request; this effectively ignores the headers
|
|
78
|
+
in the spec for a single request.
|
|
79
|
+
:type _headers: dict, optional
|
|
80
|
+
:param _host_index: set to override the host_index for a single
|
|
81
|
+
request; this effectively ignores the host_index
|
|
82
|
+
in the spec for a single request.
|
|
83
|
+
:type _host_index: int, optional
|
|
84
|
+
:return: Returns the result object.
|
|
85
|
+
""" # noqa: E501 docstring might be too long
|
|
86
|
+
|
|
87
|
+
_param = self._disable_service_serialize(
|
|
88
|
+
project_id=project_id,
|
|
89
|
+
service_id=service_id,
|
|
90
|
+
_request_auth=_request_auth,
|
|
91
|
+
_content_type=_content_type,
|
|
92
|
+
_headers=_headers,
|
|
93
|
+
_host_index=_host_index,
|
|
94
|
+
)
|
|
95
|
+
|
|
96
|
+
_response_types_map: Dict[str, Optional[str]] = {
|
|
97
|
+
"202": None,
|
|
98
|
+
"404": None,
|
|
99
|
+
}
|
|
100
|
+
response_data = self.api_client.call_api(*_param, _request_timeout=_request_timeout)
|
|
101
|
+
response_data.read()
|
|
102
|
+
return self.api_client.response_deserialize(
|
|
103
|
+
response_data=response_data,
|
|
104
|
+
response_types_map=_response_types_map,
|
|
105
|
+
).data
|
|
106
|
+
|
|
107
|
+
@validate_call
|
|
108
|
+
def disable_service_with_http_info(
|
|
109
|
+
self,
|
|
110
|
+
project_id: StrictStr,
|
|
111
|
+
service_id: StrictStr,
|
|
112
|
+
_request_timeout: Union[
|
|
113
|
+
None,
|
|
114
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
115
|
+
Tuple[Annotated[StrictFloat, Field(gt=0)], Annotated[StrictFloat, Field(gt=0)]],
|
|
116
|
+
] = None,
|
|
117
|
+
_request_auth: Optional[Dict[StrictStr, Any]] = None,
|
|
118
|
+
_content_type: Optional[StrictStr] = None,
|
|
119
|
+
_headers: Optional[Dict[StrictStr, Any]] = None,
|
|
120
|
+
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
|
|
121
|
+
) -> ApiResponse[None]:
|
|
122
|
+
"""disable_service
|
|
123
|
+
|
|
124
|
+
disables the service in a project.
|
|
125
|
+
|
|
126
|
+
:param project_id: (required)
|
|
127
|
+
:type project_id: str
|
|
128
|
+
:param service_id: (required)
|
|
129
|
+
:type service_id: str
|
|
130
|
+
:param _request_timeout: timeout setting for this request. If one
|
|
131
|
+
number provided, it will be total request
|
|
132
|
+
timeout. It can also be a pair (tuple) of
|
|
133
|
+
(connection, read) timeouts.
|
|
134
|
+
:type _request_timeout: int, tuple(int, int), optional
|
|
135
|
+
:param _request_auth: set to override the auth_settings for an a single
|
|
136
|
+
request; this effectively ignores the
|
|
137
|
+
authentication in the spec for a single request.
|
|
138
|
+
:type _request_auth: dict, optional
|
|
139
|
+
:param _content_type: force content-type for the request.
|
|
140
|
+
:type _content_type: str, Optional
|
|
141
|
+
:param _headers: set to override the headers for a single
|
|
142
|
+
request; this effectively ignores the headers
|
|
143
|
+
in the spec for a single request.
|
|
144
|
+
:type _headers: dict, optional
|
|
145
|
+
:param _host_index: set to override the host_index for a single
|
|
146
|
+
request; this effectively ignores the host_index
|
|
147
|
+
in the spec for a single request.
|
|
148
|
+
:type _host_index: int, optional
|
|
149
|
+
:return: Returns the result object.
|
|
150
|
+
""" # noqa: E501 docstring might be too long
|
|
151
|
+
|
|
152
|
+
_param = self._disable_service_serialize(
|
|
153
|
+
project_id=project_id,
|
|
154
|
+
service_id=service_id,
|
|
155
|
+
_request_auth=_request_auth,
|
|
156
|
+
_content_type=_content_type,
|
|
157
|
+
_headers=_headers,
|
|
158
|
+
_host_index=_host_index,
|
|
159
|
+
)
|
|
160
|
+
|
|
161
|
+
_response_types_map: Dict[str, Optional[str]] = {
|
|
162
|
+
"202": None,
|
|
163
|
+
"404": None,
|
|
164
|
+
}
|
|
165
|
+
response_data = self.api_client.call_api(*_param, _request_timeout=_request_timeout)
|
|
166
|
+
response_data.read()
|
|
167
|
+
return self.api_client.response_deserialize(
|
|
168
|
+
response_data=response_data,
|
|
169
|
+
response_types_map=_response_types_map,
|
|
170
|
+
)
|
|
171
|
+
|
|
172
|
+
@validate_call
|
|
173
|
+
def disable_service_without_preload_content(
|
|
174
|
+
self,
|
|
175
|
+
project_id: StrictStr,
|
|
176
|
+
service_id: StrictStr,
|
|
177
|
+
_request_timeout: Union[
|
|
178
|
+
None,
|
|
179
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
180
|
+
Tuple[Annotated[StrictFloat, Field(gt=0)], Annotated[StrictFloat, Field(gt=0)]],
|
|
181
|
+
] = None,
|
|
182
|
+
_request_auth: Optional[Dict[StrictStr, Any]] = None,
|
|
183
|
+
_content_type: Optional[StrictStr] = None,
|
|
184
|
+
_headers: Optional[Dict[StrictStr, Any]] = None,
|
|
185
|
+
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
|
|
186
|
+
) -> RESTResponseType:
|
|
187
|
+
"""disable_service
|
|
188
|
+
|
|
189
|
+
disables the service in a project.
|
|
190
|
+
|
|
191
|
+
:param project_id: (required)
|
|
192
|
+
:type project_id: str
|
|
193
|
+
:param service_id: (required)
|
|
194
|
+
:type service_id: str
|
|
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 docstring might be too long
|
|
216
|
+
|
|
217
|
+
_param = self._disable_service_serialize(
|
|
218
|
+
project_id=project_id,
|
|
219
|
+
service_id=service_id,
|
|
220
|
+
_request_auth=_request_auth,
|
|
221
|
+
_content_type=_content_type,
|
|
222
|
+
_headers=_headers,
|
|
223
|
+
_host_index=_host_index,
|
|
224
|
+
)
|
|
225
|
+
|
|
226
|
+
_response_types_map: Dict[str, Optional[str]] = {
|
|
227
|
+
"202": None,
|
|
228
|
+
"404": None,
|
|
229
|
+
}
|
|
230
|
+
response_data = self.api_client.call_api(*_param, _request_timeout=_request_timeout)
|
|
231
|
+
return response_data.response
|
|
232
|
+
|
|
233
|
+
def _disable_service_serialize(
|
|
234
|
+
self,
|
|
235
|
+
project_id,
|
|
236
|
+
service_id,
|
|
237
|
+
_request_auth,
|
|
238
|
+
_content_type,
|
|
239
|
+
_headers,
|
|
240
|
+
_host_index,
|
|
241
|
+
) -> RequestSerialized:
|
|
242
|
+
|
|
243
|
+
_host = None
|
|
244
|
+
|
|
245
|
+
_collection_formats: Dict[str, str] = {}
|
|
246
|
+
|
|
247
|
+
_path_params: Dict[str, str] = {}
|
|
248
|
+
_query_params: List[Tuple[str, str]] = []
|
|
249
|
+
_header_params: Dict[str, Optional[str]] = _headers or {}
|
|
250
|
+
_form_params: List[Tuple[str, str]] = []
|
|
251
|
+
_files: Dict[str, Union[str, bytes]] = {}
|
|
252
|
+
_body_params: Optional[bytes] = None
|
|
253
|
+
|
|
254
|
+
# process the path parameters
|
|
255
|
+
if project_id is not None:
|
|
256
|
+
_path_params["projectId"] = project_id
|
|
257
|
+
if service_id is not None:
|
|
258
|
+
_path_params["serviceId"] = service_id
|
|
259
|
+
# process the query parameters
|
|
260
|
+
# process the header parameters
|
|
261
|
+
# process the form parameters
|
|
262
|
+
# process the body parameter
|
|
263
|
+
|
|
264
|
+
# authentication setting
|
|
265
|
+
_auth_settings: List[str] = []
|
|
266
|
+
|
|
267
|
+
return self.api_client.param_serialize(
|
|
268
|
+
method="DELETE",
|
|
269
|
+
resource_path="/v1/projects/{projectId}/services/{serviceId}",
|
|
270
|
+
path_params=_path_params,
|
|
271
|
+
query_params=_query_params,
|
|
272
|
+
header_params=_header_params,
|
|
273
|
+
body=_body_params,
|
|
274
|
+
post_params=_form_params,
|
|
275
|
+
files=_files,
|
|
276
|
+
auth_settings=_auth_settings,
|
|
277
|
+
collection_formats=_collection_formats,
|
|
278
|
+
_host=_host,
|
|
279
|
+
_request_auth=_request_auth,
|
|
280
|
+
)
|
|
281
|
+
|
|
282
|
+
@validate_call
|
|
283
|
+
def enable_service(
|
|
284
|
+
self,
|
|
285
|
+
project_id: StrictStr,
|
|
286
|
+
service_id: StrictStr,
|
|
287
|
+
_request_timeout: Union[
|
|
288
|
+
None,
|
|
289
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
290
|
+
Tuple[Annotated[StrictFloat, Field(gt=0)], Annotated[StrictFloat, Field(gt=0)]],
|
|
291
|
+
] = None,
|
|
292
|
+
_request_auth: Optional[Dict[StrictStr, Any]] = None,
|
|
293
|
+
_content_type: Optional[StrictStr] = None,
|
|
294
|
+
_headers: Optional[Dict[StrictStr, Any]] = None,
|
|
295
|
+
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
|
|
296
|
+
) -> None:
|
|
297
|
+
"""enable_service
|
|
298
|
+
|
|
299
|
+
enables the service in a project.
|
|
300
|
+
|
|
301
|
+
:param project_id: (required)
|
|
302
|
+
:type project_id: str
|
|
303
|
+
:param service_id: (required)
|
|
304
|
+
:type service_id: str
|
|
305
|
+
:param _request_timeout: timeout setting for this request. If one
|
|
306
|
+
number provided, it will be total request
|
|
307
|
+
timeout. It can also be a pair (tuple) of
|
|
308
|
+
(connection, read) timeouts.
|
|
309
|
+
:type _request_timeout: int, tuple(int, int), optional
|
|
310
|
+
:param _request_auth: set to override the auth_settings for an a single
|
|
311
|
+
request; this effectively ignores the
|
|
312
|
+
authentication in the spec for a single request.
|
|
313
|
+
:type _request_auth: dict, optional
|
|
314
|
+
:param _content_type: force content-type for the request.
|
|
315
|
+
:type _content_type: str, Optional
|
|
316
|
+
:param _headers: set to override the headers for a single
|
|
317
|
+
request; this effectively ignores the headers
|
|
318
|
+
in the spec for a single request.
|
|
319
|
+
:type _headers: dict, optional
|
|
320
|
+
:param _host_index: set to override the host_index for a single
|
|
321
|
+
request; this effectively ignores the host_index
|
|
322
|
+
in the spec for a single request.
|
|
323
|
+
:type _host_index: int, optional
|
|
324
|
+
:return: Returns the result object.
|
|
325
|
+
""" # noqa: E501 docstring might be too long
|
|
326
|
+
|
|
327
|
+
_param = self._enable_service_serialize(
|
|
328
|
+
project_id=project_id,
|
|
329
|
+
service_id=service_id,
|
|
330
|
+
_request_auth=_request_auth,
|
|
331
|
+
_content_type=_content_type,
|
|
332
|
+
_headers=_headers,
|
|
333
|
+
_host_index=_host_index,
|
|
334
|
+
)
|
|
335
|
+
|
|
336
|
+
_response_types_map: Dict[str, Optional[str]] = {
|
|
337
|
+
"202": None,
|
|
338
|
+
"404": None,
|
|
339
|
+
}
|
|
340
|
+
response_data = self.api_client.call_api(*_param, _request_timeout=_request_timeout)
|
|
341
|
+
response_data.read()
|
|
342
|
+
return self.api_client.response_deserialize(
|
|
343
|
+
response_data=response_data,
|
|
344
|
+
response_types_map=_response_types_map,
|
|
345
|
+
).data
|
|
346
|
+
|
|
347
|
+
@validate_call
|
|
348
|
+
def enable_service_with_http_info(
|
|
349
|
+
self,
|
|
350
|
+
project_id: StrictStr,
|
|
351
|
+
service_id: StrictStr,
|
|
352
|
+
_request_timeout: Union[
|
|
353
|
+
None,
|
|
354
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
355
|
+
Tuple[Annotated[StrictFloat, Field(gt=0)], Annotated[StrictFloat, Field(gt=0)]],
|
|
356
|
+
] = None,
|
|
357
|
+
_request_auth: Optional[Dict[StrictStr, Any]] = None,
|
|
358
|
+
_content_type: Optional[StrictStr] = None,
|
|
359
|
+
_headers: Optional[Dict[StrictStr, Any]] = None,
|
|
360
|
+
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
|
|
361
|
+
) -> ApiResponse[None]:
|
|
362
|
+
"""enable_service
|
|
363
|
+
|
|
364
|
+
enables the service in a project.
|
|
365
|
+
|
|
366
|
+
:param project_id: (required)
|
|
367
|
+
:type project_id: str
|
|
368
|
+
:param service_id: (required)
|
|
369
|
+
:type service_id: str
|
|
370
|
+
:param _request_timeout: timeout setting for this request. If one
|
|
371
|
+
number provided, it will be total request
|
|
372
|
+
timeout. It can also be a pair (tuple) of
|
|
373
|
+
(connection, read) timeouts.
|
|
374
|
+
:type _request_timeout: int, tuple(int, int), optional
|
|
375
|
+
:param _request_auth: set to override the auth_settings for an a single
|
|
376
|
+
request; this effectively ignores the
|
|
377
|
+
authentication in the spec for a single request.
|
|
378
|
+
:type _request_auth: dict, optional
|
|
379
|
+
:param _content_type: force content-type for the request.
|
|
380
|
+
:type _content_type: str, Optional
|
|
381
|
+
:param _headers: set to override the headers for a single
|
|
382
|
+
request; this effectively ignores the headers
|
|
383
|
+
in the spec for a single request.
|
|
384
|
+
:type _headers: dict, optional
|
|
385
|
+
:param _host_index: set to override the host_index for a single
|
|
386
|
+
request; this effectively ignores the host_index
|
|
387
|
+
in the spec for a single request.
|
|
388
|
+
:type _host_index: int, optional
|
|
389
|
+
:return: Returns the result object.
|
|
390
|
+
""" # noqa: E501 docstring might be too long
|
|
391
|
+
|
|
392
|
+
_param = self._enable_service_serialize(
|
|
393
|
+
project_id=project_id,
|
|
394
|
+
service_id=service_id,
|
|
395
|
+
_request_auth=_request_auth,
|
|
396
|
+
_content_type=_content_type,
|
|
397
|
+
_headers=_headers,
|
|
398
|
+
_host_index=_host_index,
|
|
399
|
+
)
|
|
400
|
+
|
|
401
|
+
_response_types_map: Dict[str, Optional[str]] = {
|
|
402
|
+
"202": None,
|
|
403
|
+
"404": None,
|
|
404
|
+
}
|
|
405
|
+
response_data = self.api_client.call_api(*_param, _request_timeout=_request_timeout)
|
|
406
|
+
response_data.read()
|
|
407
|
+
return self.api_client.response_deserialize(
|
|
408
|
+
response_data=response_data,
|
|
409
|
+
response_types_map=_response_types_map,
|
|
410
|
+
)
|
|
411
|
+
|
|
412
|
+
@validate_call
|
|
413
|
+
def enable_service_without_preload_content(
|
|
414
|
+
self,
|
|
415
|
+
project_id: StrictStr,
|
|
416
|
+
service_id: StrictStr,
|
|
417
|
+
_request_timeout: Union[
|
|
418
|
+
None,
|
|
419
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
420
|
+
Tuple[Annotated[StrictFloat, Field(gt=0)], Annotated[StrictFloat, Field(gt=0)]],
|
|
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
|
+
) -> RESTResponseType:
|
|
427
|
+
"""enable_service
|
|
428
|
+
|
|
429
|
+
enables the service in a project.
|
|
430
|
+
|
|
431
|
+
:param project_id: (required)
|
|
432
|
+
:type project_id: str
|
|
433
|
+
:param service_id: (required)
|
|
434
|
+
:type service_id: str
|
|
435
|
+
:param _request_timeout: timeout setting for this request. If one
|
|
436
|
+
number provided, it will be total request
|
|
437
|
+
timeout. It can also be a pair (tuple) of
|
|
438
|
+
(connection, read) timeouts.
|
|
439
|
+
:type _request_timeout: int, tuple(int, int), optional
|
|
440
|
+
:param _request_auth: set to override the auth_settings for an a single
|
|
441
|
+
request; this effectively ignores the
|
|
442
|
+
authentication in the spec for a single request.
|
|
443
|
+
:type _request_auth: dict, optional
|
|
444
|
+
:param _content_type: force content-type for the request.
|
|
445
|
+
:type _content_type: str, Optional
|
|
446
|
+
:param _headers: set to override the headers for a single
|
|
447
|
+
request; this effectively ignores the headers
|
|
448
|
+
in the spec for a single request.
|
|
449
|
+
:type _headers: dict, optional
|
|
450
|
+
:param _host_index: set to override the host_index for a single
|
|
451
|
+
request; this effectively ignores the host_index
|
|
452
|
+
in the spec for a single request.
|
|
453
|
+
:type _host_index: int, optional
|
|
454
|
+
:return: Returns the result object.
|
|
455
|
+
""" # noqa: E501 docstring might be too long
|
|
456
|
+
|
|
457
|
+
_param = self._enable_service_serialize(
|
|
458
|
+
project_id=project_id,
|
|
459
|
+
service_id=service_id,
|
|
460
|
+
_request_auth=_request_auth,
|
|
461
|
+
_content_type=_content_type,
|
|
462
|
+
_headers=_headers,
|
|
463
|
+
_host_index=_host_index,
|
|
464
|
+
)
|
|
465
|
+
|
|
466
|
+
_response_types_map: Dict[str, Optional[str]] = {
|
|
467
|
+
"202": None,
|
|
468
|
+
"404": None,
|
|
469
|
+
}
|
|
470
|
+
response_data = self.api_client.call_api(*_param, _request_timeout=_request_timeout)
|
|
471
|
+
return response_data.response
|
|
472
|
+
|
|
473
|
+
def _enable_service_serialize(
|
|
474
|
+
self,
|
|
475
|
+
project_id,
|
|
476
|
+
service_id,
|
|
477
|
+
_request_auth,
|
|
478
|
+
_content_type,
|
|
479
|
+
_headers,
|
|
480
|
+
_host_index,
|
|
481
|
+
) -> RequestSerialized:
|
|
482
|
+
|
|
483
|
+
_host = None
|
|
484
|
+
|
|
485
|
+
_collection_formats: Dict[str, str] = {}
|
|
486
|
+
|
|
487
|
+
_path_params: Dict[str, str] = {}
|
|
488
|
+
_query_params: List[Tuple[str, str]] = []
|
|
489
|
+
_header_params: Dict[str, Optional[str]] = _headers or {}
|
|
490
|
+
_form_params: List[Tuple[str, str]] = []
|
|
491
|
+
_files: Dict[str, Union[str, bytes]] = {}
|
|
492
|
+
_body_params: Optional[bytes] = None
|
|
493
|
+
|
|
494
|
+
# process the path parameters
|
|
495
|
+
if project_id is not None:
|
|
496
|
+
_path_params["projectId"] = project_id
|
|
497
|
+
if service_id is not None:
|
|
498
|
+
_path_params["serviceId"] = service_id
|
|
499
|
+
# process the query parameters
|
|
500
|
+
# process the header parameters
|
|
501
|
+
# process the form parameters
|
|
502
|
+
# process the body parameter
|
|
503
|
+
|
|
504
|
+
# authentication setting
|
|
505
|
+
_auth_settings: List[str] = []
|
|
506
|
+
|
|
507
|
+
return self.api_client.param_serialize(
|
|
508
|
+
method="POST",
|
|
509
|
+
resource_path="/v1/projects/{projectId}/services/{serviceId}",
|
|
510
|
+
path_params=_path_params,
|
|
511
|
+
query_params=_query_params,
|
|
512
|
+
header_params=_header_params,
|
|
513
|
+
body=_body_params,
|
|
514
|
+
post_params=_form_params,
|
|
515
|
+
files=_files,
|
|
516
|
+
auth_settings=_auth_settings,
|
|
517
|
+
collection_formats=_collection_formats,
|
|
518
|
+
_host=_host,
|
|
519
|
+
_request_auth=_request_auth,
|
|
520
|
+
)
|
|
521
|
+
|
|
522
|
+
@validate_call
|
|
523
|
+
def get_service_status(
|
|
524
|
+
self,
|
|
525
|
+
project_id: StrictStr,
|
|
526
|
+
service_id: StrictStr,
|
|
527
|
+
_request_timeout: Union[
|
|
528
|
+
None,
|
|
529
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
530
|
+
Tuple[Annotated[StrictFloat, Field(gt=0)], Annotated[StrictFloat, Field(gt=0)]],
|
|
531
|
+
] = None,
|
|
532
|
+
_request_auth: Optional[Dict[StrictStr, Any]] = None,
|
|
533
|
+
_content_type: Optional[StrictStr] = None,
|
|
534
|
+
_headers: Optional[Dict[StrictStr, Any]] = None,
|
|
535
|
+
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
|
|
536
|
+
) -> ServiceStatus:
|
|
537
|
+
"""get_service_status
|
|
538
|
+
|
|
539
|
+
returns the current status of a service in a project.
|
|
540
|
+
|
|
541
|
+
:param project_id: (required)
|
|
542
|
+
:type project_id: str
|
|
543
|
+
:param service_id: (required)
|
|
544
|
+
:type service_id: str
|
|
545
|
+
:param _request_timeout: timeout setting for this request. If one
|
|
546
|
+
number provided, it will be total request
|
|
547
|
+
timeout. It can also be a pair (tuple) of
|
|
548
|
+
(connection, read) timeouts.
|
|
549
|
+
:type _request_timeout: int, tuple(int, int), optional
|
|
550
|
+
:param _request_auth: set to override the auth_settings for an a single
|
|
551
|
+
request; this effectively ignores the
|
|
552
|
+
authentication in the spec for a single request.
|
|
553
|
+
:type _request_auth: dict, optional
|
|
554
|
+
:param _content_type: force content-type for the request.
|
|
555
|
+
:type _content_type: str, Optional
|
|
556
|
+
:param _headers: set to override the headers for a single
|
|
557
|
+
request; this effectively ignores the headers
|
|
558
|
+
in the spec for a single request.
|
|
559
|
+
:type _headers: dict, optional
|
|
560
|
+
:param _host_index: set to override the host_index for a single
|
|
561
|
+
request; this effectively ignores the host_index
|
|
562
|
+
in the spec for a single request.
|
|
563
|
+
:type _host_index: int, optional
|
|
564
|
+
:return: Returns the result object.
|
|
565
|
+
""" # noqa: E501 docstring might be too long
|
|
566
|
+
|
|
567
|
+
_param = self._get_service_status_serialize(
|
|
568
|
+
project_id=project_id,
|
|
569
|
+
service_id=service_id,
|
|
570
|
+
_request_auth=_request_auth,
|
|
571
|
+
_content_type=_content_type,
|
|
572
|
+
_headers=_headers,
|
|
573
|
+
_host_index=_host_index,
|
|
574
|
+
)
|
|
575
|
+
|
|
576
|
+
_response_types_map: Dict[str, Optional[str]] = {
|
|
577
|
+
"200": "ServiceStatus",
|
|
578
|
+
"404": None,
|
|
579
|
+
}
|
|
580
|
+
response_data = self.api_client.call_api(*_param, _request_timeout=_request_timeout)
|
|
581
|
+
response_data.read()
|
|
582
|
+
return self.api_client.response_deserialize(
|
|
583
|
+
response_data=response_data,
|
|
584
|
+
response_types_map=_response_types_map,
|
|
585
|
+
).data
|
|
586
|
+
|
|
587
|
+
@validate_call
|
|
588
|
+
def get_service_status_with_http_info(
|
|
589
|
+
self,
|
|
590
|
+
project_id: StrictStr,
|
|
591
|
+
service_id: StrictStr,
|
|
592
|
+
_request_timeout: Union[
|
|
593
|
+
None,
|
|
594
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
595
|
+
Tuple[Annotated[StrictFloat, Field(gt=0)], Annotated[StrictFloat, Field(gt=0)]],
|
|
596
|
+
] = None,
|
|
597
|
+
_request_auth: Optional[Dict[StrictStr, Any]] = None,
|
|
598
|
+
_content_type: Optional[StrictStr] = None,
|
|
599
|
+
_headers: Optional[Dict[StrictStr, Any]] = None,
|
|
600
|
+
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
|
|
601
|
+
) -> ApiResponse[ServiceStatus]:
|
|
602
|
+
"""get_service_status
|
|
603
|
+
|
|
604
|
+
returns the current status of a service in a project.
|
|
605
|
+
|
|
606
|
+
:param project_id: (required)
|
|
607
|
+
:type project_id: str
|
|
608
|
+
:param service_id: (required)
|
|
609
|
+
:type service_id: str
|
|
610
|
+
:param _request_timeout: timeout setting for this request. If one
|
|
611
|
+
number provided, it will be total request
|
|
612
|
+
timeout. It can also be a pair (tuple) of
|
|
613
|
+
(connection, read) timeouts.
|
|
614
|
+
:type _request_timeout: int, tuple(int, int), optional
|
|
615
|
+
:param _request_auth: set to override the auth_settings for an a single
|
|
616
|
+
request; this effectively ignores the
|
|
617
|
+
authentication in the spec for a single request.
|
|
618
|
+
:type _request_auth: dict, optional
|
|
619
|
+
:param _content_type: force content-type for the request.
|
|
620
|
+
:type _content_type: str, Optional
|
|
621
|
+
:param _headers: set to override the headers for a single
|
|
622
|
+
request; this effectively ignores the headers
|
|
623
|
+
in the spec for a single request.
|
|
624
|
+
:type _headers: dict, optional
|
|
625
|
+
:param _host_index: set to override the host_index for a single
|
|
626
|
+
request; this effectively ignores the host_index
|
|
627
|
+
in the spec for a single request.
|
|
628
|
+
:type _host_index: int, optional
|
|
629
|
+
:return: Returns the result object.
|
|
630
|
+
""" # noqa: E501 docstring might be too long
|
|
631
|
+
|
|
632
|
+
_param = self._get_service_status_serialize(
|
|
633
|
+
project_id=project_id,
|
|
634
|
+
service_id=service_id,
|
|
635
|
+
_request_auth=_request_auth,
|
|
636
|
+
_content_type=_content_type,
|
|
637
|
+
_headers=_headers,
|
|
638
|
+
_host_index=_host_index,
|
|
639
|
+
)
|
|
640
|
+
|
|
641
|
+
_response_types_map: Dict[str, Optional[str]] = {
|
|
642
|
+
"200": "ServiceStatus",
|
|
643
|
+
"404": None,
|
|
644
|
+
}
|
|
645
|
+
response_data = self.api_client.call_api(*_param, _request_timeout=_request_timeout)
|
|
646
|
+
response_data.read()
|
|
647
|
+
return self.api_client.response_deserialize(
|
|
648
|
+
response_data=response_data,
|
|
649
|
+
response_types_map=_response_types_map,
|
|
650
|
+
)
|
|
651
|
+
|
|
652
|
+
@validate_call
|
|
653
|
+
def get_service_status_without_preload_content(
|
|
654
|
+
self,
|
|
655
|
+
project_id: StrictStr,
|
|
656
|
+
service_id: StrictStr,
|
|
657
|
+
_request_timeout: Union[
|
|
658
|
+
None,
|
|
659
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
660
|
+
Tuple[Annotated[StrictFloat, Field(gt=0)], Annotated[StrictFloat, Field(gt=0)]],
|
|
661
|
+
] = None,
|
|
662
|
+
_request_auth: Optional[Dict[StrictStr, Any]] = None,
|
|
663
|
+
_content_type: Optional[StrictStr] = None,
|
|
664
|
+
_headers: Optional[Dict[StrictStr, Any]] = None,
|
|
665
|
+
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
|
|
666
|
+
) -> RESTResponseType:
|
|
667
|
+
"""get_service_status
|
|
668
|
+
|
|
669
|
+
returns the current status of a service in a project.
|
|
670
|
+
|
|
671
|
+
:param project_id: (required)
|
|
672
|
+
:type project_id: str
|
|
673
|
+
:param service_id: (required)
|
|
674
|
+
:type service_id: str
|
|
675
|
+
:param _request_timeout: timeout setting for this request. If one
|
|
676
|
+
number provided, it will be total request
|
|
677
|
+
timeout. It can also be a pair (tuple) of
|
|
678
|
+
(connection, read) timeouts.
|
|
679
|
+
:type _request_timeout: int, tuple(int, int), optional
|
|
680
|
+
:param _request_auth: set to override the auth_settings for an a single
|
|
681
|
+
request; this effectively ignores the
|
|
682
|
+
authentication in the spec for a single request.
|
|
683
|
+
:type _request_auth: dict, optional
|
|
684
|
+
:param _content_type: force content-type for the request.
|
|
685
|
+
:type _content_type: str, Optional
|
|
686
|
+
:param _headers: set to override the headers for a single
|
|
687
|
+
request; this effectively ignores the headers
|
|
688
|
+
in the spec for a single request.
|
|
689
|
+
:type _headers: dict, optional
|
|
690
|
+
:param _host_index: set to override the host_index for a single
|
|
691
|
+
request; this effectively ignores the host_index
|
|
692
|
+
in the spec for a single request.
|
|
693
|
+
:type _host_index: int, optional
|
|
694
|
+
:return: Returns the result object.
|
|
695
|
+
""" # noqa: E501 docstring might be too long
|
|
696
|
+
|
|
697
|
+
_param = self._get_service_status_serialize(
|
|
698
|
+
project_id=project_id,
|
|
699
|
+
service_id=service_id,
|
|
700
|
+
_request_auth=_request_auth,
|
|
701
|
+
_content_type=_content_type,
|
|
702
|
+
_headers=_headers,
|
|
703
|
+
_host_index=_host_index,
|
|
704
|
+
)
|
|
705
|
+
|
|
706
|
+
_response_types_map: Dict[str, Optional[str]] = {
|
|
707
|
+
"200": "ServiceStatus",
|
|
708
|
+
"404": None,
|
|
709
|
+
}
|
|
710
|
+
response_data = self.api_client.call_api(*_param, _request_timeout=_request_timeout)
|
|
711
|
+
return response_data.response
|
|
712
|
+
|
|
713
|
+
def _get_service_status_serialize(
|
|
714
|
+
self,
|
|
715
|
+
project_id,
|
|
716
|
+
service_id,
|
|
717
|
+
_request_auth,
|
|
718
|
+
_content_type,
|
|
719
|
+
_headers,
|
|
720
|
+
_host_index,
|
|
721
|
+
) -> RequestSerialized:
|
|
722
|
+
|
|
723
|
+
_host = None
|
|
724
|
+
|
|
725
|
+
_collection_formats: Dict[str, str] = {}
|
|
726
|
+
|
|
727
|
+
_path_params: Dict[str, str] = {}
|
|
728
|
+
_query_params: List[Tuple[str, str]] = []
|
|
729
|
+
_header_params: Dict[str, Optional[str]] = _headers or {}
|
|
730
|
+
_form_params: List[Tuple[str, str]] = []
|
|
731
|
+
_files: Dict[str, Union[str, bytes]] = {}
|
|
732
|
+
_body_params: Optional[bytes] = None
|
|
733
|
+
|
|
734
|
+
# process the path parameters
|
|
735
|
+
if project_id is not None:
|
|
736
|
+
_path_params["projectId"] = project_id
|
|
737
|
+
if service_id is not None:
|
|
738
|
+
_path_params["serviceId"] = service_id
|
|
739
|
+
# process the query parameters
|
|
740
|
+
# process the header parameters
|
|
741
|
+
# process the form parameters
|
|
742
|
+
# process the body parameter
|
|
743
|
+
|
|
744
|
+
# set the HTTP header `Accept`
|
|
745
|
+
if "Accept" not in _header_params:
|
|
746
|
+
_header_params["Accept"] = self.api_client.select_header_accept(["application/json"])
|
|
747
|
+
|
|
748
|
+
# authentication setting
|
|
749
|
+
_auth_settings: List[str] = []
|
|
750
|
+
|
|
751
|
+
return self.api_client.param_serialize(
|
|
752
|
+
method="GET",
|
|
753
|
+
resource_path="/v1/projects/{projectId}/services/{serviceId}",
|
|
754
|
+
path_params=_path_params,
|
|
755
|
+
query_params=_query_params,
|
|
756
|
+
header_params=_header_params,
|
|
757
|
+
body=_body_params,
|
|
758
|
+
post_params=_form_params,
|
|
759
|
+
files=_files,
|
|
760
|
+
auth_settings=_auth_settings,
|
|
761
|
+
collection_formats=_collection_formats,
|
|
762
|
+
_host=_host,
|
|
763
|
+
_request_auth=_request_auth,
|
|
764
|
+
)
|
|
765
|
+
|
|
766
|
+
@validate_call
|
|
767
|
+
def list_service_status(
|
|
768
|
+
self,
|
|
769
|
+
project_id: StrictStr,
|
|
770
|
+
cursor: Optional[StrictStr] = None,
|
|
771
|
+
_request_timeout: Union[
|
|
772
|
+
None,
|
|
773
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
774
|
+
Tuple[Annotated[StrictFloat, Field(gt=0)], Annotated[StrictFloat, Field(gt=0)]],
|
|
775
|
+
] = None,
|
|
776
|
+
_request_auth: Optional[Dict[StrictStr, Any]] = None,
|
|
777
|
+
_content_type: Optional[StrictStr] = None,
|
|
778
|
+
_headers: Optional[Dict[StrictStr, Any]] = None,
|
|
779
|
+
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
|
|
780
|
+
) -> ListServiceStatus200Response:
|
|
781
|
+
"""list_service_status
|
|
782
|
+
|
|
783
|
+
returns a list of all available services for a project.
|
|
784
|
+
|
|
785
|
+
:param project_id: (required)
|
|
786
|
+
:type project_id: str
|
|
787
|
+
:param cursor:
|
|
788
|
+
:type cursor: str
|
|
789
|
+
:param _request_timeout: timeout setting for this request. If one
|
|
790
|
+
number provided, it will be total request
|
|
791
|
+
timeout. It can also be a pair (tuple) of
|
|
792
|
+
(connection, read) timeouts.
|
|
793
|
+
:type _request_timeout: int, tuple(int, int), optional
|
|
794
|
+
:param _request_auth: set to override the auth_settings for an a single
|
|
795
|
+
request; this effectively ignores the
|
|
796
|
+
authentication in the spec for a single request.
|
|
797
|
+
:type _request_auth: dict, optional
|
|
798
|
+
:param _content_type: force content-type for the request.
|
|
799
|
+
:type _content_type: str, Optional
|
|
800
|
+
:param _headers: set to override the headers for a single
|
|
801
|
+
request; this effectively ignores the headers
|
|
802
|
+
in the spec for a single request.
|
|
803
|
+
:type _headers: dict, optional
|
|
804
|
+
:param _host_index: set to override the host_index for a single
|
|
805
|
+
request; this effectively ignores the host_index
|
|
806
|
+
in the spec for a single request.
|
|
807
|
+
:type _host_index: int, optional
|
|
808
|
+
:return: Returns the result object.
|
|
809
|
+
""" # noqa: E501 docstring might be too long
|
|
810
|
+
|
|
811
|
+
_param = self._list_service_status_serialize(
|
|
812
|
+
project_id=project_id,
|
|
813
|
+
cursor=cursor,
|
|
814
|
+
_request_auth=_request_auth,
|
|
815
|
+
_content_type=_content_type,
|
|
816
|
+
_headers=_headers,
|
|
817
|
+
_host_index=_host_index,
|
|
818
|
+
)
|
|
819
|
+
|
|
820
|
+
_response_types_map: Dict[str, Optional[str]] = {
|
|
821
|
+
"200": "ListServiceStatus200Response",
|
|
822
|
+
}
|
|
823
|
+
response_data = self.api_client.call_api(*_param, _request_timeout=_request_timeout)
|
|
824
|
+
response_data.read()
|
|
825
|
+
return self.api_client.response_deserialize(
|
|
826
|
+
response_data=response_data,
|
|
827
|
+
response_types_map=_response_types_map,
|
|
828
|
+
).data
|
|
829
|
+
|
|
830
|
+
@validate_call
|
|
831
|
+
def list_service_status_with_http_info(
|
|
832
|
+
self,
|
|
833
|
+
project_id: StrictStr,
|
|
834
|
+
cursor: Optional[StrictStr] = None,
|
|
835
|
+
_request_timeout: Union[
|
|
836
|
+
None,
|
|
837
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
838
|
+
Tuple[Annotated[StrictFloat, Field(gt=0)], Annotated[StrictFloat, Field(gt=0)]],
|
|
839
|
+
] = None,
|
|
840
|
+
_request_auth: Optional[Dict[StrictStr, Any]] = None,
|
|
841
|
+
_content_type: Optional[StrictStr] = None,
|
|
842
|
+
_headers: Optional[Dict[StrictStr, Any]] = None,
|
|
843
|
+
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
|
|
844
|
+
) -> ApiResponse[ListServiceStatus200Response]:
|
|
845
|
+
"""list_service_status
|
|
846
|
+
|
|
847
|
+
returns a list of all available services for a project.
|
|
848
|
+
|
|
849
|
+
:param project_id: (required)
|
|
850
|
+
:type project_id: str
|
|
851
|
+
:param cursor:
|
|
852
|
+
:type cursor: str
|
|
853
|
+
:param _request_timeout: timeout setting for this request. If one
|
|
854
|
+
number provided, it will be total request
|
|
855
|
+
timeout. It can also be a pair (tuple) of
|
|
856
|
+
(connection, read) timeouts.
|
|
857
|
+
:type _request_timeout: int, tuple(int, int), optional
|
|
858
|
+
:param _request_auth: set to override the auth_settings for an a single
|
|
859
|
+
request; this effectively ignores the
|
|
860
|
+
authentication in the spec for a single request.
|
|
861
|
+
:type _request_auth: dict, optional
|
|
862
|
+
:param _content_type: force content-type for the request.
|
|
863
|
+
:type _content_type: str, Optional
|
|
864
|
+
:param _headers: set to override the headers for a single
|
|
865
|
+
request; this effectively ignores the headers
|
|
866
|
+
in the spec for a single request.
|
|
867
|
+
:type _headers: dict, optional
|
|
868
|
+
:param _host_index: set to override the host_index for a single
|
|
869
|
+
request; this effectively ignores the host_index
|
|
870
|
+
in the spec for a single request.
|
|
871
|
+
:type _host_index: int, optional
|
|
872
|
+
:return: Returns the result object.
|
|
873
|
+
""" # noqa: E501 docstring might be too long
|
|
874
|
+
|
|
875
|
+
_param = self._list_service_status_serialize(
|
|
876
|
+
project_id=project_id,
|
|
877
|
+
cursor=cursor,
|
|
878
|
+
_request_auth=_request_auth,
|
|
879
|
+
_content_type=_content_type,
|
|
880
|
+
_headers=_headers,
|
|
881
|
+
_host_index=_host_index,
|
|
882
|
+
)
|
|
883
|
+
|
|
884
|
+
_response_types_map: Dict[str, Optional[str]] = {
|
|
885
|
+
"200": "ListServiceStatus200Response",
|
|
886
|
+
}
|
|
887
|
+
response_data = self.api_client.call_api(*_param, _request_timeout=_request_timeout)
|
|
888
|
+
response_data.read()
|
|
889
|
+
return self.api_client.response_deserialize(
|
|
890
|
+
response_data=response_data,
|
|
891
|
+
response_types_map=_response_types_map,
|
|
892
|
+
)
|
|
893
|
+
|
|
894
|
+
@validate_call
|
|
895
|
+
def list_service_status_without_preload_content(
|
|
896
|
+
self,
|
|
897
|
+
project_id: StrictStr,
|
|
898
|
+
cursor: Optional[StrictStr] = None,
|
|
899
|
+
_request_timeout: Union[
|
|
900
|
+
None,
|
|
901
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
902
|
+
Tuple[Annotated[StrictFloat, Field(gt=0)], Annotated[StrictFloat, Field(gt=0)]],
|
|
903
|
+
] = None,
|
|
904
|
+
_request_auth: Optional[Dict[StrictStr, Any]] = None,
|
|
905
|
+
_content_type: Optional[StrictStr] = None,
|
|
906
|
+
_headers: Optional[Dict[StrictStr, Any]] = None,
|
|
907
|
+
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
|
|
908
|
+
) -> RESTResponseType:
|
|
909
|
+
"""list_service_status
|
|
910
|
+
|
|
911
|
+
returns a list of all available services for a project.
|
|
912
|
+
|
|
913
|
+
:param project_id: (required)
|
|
914
|
+
:type project_id: str
|
|
915
|
+
:param cursor:
|
|
916
|
+
:type cursor: str
|
|
917
|
+
:param _request_timeout: timeout setting for this request. If one
|
|
918
|
+
number provided, it will be total request
|
|
919
|
+
timeout. It can also be a pair (tuple) of
|
|
920
|
+
(connection, read) timeouts.
|
|
921
|
+
:type _request_timeout: int, tuple(int, int), optional
|
|
922
|
+
:param _request_auth: set to override the auth_settings for an a single
|
|
923
|
+
request; this effectively ignores the
|
|
924
|
+
authentication in the spec for a single request.
|
|
925
|
+
:type _request_auth: dict, optional
|
|
926
|
+
:param _content_type: force content-type for the request.
|
|
927
|
+
:type _content_type: str, Optional
|
|
928
|
+
:param _headers: set to override the headers for a single
|
|
929
|
+
request; this effectively ignores the headers
|
|
930
|
+
in the spec for a single request.
|
|
931
|
+
:type _headers: dict, optional
|
|
932
|
+
:param _host_index: set to override the host_index for a single
|
|
933
|
+
request; this effectively ignores the host_index
|
|
934
|
+
in the spec for a single request.
|
|
935
|
+
:type _host_index: int, optional
|
|
936
|
+
:return: Returns the result object.
|
|
937
|
+
""" # noqa: E501 docstring might be too long
|
|
938
|
+
|
|
939
|
+
_param = self._list_service_status_serialize(
|
|
940
|
+
project_id=project_id,
|
|
941
|
+
cursor=cursor,
|
|
942
|
+
_request_auth=_request_auth,
|
|
943
|
+
_content_type=_content_type,
|
|
944
|
+
_headers=_headers,
|
|
945
|
+
_host_index=_host_index,
|
|
946
|
+
)
|
|
947
|
+
|
|
948
|
+
_response_types_map: Dict[str, Optional[str]] = {
|
|
949
|
+
"200": "ListServiceStatus200Response",
|
|
950
|
+
}
|
|
951
|
+
response_data = self.api_client.call_api(*_param, _request_timeout=_request_timeout)
|
|
952
|
+
return response_data.response
|
|
953
|
+
|
|
954
|
+
def _list_service_status_serialize(
|
|
955
|
+
self,
|
|
956
|
+
project_id,
|
|
957
|
+
cursor,
|
|
958
|
+
_request_auth,
|
|
959
|
+
_content_type,
|
|
960
|
+
_headers,
|
|
961
|
+
_host_index,
|
|
962
|
+
) -> RequestSerialized:
|
|
963
|
+
|
|
964
|
+
_host = None
|
|
965
|
+
|
|
966
|
+
_collection_formats: Dict[str, str] = {}
|
|
967
|
+
|
|
968
|
+
_path_params: Dict[str, str] = {}
|
|
969
|
+
_query_params: List[Tuple[str, str]] = []
|
|
970
|
+
_header_params: Dict[str, Optional[str]] = _headers or {}
|
|
971
|
+
_form_params: List[Tuple[str, str]] = []
|
|
972
|
+
_files: Dict[str, Union[str, bytes]] = {}
|
|
973
|
+
_body_params: Optional[bytes] = None
|
|
974
|
+
|
|
975
|
+
# process the path parameters
|
|
976
|
+
if project_id is not None:
|
|
977
|
+
_path_params["projectId"] = project_id
|
|
978
|
+
# process the query parameters
|
|
979
|
+
if cursor is not None:
|
|
980
|
+
|
|
981
|
+
_query_params.append(("cursor", cursor))
|
|
982
|
+
|
|
983
|
+
# process the header parameters
|
|
984
|
+
# process the form parameters
|
|
985
|
+
# process the body parameter
|
|
986
|
+
|
|
987
|
+
# set the HTTP header `Accept`
|
|
988
|
+
if "Accept" not in _header_params:
|
|
989
|
+
_header_params["Accept"] = self.api_client.select_header_accept(["application/json"])
|
|
990
|
+
|
|
991
|
+
# authentication setting
|
|
992
|
+
_auth_settings: List[str] = []
|
|
993
|
+
|
|
994
|
+
return self.api_client.param_serialize(
|
|
995
|
+
method="GET",
|
|
996
|
+
resource_path="/v1/projects/{projectId}/services",
|
|
997
|
+
path_params=_path_params,
|
|
998
|
+
query_params=_query_params,
|
|
999
|
+
header_params=_header_params,
|
|
1000
|
+
body=_body_params,
|
|
1001
|
+
post_params=_form_params,
|
|
1002
|
+
files=_files,
|
|
1003
|
+
auth_settings=_auth_settings,
|
|
1004
|
+
collection_formats=_collection_formats,
|
|
1005
|
+
_host=_host,
|
|
1006
|
+
_request_auth=_request_auth,
|
|
1007
|
+
)
|