wds-client 0.6.0__py3-none-any.whl → 0.8.0__py3-none-any.whl
Sign up to get free protection for your applications and to get access to all the features.
- wds_client/__init__.py +8 -10
- wds_client/api/__init__.py +1 -2
- wds_client/api/capabilities_api.py +237 -102
- wds_client/api/cloning_api.py +782 -329
- wds_client/api/general_wds_information_api.py +463 -191
- wds_client/api/import_api.py +288 -127
- wds_client/api/instances_api.py +783 -333
- wds_client/api/job_api.py +518 -215
- wds_client/api/records_api.py +2512 -1089
- wds_client/api/schema_api.py +1450 -626
- wds_client/api_client.py +414 -310
- wds_client/api_response.py +21 -0
- wds_client/configuration.py +110 -53
- wds_client/exceptions.py +99 -20
- wds_client/models/__init__.py +4 -8
- wds_client/models/app.py +68 -125
- wds_client/models/attribute_data_type.py +31 -94
- wds_client/models/attribute_schema.py +71 -157
- wds_client/models/attribute_schema_update.py +69 -127
- wds_client/models/backup_job.py +96 -298
- wds_client/models/backup_response.py +70 -157
- wds_client/models/backup_restore_request.py +68 -129
- wds_client/models/batch_operation.py +83 -137
- wds_client/models/batch_record_request.py +70 -160
- wds_client/models/batch_response.py +68 -127
- wds_client/models/build.py +79 -207
- wds_client/models/capabilities.py +83 -103
- wds_client/models/clone_job.py +96 -298
- wds_client/models/clone_response.py +68 -129
- wds_client/models/commit.py +69 -125
- wds_client/models/error_response.py +78 -222
- wds_client/models/generic_job.py +102 -334
- wds_client/models/git.py +76 -129
- wds_client/models/import_request.py +77 -165
- wds_client/models/job.py +87 -243
- wds_client/models/job_v1.py +97 -277
- wds_client/models/record_query_response.py +86 -162
- wds_client/models/record_request.py +60 -96
- wds_client/models/record_response.py +70 -160
- wds_client/models/record_type_schema.py +84 -191
- wds_client/models/search_filter.py +60 -95
- wds_client/models/search_request.py +84 -220
- wds_client/models/search_sort_direction.py +17 -80
- wds_client/models/status_response.py +68 -125
- wds_client/models/tsv_upload_response.py +68 -127
- wds_client/models/version_response.py +86 -155
- wds_client/py.typed +0 -0
- wds_client/rest.py +136 -170
- wds_client-0.8.0.dist-info/METADATA +17 -0
- wds_client-0.8.0.dist-info/RECORD +52 -0
- wds_client/models/backup_job_all_of.py +0 -148
- wds_client/models/clone_job_all_of.py +0 -148
- wds_client/models/generic_job_all_of.py +0 -150
- wds_client/models/inline_object.py +0 -123
- wds_client-0.6.0.dist-info/METADATA +0 -16
- wds_client-0.6.0.dist-info/RECORD +0 -54
- {wds_client-0.6.0.dist-info → wds_client-0.8.0.dist-info}/WHEEL +0 -0
- {wds_client-0.6.0.dist-info → wds_client-0.8.0.dist-info}/top_level.txt +0 -0
@@ -3,176 +3,89 @@
|
|
3
3
|
"""
|
4
4
|
Workspace Data Service
|
5
5
|
|
6
|
-
This page lists current APIs.
|
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
7
|
|
8
8
|
The version of the OpenAPI document: v0.2
|
9
|
-
Generated by
|
10
|
-
|
9
|
+
Generated by OpenAPI Generator (https://openapi-generator.tech)
|
10
|
+
|
11
|
+
Do not edit the class manually.
|
12
|
+
""" # noqa: E501
|
11
13
|
|
12
14
|
|
15
|
+
from __future__ import annotations
|
13
16
|
import pprint
|
14
17
|
import re # noqa: F401
|
18
|
+
import json
|
15
19
|
|
16
|
-
import
|
17
|
-
|
18
|
-
from
|
19
|
-
|
20
|
-
|
21
|
-
class BackupResponse(object):
|
22
|
-
"""NOTE: This class is auto generated by OpenAPI Generator.
|
23
|
-
Ref: https://openapi-generator.tech
|
24
|
-
|
25
|
-
Do not edit the class manually.
|
26
|
-
"""
|
20
|
+
from pydantic import BaseModel, ConfigDict, Field, StrictStr
|
21
|
+
from typing import Any, ClassVar, Dict, List, Optional
|
22
|
+
from typing import Optional, Set
|
23
|
+
from typing_extensions import Self
|
27
24
|
|
25
|
+
class BackupResponse(BaseModel):
|
28
26
|
"""
|
29
|
-
|
30
|
-
|
31
|
-
|
32
|
-
|
33
|
-
|
34
|
-
"""
|
35
|
-
|
36
|
-
|
37
|
-
|
38
|
-
|
39
|
-
|
40
|
-
|
41
|
-
|
42
|
-
|
43
|
-
|
44
|
-
|
45
|
-
|
46
|
-
|
47
|
-
def
|
48
|
-
"""
|
49
|
-
|
50
|
-
|
51
|
-
|
52
|
-
|
53
|
-
|
54
|
-
|
55
|
-
|
56
|
-
|
57
|
-
|
58
|
-
|
59
|
-
|
60
|
-
|
61
|
-
|
62
|
-
|
63
|
-
|
64
|
-
|
65
|
-
|
66
|
-
def filename(self):
|
67
|
-
"""Gets the filename of this BackupResponse. # noqa: E501
|
68
|
-
|
69
|
-
backup location # noqa: E501
|
70
|
-
|
71
|
-
:return: The filename of this BackupResponse. # noqa: E501
|
72
|
-
:rtype: str
|
27
|
+
BackupResponse
|
28
|
+
""" # noqa: E501
|
29
|
+
filename: Optional[StrictStr] = Field(default=None, description="backup location")
|
30
|
+
requester: Optional[StrictStr] = Field(default=None, description="workspace which initiated the backup")
|
31
|
+
description: Optional[StrictStr] = Field(default=None, description="description of this backup")
|
32
|
+
__properties: ClassVar[List[str]] = ["filename", "requester", "description"]
|
33
|
+
|
34
|
+
model_config = ConfigDict(
|
35
|
+
populate_by_name=True,
|
36
|
+
validate_assignment=True,
|
37
|
+
protected_namespaces=(),
|
38
|
+
)
|
39
|
+
|
40
|
+
|
41
|
+
def to_str(self) -> str:
|
42
|
+
"""Returns the string representation of the model using alias"""
|
43
|
+
return pprint.pformat(self.model_dump(by_alias=True))
|
44
|
+
|
45
|
+
def to_json(self) -> str:
|
46
|
+
"""Returns the JSON representation of the model using alias"""
|
47
|
+
# TODO: pydantic v2: use .model_dump_json(by_alias=True, exclude_unset=True) instead
|
48
|
+
return json.dumps(self.to_dict())
|
49
|
+
|
50
|
+
@classmethod
|
51
|
+
def from_json(cls, json_str: str) -> Optional[Self]:
|
52
|
+
"""Create an instance of BackupResponse from a JSON string"""
|
53
|
+
return cls.from_dict(json.loads(json_str))
|
54
|
+
|
55
|
+
def to_dict(self) -> Dict[str, Any]:
|
56
|
+
"""Return the dictionary representation of the model using alias.
|
57
|
+
|
58
|
+
This has the following differences from calling pydantic's
|
59
|
+
`self.model_dump(by_alias=True)`:
|
60
|
+
|
61
|
+
* `None` is only added to the output dict for nullable fields that
|
62
|
+
were set at model initialization. Other fields with value `None`
|
63
|
+
are ignored.
|
73
64
|
"""
|
74
|
-
|
65
|
+
excluded_fields: Set[str] = set([
|
66
|
+
])
|
75
67
|
|
76
|
-
|
77
|
-
|
78
|
-
|
68
|
+
_dict = self.model_dump(
|
69
|
+
by_alias=True,
|
70
|
+
exclude=excluded_fields,
|
71
|
+
exclude_none=True,
|
72
|
+
)
|
73
|
+
return _dict
|
79
74
|
|
80
|
-
|
75
|
+
@classmethod
|
76
|
+
def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
|
77
|
+
"""Create an instance of BackupResponse from a dict"""
|
78
|
+
if obj is None:
|
79
|
+
return None
|
81
80
|
|
82
|
-
|
83
|
-
|
84
|
-
"""
|
81
|
+
if not isinstance(obj, dict):
|
82
|
+
return cls.model_validate(obj)
|
85
83
|
|
86
|
-
|
84
|
+
_obj = cls.model_validate({
|
85
|
+
"filename": obj.get("filename"),
|
86
|
+
"requester": obj.get("requester"),
|
87
|
+
"description": obj.get("description")
|
88
|
+
})
|
89
|
+
return _obj
|
87
90
|
|
88
|
-
@property
|
89
|
-
def requester(self):
|
90
|
-
"""Gets the requester of this BackupResponse. # noqa: E501
|
91
|
-
|
92
|
-
workspace which initiated the backup # noqa: E501
|
93
|
-
|
94
|
-
:return: The requester of this BackupResponse. # noqa: E501
|
95
|
-
:rtype: str
|
96
|
-
"""
|
97
|
-
return self._requester
|
98
|
-
|
99
|
-
@requester.setter
|
100
|
-
def requester(self, requester):
|
101
|
-
"""Sets the requester of this BackupResponse.
|
102
|
-
|
103
|
-
workspace which initiated the backup # noqa: E501
|
104
|
-
|
105
|
-
:param requester: The requester of this BackupResponse. # noqa: E501
|
106
|
-
:type: str
|
107
|
-
"""
|
108
|
-
|
109
|
-
self._requester = requester
|
110
|
-
|
111
|
-
@property
|
112
|
-
def description(self):
|
113
|
-
"""Gets the description of this BackupResponse. # noqa: E501
|
114
|
-
|
115
|
-
description of this backup # noqa: E501
|
116
|
-
|
117
|
-
:return: The description of this BackupResponse. # noqa: E501
|
118
|
-
:rtype: str
|
119
|
-
"""
|
120
|
-
return self._description
|
121
|
-
|
122
|
-
@description.setter
|
123
|
-
def description(self, description):
|
124
|
-
"""Sets the description of this BackupResponse.
|
125
|
-
|
126
|
-
description of this backup # noqa: E501
|
127
|
-
|
128
|
-
:param description: The description of this BackupResponse. # noqa: E501
|
129
|
-
:type: str
|
130
|
-
"""
|
131
91
|
|
132
|
-
self._description = description
|
133
|
-
|
134
|
-
def to_dict(self):
|
135
|
-
"""Returns the model properties as a dict"""
|
136
|
-
result = {}
|
137
|
-
|
138
|
-
for attr, _ in six.iteritems(self.openapi_types):
|
139
|
-
value = getattr(self, attr)
|
140
|
-
if isinstance(value, list):
|
141
|
-
result[attr] = list(map(
|
142
|
-
lambda x: x.to_dict() if hasattr(x, "to_dict") else x,
|
143
|
-
value
|
144
|
-
))
|
145
|
-
elif hasattr(value, "to_dict"):
|
146
|
-
result[attr] = value.to_dict()
|
147
|
-
elif isinstance(value, dict):
|
148
|
-
result[attr] = dict(map(
|
149
|
-
lambda item: (item[0], item[1].to_dict())
|
150
|
-
if hasattr(item[1], "to_dict") else item,
|
151
|
-
value.items()
|
152
|
-
))
|
153
|
-
else:
|
154
|
-
result[attr] = value
|
155
|
-
|
156
|
-
return result
|
157
|
-
|
158
|
-
def to_str(self):
|
159
|
-
"""Returns the string representation of the model"""
|
160
|
-
return pprint.pformat(self.to_dict())
|
161
|
-
|
162
|
-
def __repr__(self):
|
163
|
-
"""For `print` and `pprint`"""
|
164
|
-
return self.to_str()
|
165
|
-
|
166
|
-
def __eq__(self, other):
|
167
|
-
"""Returns true if both objects are equal"""
|
168
|
-
if not isinstance(other, BackupResponse):
|
169
|
-
return False
|
170
|
-
|
171
|
-
return self.to_dict() == other.to_dict()
|
172
|
-
|
173
|
-
def __ne__(self, other):
|
174
|
-
"""Returns true if both objects are not equal"""
|
175
|
-
if not isinstance(other, BackupResponse):
|
176
|
-
return True
|
177
|
-
|
178
|
-
return self.to_dict() != other.to_dict()
|
@@ -3,148 +3,87 @@
|
|
3
3
|
"""
|
4
4
|
Workspace Data Service
|
5
5
|
|
6
|
-
This page lists current APIs.
|
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
7
|
|
8
8
|
The version of the OpenAPI document: v0.2
|
9
|
-
Generated by
|
10
|
-
|
9
|
+
Generated by OpenAPI Generator (https://openapi-generator.tech)
|
10
|
+
|
11
|
+
Do not edit the class manually.
|
12
|
+
""" # noqa: E501
|
11
13
|
|
12
14
|
|
15
|
+
from __future__ import annotations
|
13
16
|
import pprint
|
14
17
|
import re # noqa: F401
|
18
|
+
import json
|
15
19
|
|
16
|
-
import
|
17
|
-
|
18
|
-
from
|
19
|
-
|
20
|
-
|
21
|
-
class BackupRestoreRequest(object):
|
22
|
-
"""NOTE: This class is auto generated by OpenAPI Generator.
|
23
|
-
Ref: https://openapi-generator.tech
|
24
|
-
|
25
|
-
Do not edit the class manually.
|
26
|
-
"""
|
20
|
+
from pydantic import BaseModel, ConfigDict, Field, StrictStr
|
21
|
+
from typing import Any, ClassVar, Dict, List, Optional
|
22
|
+
from typing import Optional, Set
|
23
|
+
from typing_extensions import Self
|
27
24
|
|
25
|
+
class BackupRestoreRequest(BaseModel):
|
28
26
|
"""
|
29
|
-
|
30
|
-
|
31
|
-
|
32
|
-
|
33
|
-
|
34
|
-
|
35
|
-
|
36
|
-
|
37
|
-
|
38
|
-
|
39
|
-
|
40
|
-
|
41
|
-
|
42
|
-
|
43
|
-
|
44
|
-
|
45
|
-
|
46
|
-
|
47
|
-
|
48
|
-
|
49
|
-
self.
|
50
|
-
|
51
|
-
|
52
|
-
|
53
|
-
|
54
|
-
|
55
|
-
|
56
|
-
|
57
|
-
|
58
|
-
|
59
|
-
|
60
|
-
|
61
|
-
|
62
|
-
|
63
|
-
|
64
|
-
|
65
|
-
|
66
|
-
:return: The requesting_workspace_id of this BackupRestoreRequest. # noqa: E501
|
67
|
-
:rtype: str
|
27
|
+
BackupRestoreRequest
|
28
|
+
""" # noqa: E501
|
29
|
+
requesting_workspace_id: Optional[StrictStr] = Field(default=None, description="workspace requesting the backup. Optional; defaults to the workspace in which this WDS is running.", alias="requestingWorkspaceId")
|
30
|
+
description: Optional[StrictStr] = Field(default=None, description="User-friendly description to associate with this backup. Optional.")
|
31
|
+
__properties: ClassVar[List[str]] = ["requestingWorkspaceId", "description"]
|
32
|
+
|
33
|
+
model_config = ConfigDict(
|
34
|
+
populate_by_name=True,
|
35
|
+
validate_assignment=True,
|
36
|
+
protected_namespaces=(),
|
37
|
+
)
|
38
|
+
|
39
|
+
|
40
|
+
def to_str(self) -> str:
|
41
|
+
"""Returns the string representation of the model using alias"""
|
42
|
+
return pprint.pformat(self.model_dump(by_alias=True))
|
43
|
+
|
44
|
+
def to_json(self) -> str:
|
45
|
+
"""Returns the JSON representation of the model using alias"""
|
46
|
+
# TODO: pydantic v2: use .model_dump_json(by_alias=True, exclude_unset=True) instead
|
47
|
+
return json.dumps(self.to_dict())
|
48
|
+
|
49
|
+
@classmethod
|
50
|
+
def from_json(cls, json_str: str) -> Optional[Self]:
|
51
|
+
"""Create an instance of BackupRestoreRequest from a JSON string"""
|
52
|
+
return cls.from_dict(json.loads(json_str))
|
53
|
+
|
54
|
+
def to_dict(self) -> Dict[str, Any]:
|
55
|
+
"""Return the dictionary representation of the model using alias.
|
56
|
+
|
57
|
+
This has the following differences from calling pydantic's
|
58
|
+
`self.model_dump(by_alias=True)`:
|
59
|
+
|
60
|
+
* `None` is only added to the output dict for nullable fields that
|
61
|
+
were set at model initialization. Other fields with value `None`
|
62
|
+
are ignored.
|
68
63
|
"""
|
69
|
-
|
70
|
-
|
71
|
-
@requesting_workspace_id.setter
|
72
|
-
def requesting_workspace_id(self, requesting_workspace_id):
|
73
|
-
"""Sets the requesting_workspace_id of this BackupRestoreRequest.
|
64
|
+
excluded_fields: Set[str] = set([
|
65
|
+
])
|
74
66
|
|
75
|
-
|
67
|
+
_dict = self.model_dump(
|
68
|
+
by_alias=True,
|
69
|
+
exclude=excluded_fields,
|
70
|
+
exclude_none=True,
|
71
|
+
)
|
72
|
+
return _dict
|
76
73
|
|
77
|
-
|
78
|
-
|
79
|
-
"""
|
74
|
+
@classmethod
|
75
|
+
def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
|
76
|
+
"""Create an instance of BackupRestoreRequest from a dict"""
|
77
|
+
if obj is None:
|
78
|
+
return None
|
80
79
|
|
81
|
-
|
80
|
+
if not isinstance(obj, dict):
|
81
|
+
return cls.model_validate(obj)
|
82
82
|
|
83
|
-
|
84
|
-
|
85
|
-
|
83
|
+
_obj = cls.model_validate({
|
84
|
+
"requestingWorkspaceId": obj.get("requestingWorkspaceId"),
|
85
|
+
"description": obj.get("description")
|
86
|
+
})
|
87
|
+
return _obj
|
86
88
|
|
87
|
-
User-friendly description to associate with this backup. Optional. # noqa: E501
|
88
|
-
|
89
|
-
:return: The description of this BackupRestoreRequest. # noqa: E501
|
90
|
-
:rtype: str
|
91
|
-
"""
|
92
|
-
return self._description
|
93
|
-
|
94
|
-
@description.setter
|
95
|
-
def description(self, description):
|
96
|
-
"""Sets the description of this BackupRestoreRequest.
|
97
|
-
|
98
|
-
User-friendly description to associate with this backup. Optional. # noqa: E501
|
99
|
-
|
100
|
-
:param description: The description of this BackupRestoreRequest. # noqa: E501
|
101
|
-
:type: str
|
102
|
-
"""
|
103
89
|
|
104
|
-
self._description = description
|
105
|
-
|
106
|
-
def to_dict(self):
|
107
|
-
"""Returns the model properties as a dict"""
|
108
|
-
result = {}
|
109
|
-
|
110
|
-
for attr, _ in six.iteritems(self.openapi_types):
|
111
|
-
value = getattr(self, attr)
|
112
|
-
if isinstance(value, list):
|
113
|
-
result[attr] = list(map(
|
114
|
-
lambda x: x.to_dict() if hasattr(x, "to_dict") else x,
|
115
|
-
value
|
116
|
-
))
|
117
|
-
elif hasattr(value, "to_dict"):
|
118
|
-
result[attr] = value.to_dict()
|
119
|
-
elif isinstance(value, dict):
|
120
|
-
result[attr] = dict(map(
|
121
|
-
lambda item: (item[0], item[1].to_dict())
|
122
|
-
if hasattr(item[1], "to_dict") else item,
|
123
|
-
value.items()
|
124
|
-
))
|
125
|
-
else:
|
126
|
-
result[attr] = value
|
127
|
-
|
128
|
-
return result
|
129
|
-
|
130
|
-
def to_str(self):
|
131
|
-
"""Returns the string representation of the model"""
|
132
|
-
return pprint.pformat(self.to_dict())
|
133
|
-
|
134
|
-
def __repr__(self):
|
135
|
-
"""For `print` and `pprint`"""
|
136
|
-
return self.to_str()
|
137
|
-
|
138
|
-
def __eq__(self, other):
|
139
|
-
"""Returns true if both objects are equal"""
|
140
|
-
if not isinstance(other, BackupRestoreRequest):
|
141
|
-
return False
|
142
|
-
|
143
|
-
return self.to_dict() == other.to_dict()
|
144
|
-
|
145
|
-
def __ne__(self, other):
|
146
|
-
"""Returns true if both objects are not equal"""
|
147
|
-
if not isinstance(other, BackupRestoreRequest):
|
148
|
-
return True
|
149
|
-
|
150
|
-
return self.to_dict() != other.to_dict()
|