daytona_api_client 0.21.3a0__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.
Potentially problematic release.
This version of daytona_api_client might be problematic. Click here for more details.
- daytona_api_client/__init__.py +129 -0
- daytona_api_client/api/__init__.py +15 -0
- daytona_api_client/api/api_keys_api.py +1234 -0
- daytona_api_client/api/docker_registry_api.py +1741 -0
- daytona_api_client/api/object_storage_api.py +268 -0
- daytona_api_client/api/organizations_api.py +5792 -0
- daytona_api_client/api/preview_api.py +715 -0
- daytona_api_client/api/runners_api.py +664 -0
- daytona_api_client/api/sandbox_api.py +3584 -0
- daytona_api_client/api/snapshots_api.py +1830 -0
- daytona_api_client/api/toolbox_api.py +10545 -0
- daytona_api_client/api/users_api.py +1733 -0
- daytona_api_client/api/volumes_api.py +1267 -0
- daytona_api_client/api/workspace_api.py +3626 -0
- daytona_api_client/api_client.py +696 -0
- daytona_api_client/api_response.py +20 -0
- daytona_api_client/configuration.py +586 -0
- daytona_api_client/exceptions.py +216 -0
- daytona_api_client/models/__init__.py +101 -0
- daytona_api_client/models/account_provider.py +101 -0
- daytona_api_client/models/account_provider_dto.py +101 -0
- daytona_api_client/models/api_key_list.py +149 -0
- daytona_api_client/models/api_key_response.py +142 -0
- daytona_api_client/models/build_info.py +115 -0
- daytona_api_client/models/build_snapshot.py +118 -0
- daytona_api_client/models/command.py +104 -0
- daytona_api_client/models/completion_context.py +103 -0
- daytona_api_client/models/completion_item.py +124 -0
- daytona_api_client/models/completion_list.py +116 -0
- daytona_api_client/models/create_api_key.py +134 -0
- daytona_api_client/models/create_build_info.py +107 -0
- daytona_api_client/models/create_docker_registry.py +123 -0
- daytona_api_client/models/create_linked_account.py +101 -0
- daytona_api_client/models/create_organization.py +100 -0
- daytona_api_client/models/create_organization_invitation.py +122 -0
- daytona_api_client/models/create_organization_quota.py +130 -0
- daytona_api_client/models/create_organization_role.py +126 -0
- daytona_api_client/models/create_runner.py +150 -0
- daytona_api_client/models/create_sandbox.py +198 -0
- daytona_api_client/models/create_session_request.py +100 -0
- daytona_api_client/models/create_snapshot.py +138 -0
- daytona_api_client/models/create_user.py +132 -0
- daytona_api_client/models/create_volume.py +100 -0
- daytona_api_client/models/create_workspace.py +196 -0
- daytona_api_client/models/docker_registry.py +135 -0
- daytona_api_client/models/execute_request.py +104 -0
- daytona_api_client/models/execute_response.py +101 -0
- daytona_api_client/models/file_info.py +118 -0
- daytona_api_client/models/file_status.py +110 -0
- daytona_api_client/models/get_build_logs400_response.py +101 -0
- daytona_api_client/models/git_add_request.py +101 -0
- daytona_api_client/models/git_branch_request.py +101 -0
- daytona_api_client/models/git_checkout_request.py +101 -0
- daytona_api_client/models/git_clone_request.py +114 -0
- daytona_api_client/models/git_commit_info.py +112 -0
- daytona_api_client/models/git_commit_request.py +110 -0
- daytona_api_client/models/git_commit_response.py +100 -0
- daytona_api_client/models/git_delete_branch_request.py +101 -0
- daytona_api_client/models/git_repo_request.py +104 -0
- daytona_api_client/models/git_status.py +122 -0
- daytona_api_client/models/list_branch_response.py +100 -0
- daytona_api_client/models/lsp_completion_params.py +120 -0
- daytona_api_client/models/lsp_document_request.py +104 -0
- daytona_api_client/models/lsp_location.py +107 -0
- daytona_api_client/models/lsp_server_request.py +101 -0
- daytona_api_client/models/lsp_symbol.py +112 -0
- daytona_api_client/models/match.py +102 -0
- daytona_api_client/models/organization.py +134 -0
- daytona_api_client/models/organization_invitation.py +161 -0
- daytona_api_client/models/organization_role.py +147 -0
- daytona_api_client/models/organization_suspension.py +102 -0
- daytona_api_client/models/organization_user.py +145 -0
- daytona_api_client/models/paginated_snapshots_dto.py +120 -0
- daytona_api_client/models/port_preview_url.py +101 -0
- daytona_api_client/models/position.py +101 -0
- daytona_api_client/models/project_dir_response.py +100 -0
- daytona_api_client/models/range.py +113 -0
- daytona_api_client/models/registry_push_access_dto.py +114 -0
- daytona_api_client/models/replace_request.py +104 -0
- daytona_api_client/models/replace_result.py +102 -0
- daytona_api_client/models/sandbox.py +226 -0
- daytona_api_client/models/sandbox_info.py +110 -0
- daytona_api_client/models/sandbox_labels.py +100 -0
- daytona_api_client/models/sandbox_state.py +50 -0
- daytona_api_client/models/sandbox_volume.py +101 -0
- daytona_api_client/models/search_files_response.py +100 -0
- daytona_api_client/models/session.py +121 -0
- daytona_api_client/models/session_execute_request.py +110 -0
- daytona_api_client/models/session_execute_response.py +106 -0
- daytona_api_client/models/set_snapshot_general_status_dto.py +100 -0
- daytona_api_client/models/snapshot_dto.py +185 -0
- daytona_api_client/models/snapshot_state.py +44 -0
- daytona_api_client/models/storage_access_dto.py +121 -0
- daytona_api_client/models/toggle_state.py +100 -0
- daytona_api_client/models/update_assigned_organization_roles.py +100 -0
- daytona_api_client/models/update_docker_registry.py +104 -0
- daytona_api_client/models/update_organization_invitation.py +114 -0
- daytona_api_client/models/update_organization_member_role.py +107 -0
- daytona_api_client/models/update_organization_quota.py +175 -0
- daytona_api_client/models/update_organization_role.py +126 -0
- daytona_api_client/models/upload_file.py +101 -0
- daytona_api_client/models/upload_file_dto.py +101 -0
- daytona_api_client/models/upload_file_request_file.py +159 -0
- daytona_api_client/models/upload_files_multi_request_files_inner.py +101 -0
- daytona_api_client/models/usage_overview.py +124 -0
- daytona_api_client/models/user.py +120 -0
- daytona_api_client/models/user_public_key.py +101 -0
- daytona_api_client/models/volume.py +133 -0
- daytona_api_client/models/volume_dto.py +138 -0
- daytona_api_client/models/volume_state.py +41 -0
- daytona_api_client/models/workspace.py +259 -0
- daytona_api_client/py.typed +0 -0
- daytona_api_client/rest.py +208 -0
- daytona_api_client-0.21.3a0.dist-info/METADATA +23 -0
- daytona_api_client-0.21.3a0.dist-info/RECORD +117 -0
- daytona_api_client-0.21.3a0.dist-info/WHEEL +5 -0
- daytona_api_client-0.21.3a0.dist-info/top_level.txt +1 -0
|
@@ -0,0 +1,1741 @@
|
|
|
1
|
+
# coding: utf-8
|
|
2
|
+
|
|
3
|
+
"""
|
|
4
|
+
Daytona
|
|
5
|
+
|
|
6
|
+
Daytona AI platform API Docs
|
|
7
|
+
|
|
8
|
+
The version of the OpenAPI document: 1.0
|
|
9
|
+
Contact: support@daytona.com
|
|
10
|
+
Generated by OpenAPI Generator (https://openapi-generator.tech)
|
|
11
|
+
|
|
12
|
+
Do not edit the class manually.
|
|
13
|
+
""" # noqa: E501
|
|
14
|
+
|
|
15
|
+
import warnings
|
|
16
|
+
from pydantic import validate_call, Field, StrictFloat, StrictStr, StrictInt
|
|
17
|
+
from typing import Any, Dict, List, Optional, Tuple, Union
|
|
18
|
+
from typing_extensions import Annotated
|
|
19
|
+
|
|
20
|
+
from pydantic import Field, StrictStr
|
|
21
|
+
from typing import List, Optional
|
|
22
|
+
from typing_extensions import Annotated
|
|
23
|
+
from daytona_api_client.models.create_docker_registry import CreateDockerRegistry
|
|
24
|
+
from daytona_api_client.models.docker_registry import DockerRegistry
|
|
25
|
+
from daytona_api_client.models.registry_push_access_dto import RegistryPushAccessDto
|
|
26
|
+
from daytona_api_client.models.update_docker_registry import UpdateDockerRegistry
|
|
27
|
+
|
|
28
|
+
from daytona_api_client.api_client import ApiClient, RequestSerialized
|
|
29
|
+
from daytona_api_client.api_response import ApiResponse
|
|
30
|
+
from daytona_api_client.rest import RESTResponseType
|
|
31
|
+
|
|
32
|
+
|
|
33
|
+
class DockerRegistryApi:
|
|
34
|
+
"""NOTE: This class is auto generated by OpenAPI Generator
|
|
35
|
+
Ref: https://openapi-generator.tech
|
|
36
|
+
|
|
37
|
+
Do not edit the class manually.
|
|
38
|
+
"""
|
|
39
|
+
|
|
40
|
+
def __init__(self, api_client=None) -> None:
|
|
41
|
+
if api_client is None:
|
|
42
|
+
api_client = ApiClient.get_default()
|
|
43
|
+
self.api_client = api_client
|
|
44
|
+
|
|
45
|
+
@validate_call
|
|
46
|
+
def create_registry(
|
|
47
|
+
self,
|
|
48
|
+
create_docker_registry: CreateDockerRegistry,
|
|
49
|
+
x_daytona_organization_id: Annotated[
|
|
50
|
+
Optional[StrictStr], Field(description="Use with JWT to specify the organization ID")
|
|
51
|
+
] = None,
|
|
52
|
+
_request_timeout: Union[
|
|
53
|
+
None,
|
|
54
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
55
|
+
Tuple[Annotated[StrictFloat, Field(gt=0)], Annotated[StrictFloat, Field(gt=0)]],
|
|
56
|
+
] = None,
|
|
57
|
+
_request_auth: Optional[Dict[StrictStr, Any]] = None,
|
|
58
|
+
_content_type: Optional[StrictStr] = None,
|
|
59
|
+
_headers: Optional[Dict[StrictStr, Any]] = None,
|
|
60
|
+
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
|
|
61
|
+
) -> DockerRegistry:
|
|
62
|
+
"""Create registry
|
|
63
|
+
|
|
64
|
+
|
|
65
|
+
:param create_docker_registry: (required)
|
|
66
|
+
:type create_docker_registry: CreateDockerRegistry
|
|
67
|
+
:param x_daytona_organization_id: Use with JWT to specify the organization ID
|
|
68
|
+
:type x_daytona_organization_id: str
|
|
69
|
+
:param _request_timeout: timeout setting for this request. If one
|
|
70
|
+
number provided, it will be total request
|
|
71
|
+
timeout. It can also be a pair (tuple) of
|
|
72
|
+
(connection, read) timeouts.
|
|
73
|
+
:type _request_timeout: int, tuple(int, int), optional
|
|
74
|
+
:param _request_auth: set to override the auth_settings for an a single
|
|
75
|
+
request; this effectively ignores the
|
|
76
|
+
authentication in the spec for a single request.
|
|
77
|
+
:type _request_auth: dict, optional
|
|
78
|
+
:param _content_type: force content-type for the request.
|
|
79
|
+
:type _content_type: str, Optional
|
|
80
|
+
:param _headers: set to override the headers for a single
|
|
81
|
+
request; this effectively ignores the headers
|
|
82
|
+
in the spec for a single request.
|
|
83
|
+
:type _headers: dict, optional
|
|
84
|
+
:param _host_index: set to override the host_index for a single
|
|
85
|
+
request; this effectively ignores the host_index
|
|
86
|
+
in the spec for a single request.
|
|
87
|
+
:type _host_index: int, optional
|
|
88
|
+
:return: Returns the result object.
|
|
89
|
+
""" # noqa: E501
|
|
90
|
+
|
|
91
|
+
_param = self._create_registry_serialize(
|
|
92
|
+
create_docker_registry=create_docker_registry,
|
|
93
|
+
x_daytona_organization_id=x_daytona_organization_id,
|
|
94
|
+
_request_auth=_request_auth,
|
|
95
|
+
_content_type=_content_type,
|
|
96
|
+
_headers=_headers,
|
|
97
|
+
_host_index=_host_index,
|
|
98
|
+
)
|
|
99
|
+
|
|
100
|
+
_response_types_map: Dict[str, Optional[str]] = {
|
|
101
|
+
"201": "DockerRegistry",
|
|
102
|
+
}
|
|
103
|
+
response_data = self.api_client.call_api(*_param, _request_timeout=_request_timeout)
|
|
104
|
+
response_data.read()
|
|
105
|
+
return self.api_client.response_deserialize(
|
|
106
|
+
response_data=response_data,
|
|
107
|
+
response_types_map=_response_types_map,
|
|
108
|
+
).data
|
|
109
|
+
|
|
110
|
+
@validate_call
|
|
111
|
+
def create_registry_with_http_info(
|
|
112
|
+
self,
|
|
113
|
+
create_docker_registry: CreateDockerRegistry,
|
|
114
|
+
x_daytona_organization_id: Annotated[
|
|
115
|
+
Optional[StrictStr], Field(description="Use with JWT to specify the organization ID")
|
|
116
|
+
] = None,
|
|
117
|
+
_request_timeout: Union[
|
|
118
|
+
None,
|
|
119
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
120
|
+
Tuple[Annotated[StrictFloat, Field(gt=0)], Annotated[StrictFloat, Field(gt=0)]],
|
|
121
|
+
] = None,
|
|
122
|
+
_request_auth: Optional[Dict[StrictStr, Any]] = None,
|
|
123
|
+
_content_type: Optional[StrictStr] = None,
|
|
124
|
+
_headers: Optional[Dict[StrictStr, Any]] = None,
|
|
125
|
+
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
|
|
126
|
+
) -> ApiResponse[DockerRegistry]:
|
|
127
|
+
"""Create registry
|
|
128
|
+
|
|
129
|
+
|
|
130
|
+
:param create_docker_registry: (required)
|
|
131
|
+
:type create_docker_registry: CreateDockerRegistry
|
|
132
|
+
:param x_daytona_organization_id: Use with JWT to specify the organization ID
|
|
133
|
+
:type x_daytona_organization_id: str
|
|
134
|
+
:param _request_timeout: timeout setting for this request. If one
|
|
135
|
+
number provided, it will be total request
|
|
136
|
+
timeout. It can also be a pair (tuple) of
|
|
137
|
+
(connection, read) timeouts.
|
|
138
|
+
:type _request_timeout: int, tuple(int, int), optional
|
|
139
|
+
:param _request_auth: set to override the auth_settings for an a single
|
|
140
|
+
request; this effectively ignores the
|
|
141
|
+
authentication in the spec for a single request.
|
|
142
|
+
:type _request_auth: dict, optional
|
|
143
|
+
:param _content_type: force content-type for the request.
|
|
144
|
+
:type _content_type: str, Optional
|
|
145
|
+
:param _headers: set to override the headers for a single
|
|
146
|
+
request; this effectively ignores the headers
|
|
147
|
+
in the spec for a single request.
|
|
148
|
+
:type _headers: dict, optional
|
|
149
|
+
:param _host_index: set to override the host_index for a single
|
|
150
|
+
request; this effectively ignores the host_index
|
|
151
|
+
in the spec for a single request.
|
|
152
|
+
:type _host_index: int, optional
|
|
153
|
+
:return: Returns the result object.
|
|
154
|
+
""" # noqa: E501
|
|
155
|
+
|
|
156
|
+
_param = self._create_registry_serialize(
|
|
157
|
+
create_docker_registry=create_docker_registry,
|
|
158
|
+
x_daytona_organization_id=x_daytona_organization_id,
|
|
159
|
+
_request_auth=_request_auth,
|
|
160
|
+
_content_type=_content_type,
|
|
161
|
+
_headers=_headers,
|
|
162
|
+
_host_index=_host_index,
|
|
163
|
+
)
|
|
164
|
+
|
|
165
|
+
_response_types_map: Dict[str, Optional[str]] = {
|
|
166
|
+
"201": "DockerRegistry",
|
|
167
|
+
}
|
|
168
|
+
response_data = self.api_client.call_api(*_param, _request_timeout=_request_timeout)
|
|
169
|
+
response_data.read()
|
|
170
|
+
return self.api_client.response_deserialize(
|
|
171
|
+
response_data=response_data,
|
|
172
|
+
response_types_map=_response_types_map,
|
|
173
|
+
)
|
|
174
|
+
|
|
175
|
+
@validate_call
|
|
176
|
+
def create_registry_without_preload_content(
|
|
177
|
+
self,
|
|
178
|
+
create_docker_registry: CreateDockerRegistry,
|
|
179
|
+
x_daytona_organization_id: Annotated[
|
|
180
|
+
Optional[StrictStr], Field(description="Use with JWT to specify the organization ID")
|
|
181
|
+
] = None,
|
|
182
|
+
_request_timeout: Union[
|
|
183
|
+
None,
|
|
184
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
185
|
+
Tuple[Annotated[StrictFloat, Field(gt=0)], Annotated[StrictFloat, Field(gt=0)]],
|
|
186
|
+
] = None,
|
|
187
|
+
_request_auth: Optional[Dict[StrictStr, Any]] = None,
|
|
188
|
+
_content_type: Optional[StrictStr] = None,
|
|
189
|
+
_headers: Optional[Dict[StrictStr, Any]] = None,
|
|
190
|
+
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
|
|
191
|
+
) -> RESTResponseType:
|
|
192
|
+
"""Create registry
|
|
193
|
+
|
|
194
|
+
|
|
195
|
+
:param create_docker_registry: (required)
|
|
196
|
+
:type create_docker_registry: CreateDockerRegistry
|
|
197
|
+
:param x_daytona_organization_id: Use with JWT to specify the organization ID
|
|
198
|
+
:type x_daytona_organization_id: str
|
|
199
|
+
:param _request_timeout: timeout setting for this request. If one
|
|
200
|
+
number provided, it will be total request
|
|
201
|
+
timeout. It can also be a pair (tuple) of
|
|
202
|
+
(connection, read) timeouts.
|
|
203
|
+
:type _request_timeout: int, tuple(int, int), optional
|
|
204
|
+
:param _request_auth: set to override the auth_settings for an a single
|
|
205
|
+
request; this effectively ignores the
|
|
206
|
+
authentication in the spec for a single request.
|
|
207
|
+
:type _request_auth: dict, optional
|
|
208
|
+
:param _content_type: force content-type for the request.
|
|
209
|
+
:type _content_type: str, Optional
|
|
210
|
+
:param _headers: set to override the headers for a single
|
|
211
|
+
request; this effectively ignores the headers
|
|
212
|
+
in the spec for a single request.
|
|
213
|
+
:type _headers: dict, optional
|
|
214
|
+
:param _host_index: set to override the host_index for a single
|
|
215
|
+
request; this effectively ignores the host_index
|
|
216
|
+
in the spec for a single request.
|
|
217
|
+
:type _host_index: int, optional
|
|
218
|
+
:return: Returns the result object.
|
|
219
|
+
""" # noqa: E501
|
|
220
|
+
|
|
221
|
+
_param = self._create_registry_serialize(
|
|
222
|
+
create_docker_registry=create_docker_registry,
|
|
223
|
+
x_daytona_organization_id=x_daytona_organization_id,
|
|
224
|
+
_request_auth=_request_auth,
|
|
225
|
+
_content_type=_content_type,
|
|
226
|
+
_headers=_headers,
|
|
227
|
+
_host_index=_host_index,
|
|
228
|
+
)
|
|
229
|
+
|
|
230
|
+
_response_types_map: Dict[str, Optional[str]] = {
|
|
231
|
+
"201": "DockerRegistry",
|
|
232
|
+
}
|
|
233
|
+
response_data = self.api_client.call_api(*_param, _request_timeout=_request_timeout)
|
|
234
|
+
return response_data.response
|
|
235
|
+
|
|
236
|
+
def _create_registry_serialize(
|
|
237
|
+
self,
|
|
238
|
+
create_docker_registry,
|
|
239
|
+
x_daytona_organization_id,
|
|
240
|
+
_request_auth,
|
|
241
|
+
_content_type,
|
|
242
|
+
_headers,
|
|
243
|
+
_host_index,
|
|
244
|
+
) -> RequestSerialized:
|
|
245
|
+
_host = None
|
|
246
|
+
|
|
247
|
+
_collection_formats: Dict[str, str] = {}
|
|
248
|
+
|
|
249
|
+
_path_params: Dict[str, str] = {}
|
|
250
|
+
_query_params: List[Tuple[str, str]] = []
|
|
251
|
+
_header_params: Dict[str, Optional[str]] = _headers or {}
|
|
252
|
+
_form_params: List[Tuple[str, str]] = []
|
|
253
|
+
_files: Dict[str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]] = {}
|
|
254
|
+
_body_params: Optional[bytes] = None
|
|
255
|
+
|
|
256
|
+
# process the path parameters
|
|
257
|
+
# process the query parameters
|
|
258
|
+
# process the header parameters
|
|
259
|
+
if x_daytona_organization_id is not None:
|
|
260
|
+
_header_params["X-Daytona-Organization-ID"] = x_daytona_organization_id
|
|
261
|
+
# process the form parameters
|
|
262
|
+
# process the body parameter
|
|
263
|
+
if create_docker_registry is not None:
|
|
264
|
+
_body_params = create_docker_registry
|
|
265
|
+
|
|
266
|
+
# set the HTTP header `Accept`
|
|
267
|
+
if "Accept" not in _header_params:
|
|
268
|
+
_header_params["Accept"] = self.api_client.select_header_accept(["application/json"])
|
|
269
|
+
|
|
270
|
+
# set the HTTP header `Content-Type`
|
|
271
|
+
if _content_type:
|
|
272
|
+
_header_params["Content-Type"] = _content_type
|
|
273
|
+
else:
|
|
274
|
+
_default_content_type = self.api_client.select_header_content_type(["application/json"])
|
|
275
|
+
if _default_content_type is not None:
|
|
276
|
+
_header_params["Content-Type"] = _default_content_type
|
|
277
|
+
|
|
278
|
+
# authentication setting
|
|
279
|
+
_auth_settings: List[str] = ["bearer", "oauth2"]
|
|
280
|
+
|
|
281
|
+
return self.api_client.param_serialize(
|
|
282
|
+
method="POST",
|
|
283
|
+
resource_path="/docker-registry",
|
|
284
|
+
path_params=_path_params,
|
|
285
|
+
query_params=_query_params,
|
|
286
|
+
header_params=_header_params,
|
|
287
|
+
body=_body_params,
|
|
288
|
+
post_params=_form_params,
|
|
289
|
+
files=_files,
|
|
290
|
+
auth_settings=_auth_settings,
|
|
291
|
+
collection_formats=_collection_formats,
|
|
292
|
+
_host=_host,
|
|
293
|
+
_request_auth=_request_auth,
|
|
294
|
+
)
|
|
295
|
+
|
|
296
|
+
@validate_call
|
|
297
|
+
def delete_registry(
|
|
298
|
+
self,
|
|
299
|
+
id: Annotated[StrictStr, Field(description="ID of the docker registry")],
|
|
300
|
+
x_daytona_organization_id: Annotated[
|
|
301
|
+
Optional[StrictStr], Field(description="Use with JWT to specify the organization ID")
|
|
302
|
+
] = None,
|
|
303
|
+
_request_timeout: Union[
|
|
304
|
+
None,
|
|
305
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
306
|
+
Tuple[Annotated[StrictFloat, Field(gt=0)], Annotated[StrictFloat, Field(gt=0)]],
|
|
307
|
+
] = None,
|
|
308
|
+
_request_auth: Optional[Dict[StrictStr, Any]] = None,
|
|
309
|
+
_content_type: Optional[StrictStr] = None,
|
|
310
|
+
_headers: Optional[Dict[StrictStr, Any]] = None,
|
|
311
|
+
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
|
|
312
|
+
) -> None:
|
|
313
|
+
"""Delete registry
|
|
314
|
+
|
|
315
|
+
|
|
316
|
+
:param id: ID of the docker registry (required)
|
|
317
|
+
:type id: str
|
|
318
|
+
:param x_daytona_organization_id: Use with JWT to specify the organization ID
|
|
319
|
+
:type x_daytona_organization_id: str
|
|
320
|
+
:param _request_timeout: timeout setting for this request. If one
|
|
321
|
+
number provided, it will be total request
|
|
322
|
+
timeout. It can also be a pair (tuple) of
|
|
323
|
+
(connection, read) timeouts.
|
|
324
|
+
:type _request_timeout: int, tuple(int, int), optional
|
|
325
|
+
:param _request_auth: set to override the auth_settings for an a single
|
|
326
|
+
request; this effectively ignores the
|
|
327
|
+
authentication in the spec for a single request.
|
|
328
|
+
:type _request_auth: dict, optional
|
|
329
|
+
:param _content_type: force content-type for the request.
|
|
330
|
+
:type _content_type: str, Optional
|
|
331
|
+
:param _headers: set to override the headers for a single
|
|
332
|
+
request; this effectively ignores the headers
|
|
333
|
+
in the spec for a single request.
|
|
334
|
+
:type _headers: dict, optional
|
|
335
|
+
:param _host_index: set to override the host_index for a single
|
|
336
|
+
request; this effectively ignores the host_index
|
|
337
|
+
in the spec for a single request.
|
|
338
|
+
:type _host_index: int, optional
|
|
339
|
+
:return: Returns the result object.
|
|
340
|
+
""" # noqa: E501
|
|
341
|
+
|
|
342
|
+
_param = self._delete_registry_serialize(
|
|
343
|
+
id=id,
|
|
344
|
+
x_daytona_organization_id=x_daytona_organization_id,
|
|
345
|
+
_request_auth=_request_auth,
|
|
346
|
+
_content_type=_content_type,
|
|
347
|
+
_headers=_headers,
|
|
348
|
+
_host_index=_host_index,
|
|
349
|
+
)
|
|
350
|
+
|
|
351
|
+
_response_types_map: Dict[str, Optional[str]] = {
|
|
352
|
+
"204": None,
|
|
353
|
+
}
|
|
354
|
+
response_data = self.api_client.call_api(*_param, _request_timeout=_request_timeout)
|
|
355
|
+
response_data.read()
|
|
356
|
+
return self.api_client.response_deserialize(
|
|
357
|
+
response_data=response_data,
|
|
358
|
+
response_types_map=_response_types_map,
|
|
359
|
+
).data
|
|
360
|
+
|
|
361
|
+
@validate_call
|
|
362
|
+
def delete_registry_with_http_info(
|
|
363
|
+
self,
|
|
364
|
+
id: Annotated[StrictStr, Field(description="ID of the docker registry")],
|
|
365
|
+
x_daytona_organization_id: Annotated[
|
|
366
|
+
Optional[StrictStr], Field(description="Use with JWT to specify the organization ID")
|
|
367
|
+
] = None,
|
|
368
|
+
_request_timeout: Union[
|
|
369
|
+
None,
|
|
370
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
371
|
+
Tuple[Annotated[StrictFloat, Field(gt=0)], Annotated[StrictFloat, Field(gt=0)]],
|
|
372
|
+
] = None,
|
|
373
|
+
_request_auth: Optional[Dict[StrictStr, Any]] = None,
|
|
374
|
+
_content_type: Optional[StrictStr] = None,
|
|
375
|
+
_headers: Optional[Dict[StrictStr, Any]] = None,
|
|
376
|
+
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
|
|
377
|
+
) -> ApiResponse[None]:
|
|
378
|
+
"""Delete registry
|
|
379
|
+
|
|
380
|
+
|
|
381
|
+
:param id: ID of the docker registry (required)
|
|
382
|
+
:type id: str
|
|
383
|
+
:param x_daytona_organization_id: Use with JWT to specify the organization ID
|
|
384
|
+
:type x_daytona_organization_id: str
|
|
385
|
+
:param _request_timeout: timeout setting for this request. If one
|
|
386
|
+
number provided, it will be total request
|
|
387
|
+
timeout. It can also be a pair (tuple) of
|
|
388
|
+
(connection, read) timeouts.
|
|
389
|
+
:type _request_timeout: int, tuple(int, int), optional
|
|
390
|
+
:param _request_auth: set to override the auth_settings for an a single
|
|
391
|
+
request; this effectively ignores the
|
|
392
|
+
authentication in the spec for a single request.
|
|
393
|
+
:type _request_auth: dict, optional
|
|
394
|
+
:param _content_type: force content-type for the request.
|
|
395
|
+
:type _content_type: str, Optional
|
|
396
|
+
:param _headers: set to override the headers for a single
|
|
397
|
+
request; this effectively ignores the headers
|
|
398
|
+
in the spec for a single request.
|
|
399
|
+
:type _headers: dict, optional
|
|
400
|
+
:param _host_index: set to override the host_index for a single
|
|
401
|
+
request; this effectively ignores the host_index
|
|
402
|
+
in the spec for a single request.
|
|
403
|
+
:type _host_index: int, optional
|
|
404
|
+
:return: Returns the result object.
|
|
405
|
+
""" # noqa: E501
|
|
406
|
+
|
|
407
|
+
_param = self._delete_registry_serialize(
|
|
408
|
+
id=id,
|
|
409
|
+
x_daytona_organization_id=x_daytona_organization_id,
|
|
410
|
+
_request_auth=_request_auth,
|
|
411
|
+
_content_type=_content_type,
|
|
412
|
+
_headers=_headers,
|
|
413
|
+
_host_index=_host_index,
|
|
414
|
+
)
|
|
415
|
+
|
|
416
|
+
_response_types_map: Dict[str, Optional[str]] = {
|
|
417
|
+
"204": None,
|
|
418
|
+
}
|
|
419
|
+
response_data = self.api_client.call_api(*_param, _request_timeout=_request_timeout)
|
|
420
|
+
response_data.read()
|
|
421
|
+
return self.api_client.response_deserialize(
|
|
422
|
+
response_data=response_data,
|
|
423
|
+
response_types_map=_response_types_map,
|
|
424
|
+
)
|
|
425
|
+
|
|
426
|
+
@validate_call
|
|
427
|
+
def delete_registry_without_preload_content(
|
|
428
|
+
self,
|
|
429
|
+
id: Annotated[StrictStr, Field(description="ID of the docker registry")],
|
|
430
|
+
x_daytona_organization_id: Annotated[
|
|
431
|
+
Optional[StrictStr], Field(description="Use with JWT to specify the organization ID")
|
|
432
|
+
] = None,
|
|
433
|
+
_request_timeout: Union[
|
|
434
|
+
None,
|
|
435
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
436
|
+
Tuple[Annotated[StrictFloat, Field(gt=0)], Annotated[StrictFloat, Field(gt=0)]],
|
|
437
|
+
] = None,
|
|
438
|
+
_request_auth: Optional[Dict[StrictStr, Any]] = None,
|
|
439
|
+
_content_type: Optional[StrictStr] = None,
|
|
440
|
+
_headers: Optional[Dict[StrictStr, Any]] = None,
|
|
441
|
+
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
|
|
442
|
+
) -> RESTResponseType:
|
|
443
|
+
"""Delete registry
|
|
444
|
+
|
|
445
|
+
|
|
446
|
+
:param id: ID of the docker registry (required)
|
|
447
|
+
:type id: str
|
|
448
|
+
:param x_daytona_organization_id: Use with JWT to specify the organization ID
|
|
449
|
+
:type x_daytona_organization_id: str
|
|
450
|
+
:param _request_timeout: timeout setting for this request. If one
|
|
451
|
+
number provided, it will be total request
|
|
452
|
+
timeout. It can also be a pair (tuple) of
|
|
453
|
+
(connection, read) timeouts.
|
|
454
|
+
:type _request_timeout: int, tuple(int, int), optional
|
|
455
|
+
:param _request_auth: set to override the auth_settings for an a single
|
|
456
|
+
request; this effectively ignores the
|
|
457
|
+
authentication in the spec for a single request.
|
|
458
|
+
:type _request_auth: dict, optional
|
|
459
|
+
:param _content_type: force content-type for the request.
|
|
460
|
+
:type _content_type: str, Optional
|
|
461
|
+
:param _headers: set to override the headers for a single
|
|
462
|
+
request; this effectively ignores the headers
|
|
463
|
+
in the spec for a single request.
|
|
464
|
+
:type _headers: dict, optional
|
|
465
|
+
:param _host_index: set to override the host_index for a single
|
|
466
|
+
request; this effectively ignores the host_index
|
|
467
|
+
in the spec for a single request.
|
|
468
|
+
:type _host_index: int, optional
|
|
469
|
+
:return: Returns the result object.
|
|
470
|
+
""" # noqa: E501
|
|
471
|
+
|
|
472
|
+
_param = self._delete_registry_serialize(
|
|
473
|
+
id=id,
|
|
474
|
+
x_daytona_organization_id=x_daytona_organization_id,
|
|
475
|
+
_request_auth=_request_auth,
|
|
476
|
+
_content_type=_content_type,
|
|
477
|
+
_headers=_headers,
|
|
478
|
+
_host_index=_host_index,
|
|
479
|
+
)
|
|
480
|
+
|
|
481
|
+
_response_types_map: Dict[str, Optional[str]] = {
|
|
482
|
+
"204": None,
|
|
483
|
+
}
|
|
484
|
+
response_data = self.api_client.call_api(*_param, _request_timeout=_request_timeout)
|
|
485
|
+
return response_data.response
|
|
486
|
+
|
|
487
|
+
def _delete_registry_serialize(
|
|
488
|
+
self,
|
|
489
|
+
id,
|
|
490
|
+
x_daytona_organization_id,
|
|
491
|
+
_request_auth,
|
|
492
|
+
_content_type,
|
|
493
|
+
_headers,
|
|
494
|
+
_host_index,
|
|
495
|
+
) -> RequestSerialized:
|
|
496
|
+
_host = None
|
|
497
|
+
|
|
498
|
+
_collection_formats: Dict[str, str] = {}
|
|
499
|
+
|
|
500
|
+
_path_params: Dict[str, str] = {}
|
|
501
|
+
_query_params: List[Tuple[str, str]] = []
|
|
502
|
+
_header_params: Dict[str, Optional[str]] = _headers or {}
|
|
503
|
+
_form_params: List[Tuple[str, str]] = []
|
|
504
|
+
_files: Dict[str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]] = {}
|
|
505
|
+
_body_params: Optional[bytes] = None
|
|
506
|
+
|
|
507
|
+
# process the path parameters
|
|
508
|
+
if id is not None:
|
|
509
|
+
_path_params["id"] = id
|
|
510
|
+
# process the query parameters
|
|
511
|
+
# process the header parameters
|
|
512
|
+
if x_daytona_organization_id is not None:
|
|
513
|
+
_header_params["X-Daytona-Organization-ID"] = x_daytona_organization_id
|
|
514
|
+
# process the form parameters
|
|
515
|
+
# process the body parameter
|
|
516
|
+
|
|
517
|
+
# authentication setting
|
|
518
|
+
_auth_settings: List[str] = ["bearer", "oauth2"]
|
|
519
|
+
|
|
520
|
+
return self.api_client.param_serialize(
|
|
521
|
+
method="DELETE",
|
|
522
|
+
resource_path="/docker-registry/{id}",
|
|
523
|
+
path_params=_path_params,
|
|
524
|
+
query_params=_query_params,
|
|
525
|
+
header_params=_header_params,
|
|
526
|
+
body=_body_params,
|
|
527
|
+
post_params=_form_params,
|
|
528
|
+
files=_files,
|
|
529
|
+
auth_settings=_auth_settings,
|
|
530
|
+
collection_formats=_collection_formats,
|
|
531
|
+
_host=_host,
|
|
532
|
+
_request_auth=_request_auth,
|
|
533
|
+
)
|
|
534
|
+
|
|
535
|
+
@validate_call
|
|
536
|
+
def get_registry(
|
|
537
|
+
self,
|
|
538
|
+
id: Annotated[StrictStr, Field(description="ID of the docker registry")],
|
|
539
|
+
x_daytona_organization_id: Annotated[
|
|
540
|
+
Optional[StrictStr], Field(description="Use with JWT to specify the organization ID")
|
|
541
|
+
] = None,
|
|
542
|
+
_request_timeout: Union[
|
|
543
|
+
None,
|
|
544
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
545
|
+
Tuple[Annotated[StrictFloat, Field(gt=0)], Annotated[StrictFloat, Field(gt=0)]],
|
|
546
|
+
] = None,
|
|
547
|
+
_request_auth: Optional[Dict[StrictStr, Any]] = None,
|
|
548
|
+
_content_type: Optional[StrictStr] = None,
|
|
549
|
+
_headers: Optional[Dict[StrictStr, Any]] = None,
|
|
550
|
+
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
|
|
551
|
+
) -> DockerRegistry:
|
|
552
|
+
"""Get registry
|
|
553
|
+
|
|
554
|
+
|
|
555
|
+
:param id: ID of the docker registry (required)
|
|
556
|
+
:type id: str
|
|
557
|
+
:param x_daytona_organization_id: Use with JWT to specify the organization ID
|
|
558
|
+
:type x_daytona_organization_id: str
|
|
559
|
+
:param _request_timeout: timeout setting for this request. If one
|
|
560
|
+
number provided, it will be total request
|
|
561
|
+
timeout. It can also be a pair (tuple) of
|
|
562
|
+
(connection, read) timeouts.
|
|
563
|
+
:type _request_timeout: int, tuple(int, int), optional
|
|
564
|
+
:param _request_auth: set to override the auth_settings for an a single
|
|
565
|
+
request; this effectively ignores the
|
|
566
|
+
authentication in the spec for a single request.
|
|
567
|
+
:type _request_auth: dict, optional
|
|
568
|
+
:param _content_type: force content-type for the request.
|
|
569
|
+
:type _content_type: str, Optional
|
|
570
|
+
:param _headers: set to override the headers for a single
|
|
571
|
+
request; this effectively ignores the headers
|
|
572
|
+
in the spec for a single request.
|
|
573
|
+
:type _headers: dict, optional
|
|
574
|
+
:param _host_index: set to override the host_index for a single
|
|
575
|
+
request; this effectively ignores the host_index
|
|
576
|
+
in the spec for a single request.
|
|
577
|
+
:type _host_index: int, optional
|
|
578
|
+
:return: Returns the result object.
|
|
579
|
+
""" # noqa: E501
|
|
580
|
+
|
|
581
|
+
_param = self._get_registry_serialize(
|
|
582
|
+
id=id,
|
|
583
|
+
x_daytona_organization_id=x_daytona_organization_id,
|
|
584
|
+
_request_auth=_request_auth,
|
|
585
|
+
_content_type=_content_type,
|
|
586
|
+
_headers=_headers,
|
|
587
|
+
_host_index=_host_index,
|
|
588
|
+
)
|
|
589
|
+
|
|
590
|
+
_response_types_map: Dict[str, Optional[str]] = {
|
|
591
|
+
"200": "DockerRegistry",
|
|
592
|
+
}
|
|
593
|
+
response_data = self.api_client.call_api(*_param, _request_timeout=_request_timeout)
|
|
594
|
+
response_data.read()
|
|
595
|
+
return self.api_client.response_deserialize(
|
|
596
|
+
response_data=response_data,
|
|
597
|
+
response_types_map=_response_types_map,
|
|
598
|
+
).data
|
|
599
|
+
|
|
600
|
+
@validate_call
|
|
601
|
+
def get_registry_with_http_info(
|
|
602
|
+
self,
|
|
603
|
+
id: Annotated[StrictStr, Field(description="ID of the docker registry")],
|
|
604
|
+
x_daytona_organization_id: Annotated[
|
|
605
|
+
Optional[StrictStr], Field(description="Use with JWT to specify the organization ID")
|
|
606
|
+
] = None,
|
|
607
|
+
_request_timeout: Union[
|
|
608
|
+
None,
|
|
609
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
610
|
+
Tuple[Annotated[StrictFloat, Field(gt=0)], Annotated[StrictFloat, Field(gt=0)]],
|
|
611
|
+
] = None,
|
|
612
|
+
_request_auth: Optional[Dict[StrictStr, Any]] = None,
|
|
613
|
+
_content_type: Optional[StrictStr] = None,
|
|
614
|
+
_headers: Optional[Dict[StrictStr, Any]] = None,
|
|
615
|
+
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
|
|
616
|
+
) -> ApiResponse[DockerRegistry]:
|
|
617
|
+
"""Get registry
|
|
618
|
+
|
|
619
|
+
|
|
620
|
+
:param id: ID of the docker registry (required)
|
|
621
|
+
:type id: str
|
|
622
|
+
:param x_daytona_organization_id: Use with JWT to specify the organization ID
|
|
623
|
+
:type x_daytona_organization_id: str
|
|
624
|
+
:param _request_timeout: timeout setting for this request. If one
|
|
625
|
+
number provided, it will be total request
|
|
626
|
+
timeout. It can also be a pair (tuple) of
|
|
627
|
+
(connection, read) timeouts.
|
|
628
|
+
:type _request_timeout: int, tuple(int, int), optional
|
|
629
|
+
:param _request_auth: set to override the auth_settings for an a single
|
|
630
|
+
request; this effectively ignores the
|
|
631
|
+
authentication in the spec for a single request.
|
|
632
|
+
:type _request_auth: dict, optional
|
|
633
|
+
:param _content_type: force content-type for the request.
|
|
634
|
+
:type _content_type: str, Optional
|
|
635
|
+
:param _headers: set to override the headers for a single
|
|
636
|
+
request; this effectively ignores the headers
|
|
637
|
+
in the spec for a single request.
|
|
638
|
+
:type _headers: dict, optional
|
|
639
|
+
:param _host_index: set to override the host_index for a single
|
|
640
|
+
request; this effectively ignores the host_index
|
|
641
|
+
in the spec for a single request.
|
|
642
|
+
:type _host_index: int, optional
|
|
643
|
+
:return: Returns the result object.
|
|
644
|
+
""" # noqa: E501
|
|
645
|
+
|
|
646
|
+
_param = self._get_registry_serialize(
|
|
647
|
+
id=id,
|
|
648
|
+
x_daytona_organization_id=x_daytona_organization_id,
|
|
649
|
+
_request_auth=_request_auth,
|
|
650
|
+
_content_type=_content_type,
|
|
651
|
+
_headers=_headers,
|
|
652
|
+
_host_index=_host_index,
|
|
653
|
+
)
|
|
654
|
+
|
|
655
|
+
_response_types_map: Dict[str, Optional[str]] = {
|
|
656
|
+
"200": "DockerRegistry",
|
|
657
|
+
}
|
|
658
|
+
response_data = self.api_client.call_api(*_param, _request_timeout=_request_timeout)
|
|
659
|
+
response_data.read()
|
|
660
|
+
return self.api_client.response_deserialize(
|
|
661
|
+
response_data=response_data,
|
|
662
|
+
response_types_map=_response_types_map,
|
|
663
|
+
)
|
|
664
|
+
|
|
665
|
+
@validate_call
|
|
666
|
+
def get_registry_without_preload_content(
|
|
667
|
+
self,
|
|
668
|
+
id: Annotated[StrictStr, Field(description="ID of the docker registry")],
|
|
669
|
+
x_daytona_organization_id: Annotated[
|
|
670
|
+
Optional[StrictStr], Field(description="Use with JWT to specify the organization ID")
|
|
671
|
+
] = None,
|
|
672
|
+
_request_timeout: Union[
|
|
673
|
+
None,
|
|
674
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
675
|
+
Tuple[Annotated[StrictFloat, Field(gt=0)], Annotated[StrictFloat, Field(gt=0)]],
|
|
676
|
+
] = None,
|
|
677
|
+
_request_auth: Optional[Dict[StrictStr, Any]] = None,
|
|
678
|
+
_content_type: Optional[StrictStr] = None,
|
|
679
|
+
_headers: Optional[Dict[StrictStr, Any]] = None,
|
|
680
|
+
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
|
|
681
|
+
) -> RESTResponseType:
|
|
682
|
+
"""Get registry
|
|
683
|
+
|
|
684
|
+
|
|
685
|
+
:param id: ID of the docker registry (required)
|
|
686
|
+
:type id: str
|
|
687
|
+
:param x_daytona_organization_id: Use with JWT to specify the organization ID
|
|
688
|
+
:type x_daytona_organization_id: str
|
|
689
|
+
:param _request_timeout: timeout setting for this request. If one
|
|
690
|
+
number provided, it will be total request
|
|
691
|
+
timeout. It can also be a pair (tuple) of
|
|
692
|
+
(connection, read) timeouts.
|
|
693
|
+
:type _request_timeout: int, tuple(int, int), optional
|
|
694
|
+
:param _request_auth: set to override the auth_settings for an a single
|
|
695
|
+
request; this effectively ignores the
|
|
696
|
+
authentication in the spec for a single request.
|
|
697
|
+
:type _request_auth: dict, optional
|
|
698
|
+
:param _content_type: force content-type for the request.
|
|
699
|
+
:type _content_type: str, Optional
|
|
700
|
+
:param _headers: set to override the headers for a single
|
|
701
|
+
request; this effectively ignores the headers
|
|
702
|
+
in the spec for a single request.
|
|
703
|
+
:type _headers: dict, optional
|
|
704
|
+
:param _host_index: set to override the host_index for a single
|
|
705
|
+
request; this effectively ignores the host_index
|
|
706
|
+
in the spec for a single request.
|
|
707
|
+
:type _host_index: int, optional
|
|
708
|
+
:return: Returns the result object.
|
|
709
|
+
""" # noqa: E501
|
|
710
|
+
|
|
711
|
+
_param = self._get_registry_serialize(
|
|
712
|
+
id=id,
|
|
713
|
+
x_daytona_organization_id=x_daytona_organization_id,
|
|
714
|
+
_request_auth=_request_auth,
|
|
715
|
+
_content_type=_content_type,
|
|
716
|
+
_headers=_headers,
|
|
717
|
+
_host_index=_host_index,
|
|
718
|
+
)
|
|
719
|
+
|
|
720
|
+
_response_types_map: Dict[str, Optional[str]] = {
|
|
721
|
+
"200": "DockerRegistry",
|
|
722
|
+
}
|
|
723
|
+
response_data = self.api_client.call_api(*_param, _request_timeout=_request_timeout)
|
|
724
|
+
return response_data.response
|
|
725
|
+
|
|
726
|
+
def _get_registry_serialize(
|
|
727
|
+
self,
|
|
728
|
+
id,
|
|
729
|
+
x_daytona_organization_id,
|
|
730
|
+
_request_auth,
|
|
731
|
+
_content_type,
|
|
732
|
+
_headers,
|
|
733
|
+
_host_index,
|
|
734
|
+
) -> RequestSerialized:
|
|
735
|
+
_host = None
|
|
736
|
+
|
|
737
|
+
_collection_formats: Dict[str, str] = {}
|
|
738
|
+
|
|
739
|
+
_path_params: Dict[str, str] = {}
|
|
740
|
+
_query_params: List[Tuple[str, str]] = []
|
|
741
|
+
_header_params: Dict[str, Optional[str]] = _headers or {}
|
|
742
|
+
_form_params: List[Tuple[str, str]] = []
|
|
743
|
+
_files: Dict[str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]] = {}
|
|
744
|
+
_body_params: Optional[bytes] = None
|
|
745
|
+
|
|
746
|
+
# process the path parameters
|
|
747
|
+
if id is not None:
|
|
748
|
+
_path_params["id"] = id
|
|
749
|
+
# process the query parameters
|
|
750
|
+
# process the header parameters
|
|
751
|
+
if x_daytona_organization_id is not None:
|
|
752
|
+
_header_params["X-Daytona-Organization-ID"] = x_daytona_organization_id
|
|
753
|
+
# process the form parameters
|
|
754
|
+
# process the body parameter
|
|
755
|
+
|
|
756
|
+
# set the HTTP header `Accept`
|
|
757
|
+
if "Accept" not in _header_params:
|
|
758
|
+
_header_params["Accept"] = self.api_client.select_header_accept(["application/json"])
|
|
759
|
+
|
|
760
|
+
# authentication setting
|
|
761
|
+
_auth_settings: List[str] = ["bearer", "oauth2"]
|
|
762
|
+
|
|
763
|
+
return self.api_client.param_serialize(
|
|
764
|
+
method="GET",
|
|
765
|
+
resource_path="/docker-registry/{id}",
|
|
766
|
+
path_params=_path_params,
|
|
767
|
+
query_params=_query_params,
|
|
768
|
+
header_params=_header_params,
|
|
769
|
+
body=_body_params,
|
|
770
|
+
post_params=_form_params,
|
|
771
|
+
files=_files,
|
|
772
|
+
auth_settings=_auth_settings,
|
|
773
|
+
collection_formats=_collection_formats,
|
|
774
|
+
_host=_host,
|
|
775
|
+
_request_auth=_request_auth,
|
|
776
|
+
)
|
|
777
|
+
|
|
778
|
+
@validate_call
|
|
779
|
+
def get_transient_push_access(
|
|
780
|
+
self,
|
|
781
|
+
x_daytona_organization_id: Annotated[
|
|
782
|
+
Optional[StrictStr], Field(description="Use with JWT to specify the organization ID")
|
|
783
|
+
] = None,
|
|
784
|
+
_request_timeout: Union[
|
|
785
|
+
None,
|
|
786
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
787
|
+
Tuple[Annotated[StrictFloat, Field(gt=0)], Annotated[StrictFloat, Field(gt=0)]],
|
|
788
|
+
] = None,
|
|
789
|
+
_request_auth: Optional[Dict[StrictStr, Any]] = None,
|
|
790
|
+
_content_type: Optional[StrictStr] = None,
|
|
791
|
+
_headers: Optional[Dict[StrictStr, Any]] = None,
|
|
792
|
+
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
|
|
793
|
+
) -> RegistryPushAccessDto:
|
|
794
|
+
"""Get temporary registry access for pushing snapshots
|
|
795
|
+
|
|
796
|
+
|
|
797
|
+
:param x_daytona_organization_id: Use with JWT to specify the organization ID
|
|
798
|
+
:type x_daytona_organization_id: str
|
|
799
|
+
:param _request_timeout: timeout setting for this request. If one
|
|
800
|
+
number provided, it will be total request
|
|
801
|
+
timeout. It can also be a pair (tuple) of
|
|
802
|
+
(connection, read) timeouts.
|
|
803
|
+
:type _request_timeout: int, tuple(int, int), optional
|
|
804
|
+
:param _request_auth: set to override the auth_settings for an a single
|
|
805
|
+
request; this effectively ignores the
|
|
806
|
+
authentication in the spec for a single request.
|
|
807
|
+
:type _request_auth: dict, optional
|
|
808
|
+
:param _content_type: force content-type for the request.
|
|
809
|
+
:type _content_type: str, Optional
|
|
810
|
+
:param _headers: set to override the headers for a single
|
|
811
|
+
request; this effectively ignores the headers
|
|
812
|
+
in the spec for a single request.
|
|
813
|
+
:type _headers: dict, optional
|
|
814
|
+
:param _host_index: set to override the host_index for a single
|
|
815
|
+
request; this effectively ignores the host_index
|
|
816
|
+
in the spec for a single request.
|
|
817
|
+
:type _host_index: int, optional
|
|
818
|
+
:return: Returns the result object.
|
|
819
|
+
""" # noqa: E501
|
|
820
|
+
|
|
821
|
+
_param = self._get_transient_push_access_serialize(
|
|
822
|
+
x_daytona_organization_id=x_daytona_organization_id,
|
|
823
|
+
_request_auth=_request_auth,
|
|
824
|
+
_content_type=_content_type,
|
|
825
|
+
_headers=_headers,
|
|
826
|
+
_host_index=_host_index,
|
|
827
|
+
)
|
|
828
|
+
|
|
829
|
+
_response_types_map: Dict[str, Optional[str]] = {
|
|
830
|
+
"200": "RegistryPushAccessDto",
|
|
831
|
+
}
|
|
832
|
+
response_data = self.api_client.call_api(*_param, _request_timeout=_request_timeout)
|
|
833
|
+
response_data.read()
|
|
834
|
+
return self.api_client.response_deserialize(
|
|
835
|
+
response_data=response_data,
|
|
836
|
+
response_types_map=_response_types_map,
|
|
837
|
+
).data
|
|
838
|
+
|
|
839
|
+
@validate_call
|
|
840
|
+
def get_transient_push_access_with_http_info(
|
|
841
|
+
self,
|
|
842
|
+
x_daytona_organization_id: Annotated[
|
|
843
|
+
Optional[StrictStr], Field(description="Use with JWT to specify the organization ID")
|
|
844
|
+
] = None,
|
|
845
|
+
_request_timeout: Union[
|
|
846
|
+
None,
|
|
847
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
848
|
+
Tuple[Annotated[StrictFloat, Field(gt=0)], Annotated[StrictFloat, Field(gt=0)]],
|
|
849
|
+
] = None,
|
|
850
|
+
_request_auth: Optional[Dict[StrictStr, Any]] = None,
|
|
851
|
+
_content_type: Optional[StrictStr] = None,
|
|
852
|
+
_headers: Optional[Dict[StrictStr, Any]] = None,
|
|
853
|
+
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
|
|
854
|
+
) -> ApiResponse[RegistryPushAccessDto]:
|
|
855
|
+
"""Get temporary registry access for pushing snapshots
|
|
856
|
+
|
|
857
|
+
|
|
858
|
+
:param x_daytona_organization_id: Use with JWT to specify the organization ID
|
|
859
|
+
:type x_daytona_organization_id: str
|
|
860
|
+
:param _request_timeout: timeout setting for this request. If one
|
|
861
|
+
number provided, it will be total request
|
|
862
|
+
timeout. It can also be a pair (tuple) of
|
|
863
|
+
(connection, read) timeouts.
|
|
864
|
+
:type _request_timeout: int, tuple(int, int), optional
|
|
865
|
+
:param _request_auth: set to override the auth_settings for an a single
|
|
866
|
+
request; this effectively ignores the
|
|
867
|
+
authentication in the spec for a single request.
|
|
868
|
+
:type _request_auth: dict, optional
|
|
869
|
+
:param _content_type: force content-type for the request.
|
|
870
|
+
:type _content_type: str, Optional
|
|
871
|
+
:param _headers: set to override the headers for a single
|
|
872
|
+
request; this effectively ignores the headers
|
|
873
|
+
in the spec for a single request.
|
|
874
|
+
:type _headers: dict, optional
|
|
875
|
+
:param _host_index: set to override the host_index for a single
|
|
876
|
+
request; this effectively ignores the host_index
|
|
877
|
+
in the spec for a single request.
|
|
878
|
+
:type _host_index: int, optional
|
|
879
|
+
:return: Returns the result object.
|
|
880
|
+
""" # noqa: E501
|
|
881
|
+
|
|
882
|
+
_param = self._get_transient_push_access_serialize(
|
|
883
|
+
x_daytona_organization_id=x_daytona_organization_id,
|
|
884
|
+
_request_auth=_request_auth,
|
|
885
|
+
_content_type=_content_type,
|
|
886
|
+
_headers=_headers,
|
|
887
|
+
_host_index=_host_index,
|
|
888
|
+
)
|
|
889
|
+
|
|
890
|
+
_response_types_map: Dict[str, Optional[str]] = {
|
|
891
|
+
"200": "RegistryPushAccessDto",
|
|
892
|
+
}
|
|
893
|
+
response_data = self.api_client.call_api(*_param, _request_timeout=_request_timeout)
|
|
894
|
+
response_data.read()
|
|
895
|
+
return self.api_client.response_deserialize(
|
|
896
|
+
response_data=response_data,
|
|
897
|
+
response_types_map=_response_types_map,
|
|
898
|
+
)
|
|
899
|
+
|
|
900
|
+
@validate_call
|
|
901
|
+
def get_transient_push_access_without_preload_content(
|
|
902
|
+
self,
|
|
903
|
+
x_daytona_organization_id: Annotated[
|
|
904
|
+
Optional[StrictStr], Field(description="Use with JWT to specify the organization ID")
|
|
905
|
+
] = None,
|
|
906
|
+
_request_timeout: Union[
|
|
907
|
+
None,
|
|
908
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
909
|
+
Tuple[Annotated[StrictFloat, Field(gt=0)], Annotated[StrictFloat, Field(gt=0)]],
|
|
910
|
+
] = None,
|
|
911
|
+
_request_auth: Optional[Dict[StrictStr, Any]] = None,
|
|
912
|
+
_content_type: Optional[StrictStr] = None,
|
|
913
|
+
_headers: Optional[Dict[StrictStr, Any]] = None,
|
|
914
|
+
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
|
|
915
|
+
) -> RESTResponseType:
|
|
916
|
+
"""Get temporary registry access for pushing snapshots
|
|
917
|
+
|
|
918
|
+
|
|
919
|
+
:param x_daytona_organization_id: Use with JWT to specify the organization ID
|
|
920
|
+
:type x_daytona_organization_id: str
|
|
921
|
+
:param _request_timeout: timeout setting for this request. If one
|
|
922
|
+
number provided, it will be total request
|
|
923
|
+
timeout. It can also be a pair (tuple) of
|
|
924
|
+
(connection, read) timeouts.
|
|
925
|
+
:type _request_timeout: int, tuple(int, int), optional
|
|
926
|
+
:param _request_auth: set to override the auth_settings for an a single
|
|
927
|
+
request; this effectively ignores the
|
|
928
|
+
authentication in the spec for a single request.
|
|
929
|
+
:type _request_auth: dict, optional
|
|
930
|
+
:param _content_type: force content-type for the request.
|
|
931
|
+
:type _content_type: str, Optional
|
|
932
|
+
:param _headers: set to override the headers for a single
|
|
933
|
+
request; this effectively ignores the headers
|
|
934
|
+
in the spec for a single request.
|
|
935
|
+
:type _headers: dict, optional
|
|
936
|
+
:param _host_index: set to override the host_index for a single
|
|
937
|
+
request; this effectively ignores the host_index
|
|
938
|
+
in the spec for a single request.
|
|
939
|
+
:type _host_index: int, optional
|
|
940
|
+
:return: Returns the result object.
|
|
941
|
+
""" # noqa: E501
|
|
942
|
+
|
|
943
|
+
_param = self._get_transient_push_access_serialize(
|
|
944
|
+
x_daytona_organization_id=x_daytona_organization_id,
|
|
945
|
+
_request_auth=_request_auth,
|
|
946
|
+
_content_type=_content_type,
|
|
947
|
+
_headers=_headers,
|
|
948
|
+
_host_index=_host_index,
|
|
949
|
+
)
|
|
950
|
+
|
|
951
|
+
_response_types_map: Dict[str, Optional[str]] = {
|
|
952
|
+
"200": "RegistryPushAccessDto",
|
|
953
|
+
}
|
|
954
|
+
response_data = self.api_client.call_api(*_param, _request_timeout=_request_timeout)
|
|
955
|
+
return response_data.response
|
|
956
|
+
|
|
957
|
+
def _get_transient_push_access_serialize(
|
|
958
|
+
self,
|
|
959
|
+
x_daytona_organization_id,
|
|
960
|
+
_request_auth,
|
|
961
|
+
_content_type,
|
|
962
|
+
_headers,
|
|
963
|
+
_host_index,
|
|
964
|
+
) -> RequestSerialized:
|
|
965
|
+
_host = None
|
|
966
|
+
|
|
967
|
+
_collection_formats: Dict[str, str] = {}
|
|
968
|
+
|
|
969
|
+
_path_params: Dict[str, str] = {}
|
|
970
|
+
_query_params: List[Tuple[str, str]] = []
|
|
971
|
+
_header_params: Dict[str, Optional[str]] = _headers or {}
|
|
972
|
+
_form_params: List[Tuple[str, str]] = []
|
|
973
|
+
_files: Dict[str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]] = {}
|
|
974
|
+
_body_params: Optional[bytes] = None
|
|
975
|
+
|
|
976
|
+
# process the path parameters
|
|
977
|
+
# process the query parameters
|
|
978
|
+
# process the header parameters
|
|
979
|
+
if x_daytona_organization_id is not None:
|
|
980
|
+
_header_params["X-Daytona-Organization-ID"] = x_daytona_organization_id
|
|
981
|
+
# process the form parameters
|
|
982
|
+
# process the body parameter
|
|
983
|
+
|
|
984
|
+
# set the HTTP header `Accept`
|
|
985
|
+
if "Accept" not in _header_params:
|
|
986
|
+
_header_params["Accept"] = self.api_client.select_header_accept(["application/json"])
|
|
987
|
+
|
|
988
|
+
# authentication setting
|
|
989
|
+
_auth_settings: List[str] = ["bearer", "oauth2"]
|
|
990
|
+
|
|
991
|
+
return self.api_client.param_serialize(
|
|
992
|
+
method="GET",
|
|
993
|
+
resource_path="/docker-registry/registry-push-access",
|
|
994
|
+
path_params=_path_params,
|
|
995
|
+
query_params=_query_params,
|
|
996
|
+
header_params=_header_params,
|
|
997
|
+
body=_body_params,
|
|
998
|
+
post_params=_form_params,
|
|
999
|
+
files=_files,
|
|
1000
|
+
auth_settings=_auth_settings,
|
|
1001
|
+
collection_formats=_collection_formats,
|
|
1002
|
+
_host=_host,
|
|
1003
|
+
_request_auth=_request_auth,
|
|
1004
|
+
)
|
|
1005
|
+
|
|
1006
|
+
@validate_call
|
|
1007
|
+
def list_registries(
|
|
1008
|
+
self,
|
|
1009
|
+
x_daytona_organization_id: Annotated[
|
|
1010
|
+
Optional[StrictStr], Field(description="Use with JWT to specify the organization ID")
|
|
1011
|
+
] = None,
|
|
1012
|
+
_request_timeout: Union[
|
|
1013
|
+
None,
|
|
1014
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
1015
|
+
Tuple[Annotated[StrictFloat, Field(gt=0)], Annotated[StrictFloat, Field(gt=0)]],
|
|
1016
|
+
] = None,
|
|
1017
|
+
_request_auth: Optional[Dict[StrictStr, Any]] = None,
|
|
1018
|
+
_content_type: Optional[StrictStr] = None,
|
|
1019
|
+
_headers: Optional[Dict[StrictStr, Any]] = None,
|
|
1020
|
+
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
|
|
1021
|
+
) -> List[DockerRegistry]:
|
|
1022
|
+
"""List registries
|
|
1023
|
+
|
|
1024
|
+
|
|
1025
|
+
:param x_daytona_organization_id: Use with JWT to specify the organization ID
|
|
1026
|
+
:type x_daytona_organization_id: str
|
|
1027
|
+
:param _request_timeout: timeout setting for this request. If one
|
|
1028
|
+
number provided, it will be total request
|
|
1029
|
+
timeout. It can also be a pair (tuple) of
|
|
1030
|
+
(connection, read) timeouts.
|
|
1031
|
+
:type _request_timeout: int, tuple(int, int), optional
|
|
1032
|
+
:param _request_auth: set to override the auth_settings for an a single
|
|
1033
|
+
request; this effectively ignores the
|
|
1034
|
+
authentication in the spec for a single request.
|
|
1035
|
+
:type _request_auth: dict, optional
|
|
1036
|
+
:param _content_type: force content-type for the request.
|
|
1037
|
+
:type _content_type: str, Optional
|
|
1038
|
+
:param _headers: set to override the headers for a single
|
|
1039
|
+
request; this effectively ignores the headers
|
|
1040
|
+
in the spec for a single request.
|
|
1041
|
+
:type _headers: dict, optional
|
|
1042
|
+
:param _host_index: set to override the host_index for a single
|
|
1043
|
+
request; this effectively ignores the host_index
|
|
1044
|
+
in the spec for a single request.
|
|
1045
|
+
:type _host_index: int, optional
|
|
1046
|
+
:return: Returns the result object.
|
|
1047
|
+
""" # noqa: E501
|
|
1048
|
+
|
|
1049
|
+
_param = self._list_registries_serialize(
|
|
1050
|
+
x_daytona_organization_id=x_daytona_organization_id,
|
|
1051
|
+
_request_auth=_request_auth,
|
|
1052
|
+
_content_type=_content_type,
|
|
1053
|
+
_headers=_headers,
|
|
1054
|
+
_host_index=_host_index,
|
|
1055
|
+
)
|
|
1056
|
+
|
|
1057
|
+
_response_types_map: Dict[str, Optional[str]] = {
|
|
1058
|
+
"200": "List[DockerRegistry]",
|
|
1059
|
+
}
|
|
1060
|
+
response_data = self.api_client.call_api(*_param, _request_timeout=_request_timeout)
|
|
1061
|
+
response_data.read()
|
|
1062
|
+
return self.api_client.response_deserialize(
|
|
1063
|
+
response_data=response_data,
|
|
1064
|
+
response_types_map=_response_types_map,
|
|
1065
|
+
).data
|
|
1066
|
+
|
|
1067
|
+
@validate_call
|
|
1068
|
+
def list_registries_with_http_info(
|
|
1069
|
+
self,
|
|
1070
|
+
x_daytona_organization_id: Annotated[
|
|
1071
|
+
Optional[StrictStr], Field(description="Use with JWT to specify the organization ID")
|
|
1072
|
+
] = None,
|
|
1073
|
+
_request_timeout: Union[
|
|
1074
|
+
None,
|
|
1075
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
1076
|
+
Tuple[Annotated[StrictFloat, Field(gt=0)], Annotated[StrictFloat, Field(gt=0)]],
|
|
1077
|
+
] = None,
|
|
1078
|
+
_request_auth: Optional[Dict[StrictStr, Any]] = None,
|
|
1079
|
+
_content_type: Optional[StrictStr] = None,
|
|
1080
|
+
_headers: Optional[Dict[StrictStr, Any]] = None,
|
|
1081
|
+
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
|
|
1082
|
+
) -> ApiResponse[List[DockerRegistry]]:
|
|
1083
|
+
"""List registries
|
|
1084
|
+
|
|
1085
|
+
|
|
1086
|
+
:param x_daytona_organization_id: Use with JWT to specify the organization ID
|
|
1087
|
+
:type x_daytona_organization_id: str
|
|
1088
|
+
:param _request_timeout: timeout setting for this request. If one
|
|
1089
|
+
number provided, it will be total request
|
|
1090
|
+
timeout. It can also be a pair (tuple) of
|
|
1091
|
+
(connection, read) timeouts.
|
|
1092
|
+
:type _request_timeout: int, tuple(int, int), optional
|
|
1093
|
+
:param _request_auth: set to override the auth_settings for an a single
|
|
1094
|
+
request; this effectively ignores the
|
|
1095
|
+
authentication in the spec for a single request.
|
|
1096
|
+
:type _request_auth: dict, optional
|
|
1097
|
+
:param _content_type: force content-type for the request.
|
|
1098
|
+
:type _content_type: str, Optional
|
|
1099
|
+
:param _headers: set to override the headers for a single
|
|
1100
|
+
request; this effectively ignores the headers
|
|
1101
|
+
in the spec for a single request.
|
|
1102
|
+
:type _headers: dict, optional
|
|
1103
|
+
:param _host_index: set to override the host_index for a single
|
|
1104
|
+
request; this effectively ignores the host_index
|
|
1105
|
+
in the spec for a single request.
|
|
1106
|
+
:type _host_index: int, optional
|
|
1107
|
+
:return: Returns the result object.
|
|
1108
|
+
""" # noqa: E501
|
|
1109
|
+
|
|
1110
|
+
_param = self._list_registries_serialize(
|
|
1111
|
+
x_daytona_organization_id=x_daytona_organization_id,
|
|
1112
|
+
_request_auth=_request_auth,
|
|
1113
|
+
_content_type=_content_type,
|
|
1114
|
+
_headers=_headers,
|
|
1115
|
+
_host_index=_host_index,
|
|
1116
|
+
)
|
|
1117
|
+
|
|
1118
|
+
_response_types_map: Dict[str, Optional[str]] = {
|
|
1119
|
+
"200": "List[DockerRegistry]",
|
|
1120
|
+
}
|
|
1121
|
+
response_data = self.api_client.call_api(*_param, _request_timeout=_request_timeout)
|
|
1122
|
+
response_data.read()
|
|
1123
|
+
return self.api_client.response_deserialize(
|
|
1124
|
+
response_data=response_data,
|
|
1125
|
+
response_types_map=_response_types_map,
|
|
1126
|
+
)
|
|
1127
|
+
|
|
1128
|
+
@validate_call
|
|
1129
|
+
def list_registries_without_preload_content(
|
|
1130
|
+
self,
|
|
1131
|
+
x_daytona_organization_id: Annotated[
|
|
1132
|
+
Optional[StrictStr], Field(description="Use with JWT to specify the organization ID")
|
|
1133
|
+
] = None,
|
|
1134
|
+
_request_timeout: Union[
|
|
1135
|
+
None,
|
|
1136
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
1137
|
+
Tuple[Annotated[StrictFloat, Field(gt=0)], Annotated[StrictFloat, Field(gt=0)]],
|
|
1138
|
+
] = None,
|
|
1139
|
+
_request_auth: Optional[Dict[StrictStr, Any]] = None,
|
|
1140
|
+
_content_type: Optional[StrictStr] = None,
|
|
1141
|
+
_headers: Optional[Dict[StrictStr, Any]] = None,
|
|
1142
|
+
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
|
|
1143
|
+
) -> RESTResponseType:
|
|
1144
|
+
"""List registries
|
|
1145
|
+
|
|
1146
|
+
|
|
1147
|
+
:param x_daytona_organization_id: Use with JWT to specify the organization ID
|
|
1148
|
+
:type x_daytona_organization_id: str
|
|
1149
|
+
:param _request_timeout: timeout setting for this request. If one
|
|
1150
|
+
number provided, it will be total request
|
|
1151
|
+
timeout. It can also be a pair (tuple) of
|
|
1152
|
+
(connection, read) timeouts.
|
|
1153
|
+
:type _request_timeout: int, tuple(int, int), optional
|
|
1154
|
+
:param _request_auth: set to override the auth_settings for an a single
|
|
1155
|
+
request; this effectively ignores the
|
|
1156
|
+
authentication in the spec for a single request.
|
|
1157
|
+
:type _request_auth: dict, optional
|
|
1158
|
+
:param _content_type: force content-type for the request.
|
|
1159
|
+
:type _content_type: str, Optional
|
|
1160
|
+
:param _headers: set to override the headers for a single
|
|
1161
|
+
request; this effectively ignores the headers
|
|
1162
|
+
in the spec for a single request.
|
|
1163
|
+
:type _headers: dict, optional
|
|
1164
|
+
:param _host_index: set to override the host_index for a single
|
|
1165
|
+
request; this effectively ignores the host_index
|
|
1166
|
+
in the spec for a single request.
|
|
1167
|
+
:type _host_index: int, optional
|
|
1168
|
+
:return: Returns the result object.
|
|
1169
|
+
""" # noqa: E501
|
|
1170
|
+
|
|
1171
|
+
_param = self._list_registries_serialize(
|
|
1172
|
+
x_daytona_organization_id=x_daytona_organization_id,
|
|
1173
|
+
_request_auth=_request_auth,
|
|
1174
|
+
_content_type=_content_type,
|
|
1175
|
+
_headers=_headers,
|
|
1176
|
+
_host_index=_host_index,
|
|
1177
|
+
)
|
|
1178
|
+
|
|
1179
|
+
_response_types_map: Dict[str, Optional[str]] = {
|
|
1180
|
+
"200": "List[DockerRegistry]",
|
|
1181
|
+
}
|
|
1182
|
+
response_data = self.api_client.call_api(*_param, _request_timeout=_request_timeout)
|
|
1183
|
+
return response_data.response
|
|
1184
|
+
|
|
1185
|
+
def _list_registries_serialize(
|
|
1186
|
+
self,
|
|
1187
|
+
x_daytona_organization_id,
|
|
1188
|
+
_request_auth,
|
|
1189
|
+
_content_type,
|
|
1190
|
+
_headers,
|
|
1191
|
+
_host_index,
|
|
1192
|
+
) -> RequestSerialized:
|
|
1193
|
+
_host = None
|
|
1194
|
+
|
|
1195
|
+
_collection_formats: Dict[str, str] = {}
|
|
1196
|
+
|
|
1197
|
+
_path_params: Dict[str, str] = {}
|
|
1198
|
+
_query_params: List[Tuple[str, str]] = []
|
|
1199
|
+
_header_params: Dict[str, Optional[str]] = _headers or {}
|
|
1200
|
+
_form_params: List[Tuple[str, str]] = []
|
|
1201
|
+
_files: Dict[str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]] = {}
|
|
1202
|
+
_body_params: Optional[bytes] = None
|
|
1203
|
+
|
|
1204
|
+
# process the path parameters
|
|
1205
|
+
# process the query parameters
|
|
1206
|
+
# process the header parameters
|
|
1207
|
+
if x_daytona_organization_id is not None:
|
|
1208
|
+
_header_params["X-Daytona-Organization-ID"] = x_daytona_organization_id
|
|
1209
|
+
# process the form parameters
|
|
1210
|
+
# process the body parameter
|
|
1211
|
+
|
|
1212
|
+
# set the HTTP header `Accept`
|
|
1213
|
+
if "Accept" not in _header_params:
|
|
1214
|
+
_header_params["Accept"] = self.api_client.select_header_accept(["application/json"])
|
|
1215
|
+
|
|
1216
|
+
# authentication setting
|
|
1217
|
+
_auth_settings: List[str] = ["bearer", "oauth2"]
|
|
1218
|
+
|
|
1219
|
+
return self.api_client.param_serialize(
|
|
1220
|
+
method="GET",
|
|
1221
|
+
resource_path="/docker-registry",
|
|
1222
|
+
path_params=_path_params,
|
|
1223
|
+
query_params=_query_params,
|
|
1224
|
+
header_params=_header_params,
|
|
1225
|
+
body=_body_params,
|
|
1226
|
+
post_params=_form_params,
|
|
1227
|
+
files=_files,
|
|
1228
|
+
auth_settings=_auth_settings,
|
|
1229
|
+
collection_formats=_collection_formats,
|
|
1230
|
+
_host=_host,
|
|
1231
|
+
_request_auth=_request_auth,
|
|
1232
|
+
)
|
|
1233
|
+
|
|
1234
|
+
@validate_call
|
|
1235
|
+
def set_default_registry(
|
|
1236
|
+
self,
|
|
1237
|
+
id: Annotated[StrictStr, Field(description="ID of the docker registry")],
|
|
1238
|
+
x_daytona_organization_id: Annotated[
|
|
1239
|
+
Optional[StrictStr], Field(description="Use with JWT to specify the organization ID")
|
|
1240
|
+
] = None,
|
|
1241
|
+
_request_timeout: Union[
|
|
1242
|
+
None,
|
|
1243
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
1244
|
+
Tuple[Annotated[StrictFloat, Field(gt=0)], Annotated[StrictFloat, Field(gt=0)]],
|
|
1245
|
+
] = None,
|
|
1246
|
+
_request_auth: Optional[Dict[StrictStr, Any]] = None,
|
|
1247
|
+
_content_type: Optional[StrictStr] = None,
|
|
1248
|
+
_headers: Optional[Dict[StrictStr, Any]] = None,
|
|
1249
|
+
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
|
|
1250
|
+
) -> DockerRegistry:
|
|
1251
|
+
"""Set default registry
|
|
1252
|
+
|
|
1253
|
+
|
|
1254
|
+
:param id: ID of the docker registry (required)
|
|
1255
|
+
:type id: str
|
|
1256
|
+
:param x_daytona_organization_id: Use with JWT to specify the organization ID
|
|
1257
|
+
:type x_daytona_organization_id: str
|
|
1258
|
+
:param _request_timeout: timeout setting for this request. If one
|
|
1259
|
+
number provided, it will be total request
|
|
1260
|
+
timeout. It can also be a pair (tuple) of
|
|
1261
|
+
(connection, read) timeouts.
|
|
1262
|
+
:type _request_timeout: int, tuple(int, int), optional
|
|
1263
|
+
:param _request_auth: set to override the auth_settings for an a single
|
|
1264
|
+
request; this effectively ignores the
|
|
1265
|
+
authentication in the spec for a single request.
|
|
1266
|
+
:type _request_auth: dict, optional
|
|
1267
|
+
:param _content_type: force content-type for the request.
|
|
1268
|
+
:type _content_type: str, Optional
|
|
1269
|
+
:param _headers: set to override the headers for a single
|
|
1270
|
+
request; this effectively ignores the headers
|
|
1271
|
+
in the spec for a single request.
|
|
1272
|
+
:type _headers: dict, optional
|
|
1273
|
+
:param _host_index: set to override the host_index for a single
|
|
1274
|
+
request; this effectively ignores the host_index
|
|
1275
|
+
in the spec for a single request.
|
|
1276
|
+
:type _host_index: int, optional
|
|
1277
|
+
:return: Returns the result object.
|
|
1278
|
+
""" # noqa: E501
|
|
1279
|
+
|
|
1280
|
+
_param = self._set_default_registry_serialize(
|
|
1281
|
+
id=id,
|
|
1282
|
+
x_daytona_organization_id=x_daytona_organization_id,
|
|
1283
|
+
_request_auth=_request_auth,
|
|
1284
|
+
_content_type=_content_type,
|
|
1285
|
+
_headers=_headers,
|
|
1286
|
+
_host_index=_host_index,
|
|
1287
|
+
)
|
|
1288
|
+
|
|
1289
|
+
_response_types_map: Dict[str, Optional[str]] = {
|
|
1290
|
+
"200": "DockerRegistry",
|
|
1291
|
+
}
|
|
1292
|
+
response_data = self.api_client.call_api(*_param, _request_timeout=_request_timeout)
|
|
1293
|
+
response_data.read()
|
|
1294
|
+
return self.api_client.response_deserialize(
|
|
1295
|
+
response_data=response_data,
|
|
1296
|
+
response_types_map=_response_types_map,
|
|
1297
|
+
).data
|
|
1298
|
+
|
|
1299
|
+
@validate_call
|
|
1300
|
+
def set_default_registry_with_http_info(
|
|
1301
|
+
self,
|
|
1302
|
+
id: Annotated[StrictStr, Field(description="ID of the docker registry")],
|
|
1303
|
+
x_daytona_organization_id: Annotated[
|
|
1304
|
+
Optional[StrictStr], Field(description="Use with JWT to specify the organization ID")
|
|
1305
|
+
] = None,
|
|
1306
|
+
_request_timeout: Union[
|
|
1307
|
+
None,
|
|
1308
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
1309
|
+
Tuple[Annotated[StrictFloat, Field(gt=0)], Annotated[StrictFloat, Field(gt=0)]],
|
|
1310
|
+
] = None,
|
|
1311
|
+
_request_auth: Optional[Dict[StrictStr, Any]] = None,
|
|
1312
|
+
_content_type: Optional[StrictStr] = None,
|
|
1313
|
+
_headers: Optional[Dict[StrictStr, Any]] = None,
|
|
1314
|
+
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
|
|
1315
|
+
) -> ApiResponse[DockerRegistry]:
|
|
1316
|
+
"""Set default registry
|
|
1317
|
+
|
|
1318
|
+
|
|
1319
|
+
:param id: ID of the docker registry (required)
|
|
1320
|
+
:type id: str
|
|
1321
|
+
:param x_daytona_organization_id: Use with JWT to specify the organization ID
|
|
1322
|
+
:type x_daytona_organization_id: str
|
|
1323
|
+
:param _request_timeout: timeout setting for this request. If one
|
|
1324
|
+
number provided, it will be total request
|
|
1325
|
+
timeout. It can also be a pair (tuple) of
|
|
1326
|
+
(connection, read) timeouts.
|
|
1327
|
+
:type _request_timeout: int, tuple(int, int), optional
|
|
1328
|
+
:param _request_auth: set to override the auth_settings for an a single
|
|
1329
|
+
request; this effectively ignores the
|
|
1330
|
+
authentication in the spec for a single request.
|
|
1331
|
+
:type _request_auth: dict, optional
|
|
1332
|
+
:param _content_type: force content-type for the request.
|
|
1333
|
+
:type _content_type: str, Optional
|
|
1334
|
+
:param _headers: set to override the headers for a single
|
|
1335
|
+
request; this effectively ignores the headers
|
|
1336
|
+
in the spec for a single request.
|
|
1337
|
+
:type _headers: dict, optional
|
|
1338
|
+
:param _host_index: set to override the host_index for a single
|
|
1339
|
+
request; this effectively ignores the host_index
|
|
1340
|
+
in the spec for a single request.
|
|
1341
|
+
:type _host_index: int, optional
|
|
1342
|
+
:return: Returns the result object.
|
|
1343
|
+
""" # noqa: E501
|
|
1344
|
+
|
|
1345
|
+
_param = self._set_default_registry_serialize(
|
|
1346
|
+
id=id,
|
|
1347
|
+
x_daytona_organization_id=x_daytona_organization_id,
|
|
1348
|
+
_request_auth=_request_auth,
|
|
1349
|
+
_content_type=_content_type,
|
|
1350
|
+
_headers=_headers,
|
|
1351
|
+
_host_index=_host_index,
|
|
1352
|
+
)
|
|
1353
|
+
|
|
1354
|
+
_response_types_map: Dict[str, Optional[str]] = {
|
|
1355
|
+
"200": "DockerRegistry",
|
|
1356
|
+
}
|
|
1357
|
+
response_data = self.api_client.call_api(*_param, _request_timeout=_request_timeout)
|
|
1358
|
+
response_data.read()
|
|
1359
|
+
return self.api_client.response_deserialize(
|
|
1360
|
+
response_data=response_data,
|
|
1361
|
+
response_types_map=_response_types_map,
|
|
1362
|
+
)
|
|
1363
|
+
|
|
1364
|
+
@validate_call
|
|
1365
|
+
def set_default_registry_without_preload_content(
|
|
1366
|
+
self,
|
|
1367
|
+
id: Annotated[StrictStr, Field(description="ID of the docker registry")],
|
|
1368
|
+
x_daytona_organization_id: Annotated[
|
|
1369
|
+
Optional[StrictStr], Field(description="Use with JWT to specify the organization ID")
|
|
1370
|
+
] = None,
|
|
1371
|
+
_request_timeout: Union[
|
|
1372
|
+
None,
|
|
1373
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
1374
|
+
Tuple[Annotated[StrictFloat, Field(gt=0)], Annotated[StrictFloat, Field(gt=0)]],
|
|
1375
|
+
] = None,
|
|
1376
|
+
_request_auth: Optional[Dict[StrictStr, Any]] = None,
|
|
1377
|
+
_content_type: Optional[StrictStr] = None,
|
|
1378
|
+
_headers: Optional[Dict[StrictStr, Any]] = None,
|
|
1379
|
+
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
|
|
1380
|
+
) -> RESTResponseType:
|
|
1381
|
+
"""Set default registry
|
|
1382
|
+
|
|
1383
|
+
|
|
1384
|
+
:param id: ID of the docker registry (required)
|
|
1385
|
+
:type id: str
|
|
1386
|
+
:param x_daytona_organization_id: Use with JWT to specify the organization ID
|
|
1387
|
+
:type x_daytona_organization_id: str
|
|
1388
|
+
:param _request_timeout: timeout setting for this request. If one
|
|
1389
|
+
number provided, it will be total request
|
|
1390
|
+
timeout. It can also be a pair (tuple) of
|
|
1391
|
+
(connection, read) timeouts.
|
|
1392
|
+
:type _request_timeout: int, tuple(int, int), optional
|
|
1393
|
+
:param _request_auth: set to override the auth_settings for an a single
|
|
1394
|
+
request; this effectively ignores the
|
|
1395
|
+
authentication in the spec for a single request.
|
|
1396
|
+
:type _request_auth: dict, optional
|
|
1397
|
+
:param _content_type: force content-type for the request.
|
|
1398
|
+
:type _content_type: str, Optional
|
|
1399
|
+
:param _headers: set to override the headers for a single
|
|
1400
|
+
request; this effectively ignores the headers
|
|
1401
|
+
in the spec for a single request.
|
|
1402
|
+
:type _headers: dict, optional
|
|
1403
|
+
:param _host_index: set to override the host_index for a single
|
|
1404
|
+
request; this effectively ignores the host_index
|
|
1405
|
+
in the spec for a single request.
|
|
1406
|
+
:type _host_index: int, optional
|
|
1407
|
+
:return: Returns the result object.
|
|
1408
|
+
""" # noqa: E501
|
|
1409
|
+
|
|
1410
|
+
_param = self._set_default_registry_serialize(
|
|
1411
|
+
id=id,
|
|
1412
|
+
x_daytona_organization_id=x_daytona_organization_id,
|
|
1413
|
+
_request_auth=_request_auth,
|
|
1414
|
+
_content_type=_content_type,
|
|
1415
|
+
_headers=_headers,
|
|
1416
|
+
_host_index=_host_index,
|
|
1417
|
+
)
|
|
1418
|
+
|
|
1419
|
+
_response_types_map: Dict[str, Optional[str]] = {
|
|
1420
|
+
"200": "DockerRegistry",
|
|
1421
|
+
}
|
|
1422
|
+
response_data = self.api_client.call_api(*_param, _request_timeout=_request_timeout)
|
|
1423
|
+
return response_data.response
|
|
1424
|
+
|
|
1425
|
+
def _set_default_registry_serialize(
|
|
1426
|
+
self,
|
|
1427
|
+
id,
|
|
1428
|
+
x_daytona_organization_id,
|
|
1429
|
+
_request_auth,
|
|
1430
|
+
_content_type,
|
|
1431
|
+
_headers,
|
|
1432
|
+
_host_index,
|
|
1433
|
+
) -> RequestSerialized:
|
|
1434
|
+
_host = None
|
|
1435
|
+
|
|
1436
|
+
_collection_formats: Dict[str, str] = {}
|
|
1437
|
+
|
|
1438
|
+
_path_params: Dict[str, str] = {}
|
|
1439
|
+
_query_params: List[Tuple[str, str]] = []
|
|
1440
|
+
_header_params: Dict[str, Optional[str]] = _headers or {}
|
|
1441
|
+
_form_params: List[Tuple[str, str]] = []
|
|
1442
|
+
_files: Dict[str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]] = {}
|
|
1443
|
+
_body_params: Optional[bytes] = None
|
|
1444
|
+
|
|
1445
|
+
# process the path parameters
|
|
1446
|
+
if id is not None:
|
|
1447
|
+
_path_params["id"] = id
|
|
1448
|
+
# process the query parameters
|
|
1449
|
+
# process the header parameters
|
|
1450
|
+
if x_daytona_organization_id is not None:
|
|
1451
|
+
_header_params["X-Daytona-Organization-ID"] = x_daytona_organization_id
|
|
1452
|
+
# process the form parameters
|
|
1453
|
+
# process the body parameter
|
|
1454
|
+
|
|
1455
|
+
# set the HTTP header `Accept`
|
|
1456
|
+
if "Accept" not in _header_params:
|
|
1457
|
+
_header_params["Accept"] = self.api_client.select_header_accept(["application/json"])
|
|
1458
|
+
|
|
1459
|
+
# authentication setting
|
|
1460
|
+
_auth_settings: List[str] = ["bearer", "oauth2"]
|
|
1461
|
+
|
|
1462
|
+
return self.api_client.param_serialize(
|
|
1463
|
+
method="POST",
|
|
1464
|
+
resource_path="/docker-registry/{id}/set-default",
|
|
1465
|
+
path_params=_path_params,
|
|
1466
|
+
query_params=_query_params,
|
|
1467
|
+
header_params=_header_params,
|
|
1468
|
+
body=_body_params,
|
|
1469
|
+
post_params=_form_params,
|
|
1470
|
+
files=_files,
|
|
1471
|
+
auth_settings=_auth_settings,
|
|
1472
|
+
collection_formats=_collection_formats,
|
|
1473
|
+
_host=_host,
|
|
1474
|
+
_request_auth=_request_auth,
|
|
1475
|
+
)
|
|
1476
|
+
|
|
1477
|
+
@validate_call
|
|
1478
|
+
def update_registry(
|
|
1479
|
+
self,
|
|
1480
|
+
id: Annotated[StrictStr, Field(description="ID of the docker registry")],
|
|
1481
|
+
update_docker_registry: UpdateDockerRegistry,
|
|
1482
|
+
x_daytona_organization_id: Annotated[
|
|
1483
|
+
Optional[StrictStr], Field(description="Use with JWT to specify the organization ID")
|
|
1484
|
+
] = None,
|
|
1485
|
+
_request_timeout: Union[
|
|
1486
|
+
None,
|
|
1487
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
1488
|
+
Tuple[Annotated[StrictFloat, Field(gt=0)], Annotated[StrictFloat, Field(gt=0)]],
|
|
1489
|
+
] = None,
|
|
1490
|
+
_request_auth: Optional[Dict[StrictStr, Any]] = None,
|
|
1491
|
+
_content_type: Optional[StrictStr] = None,
|
|
1492
|
+
_headers: Optional[Dict[StrictStr, Any]] = None,
|
|
1493
|
+
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
|
|
1494
|
+
) -> DockerRegistry:
|
|
1495
|
+
"""Update registry
|
|
1496
|
+
|
|
1497
|
+
|
|
1498
|
+
:param id: ID of the docker registry (required)
|
|
1499
|
+
:type id: str
|
|
1500
|
+
:param update_docker_registry: (required)
|
|
1501
|
+
:type update_docker_registry: UpdateDockerRegistry
|
|
1502
|
+
:param x_daytona_organization_id: Use with JWT to specify the organization ID
|
|
1503
|
+
:type x_daytona_organization_id: str
|
|
1504
|
+
:param _request_timeout: timeout setting for this request. If one
|
|
1505
|
+
number provided, it will be total request
|
|
1506
|
+
timeout. It can also be a pair (tuple) of
|
|
1507
|
+
(connection, read) timeouts.
|
|
1508
|
+
:type _request_timeout: int, tuple(int, int), optional
|
|
1509
|
+
:param _request_auth: set to override the auth_settings for an a single
|
|
1510
|
+
request; this effectively ignores the
|
|
1511
|
+
authentication in the spec for a single request.
|
|
1512
|
+
:type _request_auth: dict, optional
|
|
1513
|
+
:param _content_type: force content-type for the request.
|
|
1514
|
+
:type _content_type: str, Optional
|
|
1515
|
+
:param _headers: set to override the headers for a single
|
|
1516
|
+
request; this effectively ignores the headers
|
|
1517
|
+
in the spec for a single request.
|
|
1518
|
+
:type _headers: dict, optional
|
|
1519
|
+
:param _host_index: set to override the host_index for a single
|
|
1520
|
+
request; this effectively ignores the host_index
|
|
1521
|
+
in the spec for a single request.
|
|
1522
|
+
:type _host_index: int, optional
|
|
1523
|
+
:return: Returns the result object.
|
|
1524
|
+
""" # noqa: E501
|
|
1525
|
+
|
|
1526
|
+
_param = self._update_registry_serialize(
|
|
1527
|
+
id=id,
|
|
1528
|
+
update_docker_registry=update_docker_registry,
|
|
1529
|
+
x_daytona_organization_id=x_daytona_organization_id,
|
|
1530
|
+
_request_auth=_request_auth,
|
|
1531
|
+
_content_type=_content_type,
|
|
1532
|
+
_headers=_headers,
|
|
1533
|
+
_host_index=_host_index,
|
|
1534
|
+
)
|
|
1535
|
+
|
|
1536
|
+
_response_types_map: Dict[str, Optional[str]] = {
|
|
1537
|
+
"200": "DockerRegistry",
|
|
1538
|
+
}
|
|
1539
|
+
response_data = self.api_client.call_api(*_param, _request_timeout=_request_timeout)
|
|
1540
|
+
response_data.read()
|
|
1541
|
+
return self.api_client.response_deserialize(
|
|
1542
|
+
response_data=response_data,
|
|
1543
|
+
response_types_map=_response_types_map,
|
|
1544
|
+
).data
|
|
1545
|
+
|
|
1546
|
+
@validate_call
|
|
1547
|
+
def update_registry_with_http_info(
|
|
1548
|
+
self,
|
|
1549
|
+
id: Annotated[StrictStr, Field(description="ID of the docker registry")],
|
|
1550
|
+
update_docker_registry: UpdateDockerRegistry,
|
|
1551
|
+
x_daytona_organization_id: Annotated[
|
|
1552
|
+
Optional[StrictStr], Field(description="Use with JWT to specify the organization ID")
|
|
1553
|
+
] = None,
|
|
1554
|
+
_request_timeout: Union[
|
|
1555
|
+
None,
|
|
1556
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
1557
|
+
Tuple[Annotated[StrictFloat, Field(gt=0)], Annotated[StrictFloat, Field(gt=0)]],
|
|
1558
|
+
] = None,
|
|
1559
|
+
_request_auth: Optional[Dict[StrictStr, Any]] = None,
|
|
1560
|
+
_content_type: Optional[StrictStr] = None,
|
|
1561
|
+
_headers: Optional[Dict[StrictStr, Any]] = None,
|
|
1562
|
+
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
|
|
1563
|
+
) -> ApiResponse[DockerRegistry]:
|
|
1564
|
+
"""Update registry
|
|
1565
|
+
|
|
1566
|
+
|
|
1567
|
+
:param id: ID of the docker registry (required)
|
|
1568
|
+
:type id: str
|
|
1569
|
+
:param update_docker_registry: (required)
|
|
1570
|
+
:type update_docker_registry: UpdateDockerRegistry
|
|
1571
|
+
:param x_daytona_organization_id: Use with JWT to specify the organization ID
|
|
1572
|
+
:type x_daytona_organization_id: str
|
|
1573
|
+
:param _request_timeout: timeout setting for this request. If one
|
|
1574
|
+
number provided, it will be total request
|
|
1575
|
+
timeout. It can also be a pair (tuple) of
|
|
1576
|
+
(connection, read) timeouts.
|
|
1577
|
+
:type _request_timeout: int, tuple(int, int), optional
|
|
1578
|
+
:param _request_auth: set to override the auth_settings for an a single
|
|
1579
|
+
request; this effectively ignores the
|
|
1580
|
+
authentication in the spec for a single request.
|
|
1581
|
+
:type _request_auth: dict, optional
|
|
1582
|
+
:param _content_type: force content-type for the request.
|
|
1583
|
+
:type _content_type: str, Optional
|
|
1584
|
+
:param _headers: set to override the headers for a single
|
|
1585
|
+
request; this effectively ignores the headers
|
|
1586
|
+
in the spec for a single request.
|
|
1587
|
+
:type _headers: dict, optional
|
|
1588
|
+
:param _host_index: set to override the host_index for a single
|
|
1589
|
+
request; this effectively ignores the host_index
|
|
1590
|
+
in the spec for a single request.
|
|
1591
|
+
:type _host_index: int, optional
|
|
1592
|
+
:return: Returns the result object.
|
|
1593
|
+
""" # noqa: E501
|
|
1594
|
+
|
|
1595
|
+
_param = self._update_registry_serialize(
|
|
1596
|
+
id=id,
|
|
1597
|
+
update_docker_registry=update_docker_registry,
|
|
1598
|
+
x_daytona_organization_id=x_daytona_organization_id,
|
|
1599
|
+
_request_auth=_request_auth,
|
|
1600
|
+
_content_type=_content_type,
|
|
1601
|
+
_headers=_headers,
|
|
1602
|
+
_host_index=_host_index,
|
|
1603
|
+
)
|
|
1604
|
+
|
|
1605
|
+
_response_types_map: Dict[str, Optional[str]] = {
|
|
1606
|
+
"200": "DockerRegistry",
|
|
1607
|
+
}
|
|
1608
|
+
response_data = self.api_client.call_api(*_param, _request_timeout=_request_timeout)
|
|
1609
|
+
response_data.read()
|
|
1610
|
+
return self.api_client.response_deserialize(
|
|
1611
|
+
response_data=response_data,
|
|
1612
|
+
response_types_map=_response_types_map,
|
|
1613
|
+
)
|
|
1614
|
+
|
|
1615
|
+
@validate_call
|
|
1616
|
+
def update_registry_without_preload_content(
|
|
1617
|
+
self,
|
|
1618
|
+
id: Annotated[StrictStr, Field(description="ID of the docker registry")],
|
|
1619
|
+
update_docker_registry: UpdateDockerRegistry,
|
|
1620
|
+
x_daytona_organization_id: Annotated[
|
|
1621
|
+
Optional[StrictStr], Field(description="Use with JWT to specify the organization ID")
|
|
1622
|
+
] = None,
|
|
1623
|
+
_request_timeout: Union[
|
|
1624
|
+
None,
|
|
1625
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
1626
|
+
Tuple[Annotated[StrictFloat, Field(gt=0)], Annotated[StrictFloat, Field(gt=0)]],
|
|
1627
|
+
] = None,
|
|
1628
|
+
_request_auth: Optional[Dict[StrictStr, Any]] = None,
|
|
1629
|
+
_content_type: Optional[StrictStr] = None,
|
|
1630
|
+
_headers: Optional[Dict[StrictStr, Any]] = None,
|
|
1631
|
+
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
|
|
1632
|
+
) -> RESTResponseType:
|
|
1633
|
+
"""Update registry
|
|
1634
|
+
|
|
1635
|
+
|
|
1636
|
+
:param id: ID of the docker registry (required)
|
|
1637
|
+
:type id: str
|
|
1638
|
+
:param update_docker_registry: (required)
|
|
1639
|
+
:type update_docker_registry: UpdateDockerRegistry
|
|
1640
|
+
:param x_daytona_organization_id: Use with JWT to specify the organization ID
|
|
1641
|
+
:type x_daytona_organization_id: str
|
|
1642
|
+
:param _request_timeout: timeout setting for this request. If one
|
|
1643
|
+
number provided, it will be total request
|
|
1644
|
+
timeout. It can also be a pair (tuple) of
|
|
1645
|
+
(connection, read) timeouts.
|
|
1646
|
+
:type _request_timeout: int, tuple(int, int), optional
|
|
1647
|
+
:param _request_auth: set to override the auth_settings for an a single
|
|
1648
|
+
request; this effectively ignores the
|
|
1649
|
+
authentication in the spec for a single request.
|
|
1650
|
+
:type _request_auth: dict, optional
|
|
1651
|
+
:param _content_type: force content-type for the request.
|
|
1652
|
+
:type _content_type: str, Optional
|
|
1653
|
+
:param _headers: set to override the headers for a single
|
|
1654
|
+
request; this effectively ignores the headers
|
|
1655
|
+
in the spec for a single request.
|
|
1656
|
+
:type _headers: dict, optional
|
|
1657
|
+
:param _host_index: set to override the host_index for a single
|
|
1658
|
+
request; this effectively ignores the host_index
|
|
1659
|
+
in the spec for a single request.
|
|
1660
|
+
:type _host_index: int, optional
|
|
1661
|
+
:return: Returns the result object.
|
|
1662
|
+
""" # noqa: E501
|
|
1663
|
+
|
|
1664
|
+
_param = self._update_registry_serialize(
|
|
1665
|
+
id=id,
|
|
1666
|
+
update_docker_registry=update_docker_registry,
|
|
1667
|
+
x_daytona_organization_id=x_daytona_organization_id,
|
|
1668
|
+
_request_auth=_request_auth,
|
|
1669
|
+
_content_type=_content_type,
|
|
1670
|
+
_headers=_headers,
|
|
1671
|
+
_host_index=_host_index,
|
|
1672
|
+
)
|
|
1673
|
+
|
|
1674
|
+
_response_types_map: Dict[str, Optional[str]] = {
|
|
1675
|
+
"200": "DockerRegistry",
|
|
1676
|
+
}
|
|
1677
|
+
response_data = self.api_client.call_api(*_param, _request_timeout=_request_timeout)
|
|
1678
|
+
return response_data.response
|
|
1679
|
+
|
|
1680
|
+
def _update_registry_serialize(
|
|
1681
|
+
self,
|
|
1682
|
+
id,
|
|
1683
|
+
update_docker_registry,
|
|
1684
|
+
x_daytona_organization_id,
|
|
1685
|
+
_request_auth,
|
|
1686
|
+
_content_type,
|
|
1687
|
+
_headers,
|
|
1688
|
+
_host_index,
|
|
1689
|
+
) -> RequestSerialized:
|
|
1690
|
+
_host = None
|
|
1691
|
+
|
|
1692
|
+
_collection_formats: Dict[str, str] = {}
|
|
1693
|
+
|
|
1694
|
+
_path_params: Dict[str, str] = {}
|
|
1695
|
+
_query_params: List[Tuple[str, str]] = []
|
|
1696
|
+
_header_params: Dict[str, Optional[str]] = _headers or {}
|
|
1697
|
+
_form_params: List[Tuple[str, str]] = []
|
|
1698
|
+
_files: Dict[str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]] = {}
|
|
1699
|
+
_body_params: Optional[bytes] = None
|
|
1700
|
+
|
|
1701
|
+
# process the path parameters
|
|
1702
|
+
if id is not None:
|
|
1703
|
+
_path_params["id"] = id
|
|
1704
|
+
# process the query parameters
|
|
1705
|
+
# process the header parameters
|
|
1706
|
+
if x_daytona_organization_id is not None:
|
|
1707
|
+
_header_params["X-Daytona-Organization-ID"] = x_daytona_organization_id
|
|
1708
|
+
# process the form parameters
|
|
1709
|
+
# process the body parameter
|
|
1710
|
+
if update_docker_registry is not None:
|
|
1711
|
+
_body_params = update_docker_registry
|
|
1712
|
+
|
|
1713
|
+
# set the HTTP header `Accept`
|
|
1714
|
+
if "Accept" not in _header_params:
|
|
1715
|
+
_header_params["Accept"] = self.api_client.select_header_accept(["application/json"])
|
|
1716
|
+
|
|
1717
|
+
# set the HTTP header `Content-Type`
|
|
1718
|
+
if _content_type:
|
|
1719
|
+
_header_params["Content-Type"] = _content_type
|
|
1720
|
+
else:
|
|
1721
|
+
_default_content_type = self.api_client.select_header_content_type(["application/json"])
|
|
1722
|
+
if _default_content_type is not None:
|
|
1723
|
+
_header_params["Content-Type"] = _default_content_type
|
|
1724
|
+
|
|
1725
|
+
# authentication setting
|
|
1726
|
+
_auth_settings: List[str] = ["bearer", "oauth2"]
|
|
1727
|
+
|
|
1728
|
+
return self.api_client.param_serialize(
|
|
1729
|
+
method="PATCH",
|
|
1730
|
+
resource_path="/docker-registry/{id}",
|
|
1731
|
+
path_params=_path_params,
|
|
1732
|
+
query_params=_query_params,
|
|
1733
|
+
header_params=_header_params,
|
|
1734
|
+
body=_body_params,
|
|
1735
|
+
post_params=_form_params,
|
|
1736
|
+
files=_files,
|
|
1737
|
+
auth_settings=_auth_settings,
|
|
1738
|
+
collection_formats=_collection_formats,
|
|
1739
|
+
_host=_host,
|
|
1740
|
+
_request_auth=_request_auth,
|
|
1741
|
+
)
|