wds-client 0.30.0__py3-none-any.whl → 0.31.0__py3-none-any.whl

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1,851 +0,0 @@
1
- # coding: utf-8
2
-
3
- """
4
- Workspace Data Service
5
-
6
- This page lists current APIs. All v0.2 APIs are subject to change without notice. Changelog at [https://github.com/DataBiosphere/terra-workspace-data-service/releases](https://github.com/DataBiosphere/terra-workspace-data-service/releases)
7
-
8
- The version of the OpenAPI document: v0.2
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 pydantic import Field, StrictStr
20
- from typing_extensions import Annotated
21
- from wds_client.models.backup_job import BackupJob
22
- from wds_client.models.backup_restore_request import BackupRestoreRequest
23
- from wds_client.models.clone_job import CloneJob
24
-
25
- from wds_client.api_client import ApiClient, RequestSerialized
26
- from wds_client.api_response import ApiResponse
27
- from wds_client.rest import RESTResponseType
28
-
29
-
30
- class CloningApi:
31
- """NOTE: This class is auto generated by OpenAPI Generator
32
- Ref: https://openapi-generator.tech
33
-
34
- Do not edit the class manually.
35
- """
36
-
37
- def __init__(self, api_client=None) -> None:
38
- if api_client is None:
39
- api_client = ApiClient.get_default()
40
- self.api_client = api_client
41
-
42
-
43
- @validate_call
44
- def create_backup(
45
- self,
46
- v: Annotated[StrictStr, Field(description="API version")],
47
- backup_restore_request: Annotated[BackupRestoreRequest, Field(description="A backup request")],
48
- _request_timeout: Union[
49
- None,
50
- Annotated[StrictFloat, Field(gt=0)],
51
- Tuple[
52
- Annotated[StrictFloat, Field(gt=0)],
53
- Annotated[StrictFloat, Field(gt=0)]
54
- ]
55
- ] = None,
56
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
57
- _content_type: Optional[StrictStr] = None,
58
- _headers: Optional[Dict[StrictStr, Any]] = None,
59
- _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
60
- ) -> BackupJob:
61
- """Create a backup of all WDS data
62
-
63
-
64
- :param v: API version (required)
65
- :type v: str
66
- :param backup_restore_request: A backup request (required)
67
- :type backup_restore_request: BackupRestoreRequest
68
- :param _request_timeout: timeout setting for this request. If one
69
- number provided, it will be total request
70
- timeout. It can also be a pair (tuple) of
71
- (connection, read) timeouts.
72
- :type _request_timeout: int, tuple(int, int), optional
73
- :param _request_auth: set to override the auth_settings for an a single
74
- request; this effectively ignores the
75
- authentication in the spec for a single request.
76
- :type _request_auth: dict, optional
77
- :param _content_type: force content-type for the request.
78
- :type _content_type: str, Optional
79
- :param _headers: set to override the headers for a single
80
- request; this effectively ignores the headers
81
- in the spec for a single request.
82
- :type _headers: dict, optional
83
- :param _host_index: set to override the host_index for a single
84
- request; this effectively ignores the host_index
85
- in the spec for a single request.
86
- :type _host_index: int, optional
87
- :return: Returns the result object.
88
- """ # noqa: E501
89
-
90
- _param = self._create_backup_serialize(
91
- v=v,
92
- backup_restore_request=backup_restore_request,
93
- _request_auth=_request_auth,
94
- _content_type=_content_type,
95
- _headers=_headers,
96
- _host_index=_host_index
97
- )
98
-
99
- _response_types_map: Dict[str, Optional[str]] = {
100
- '200': "BackupJob",
101
- }
102
- response_data = self.api_client.call_api(
103
- *_param,
104
- _request_timeout=_request_timeout
105
- )
106
- response_data.read()
107
- return self.api_client.response_deserialize(
108
- response_data=response_data,
109
- response_types_map=_response_types_map,
110
- ).data
111
-
112
-
113
- @validate_call
114
- def create_backup_with_http_info(
115
- self,
116
- v: Annotated[StrictStr, Field(description="API version")],
117
- backup_restore_request: Annotated[BackupRestoreRequest, Field(description="A backup request")],
118
- _request_timeout: Union[
119
- None,
120
- Annotated[StrictFloat, Field(gt=0)],
121
- Tuple[
122
- Annotated[StrictFloat, Field(gt=0)],
123
- Annotated[StrictFloat, Field(gt=0)]
124
- ]
125
- ] = None,
126
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
127
- _content_type: Optional[StrictStr] = None,
128
- _headers: Optional[Dict[StrictStr, Any]] = None,
129
- _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
130
- ) -> ApiResponse[BackupJob]:
131
- """Create a backup of all WDS data
132
-
133
-
134
- :param v: API version (required)
135
- :type v: str
136
- :param backup_restore_request: A backup request (required)
137
- :type backup_restore_request: BackupRestoreRequest
138
- :param _request_timeout: timeout setting for this request. If one
139
- number provided, it will be total request
140
- timeout. It can also be a pair (tuple) of
141
- (connection, read) timeouts.
142
- :type _request_timeout: int, tuple(int, int), optional
143
- :param _request_auth: set to override the auth_settings for an a single
144
- request; this effectively ignores the
145
- authentication in the spec for a single request.
146
- :type _request_auth: dict, optional
147
- :param _content_type: force content-type for the request.
148
- :type _content_type: str, Optional
149
- :param _headers: set to override the headers for a single
150
- request; this effectively ignores the headers
151
- in the spec for a single request.
152
- :type _headers: dict, optional
153
- :param _host_index: set to override the host_index for a single
154
- request; this effectively ignores the host_index
155
- in the spec for a single request.
156
- :type _host_index: int, optional
157
- :return: Returns the result object.
158
- """ # noqa: E501
159
-
160
- _param = self._create_backup_serialize(
161
- v=v,
162
- backup_restore_request=backup_restore_request,
163
- _request_auth=_request_auth,
164
- _content_type=_content_type,
165
- _headers=_headers,
166
- _host_index=_host_index
167
- )
168
-
169
- _response_types_map: Dict[str, Optional[str]] = {
170
- '200': "BackupJob",
171
- }
172
- response_data = self.api_client.call_api(
173
- *_param,
174
- _request_timeout=_request_timeout
175
- )
176
- response_data.read()
177
- return self.api_client.response_deserialize(
178
- response_data=response_data,
179
- response_types_map=_response_types_map,
180
- )
181
-
182
-
183
- @validate_call
184
- def create_backup_without_preload_content(
185
- self,
186
- v: Annotated[StrictStr, Field(description="API version")],
187
- backup_restore_request: Annotated[BackupRestoreRequest, Field(description="A backup request")],
188
- _request_timeout: Union[
189
- None,
190
- Annotated[StrictFloat, Field(gt=0)],
191
- Tuple[
192
- Annotated[StrictFloat, Field(gt=0)],
193
- Annotated[StrictFloat, Field(gt=0)]
194
- ]
195
- ] = None,
196
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
197
- _content_type: Optional[StrictStr] = None,
198
- _headers: Optional[Dict[StrictStr, Any]] = None,
199
- _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
200
- ) -> RESTResponseType:
201
- """Create a backup of all WDS data
202
-
203
-
204
- :param v: API version (required)
205
- :type v: str
206
- :param backup_restore_request: A backup request (required)
207
- :type backup_restore_request: BackupRestoreRequest
208
- :param _request_timeout: timeout setting for this request. If one
209
- number provided, it will be total request
210
- timeout. It can also be a pair (tuple) of
211
- (connection, read) timeouts.
212
- :type _request_timeout: int, tuple(int, int), optional
213
- :param _request_auth: set to override the auth_settings for an a single
214
- request; this effectively ignores the
215
- authentication in the spec for a single request.
216
- :type _request_auth: dict, optional
217
- :param _content_type: force content-type for the request.
218
- :type _content_type: str, Optional
219
- :param _headers: set to override the headers for a single
220
- request; this effectively ignores the headers
221
- in the spec for a single request.
222
- :type _headers: dict, optional
223
- :param _host_index: set to override the host_index for a single
224
- request; this effectively ignores the host_index
225
- in the spec for a single request.
226
- :type _host_index: int, optional
227
- :return: Returns the result object.
228
- """ # noqa: E501
229
-
230
- _param = self._create_backup_serialize(
231
- v=v,
232
- backup_restore_request=backup_restore_request,
233
- _request_auth=_request_auth,
234
- _content_type=_content_type,
235
- _headers=_headers,
236
- _host_index=_host_index
237
- )
238
-
239
- _response_types_map: Dict[str, Optional[str]] = {
240
- '200': "BackupJob",
241
- }
242
- response_data = self.api_client.call_api(
243
- *_param,
244
- _request_timeout=_request_timeout
245
- )
246
- return response_data.response
247
-
248
-
249
- def _create_backup_serialize(
250
- self,
251
- v,
252
- backup_restore_request,
253
- _request_auth,
254
- _content_type,
255
- _headers,
256
- _host_index,
257
- ) -> RequestSerialized:
258
-
259
- _host = None
260
-
261
- _collection_formats: Dict[str, str] = {
262
- }
263
-
264
- _path_params: Dict[str, str] = {}
265
- _query_params: List[Tuple[str, str]] = []
266
- _header_params: Dict[str, Optional[str]] = _headers or {}
267
- _form_params: List[Tuple[str, str]] = []
268
- _files: Dict[str, Union[str, bytes]] = {}
269
- _body_params: Optional[bytes] = None
270
-
271
- # process the path parameters
272
- if v is not None:
273
- _path_params['v'] = v
274
- # process the query parameters
275
- # process the header parameters
276
- # process the form parameters
277
- # process the body parameter
278
- if backup_restore_request is not None:
279
- _body_params = backup_restore_request
280
-
281
-
282
- # set the HTTP header `Accept`
283
- if 'Accept' not in _header_params:
284
- _header_params['Accept'] = self.api_client.select_header_accept(
285
- [
286
- 'application/json'
287
- ]
288
- )
289
-
290
- # set the HTTP header `Content-Type`
291
- if _content_type:
292
- _header_params['Content-Type'] = _content_type
293
- else:
294
- _default_content_type = (
295
- self.api_client.select_header_content_type(
296
- [
297
- 'application/json'
298
- ]
299
- )
300
- )
301
- if _default_content_type is not None:
302
- _header_params['Content-Type'] = _default_content_type
303
-
304
- # authentication setting
305
- _auth_settings: List[str] = [
306
- 'bearerAuth'
307
- ]
308
-
309
- return self.api_client.param_serialize(
310
- method='POST',
311
- resource_path='/backup/{v}',
312
- path_params=_path_params,
313
- query_params=_query_params,
314
- header_params=_header_params,
315
- body=_body_params,
316
- post_params=_form_params,
317
- files=_files,
318
- auth_settings=_auth_settings,
319
- collection_formats=_collection_formats,
320
- _host=_host,
321
- _request_auth=_request_auth
322
- )
323
-
324
-
325
-
326
-
327
- @validate_call
328
- def get_backup_status(
329
- self,
330
- v: Annotated[StrictStr, Field(description="API version")],
331
- tracking_id: Annotated[StrictStr, Field(description="Backup tracking id")],
332
- _request_timeout: Union[
333
- None,
334
- Annotated[StrictFloat, Field(gt=0)],
335
- Tuple[
336
- Annotated[StrictFloat, Field(gt=0)],
337
- Annotated[StrictFloat, Field(gt=0)]
338
- ]
339
- ] = None,
340
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
341
- _content_type: Optional[StrictStr] = None,
342
- _headers: Optional[Dict[StrictStr, Any]] = None,
343
- _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
344
- ) -> BackupJob:
345
- """Check status of a WDS data backup
346
-
347
-
348
- :param v: API version (required)
349
- :type v: str
350
- :param tracking_id: Backup tracking id (required)
351
- :type tracking_id: str
352
- :param _request_timeout: timeout setting for this request. If one
353
- number provided, it will be total request
354
- timeout. It can also be a pair (tuple) of
355
- (connection, read) timeouts.
356
- :type _request_timeout: int, tuple(int, int), optional
357
- :param _request_auth: set to override the auth_settings for an a single
358
- request; this effectively ignores the
359
- authentication in the spec for a single request.
360
- :type _request_auth: dict, optional
361
- :param _content_type: force content-type for the request.
362
- :type _content_type: str, Optional
363
- :param _headers: set to override the headers for a single
364
- request; this effectively ignores the headers
365
- in the spec for a single request.
366
- :type _headers: dict, optional
367
- :param _host_index: set to override the host_index for a single
368
- request; this effectively ignores the host_index
369
- in the spec for a single request.
370
- :type _host_index: int, optional
371
- :return: Returns the result object.
372
- """ # noqa: E501
373
-
374
- _param = self._get_backup_status_serialize(
375
- v=v,
376
- tracking_id=tracking_id,
377
- _request_auth=_request_auth,
378
- _content_type=_content_type,
379
- _headers=_headers,
380
- _host_index=_host_index
381
- )
382
-
383
- _response_types_map: Dict[str, Optional[str]] = {
384
- '200': "BackupJob",
385
- }
386
- response_data = self.api_client.call_api(
387
- *_param,
388
- _request_timeout=_request_timeout
389
- )
390
- response_data.read()
391
- return self.api_client.response_deserialize(
392
- response_data=response_data,
393
- response_types_map=_response_types_map,
394
- ).data
395
-
396
-
397
- @validate_call
398
- def get_backup_status_with_http_info(
399
- self,
400
- v: Annotated[StrictStr, Field(description="API version")],
401
- tracking_id: Annotated[StrictStr, Field(description="Backup tracking id")],
402
- _request_timeout: Union[
403
- None,
404
- Annotated[StrictFloat, Field(gt=0)],
405
- Tuple[
406
- Annotated[StrictFloat, Field(gt=0)],
407
- Annotated[StrictFloat, Field(gt=0)]
408
- ]
409
- ] = None,
410
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
411
- _content_type: Optional[StrictStr] = None,
412
- _headers: Optional[Dict[StrictStr, Any]] = None,
413
- _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
414
- ) -> ApiResponse[BackupJob]:
415
- """Check status of a WDS data backup
416
-
417
-
418
- :param v: API version (required)
419
- :type v: str
420
- :param tracking_id: Backup tracking id (required)
421
- :type tracking_id: str
422
- :param _request_timeout: timeout setting for this request. If one
423
- number provided, it will be total request
424
- timeout. It can also be a pair (tuple) of
425
- (connection, read) timeouts.
426
- :type _request_timeout: int, tuple(int, int), optional
427
- :param _request_auth: set to override the auth_settings for an a single
428
- request; this effectively ignores the
429
- authentication in the spec for a single request.
430
- :type _request_auth: dict, optional
431
- :param _content_type: force content-type for the request.
432
- :type _content_type: str, Optional
433
- :param _headers: set to override the headers for a single
434
- request; this effectively ignores the headers
435
- in the spec for a single request.
436
- :type _headers: dict, optional
437
- :param _host_index: set to override the host_index for a single
438
- request; this effectively ignores the host_index
439
- in the spec for a single request.
440
- :type _host_index: int, optional
441
- :return: Returns the result object.
442
- """ # noqa: E501
443
-
444
- _param = self._get_backup_status_serialize(
445
- v=v,
446
- tracking_id=tracking_id,
447
- _request_auth=_request_auth,
448
- _content_type=_content_type,
449
- _headers=_headers,
450
- _host_index=_host_index
451
- )
452
-
453
- _response_types_map: Dict[str, Optional[str]] = {
454
- '200': "BackupJob",
455
- }
456
- response_data = self.api_client.call_api(
457
- *_param,
458
- _request_timeout=_request_timeout
459
- )
460
- response_data.read()
461
- return self.api_client.response_deserialize(
462
- response_data=response_data,
463
- response_types_map=_response_types_map,
464
- )
465
-
466
-
467
- @validate_call
468
- def get_backup_status_without_preload_content(
469
- self,
470
- v: Annotated[StrictStr, Field(description="API version")],
471
- tracking_id: Annotated[StrictStr, Field(description="Backup tracking id")],
472
- _request_timeout: Union[
473
- None,
474
- Annotated[StrictFloat, Field(gt=0)],
475
- Tuple[
476
- Annotated[StrictFloat, Field(gt=0)],
477
- Annotated[StrictFloat, Field(gt=0)]
478
- ]
479
- ] = None,
480
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
481
- _content_type: Optional[StrictStr] = None,
482
- _headers: Optional[Dict[StrictStr, Any]] = None,
483
- _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
484
- ) -> RESTResponseType:
485
- """Check status of a WDS data backup
486
-
487
-
488
- :param v: API version (required)
489
- :type v: str
490
- :param tracking_id: Backup tracking id (required)
491
- :type tracking_id: str
492
- :param _request_timeout: timeout setting for this request. If one
493
- number provided, it will be total request
494
- timeout. It can also be a pair (tuple) of
495
- (connection, read) timeouts.
496
- :type _request_timeout: int, tuple(int, int), optional
497
- :param _request_auth: set to override the auth_settings for an a single
498
- request; this effectively ignores the
499
- authentication in the spec for a single request.
500
- :type _request_auth: dict, optional
501
- :param _content_type: force content-type for the request.
502
- :type _content_type: str, Optional
503
- :param _headers: set to override the headers for a single
504
- request; this effectively ignores the headers
505
- in the spec for a single request.
506
- :type _headers: dict, optional
507
- :param _host_index: set to override the host_index for a single
508
- request; this effectively ignores the host_index
509
- in the spec for a single request.
510
- :type _host_index: int, optional
511
- :return: Returns the result object.
512
- """ # noqa: E501
513
-
514
- _param = self._get_backup_status_serialize(
515
- v=v,
516
- tracking_id=tracking_id,
517
- _request_auth=_request_auth,
518
- _content_type=_content_type,
519
- _headers=_headers,
520
- _host_index=_host_index
521
- )
522
-
523
- _response_types_map: Dict[str, Optional[str]] = {
524
- '200': "BackupJob",
525
- }
526
- response_data = self.api_client.call_api(
527
- *_param,
528
- _request_timeout=_request_timeout
529
- )
530
- return response_data.response
531
-
532
-
533
- def _get_backup_status_serialize(
534
- self,
535
- v,
536
- tracking_id,
537
- _request_auth,
538
- _content_type,
539
- _headers,
540
- _host_index,
541
- ) -> RequestSerialized:
542
-
543
- _host = None
544
-
545
- _collection_formats: Dict[str, str] = {
546
- }
547
-
548
- _path_params: Dict[str, str] = {}
549
- _query_params: List[Tuple[str, str]] = []
550
- _header_params: Dict[str, Optional[str]] = _headers or {}
551
- _form_params: List[Tuple[str, str]] = []
552
- _files: Dict[str, Union[str, bytes]] = {}
553
- _body_params: Optional[bytes] = None
554
-
555
- # process the path parameters
556
- if v is not None:
557
- _path_params['v'] = v
558
- if tracking_id is not None:
559
- _path_params['trackingId'] = tracking_id
560
- # process the query parameters
561
- # process the header parameters
562
- # process the form parameters
563
- # process the body parameter
564
-
565
-
566
- # set the HTTP header `Accept`
567
- if 'Accept' not in _header_params:
568
- _header_params['Accept'] = self.api_client.select_header_accept(
569
- [
570
- 'application/json'
571
- ]
572
- )
573
-
574
-
575
- # authentication setting
576
- _auth_settings: List[str] = [
577
- 'bearerAuth'
578
- ]
579
-
580
- return self.api_client.param_serialize(
581
- method='GET',
582
- resource_path='/backup/{v}/{trackingId}',
583
- path_params=_path_params,
584
- query_params=_query_params,
585
- header_params=_header_params,
586
- body=_body_params,
587
- post_params=_form_params,
588
- files=_files,
589
- auth_settings=_auth_settings,
590
- collection_formats=_collection_formats,
591
- _host=_host,
592
- _request_auth=_request_auth
593
- )
594
-
595
-
596
-
597
-
598
- @validate_call
599
- def get_clone_status(
600
- self,
601
- v: Annotated[StrictStr, Field(description="API version")],
602
- _request_timeout: Union[
603
- None,
604
- Annotated[StrictFloat, Field(gt=0)],
605
- Tuple[
606
- Annotated[StrictFloat, Field(gt=0)],
607
- Annotated[StrictFloat, Field(gt=0)]
608
- ]
609
- ] = None,
610
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
611
- _content_type: Optional[StrictStr] = None,
612
- _headers: Optional[Dict[StrictStr, Any]] = None,
613
- _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
614
- ) -> CloneJob:
615
- """Check status of a WDS data clone
616
-
617
-
618
- :param v: API version (required)
619
- :type v: str
620
- :param _request_timeout: timeout setting for this request. If one
621
- number provided, it will be total request
622
- timeout. It can also be a pair (tuple) of
623
- (connection, read) timeouts.
624
- :type _request_timeout: int, tuple(int, int), optional
625
- :param _request_auth: set to override the auth_settings for an a single
626
- request; this effectively ignores the
627
- authentication in the spec for a single request.
628
- :type _request_auth: dict, optional
629
- :param _content_type: force content-type for the request.
630
- :type _content_type: str, Optional
631
- :param _headers: set to override the headers for a single
632
- request; this effectively ignores the headers
633
- in the spec for a single request.
634
- :type _headers: dict, optional
635
- :param _host_index: set to override the host_index for a single
636
- request; this effectively ignores the host_index
637
- in the spec for a single request.
638
- :type _host_index: int, optional
639
- :return: Returns the result object.
640
- """ # noqa: E501
641
-
642
- _param = self._get_clone_status_serialize(
643
- v=v,
644
- _request_auth=_request_auth,
645
- _content_type=_content_type,
646
- _headers=_headers,
647
- _host_index=_host_index
648
- )
649
-
650
- _response_types_map: Dict[str, Optional[str]] = {
651
- '200': "CloneJob",
652
- }
653
- response_data = self.api_client.call_api(
654
- *_param,
655
- _request_timeout=_request_timeout
656
- )
657
- response_data.read()
658
- return self.api_client.response_deserialize(
659
- response_data=response_data,
660
- response_types_map=_response_types_map,
661
- ).data
662
-
663
-
664
- @validate_call
665
- def get_clone_status_with_http_info(
666
- self,
667
- v: Annotated[StrictStr, Field(description="API version")],
668
- _request_timeout: Union[
669
- None,
670
- Annotated[StrictFloat, Field(gt=0)],
671
- Tuple[
672
- Annotated[StrictFloat, Field(gt=0)],
673
- Annotated[StrictFloat, Field(gt=0)]
674
- ]
675
- ] = None,
676
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
677
- _content_type: Optional[StrictStr] = None,
678
- _headers: Optional[Dict[StrictStr, Any]] = None,
679
- _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
680
- ) -> ApiResponse[CloneJob]:
681
- """Check status of a WDS data clone
682
-
683
-
684
- :param v: API version (required)
685
- :type v: str
686
- :param _request_timeout: timeout setting for this request. If one
687
- number provided, it will be total request
688
- timeout. It can also be a pair (tuple) of
689
- (connection, read) timeouts.
690
- :type _request_timeout: int, tuple(int, int), optional
691
- :param _request_auth: set to override the auth_settings for an a single
692
- request; this effectively ignores the
693
- authentication in the spec for a single request.
694
- :type _request_auth: dict, optional
695
- :param _content_type: force content-type for the request.
696
- :type _content_type: str, Optional
697
- :param _headers: set to override the headers for a single
698
- request; this effectively ignores the headers
699
- in the spec for a single request.
700
- :type _headers: dict, optional
701
- :param _host_index: set to override the host_index for a single
702
- request; this effectively ignores the host_index
703
- in the spec for a single request.
704
- :type _host_index: int, optional
705
- :return: Returns the result object.
706
- """ # noqa: E501
707
-
708
- _param = self._get_clone_status_serialize(
709
- v=v,
710
- _request_auth=_request_auth,
711
- _content_type=_content_type,
712
- _headers=_headers,
713
- _host_index=_host_index
714
- )
715
-
716
- _response_types_map: Dict[str, Optional[str]] = {
717
- '200': "CloneJob",
718
- }
719
- response_data = self.api_client.call_api(
720
- *_param,
721
- _request_timeout=_request_timeout
722
- )
723
- response_data.read()
724
- return self.api_client.response_deserialize(
725
- response_data=response_data,
726
- response_types_map=_response_types_map,
727
- )
728
-
729
-
730
- @validate_call
731
- def get_clone_status_without_preload_content(
732
- self,
733
- v: Annotated[StrictStr, Field(description="API version")],
734
- _request_timeout: Union[
735
- None,
736
- Annotated[StrictFloat, Field(gt=0)],
737
- Tuple[
738
- Annotated[StrictFloat, Field(gt=0)],
739
- Annotated[StrictFloat, Field(gt=0)]
740
- ]
741
- ] = None,
742
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
743
- _content_type: Optional[StrictStr] = None,
744
- _headers: Optional[Dict[StrictStr, Any]] = None,
745
- _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
746
- ) -> RESTResponseType:
747
- """Check status of a WDS data clone
748
-
749
-
750
- :param v: API version (required)
751
- :type v: str
752
- :param _request_timeout: timeout setting for this request. If one
753
- number provided, it will be total request
754
- timeout. It can also be a pair (tuple) of
755
- (connection, read) timeouts.
756
- :type _request_timeout: int, tuple(int, int), optional
757
- :param _request_auth: set to override the auth_settings for an a single
758
- request; this effectively ignores the
759
- authentication in the spec for a single request.
760
- :type _request_auth: dict, optional
761
- :param _content_type: force content-type for the request.
762
- :type _content_type: str, Optional
763
- :param _headers: set to override the headers for a single
764
- request; this effectively ignores the headers
765
- in the spec for a single request.
766
- :type _headers: dict, optional
767
- :param _host_index: set to override the host_index for a single
768
- request; this effectively ignores the host_index
769
- in the spec for a single request.
770
- :type _host_index: int, optional
771
- :return: Returns the result object.
772
- """ # noqa: E501
773
-
774
- _param = self._get_clone_status_serialize(
775
- v=v,
776
- _request_auth=_request_auth,
777
- _content_type=_content_type,
778
- _headers=_headers,
779
- _host_index=_host_index
780
- )
781
-
782
- _response_types_map: Dict[str, Optional[str]] = {
783
- '200': "CloneJob",
784
- }
785
- response_data = self.api_client.call_api(
786
- *_param,
787
- _request_timeout=_request_timeout
788
- )
789
- return response_data.response
790
-
791
-
792
- def _get_clone_status_serialize(
793
- self,
794
- v,
795
- _request_auth,
796
- _content_type,
797
- _headers,
798
- _host_index,
799
- ) -> RequestSerialized:
800
-
801
- _host = None
802
-
803
- _collection_formats: Dict[str, str] = {
804
- }
805
-
806
- _path_params: Dict[str, str] = {}
807
- _query_params: List[Tuple[str, str]] = []
808
- _header_params: Dict[str, Optional[str]] = _headers or {}
809
- _form_params: List[Tuple[str, str]] = []
810
- _files: Dict[str, Union[str, bytes]] = {}
811
- _body_params: Optional[bytes] = None
812
-
813
- # process the path parameters
814
- if v is not None:
815
- _path_params['v'] = v
816
- # process the query parameters
817
- # process the header parameters
818
- # process the form parameters
819
- # process the body parameter
820
-
821
-
822
- # set the HTTP header `Accept`
823
- if 'Accept' not in _header_params:
824
- _header_params['Accept'] = self.api_client.select_header_accept(
825
- [
826
- 'application/json'
827
- ]
828
- )
829
-
830
-
831
- # authentication setting
832
- _auth_settings: List[str] = [
833
- 'bearerAuth'
834
- ]
835
-
836
- return self.api_client.param_serialize(
837
- method='GET',
838
- resource_path='/clone/{v}',
839
- path_params=_path_params,
840
- query_params=_query_params,
841
- header_params=_header_params,
842
- body=_body_params,
843
- post_params=_form_params,
844
- files=_files,
845
- auth_settings=_auth_settings,
846
- collection_formats=_collection_formats,
847
- _host=_host,
848
- _request_auth=_request_auth
849
- )
850
-
851
-