daytona_api_client_async 0.0.0.dev0__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.
- daytona_api_client_async/__init__.py +195 -0
- daytona_api_client_async/api/__init__.py +21 -0
- daytona_api_client_async/api/api_keys_api.py +1673 -0
- daytona_api_client_async/api/audit_api.py +750 -0
- daytona_api_client_async/api/config_api.py +279 -0
- daytona_api_client_async/api/default_api.py +1884 -0
- daytona_api_client_async/api/docker_registry_api.py +1965 -0
- daytona_api_client_async/api/health_api.py +282 -0
- daytona_api_client_async/api/object_storage_api.py +299 -0
- daytona_api_client_async/api/organizations_api.py +7836 -0
- daytona_api_client_async/api/preview_api.py +826 -0
- daytona_api_client_async/api/regions_api.py +316 -0
- daytona_api_client_async/api/runners_api.py +1560 -0
- daytona_api_client_async/api/sandbox_api.py +6927 -0
- daytona_api_client_async/api/snapshots_api.py +2630 -0
- daytona_api_client_async/api/toolbox_api.py +20759 -0
- daytona_api_client_async/api/users_api.py +2319 -0
- daytona_api_client_async/api/volumes_api.py +1419 -0
- daytona_api_client_async/api/webhooks_api.py +1704 -0
- daytona_api_client_async/api/workspace_api.py +4036 -0
- daytona_api_client_async/api_client.py +801 -0
- daytona_api_client_async/api_response.py +21 -0
- daytona_api_client_async/configuration.py +579 -0
- daytona_api_client_async/exceptions.py +217 -0
- daytona_api_client_async/models/__init__.py +162 -0
- daytona_api_client_async/models/account_provider.py +103 -0
- daytona_api_client_async/models/announcement.py +103 -0
- daytona_api_client_async/models/api_key_list.py +132 -0
- daytona_api_client_async/models/api_key_response.py +123 -0
- daytona_api_client_async/models/audit_log.py +128 -0
- daytona_api_client_async/models/build_info.py +108 -0
- daytona_api_client_async/models/command.py +105 -0
- daytona_api_client_async/models/completion_context.py +103 -0
- daytona_api_client_async/models/completion_item.py +113 -0
- daytona_api_client_async/models/completion_list.py +111 -0
- daytona_api_client_async/models/compressed_screenshot_response.py +105 -0
- daytona_api_client_async/models/computer_use_start_response.py +103 -0
- daytona_api_client_async/models/computer_use_status_response.py +108 -0
- daytona_api_client_async/models/computer_use_stop_response.py +103 -0
- daytona_api_client_async/models/configuration.py +145 -0
- daytona_api_client_async/models/create_api_key.py +119 -0
- daytona_api_client_async/models/create_audit_log.py +128 -0
- daytona_api_client_async/models/create_build_info.py +103 -0
- daytona_api_client_async/models/create_docker_registry.py +120 -0
- daytona_api_client_async/models/create_linked_account.py +103 -0
- daytona_api_client_async/models/create_organization.py +103 -0
- daytona_api_client_async/models/create_organization_invitation.py +115 -0
- daytona_api_client_async/models/create_organization_quota.py +117 -0
- daytona_api_client_async/models/create_organization_role.py +113 -0
- daytona_api_client_async/models/create_runner.py +130 -0
- daytona_api_client_async/models/create_sandbox.py +159 -0
- daytona_api_client_async/models/create_session_request.py +101 -0
- daytona_api_client_async/models/create_snapshot.py +121 -0
- daytona_api_client_async/models/create_user.py +127 -0
- daytona_api_client_async/models/create_volume.py +101 -0
- daytona_api_client_async/models/create_workspace.py +161 -0
- daytona_api_client_async/models/daytona_configuration.py +158 -0
- daytona_api_client_async/models/display_info_response.py +101 -0
- daytona_api_client_async/models/docker_registry.py +123 -0
- daytona_api_client_async/models/download_files.py +101 -0
- daytona_api_client_async/models/empty_response.py +101 -0
- daytona_api_client_async/models/execute_request.py +105 -0
- daytona_api_client_async/models/execute_response.py +103 -0
- daytona_api_client_async/models/file_info.py +115 -0
- daytona_api_client_async/models/file_status.py +107 -0
- daytona_api_client_async/models/git_add_request.py +103 -0
- daytona_api_client_async/models/git_branch_request.py +103 -0
- daytona_api_client_async/models/git_checkout_request.py +103 -0
- daytona_api_client_async/models/git_clone_request.py +111 -0
- daytona_api_client_async/models/git_commit_info.py +109 -0
- daytona_api_client_async/models/git_commit_request.py +109 -0
- daytona_api_client_async/models/git_commit_response.py +101 -0
- daytona_api_client_async/models/git_delete_branch_request.py +103 -0
- daytona_api_client_async/models/git_repo_request.py +105 -0
- daytona_api_client_async/models/git_status.py +117 -0
- daytona_api_client_async/models/health_controller_check200_response.py +154 -0
- daytona_api_client_async/models/health_controller_check200_response_info_value.py +101 -0
- daytona_api_client_async/models/health_controller_check503_response.py +154 -0
- daytona_api_client_async/models/keyboard_hotkey_request.py +101 -0
- daytona_api_client_async/models/keyboard_hotkey_response.py +103 -0
- daytona_api_client_async/models/keyboard_press_request.py +103 -0
- daytona_api_client_async/models/keyboard_press_response.py +105 -0
- daytona_api_client_async/models/keyboard_type_request.py +103 -0
- daytona_api_client_async/models/keyboard_type_response.py +103 -0
- daytona_api_client_async/models/list_branch_response.py +101 -0
- daytona_api_client_async/models/lsp_completion_params.py +117 -0
- daytona_api_client_async/models/lsp_document_request.py +105 -0
- daytona_api_client_async/models/lsp_location.py +107 -0
- daytona_api_client_async/models/lsp_server_request.py +103 -0
- daytona_api_client_async/models/lsp_symbol.py +109 -0
- daytona_api_client_async/models/match.py +105 -0
- daytona_api_client_async/models/mouse_click_request.py +107 -0
- daytona_api_client_async/models/mouse_click_response.py +103 -0
- daytona_api_client_async/models/mouse_drag_request.py +109 -0
- daytona_api_client_async/models/mouse_drag_response.py +103 -0
- daytona_api_client_async/models/mouse_move_request.py +103 -0
- daytona_api_client_async/models/mouse_move_response.py +103 -0
- daytona_api_client_async/models/mouse_position.py +103 -0
- daytona_api_client_async/models/mouse_scroll_request.py +107 -0
- daytona_api_client_async/models/mouse_scroll_response.py +101 -0
- daytona_api_client_async/models/oidc_config.py +105 -0
- daytona_api_client_async/models/organization.py +153 -0
- daytona_api_client_async/models/organization_invitation.py +144 -0
- daytona_api_client_async/models/organization_role.py +122 -0
- daytona_api_client_async/models/organization_sandbox_default_limited_network_egress.py +101 -0
- daytona_api_client_async/models/organization_sandbox_default_network_block_all.py +101 -0
- daytona_api_client_async/models/organization_suspension.py +106 -0
- daytona_api_client_async/models/organization_usage_overview.py +117 -0
- daytona_api_client_async/models/organization_user.py +131 -0
- daytona_api_client_async/models/paginated_audit_logs.py +117 -0
- daytona_api_client_async/models/paginated_sandboxes.py +115 -0
- daytona_api_client_async/models/paginated_snapshots.py +115 -0
- daytona_api_client_async/models/paginated_snapshots_dto.py +115 -0
- daytona_api_client_async/models/paginated_workspaces.py +115 -0
- daytona_api_client_async/models/port_preview_url.py +105 -0
- daytona_api_client_async/models/position.py +103 -0
- daytona_api_client_async/models/posthog_config.py +103 -0
- daytona_api_client_async/models/process_errors_response.py +103 -0
- daytona_api_client_async/models/process_logs_response.py +103 -0
- daytona_api_client_async/models/process_restart_response.py +103 -0
- daytona_api_client_async/models/process_status_response.py +103 -0
- daytona_api_client_async/models/project_dir_response.py +101 -0
- daytona_api_client_async/models/pty_create_request.py +111 -0
- daytona_api_client_async/models/pty_create_response.py +101 -0
- daytona_api_client_async/models/pty_list_response.py +109 -0
- daytona_api_client_async/models/pty_resize_request.py +103 -0
- daytona_api_client_async/models/pty_session_info.py +115 -0
- daytona_api_client_async/models/range.py +110 -0
- daytona_api_client_async/models/rate_limit_config.py +120 -0
- daytona_api_client_async/models/rate_limit_entry.py +103 -0
- daytona_api_client_async/models/region.py +114 -0
- daytona_api_client_async/models/region_quota.py +109 -0
- daytona_api_client_async/models/region_screenshot_response.py +105 -0
- daytona_api_client_async/models/region_usage_overview.py +113 -0
- daytona_api_client_async/models/registry_push_access_dto.py +111 -0
- daytona_api_client_async/models/replace_request.py +105 -0
- daytona_api_client_async/models/replace_result.py +105 -0
- daytona_api_client_async/models/runner.py +153 -0
- daytona_api_client_async/models/runner_region.py +39 -0
- daytona_api_client_async/models/runner_snapshot_dto.py +105 -0
- daytona_api_client_async/models/runner_state.py +41 -0
- daytona_api_client_async/models/sandbox.py +193 -0
- daytona_api_client_async/models/sandbox_class.py +39 -0
- daytona_api_client_async/models/sandbox_created_post_request.py +110 -0
- daytona_api_client_async/models/sandbox_created_post_request_data.py +152 -0
- daytona_api_client_async/models/sandbox_desired_state.py +41 -0
- daytona_api_client_async/models/sandbox_info.py +105 -0
- daytona_api_client_async/models/sandbox_labels.py +101 -0
- daytona_api_client_async/models/sandbox_state.py +52 -0
- daytona_api_client_async/models/sandbox_state_updated_post_request.py +110 -0
- daytona_api_client_async/models/sandbox_state_updated_post_request_data.py +129 -0
- daytona_api_client_async/models/sandbox_state_updated_post_request_data_sandbox.py +115 -0
- daytona_api_client_async/models/sandbox_volume.py +105 -0
- daytona_api_client_async/models/screenshot_response.py +105 -0
- daytona_api_client_async/models/search_files_response.py +101 -0
- daytona_api_client_async/models/send_webhook_dto.py +105 -0
- daytona_api_client_async/models/session.py +116 -0
- daytona_api_client_async/models/session_command_logs_response.py +103 -0
- daytona_api_client_async/models/session_execute_request.py +105 -0
- daytona_api_client_async/models/session_execute_response.py +105 -0
- daytona_api_client_async/models/set_snapshot_general_status_dto.py +101 -0
- daytona_api_client_async/models/snapshot_created_post_request.py +110 -0
- daytona_api_client_async/models/snapshot_created_post_request_data.py +136 -0
- daytona_api_client_async/models/snapshot_dto.py +159 -0
- daytona_api_client_async/models/snapshot_removed_post_request.py +106 -0
- daytona_api_client_async/models/snapshot_state.py +44 -0
- daytona_api_client_async/models/snapshot_state_updated_post_request.py +110 -0
- daytona_api_client_async/models/snapshot_state_updated_post_request_data.py +129 -0
- daytona_api_client_async/models/snapshot_state_updated_post_request_data_snapshot.py +115 -0
- daytona_api_client_async/models/ssh_access_dto.py +112 -0
- daytona_api_client_async/models/ssh_access_validation_dto.py +103 -0
- daytona_api_client_async/models/storage_access_dto.py +111 -0
- daytona_api_client_async/models/update_assigned_organization_roles.py +101 -0
- daytona_api_client_async/models/update_docker_registry.py +109 -0
- daytona_api_client_async/models/update_organization_default_region.py +101 -0
- daytona_api_client_async/models/update_organization_invitation.py +113 -0
- daytona_api_client_async/models/update_organization_member_access.py +110 -0
- daytona_api_client_async/models/update_organization_member_role.py +108 -0
- daytona_api_client_async/models/update_organization_quota.py +162 -0
- daytona_api_client_async/models/update_organization_region_quota.py +120 -0
- daytona_api_client_async/models/update_organization_role.py +113 -0
- daytona_api_client_async/models/update_sandbox_state_dto.py +110 -0
- daytona_api_client_async/models/user.py +118 -0
- daytona_api_client_async/models/user_home_dir_response.py +101 -0
- daytona_api_client_async/models/user_public_key.py +103 -0
- daytona_api_client_async/models/volume_created_post_request.py +110 -0
- daytona_api_client_async/models/volume_created_post_request_data.py +126 -0
- daytona_api_client_async/models/volume_dto.py +126 -0
- daytona_api_client_async/models/volume_state.py +43 -0
- daytona_api_client_async/models/volume_state_updated_post_request.py +110 -0
- daytona_api_client_async/models/volume_state_updated_post_request_data.py +129 -0
- daytona_api_client_async/models/volume_state_updated_post_request_data_volume.py +115 -0
- daytona_api_client_async/models/webhook_app_portal_access.py +101 -0
- daytona_api_client_async/models/webhook_controller_get_app_portal_access200_response.py +101 -0
- daytona_api_client_async/models/webhook_controller_get_initialization_status200_response.py +118 -0
- daytona_api_client_async/models/webhook_controller_get_status200_response.py +101 -0
- daytona_api_client_async/models/webhook_initialization_status.py +121 -0
- daytona_api_client_async/models/windows_response.py +103 -0
- daytona_api_client_async/models/work_dir_response.py +101 -0
- daytona_api_client_async/models/workdir_response.py +101 -0
- daytona_api_client_async/models/workspace.py +215 -0
- daytona_api_client_async/models/workspace_port_preview_url.py +103 -0
- daytona_api_client_async/py.typed +0 -0
- daytona_api_client_async/rest.py +214 -0
- daytona_api_client_async-0.0.0.dev0.dist-info/METADATA +27 -0
- daytona_api_client_async-0.0.0.dev0.dist-info/RECORD +209 -0
- daytona_api_client_async-0.0.0.dev0.dist-info/WHEEL +5 -0
- daytona_api_client_async-0.0.0.dev0.dist-info/licenses/LICENSE +190 -0
- daytona_api_client_async-0.0.0.dev0.dist-info/top_level.txt +1 -0
|
@@ -0,0 +1,105 @@
|
|
|
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
|
+
|
|
16
|
+
from __future__ import annotations
|
|
17
|
+
import pprint
|
|
18
|
+
import re # noqa: F401
|
|
19
|
+
import json
|
|
20
|
+
|
|
21
|
+
from pydantic import BaseModel, ConfigDict, Field, StrictStr
|
|
22
|
+
from typing import Any, ClassVar, Dict, List
|
|
23
|
+
from typing import Optional, Set
|
|
24
|
+
from typing_extensions import Self
|
|
25
|
+
|
|
26
|
+
class ReplaceRequest(BaseModel):
|
|
27
|
+
"""
|
|
28
|
+
ReplaceRequest
|
|
29
|
+
""" # noqa: E501
|
|
30
|
+
files: List[StrictStr]
|
|
31
|
+
pattern: StrictStr
|
|
32
|
+
new_value: StrictStr = Field(alias="newValue")
|
|
33
|
+
additional_properties: Dict[str, Any] = {}
|
|
34
|
+
__properties: ClassVar[List[str]] = ["files", "pattern", "newValue"]
|
|
35
|
+
|
|
36
|
+
model_config = ConfigDict(
|
|
37
|
+
populate_by_name=True,
|
|
38
|
+
validate_assignment=True,
|
|
39
|
+
protected_namespaces=(),
|
|
40
|
+
)
|
|
41
|
+
|
|
42
|
+
|
|
43
|
+
def to_str(self) -> str:
|
|
44
|
+
"""Returns the string representation of the model using alias"""
|
|
45
|
+
return pprint.pformat(self.model_dump(by_alias=True))
|
|
46
|
+
|
|
47
|
+
def to_json(self) -> str:
|
|
48
|
+
"""Returns the JSON representation of the model using alias"""
|
|
49
|
+
# TODO: pydantic v2: use .model_dump_json(by_alias=True, exclude_unset=True) instead
|
|
50
|
+
return json.dumps(self.to_dict())
|
|
51
|
+
|
|
52
|
+
@classmethod
|
|
53
|
+
def from_json(cls, json_str: str) -> Optional[Self]:
|
|
54
|
+
"""Create an instance of ReplaceRequest from a JSON string"""
|
|
55
|
+
return cls.from_dict(json.loads(json_str))
|
|
56
|
+
|
|
57
|
+
def to_dict(self) -> Dict[str, Any]:
|
|
58
|
+
"""Return the dictionary representation of the model using alias.
|
|
59
|
+
|
|
60
|
+
This has the following differences from calling pydantic's
|
|
61
|
+
`self.model_dump(by_alias=True)`:
|
|
62
|
+
|
|
63
|
+
* `None` is only added to the output dict for nullable fields that
|
|
64
|
+
were set at model initialization. Other fields with value `None`
|
|
65
|
+
are ignored.
|
|
66
|
+
* Fields in `self.additional_properties` are added to the output dict.
|
|
67
|
+
"""
|
|
68
|
+
excluded_fields: Set[str] = set([
|
|
69
|
+
"additional_properties",
|
|
70
|
+
])
|
|
71
|
+
|
|
72
|
+
_dict = self.model_dump(
|
|
73
|
+
by_alias=True,
|
|
74
|
+
exclude=excluded_fields,
|
|
75
|
+
exclude_none=True,
|
|
76
|
+
)
|
|
77
|
+
# puts key-value pairs in additional_properties in the top level
|
|
78
|
+
if self.additional_properties is not None:
|
|
79
|
+
for _key, _value in self.additional_properties.items():
|
|
80
|
+
_dict[_key] = _value
|
|
81
|
+
|
|
82
|
+
return _dict
|
|
83
|
+
|
|
84
|
+
@classmethod
|
|
85
|
+
def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
|
|
86
|
+
"""Create an instance of ReplaceRequest from a dict"""
|
|
87
|
+
if obj is None:
|
|
88
|
+
return None
|
|
89
|
+
|
|
90
|
+
if not isinstance(obj, dict):
|
|
91
|
+
return cls.model_validate(obj)
|
|
92
|
+
|
|
93
|
+
_obj = cls.model_validate({
|
|
94
|
+
"files": obj.get("files"),
|
|
95
|
+
"pattern": obj.get("pattern"),
|
|
96
|
+
"newValue": obj.get("newValue")
|
|
97
|
+
})
|
|
98
|
+
# store additional fields in additional_properties
|
|
99
|
+
for _key in obj.keys():
|
|
100
|
+
if _key not in cls.__properties:
|
|
101
|
+
_obj.additional_properties[_key] = obj.get(_key)
|
|
102
|
+
|
|
103
|
+
return _obj
|
|
104
|
+
|
|
105
|
+
|
|
@@ -0,0 +1,105 @@
|
|
|
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
|
+
|
|
16
|
+
from __future__ import annotations
|
|
17
|
+
import pprint
|
|
18
|
+
import re # noqa: F401
|
|
19
|
+
import json
|
|
20
|
+
|
|
21
|
+
from pydantic import BaseModel, ConfigDict, StrictBool, StrictStr
|
|
22
|
+
from typing import Any, ClassVar, Dict, List, Optional
|
|
23
|
+
from typing import Optional, Set
|
|
24
|
+
from typing_extensions import Self
|
|
25
|
+
|
|
26
|
+
class ReplaceResult(BaseModel):
|
|
27
|
+
"""
|
|
28
|
+
ReplaceResult
|
|
29
|
+
""" # noqa: E501
|
|
30
|
+
file: Optional[StrictStr] = None
|
|
31
|
+
success: Optional[StrictBool] = None
|
|
32
|
+
error: Optional[StrictStr] = None
|
|
33
|
+
additional_properties: Dict[str, Any] = {}
|
|
34
|
+
__properties: ClassVar[List[str]] = ["file", "success", "error"]
|
|
35
|
+
|
|
36
|
+
model_config = ConfigDict(
|
|
37
|
+
populate_by_name=True,
|
|
38
|
+
validate_assignment=True,
|
|
39
|
+
protected_namespaces=(),
|
|
40
|
+
)
|
|
41
|
+
|
|
42
|
+
|
|
43
|
+
def to_str(self) -> str:
|
|
44
|
+
"""Returns the string representation of the model using alias"""
|
|
45
|
+
return pprint.pformat(self.model_dump(by_alias=True))
|
|
46
|
+
|
|
47
|
+
def to_json(self) -> str:
|
|
48
|
+
"""Returns the JSON representation of the model using alias"""
|
|
49
|
+
# TODO: pydantic v2: use .model_dump_json(by_alias=True, exclude_unset=True) instead
|
|
50
|
+
return json.dumps(self.to_dict())
|
|
51
|
+
|
|
52
|
+
@classmethod
|
|
53
|
+
def from_json(cls, json_str: str) -> Optional[Self]:
|
|
54
|
+
"""Create an instance of ReplaceResult from a JSON string"""
|
|
55
|
+
return cls.from_dict(json.loads(json_str))
|
|
56
|
+
|
|
57
|
+
def to_dict(self) -> Dict[str, Any]:
|
|
58
|
+
"""Return the dictionary representation of the model using alias.
|
|
59
|
+
|
|
60
|
+
This has the following differences from calling pydantic's
|
|
61
|
+
`self.model_dump(by_alias=True)`:
|
|
62
|
+
|
|
63
|
+
* `None` is only added to the output dict for nullable fields that
|
|
64
|
+
were set at model initialization. Other fields with value `None`
|
|
65
|
+
are ignored.
|
|
66
|
+
* Fields in `self.additional_properties` are added to the output dict.
|
|
67
|
+
"""
|
|
68
|
+
excluded_fields: Set[str] = set([
|
|
69
|
+
"additional_properties",
|
|
70
|
+
])
|
|
71
|
+
|
|
72
|
+
_dict = self.model_dump(
|
|
73
|
+
by_alias=True,
|
|
74
|
+
exclude=excluded_fields,
|
|
75
|
+
exclude_none=True,
|
|
76
|
+
)
|
|
77
|
+
# puts key-value pairs in additional_properties in the top level
|
|
78
|
+
if self.additional_properties is not None:
|
|
79
|
+
for _key, _value in self.additional_properties.items():
|
|
80
|
+
_dict[_key] = _value
|
|
81
|
+
|
|
82
|
+
return _dict
|
|
83
|
+
|
|
84
|
+
@classmethod
|
|
85
|
+
def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
|
|
86
|
+
"""Create an instance of ReplaceResult from a dict"""
|
|
87
|
+
if obj is None:
|
|
88
|
+
return None
|
|
89
|
+
|
|
90
|
+
if not isinstance(obj, dict):
|
|
91
|
+
return cls.model_validate(obj)
|
|
92
|
+
|
|
93
|
+
_obj = cls.model_validate({
|
|
94
|
+
"file": obj.get("file"),
|
|
95
|
+
"success": obj.get("success"),
|
|
96
|
+
"error": obj.get("error")
|
|
97
|
+
})
|
|
98
|
+
# store additional fields in additional_properties
|
|
99
|
+
for _key in obj.keys():
|
|
100
|
+
if _key not in cls.__properties:
|
|
101
|
+
_obj.additional_properties[_key] = obj.get(_key)
|
|
102
|
+
|
|
103
|
+
return _obj
|
|
104
|
+
|
|
105
|
+
|
|
@@ -0,0 +1,153 @@
|
|
|
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
|
+
|
|
16
|
+
from __future__ import annotations
|
|
17
|
+
import pprint
|
|
18
|
+
import re # noqa: F401
|
|
19
|
+
import json
|
|
20
|
+
|
|
21
|
+
from pydantic import BaseModel, ConfigDict, Field, StrictBool, StrictFloat, StrictInt, StrictStr
|
|
22
|
+
from typing import Any, ClassVar, Dict, List, Optional, Union
|
|
23
|
+
from daytona_api_client_async.models.runner_state import RunnerState
|
|
24
|
+
from daytona_api_client_async.models.sandbox_class import SandboxClass
|
|
25
|
+
from typing import Optional, Set
|
|
26
|
+
from typing_extensions import Self
|
|
27
|
+
|
|
28
|
+
class Runner(BaseModel):
|
|
29
|
+
"""
|
|
30
|
+
Runner
|
|
31
|
+
""" # noqa: E501
|
|
32
|
+
id: StrictStr = Field(description="The ID of the runner")
|
|
33
|
+
domain: StrictStr = Field(description="The domain of the runner")
|
|
34
|
+
api_url: StrictStr = Field(description="The API URL of the runner", alias="apiUrl")
|
|
35
|
+
proxy_url: StrictStr = Field(description="The proxy URL of the runner", alias="proxyUrl")
|
|
36
|
+
api_key: StrictStr = Field(description="The API key for the runner", alias="apiKey")
|
|
37
|
+
cpu: Union[StrictFloat, StrictInt] = Field(description="The CPU capacity of the runner")
|
|
38
|
+
memory: Union[StrictFloat, StrictInt] = Field(description="The memory capacity of the runner in GiB")
|
|
39
|
+
disk: Union[StrictFloat, StrictInt] = Field(description="The disk capacity of the runner in GiB")
|
|
40
|
+
gpu: Union[StrictFloat, StrictInt] = Field(description="The GPU capacity of the runner")
|
|
41
|
+
gpu_type: StrictStr = Field(description="The type of GPU", alias="gpuType")
|
|
42
|
+
var_class: SandboxClass = Field(description="The class of the runner", alias="class")
|
|
43
|
+
current_cpu_usage_percentage: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, description="Current CPU usage percentage", alias="currentCpuUsagePercentage")
|
|
44
|
+
current_memory_usage_percentage: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, description="Current RAM usage percentage", alias="currentMemoryUsagePercentage")
|
|
45
|
+
current_disk_usage_percentage: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, description="Current disk usage percentage", alias="currentDiskUsagePercentage")
|
|
46
|
+
current_allocated_cpu: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, description="Current allocated CPU", alias="currentAllocatedCpu")
|
|
47
|
+
current_allocated_memory_gi_b: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, description="Current allocated memory in GiB", alias="currentAllocatedMemoryGiB")
|
|
48
|
+
current_allocated_disk_gi_b: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, description="Current allocated disk in GiB", alias="currentAllocatedDiskGiB")
|
|
49
|
+
current_snapshot_count: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, description="Current snapshot count", alias="currentSnapshotCount")
|
|
50
|
+
availability_score: Optional[Union[StrictFloat, StrictInt]] = Field(default=None, description="Runner availability score", alias="availabilityScore")
|
|
51
|
+
region: StrictStr = Field(description="The region of the runner")
|
|
52
|
+
state: RunnerState = Field(description="The state of the runner")
|
|
53
|
+
last_checked: Optional[StrictStr] = Field(default=None, description="The last time the runner was checked", alias="lastChecked")
|
|
54
|
+
unschedulable: StrictBool = Field(description="Whether the runner is unschedulable")
|
|
55
|
+
created_at: StrictStr = Field(description="The creation timestamp of the runner", alias="createdAt")
|
|
56
|
+
updated_at: StrictStr = Field(description="The last update timestamp of the runner", alias="updatedAt")
|
|
57
|
+
version: StrictStr = Field(description="The version of the runner")
|
|
58
|
+
additional_properties: Dict[str, Any] = {}
|
|
59
|
+
__properties: ClassVar[List[str]] = ["id", "domain", "apiUrl", "proxyUrl", "apiKey", "cpu", "memory", "disk", "gpu", "gpuType", "class", "currentCpuUsagePercentage", "currentMemoryUsagePercentage", "currentDiskUsagePercentage", "currentAllocatedCpu", "currentAllocatedMemoryGiB", "currentAllocatedDiskGiB", "currentSnapshotCount", "availabilityScore", "region", "state", "lastChecked", "unschedulable", "createdAt", "updatedAt", "version"]
|
|
60
|
+
|
|
61
|
+
model_config = ConfigDict(
|
|
62
|
+
populate_by_name=True,
|
|
63
|
+
validate_assignment=True,
|
|
64
|
+
protected_namespaces=(),
|
|
65
|
+
)
|
|
66
|
+
|
|
67
|
+
|
|
68
|
+
def to_str(self) -> str:
|
|
69
|
+
"""Returns the string representation of the model using alias"""
|
|
70
|
+
return pprint.pformat(self.model_dump(by_alias=True))
|
|
71
|
+
|
|
72
|
+
def to_json(self) -> str:
|
|
73
|
+
"""Returns the JSON representation of the model using alias"""
|
|
74
|
+
# TODO: pydantic v2: use .model_dump_json(by_alias=True, exclude_unset=True) instead
|
|
75
|
+
return json.dumps(self.to_dict())
|
|
76
|
+
|
|
77
|
+
@classmethod
|
|
78
|
+
def from_json(cls, json_str: str) -> Optional[Self]:
|
|
79
|
+
"""Create an instance of Runner from a JSON string"""
|
|
80
|
+
return cls.from_dict(json.loads(json_str))
|
|
81
|
+
|
|
82
|
+
def to_dict(self) -> Dict[str, Any]:
|
|
83
|
+
"""Return the dictionary representation of the model using alias.
|
|
84
|
+
|
|
85
|
+
This has the following differences from calling pydantic's
|
|
86
|
+
`self.model_dump(by_alias=True)`:
|
|
87
|
+
|
|
88
|
+
* `None` is only added to the output dict for nullable fields that
|
|
89
|
+
were set at model initialization. Other fields with value `None`
|
|
90
|
+
are ignored.
|
|
91
|
+
* Fields in `self.additional_properties` are added to the output dict.
|
|
92
|
+
"""
|
|
93
|
+
excluded_fields: Set[str] = set([
|
|
94
|
+
"additional_properties",
|
|
95
|
+
])
|
|
96
|
+
|
|
97
|
+
_dict = self.model_dump(
|
|
98
|
+
by_alias=True,
|
|
99
|
+
exclude=excluded_fields,
|
|
100
|
+
exclude_none=True,
|
|
101
|
+
)
|
|
102
|
+
# puts key-value pairs in additional_properties in the top level
|
|
103
|
+
if self.additional_properties is not None:
|
|
104
|
+
for _key, _value in self.additional_properties.items():
|
|
105
|
+
_dict[_key] = _value
|
|
106
|
+
|
|
107
|
+
return _dict
|
|
108
|
+
|
|
109
|
+
@classmethod
|
|
110
|
+
def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
|
|
111
|
+
"""Create an instance of Runner from a dict"""
|
|
112
|
+
if obj is None:
|
|
113
|
+
return None
|
|
114
|
+
|
|
115
|
+
if not isinstance(obj, dict):
|
|
116
|
+
return cls.model_validate(obj)
|
|
117
|
+
|
|
118
|
+
_obj = cls.model_validate({
|
|
119
|
+
"id": obj.get("id"),
|
|
120
|
+
"domain": obj.get("domain"),
|
|
121
|
+
"apiUrl": obj.get("apiUrl"),
|
|
122
|
+
"proxyUrl": obj.get("proxyUrl"),
|
|
123
|
+
"apiKey": obj.get("apiKey"),
|
|
124
|
+
"cpu": obj.get("cpu"),
|
|
125
|
+
"memory": obj.get("memory"),
|
|
126
|
+
"disk": obj.get("disk"),
|
|
127
|
+
"gpu": obj.get("gpu"),
|
|
128
|
+
"gpuType": obj.get("gpuType"),
|
|
129
|
+
"class": obj.get("class"),
|
|
130
|
+
"currentCpuUsagePercentage": obj.get("currentCpuUsagePercentage"),
|
|
131
|
+
"currentMemoryUsagePercentage": obj.get("currentMemoryUsagePercentage"),
|
|
132
|
+
"currentDiskUsagePercentage": obj.get("currentDiskUsagePercentage"),
|
|
133
|
+
"currentAllocatedCpu": obj.get("currentAllocatedCpu"),
|
|
134
|
+
"currentAllocatedMemoryGiB": obj.get("currentAllocatedMemoryGiB"),
|
|
135
|
+
"currentAllocatedDiskGiB": obj.get("currentAllocatedDiskGiB"),
|
|
136
|
+
"currentSnapshotCount": obj.get("currentSnapshotCount"),
|
|
137
|
+
"availabilityScore": obj.get("availabilityScore"),
|
|
138
|
+
"region": obj.get("region"),
|
|
139
|
+
"state": obj.get("state"),
|
|
140
|
+
"lastChecked": obj.get("lastChecked"),
|
|
141
|
+
"unschedulable": obj.get("unschedulable"),
|
|
142
|
+
"createdAt": obj.get("createdAt"),
|
|
143
|
+
"updatedAt": obj.get("updatedAt"),
|
|
144
|
+
"version": obj.get("version")
|
|
145
|
+
})
|
|
146
|
+
# store additional fields in additional_properties
|
|
147
|
+
for _key in obj.keys():
|
|
148
|
+
if _key not in cls.__properties:
|
|
149
|
+
_obj.additional_properties[_key] = obj.get(_key)
|
|
150
|
+
|
|
151
|
+
return _obj
|
|
152
|
+
|
|
153
|
+
|
|
@@ -0,0 +1,39 @@
|
|
|
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
|
+
|
|
16
|
+
from __future__ import annotations
|
|
17
|
+
import json
|
|
18
|
+
from enum import Enum
|
|
19
|
+
from typing_extensions import Self
|
|
20
|
+
|
|
21
|
+
|
|
22
|
+
class RunnerRegion(str, Enum):
|
|
23
|
+
"""
|
|
24
|
+
The region of the runner
|
|
25
|
+
"""
|
|
26
|
+
|
|
27
|
+
"""
|
|
28
|
+
allowed enum values
|
|
29
|
+
"""
|
|
30
|
+
EU = 'eu'
|
|
31
|
+
US = 'us'
|
|
32
|
+
ASIA = 'asia'
|
|
33
|
+
|
|
34
|
+
@classmethod
|
|
35
|
+
def from_json(cls, json_str: str) -> Self:
|
|
36
|
+
"""Create an instance of RunnerRegion from a JSON string"""
|
|
37
|
+
return cls(json.loads(json_str))
|
|
38
|
+
|
|
39
|
+
|
|
@@ -0,0 +1,105 @@
|
|
|
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
|
+
|
|
16
|
+
from __future__ import annotations
|
|
17
|
+
import pprint
|
|
18
|
+
import re # noqa: F401
|
|
19
|
+
import json
|
|
20
|
+
|
|
21
|
+
from pydantic import BaseModel, ConfigDict, Field, StrictStr
|
|
22
|
+
from typing import Any, ClassVar, Dict, List
|
|
23
|
+
from typing import Optional, Set
|
|
24
|
+
from typing_extensions import Self
|
|
25
|
+
|
|
26
|
+
class RunnerSnapshotDto(BaseModel):
|
|
27
|
+
"""
|
|
28
|
+
RunnerSnapshotDto
|
|
29
|
+
""" # noqa: E501
|
|
30
|
+
runner_snapshot_id: StrictStr = Field(description="Runner snapshot ID", alias="runnerSnapshotId")
|
|
31
|
+
runner_id: StrictStr = Field(description="Runner ID", alias="runnerId")
|
|
32
|
+
runner_domain: StrictStr = Field(description="Runner domain", alias="runnerDomain")
|
|
33
|
+
additional_properties: Dict[str, Any] = {}
|
|
34
|
+
__properties: ClassVar[List[str]] = ["runnerSnapshotId", "runnerId", "runnerDomain"]
|
|
35
|
+
|
|
36
|
+
model_config = ConfigDict(
|
|
37
|
+
populate_by_name=True,
|
|
38
|
+
validate_assignment=True,
|
|
39
|
+
protected_namespaces=(),
|
|
40
|
+
)
|
|
41
|
+
|
|
42
|
+
|
|
43
|
+
def to_str(self) -> str:
|
|
44
|
+
"""Returns the string representation of the model using alias"""
|
|
45
|
+
return pprint.pformat(self.model_dump(by_alias=True))
|
|
46
|
+
|
|
47
|
+
def to_json(self) -> str:
|
|
48
|
+
"""Returns the JSON representation of the model using alias"""
|
|
49
|
+
# TODO: pydantic v2: use .model_dump_json(by_alias=True, exclude_unset=True) instead
|
|
50
|
+
return json.dumps(self.to_dict())
|
|
51
|
+
|
|
52
|
+
@classmethod
|
|
53
|
+
def from_json(cls, json_str: str) -> Optional[Self]:
|
|
54
|
+
"""Create an instance of RunnerSnapshotDto from a JSON string"""
|
|
55
|
+
return cls.from_dict(json.loads(json_str))
|
|
56
|
+
|
|
57
|
+
def to_dict(self) -> Dict[str, Any]:
|
|
58
|
+
"""Return the dictionary representation of the model using alias.
|
|
59
|
+
|
|
60
|
+
This has the following differences from calling pydantic's
|
|
61
|
+
`self.model_dump(by_alias=True)`:
|
|
62
|
+
|
|
63
|
+
* `None` is only added to the output dict for nullable fields that
|
|
64
|
+
were set at model initialization. Other fields with value `None`
|
|
65
|
+
are ignored.
|
|
66
|
+
* Fields in `self.additional_properties` are added to the output dict.
|
|
67
|
+
"""
|
|
68
|
+
excluded_fields: Set[str] = set([
|
|
69
|
+
"additional_properties",
|
|
70
|
+
])
|
|
71
|
+
|
|
72
|
+
_dict = self.model_dump(
|
|
73
|
+
by_alias=True,
|
|
74
|
+
exclude=excluded_fields,
|
|
75
|
+
exclude_none=True,
|
|
76
|
+
)
|
|
77
|
+
# puts key-value pairs in additional_properties in the top level
|
|
78
|
+
if self.additional_properties is not None:
|
|
79
|
+
for _key, _value in self.additional_properties.items():
|
|
80
|
+
_dict[_key] = _value
|
|
81
|
+
|
|
82
|
+
return _dict
|
|
83
|
+
|
|
84
|
+
@classmethod
|
|
85
|
+
def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
|
|
86
|
+
"""Create an instance of RunnerSnapshotDto from a dict"""
|
|
87
|
+
if obj is None:
|
|
88
|
+
return None
|
|
89
|
+
|
|
90
|
+
if not isinstance(obj, dict):
|
|
91
|
+
return cls.model_validate(obj)
|
|
92
|
+
|
|
93
|
+
_obj = cls.model_validate({
|
|
94
|
+
"runnerSnapshotId": obj.get("runnerSnapshotId"),
|
|
95
|
+
"runnerId": obj.get("runnerId"),
|
|
96
|
+
"runnerDomain": obj.get("runnerDomain")
|
|
97
|
+
})
|
|
98
|
+
# store additional fields in additional_properties
|
|
99
|
+
for _key in obj.keys():
|
|
100
|
+
if _key not in cls.__properties:
|
|
101
|
+
_obj.additional_properties[_key] = obj.get(_key)
|
|
102
|
+
|
|
103
|
+
return _obj
|
|
104
|
+
|
|
105
|
+
|
|
@@ -0,0 +1,41 @@
|
|
|
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
|
+
|
|
16
|
+
from __future__ import annotations
|
|
17
|
+
import json
|
|
18
|
+
from enum import Enum
|
|
19
|
+
from typing_extensions import Self
|
|
20
|
+
|
|
21
|
+
|
|
22
|
+
class RunnerState(str, Enum):
|
|
23
|
+
"""
|
|
24
|
+
The state of the runner
|
|
25
|
+
"""
|
|
26
|
+
|
|
27
|
+
"""
|
|
28
|
+
allowed enum values
|
|
29
|
+
"""
|
|
30
|
+
INITIALIZING = 'initializing'
|
|
31
|
+
READY = 'ready'
|
|
32
|
+
DISABLED = 'disabled'
|
|
33
|
+
DECOMMISSIONED = 'decommissioned'
|
|
34
|
+
UNRESPONSIVE = 'unresponsive'
|
|
35
|
+
|
|
36
|
+
@classmethod
|
|
37
|
+
def from_json(cls, json_str: str) -> Self:
|
|
38
|
+
"""Create an instance of RunnerState from a JSON string"""
|
|
39
|
+
return cls(json.loads(json_str))
|
|
40
|
+
|
|
41
|
+
|