daytona_toolbox_api_client 0.102.0rc2__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_toolbox_api_client might be problematic. Click here for more details.
- daytona_daemon_api_client/__init__.py +102 -0
- daytona_daemon_api_client/api/__init__.py +11 -0
- daytona_daemon_api_client/api/computer_use_api.py +6077 -0
- daytona_daemon_api_client/api/file_system_api.py +3463 -0
- daytona_daemon_api_client/api/git_api.py +3052 -0
- daytona_daemon_api_client/api/info_api.py +528 -0
- daytona_daemon_api_client/api/lsp_api.py +2027 -0
- daytona_daemon_api_client/api/port_api.py +547 -0
- daytona_daemon_api_client/api/process_api.py +2262 -0
- daytona_daemon_api_client/api_client.py +797 -0
- daytona_daemon_api_client/api_response.py +21 -0
- daytona_daemon_api_client/configuration.py +572 -0
- daytona_daemon_api_client/exceptions.py +216 -0
- daytona_daemon_api_client/models/__init__.py +79 -0
- daytona_daemon_api_client/models/command.py +104 -0
- daytona_daemon_api_client/models/completion_context.py +102 -0
- daytona_daemon_api_client/models/completion_item.py +112 -0
- daytona_daemon_api_client/models/completion_list.py +110 -0
- daytona_daemon_api_client/models/computer_use_start_response.py +115 -0
- daytona_daemon_api_client/models/computer_use_status_response.py +100 -0
- daytona_daemon_api_client/models/computer_use_stop_response.py +115 -0
- daytona_daemon_api_client/models/create_session_request.py +100 -0
- daytona_daemon_api_client/models/display_info.py +110 -0
- daytona_daemon_api_client/models/display_info_response.py +108 -0
- daytona_daemon_api_client/models/execute_request.py +104 -0
- daytona_daemon_api_client/models/execute_response.py +102 -0
- daytona_daemon_api_client/models/file_info.py +114 -0
- daytona_daemon_api_client/models/file_status.py +107 -0
- daytona_daemon_api_client/models/git_add_request.py +102 -0
- daytona_daemon_api_client/models/git_branch_request.py +102 -0
- daytona_daemon_api_client/models/git_checkout_request.py +102 -0
- daytona_daemon_api_client/models/git_clone_request.py +110 -0
- daytona_daemon_api_client/models/git_commit_info.py +108 -0
- daytona_daemon_api_client/models/git_commit_request.py +108 -0
- daytona_daemon_api_client/models/git_commit_response.py +100 -0
- daytona_daemon_api_client/models/git_git_delete_branch_request.py +102 -0
- daytona_daemon_api_client/models/git_repo_request.py +104 -0
- daytona_daemon_api_client/models/git_status.py +116 -0
- daytona_daemon_api_client/models/is_port_in_use_response.py +100 -0
- daytona_daemon_api_client/models/keyboard_hotkey_request.py +100 -0
- daytona_daemon_api_client/models/keyboard_press_request.py +102 -0
- daytona_daemon_api_client/models/keyboard_type_request.py +102 -0
- daytona_daemon_api_client/models/list_branch_response.py +100 -0
- daytona_daemon_api_client/models/lsp_completion_params.py +116 -0
- daytona_daemon_api_client/models/lsp_document_request.py +104 -0
- daytona_daemon_api_client/models/lsp_location.py +106 -0
- daytona_daemon_api_client/models/lsp_position.py +102 -0
- daytona_daemon_api_client/models/lsp_range.py +109 -0
- daytona_daemon_api_client/models/lsp_server_request.py +102 -0
- daytona_daemon_api_client/models/lsp_symbol.py +108 -0
- daytona_daemon_api_client/models/match.py +104 -0
- daytona_daemon_api_client/models/mouse_click_request.py +106 -0
- daytona_daemon_api_client/models/mouse_click_response.py +102 -0
- daytona_daemon_api_client/models/mouse_drag_request.py +108 -0
- daytona_daemon_api_client/models/mouse_drag_response.py +102 -0
- daytona_daemon_api_client/models/mouse_move_request.py +102 -0
- daytona_daemon_api_client/models/mouse_position_response.py +102 -0
- daytona_daemon_api_client/models/mouse_scroll_request.py +106 -0
- daytona_daemon_api_client/models/port_list.py +100 -0
- daytona_daemon_api_client/models/position.py +102 -0
- daytona_daemon_api_client/models/process_errors_response.py +102 -0
- daytona_daemon_api_client/models/process_logs_response.py +102 -0
- daytona_daemon_api_client/models/process_restart_response.py +102 -0
- daytona_daemon_api_client/models/process_status.py +106 -0
- daytona_daemon_api_client/models/process_status_response.py +102 -0
- daytona_daemon_api_client/models/project_dir_response.py +100 -0
- daytona_daemon_api_client/models/replace_request.py +104 -0
- daytona_daemon_api_client/models/replace_result.py +104 -0
- daytona_daemon_api_client/models/screenshot_response.py +108 -0
- daytona_daemon_api_client/models/scroll_response.py +100 -0
- daytona_daemon_api_client/models/search_files_response.py +100 -0
- daytona_daemon_api_client/models/session.py +110 -0
- daytona_daemon_api_client/models/session_execute_request.py +104 -0
- daytona_daemon_api_client/models/session_execute_response.py +108 -0
- daytona_daemon_api_client/models/status.py +43 -0
- daytona_daemon_api_client/models/window_info.py +112 -0
- daytona_daemon_api_client/models/windows_response.py +108 -0
- daytona_daemon_api_client/py.typed +0 -0
- daytona_daemon_api_client/rest.py +258 -0
- daytona_toolbox_api_client/__init__.py +102 -0
- daytona_toolbox_api_client/api/__init__.py +11 -0
- daytona_toolbox_api_client/api/computer_use_api.py +6011 -0
- daytona_toolbox_api_client/api/file_system_api.py +3310 -0
- daytona_toolbox_api_client/api/git_api.py +2970 -0
- daytona_toolbox_api_client/api/info_api.py +528 -0
- daytona_toolbox_api_client/api/lsp_api.py +1972 -0
- daytona_toolbox_api_client/api/port_api.py +544 -0
- daytona_toolbox_api_client/api/process_api.py +2200 -0
- daytona_toolbox_api_client/api_client.py +797 -0
- daytona_toolbox_api_client/api_response.py +21 -0
- daytona_toolbox_api_client/configuration.py +572 -0
- daytona_toolbox_api_client/exceptions.py +216 -0
- daytona_toolbox_api_client/models/__init__.py +79 -0
- daytona_toolbox_api_client/models/command.py +104 -0
- daytona_toolbox_api_client/models/completion_context.py +102 -0
- daytona_toolbox_api_client/models/completion_item.py +112 -0
- daytona_toolbox_api_client/models/completion_list.py +110 -0
- daytona_toolbox_api_client/models/computer_use_start_response.py +115 -0
- daytona_toolbox_api_client/models/computer_use_status_response.py +100 -0
- daytona_toolbox_api_client/models/computer_use_stop_response.py +115 -0
- daytona_toolbox_api_client/models/create_session_request.py +100 -0
- daytona_toolbox_api_client/models/display_info.py +110 -0
- daytona_toolbox_api_client/models/display_info_response.py +108 -0
- daytona_toolbox_api_client/models/execute_request.py +104 -0
- daytona_toolbox_api_client/models/execute_response.py +102 -0
- daytona_toolbox_api_client/models/file_info.py +114 -0
- daytona_toolbox_api_client/models/file_status.py +107 -0
- daytona_toolbox_api_client/models/git_add_request.py +102 -0
- daytona_toolbox_api_client/models/git_branch_request.py +102 -0
- daytona_toolbox_api_client/models/git_checkout_request.py +102 -0
- daytona_toolbox_api_client/models/git_clone_request.py +110 -0
- daytona_toolbox_api_client/models/git_commit_info.py +108 -0
- daytona_toolbox_api_client/models/git_commit_request.py +108 -0
- daytona_toolbox_api_client/models/git_commit_response.py +100 -0
- daytona_toolbox_api_client/models/git_git_delete_branch_request.py +102 -0
- daytona_toolbox_api_client/models/git_repo_request.py +104 -0
- daytona_toolbox_api_client/models/git_status.py +116 -0
- daytona_toolbox_api_client/models/is_port_in_use_response.py +100 -0
- daytona_toolbox_api_client/models/keyboard_hotkey_request.py +100 -0
- daytona_toolbox_api_client/models/keyboard_press_request.py +102 -0
- daytona_toolbox_api_client/models/keyboard_type_request.py +102 -0
- daytona_toolbox_api_client/models/list_branch_response.py +100 -0
- daytona_toolbox_api_client/models/lsp_completion_params.py +116 -0
- daytona_toolbox_api_client/models/lsp_document_request.py +104 -0
- daytona_toolbox_api_client/models/lsp_location.py +106 -0
- daytona_toolbox_api_client/models/lsp_position.py +102 -0
- daytona_toolbox_api_client/models/lsp_range.py +109 -0
- daytona_toolbox_api_client/models/lsp_server_request.py +102 -0
- daytona_toolbox_api_client/models/lsp_symbol.py +108 -0
- daytona_toolbox_api_client/models/match.py +104 -0
- daytona_toolbox_api_client/models/mouse_click_request.py +106 -0
- daytona_toolbox_api_client/models/mouse_click_response.py +102 -0
- daytona_toolbox_api_client/models/mouse_drag_request.py +108 -0
- daytona_toolbox_api_client/models/mouse_drag_response.py +102 -0
- daytona_toolbox_api_client/models/mouse_move_request.py +102 -0
- daytona_toolbox_api_client/models/mouse_position_response.py +102 -0
- daytona_toolbox_api_client/models/mouse_scroll_request.py +106 -0
- daytona_toolbox_api_client/models/port_list.py +100 -0
- daytona_toolbox_api_client/models/position.py +102 -0
- daytona_toolbox_api_client/models/process_errors_response.py +102 -0
- daytona_toolbox_api_client/models/process_logs_response.py +102 -0
- daytona_toolbox_api_client/models/process_restart_response.py +102 -0
- daytona_toolbox_api_client/models/process_status.py +106 -0
- daytona_toolbox_api_client/models/process_status_response.py +102 -0
- daytona_toolbox_api_client/models/project_dir_response.py +100 -0
- daytona_toolbox_api_client/models/replace_request.py +104 -0
- daytona_toolbox_api_client/models/replace_result.py +104 -0
- daytona_toolbox_api_client/models/screenshot_response.py +108 -0
- daytona_toolbox_api_client/models/scroll_response.py +100 -0
- daytona_toolbox_api_client/models/search_files_response.py +100 -0
- daytona_toolbox_api_client/models/session.py +110 -0
- daytona_toolbox_api_client/models/session_execute_request.py +104 -0
- daytona_toolbox_api_client/models/session_execute_response.py +108 -0
- daytona_toolbox_api_client/models/status.py +43 -0
- daytona_toolbox_api_client/models/window_info.py +112 -0
- daytona_toolbox_api_client/models/windows_response.py +108 -0
- daytona_toolbox_api_client/py.typed +0 -0
- daytona_toolbox_api_client/rest.py +258 -0
- daytona_toolbox_api_client-0.102.0rc2.dist-info/METADATA +25 -0
- daytona_toolbox_api_client-0.102.0rc2.dist-info/RECORD +163 -0
- daytona_toolbox_api_client-0.102.0rc2.dist-info/WHEEL +5 -0
- daytona_toolbox_api_client-0.102.0rc2.dist-info/licenses/LICENSE +190 -0
- daytona_toolbox_api_client-0.102.0rc2.dist-info/top_level.txt +2 -0
|
@@ -0,0 +1,108 @@
|
|
|
1
|
+
# coding: utf-8
|
|
2
|
+
|
|
3
|
+
"""
|
|
4
|
+
Daytona Daemon API
|
|
5
|
+
|
|
6
|
+
Daytona Daemon API
|
|
7
|
+
|
|
8
|
+
The version of the OpenAPI document: v0.0.0-dev
|
|
9
|
+
Generated by OpenAPI Generator (https://openapi-generator.tech)
|
|
10
|
+
|
|
11
|
+
Do not edit the class manually.
|
|
12
|
+
""" # noqa: E501
|
|
13
|
+
|
|
14
|
+
|
|
15
|
+
from __future__ import annotations
|
|
16
|
+
import pprint
|
|
17
|
+
import re # noqa: F401
|
|
18
|
+
import json
|
|
19
|
+
|
|
20
|
+
from pydantic import BaseModel, ConfigDict
|
|
21
|
+
from typing import Any, ClassVar, Dict, List, Optional
|
|
22
|
+
from daytona_toolbox_api_client.models.display_info import DisplayInfo
|
|
23
|
+
from typing import Optional, Set
|
|
24
|
+
from typing_extensions import Self
|
|
25
|
+
|
|
26
|
+
class DisplayInfoResponse(BaseModel):
|
|
27
|
+
"""
|
|
28
|
+
DisplayInfoResponse
|
|
29
|
+
""" # noqa: E501
|
|
30
|
+
displays: Optional[List[DisplayInfo]] = None
|
|
31
|
+
additional_properties: Dict[str, Any] = {}
|
|
32
|
+
__properties: ClassVar[List[str]] = ["displays"]
|
|
33
|
+
|
|
34
|
+
model_config = ConfigDict(
|
|
35
|
+
populate_by_name=True,
|
|
36
|
+
validate_assignment=True,
|
|
37
|
+
protected_namespaces=(),
|
|
38
|
+
)
|
|
39
|
+
|
|
40
|
+
|
|
41
|
+
def to_str(self) -> str:
|
|
42
|
+
"""Returns the string representation of the model using alias"""
|
|
43
|
+
return pprint.pformat(self.model_dump(by_alias=True))
|
|
44
|
+
|
|
45
|
+
def to_json(self) -> str:
|
|
46
|
+
"""Returns the JSON representation of the model using alias"""
|
|
47
|
+
# TODO: pydantic v2: use .model_dump_json(by_alias=True, exclude_unset=True) instead
|
|
48
|
+
return json.dumps(self.to_dict())
|
|
49
|
+
|
|
50
|
+
@classmethod
|
|
51
|
+
def from_json(cls, json_str: str) -> Optional[Self]:
|
|
52
|
+
"""Create an instance of DisplayInfoResponse from a JSON string"""
|
|
53
|
+
return cls.from_dict(json.loads(json_str))
|
|
54
|
+
|
|
55
|
+
def to_dict(self) -> Dict[str, Any]:
|
|
56
|
+
"""Return the dictionary representation of the model using alias.
|
|
57
|
+
|
|
58
|
+
This has the following differences from calling pydantic's
|
|
59
|
+
`self.model_dump(by_alias=True)`:
|
|
60
|
+
|
|
61
|
+
* `None` is only added to the output dict for nullable fields that
|
|
62
|
+
were set at model initialization. Other fields with value `None`
|
|
63
|
+
are ignored.
|
|
64
|
+
* Fields in `self.additional_properties` are added to the output dict.
|
|
65
|
+
"""
|
|
66
|
+
excluded_fields: Set[str] = set([
|
|
67
|
+
"additional_properties",
|
|
68
|
+
])
|
|
69
|
+
|
|
70
|
+
_dict = self.model_dump(
|
|
71
|
+
by_alias=True,
|
|
72
|
+
exclude=excluded_fields,
|
|
73
|
+
exclude_none=True,
|
|
74
|
+
)
|
|
75
|
+
# override the default output from pydantic by calling `to_dict()` of each item in displays (list)
|
|
76
|
+
_items = []
|
|
77
|
+
if self.displays:
|
|
78
|
+
for _item_displays in self.displays:
|
|
79
|
+
if _item_displays:
|
|
80
|
+
_items.append(_item_displays.to_dict())
|
|
81
|
+
_dict['displays'] = _items
|
|
82
|
+
# puts key-value pairs in additional_properties in the top level
|
|
83
|
+
if self.additional_properties is not None:
|
|
84
|
+
for _key, _value in self.additional_properties.items():
|
|
85
|
+
_dict[_key] = _value
|
|
86
|
+
|
|
87
|
+
return _dict
|
|
88
|
+
|
|
89
|
+
@classmethod
|
|
90
|
+
def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
|
|
91
|
+
"""Create an instance of DisplayInfoResponse from a dict"""
|
|
92
|
+
if obj is None:
|
|
93
|
+
return None
|
|
94
|
+
|
|
95
|
+
if not isinstance(obj, dict):
|
|
96
|
+
return cls.model_validate(obj)
|
|
97
|
+
|
|
98
|
+
_obj = cls.model_validate({
|
|
99
|
+
"displays": [DisplayInfo.from_dict(_item) for _item in obj["displays"]] if obj.get("displays") is not None else None
|
|
100
|
+
})
|
|
101
|
+
# store additional fields in additional_properties
|
|
102
|
+
for _key in obj.keys():
|
|
103
|
+
if _key not in cls.__properties:
|
|
104
|
+
_obj.additional_properties[_key] = obj.get(_key)
|
|
105
|
+
|
|
106
|
+
return _obj
|
|
107
|
+
|
|
108
|
+
|
|
@@ -0,0 +1,104 @@
|
|
|
1
|
+
# coding: utf-8
|
|
2
|
+
|
|
3
|
+
"""
|
|
4
|
+
Daytona Daemon API
|
|
5
|
+
|
|
6
|
+
Daytona Daemon API
|
|
7
|
+
|
|
8
|
+
The version of the OpenAPI document: v0.0.0-dev
|
|
9
|
+
Generated by OpenAPI Generator (https://openapi-generator.tech)
|
|
10
|
+
|
|
11
|
+
Do not edit the class manually.
|
|
12
|
+
""" # noqa: E501
|
|
13
|
+
|
|
14
|
+
|
|
15
|
+
from __future__ import annotations
|
|
16
|
+
import pprint
|
|
17
|
+
import re # noqa: F401
|
|
18
|
+
import json
|
|
19
|
+
|
|
20
|
+
from pydantic import BaseModel, ConfigDict, Field, StrictInt, StrictStr
|
|
21
|
+
from typing import Any, ClassVar, Dict, List, Optional
|
|
22
|
+
from typing import Optional, Set
|
|
23
|
+
from typing_extensions import Self
|
|
24
|
+
|
|
25
|
+
class ExecuteRequest(BaseModel):
|
|
26
|
+
"""
|
|
27
|
+
ExecuteRequest
|
|
28
|
+
""" # noqa: E501
|
|
29
|
+
command: StrictStr
|
|
30
|
+
cwd: Optional[StrictStr] = Field(default=None, description="Current working directory")
|
|
31
|
+
timeout: Optional[StrictInt] = Field(default=None, description="Timeout in seconds, defaults to 10 seconds")
|
|
32
|
+
additional_properties: Dict[str, Any] = {}
|
|
33
|
+
__properties: ClassVar[List[str]] = ["command", "cwd", "timeout"]
|
|
34
|
+
|
|
35
|
+
model_config = ConfigDict(
|
|
36
|
+
populate_by_name=True,
|
|
37
|
+
validate_assignment=True,
|
|
38
|
+
protected_namespaces=(),
|
|
39
|
+
)
|
|
40
|
+
|
|
41
|
+
|
|
42
|
+
def to_str(self) -> str:
|
|
43
|
+
"""Returns the string representation of the model using alias"""
|
|
44
|
+
return pprint.pformat(self.model_dump(by_alias=True))
|
|
45
|
+
|
|
46
|
+
def to_json(self) -> str:
|
|
47
|
+
"""Returns the JSON representation of the model using alias"""
|
|
48
|
+
# TODO: pydantic v2: use .model_dump_json(by_alias=True, exclude_unset=True) instead
|
|
49
|
+
return json.dumps(self.to_dict())
|
|
50
|
+
|
|
51
|
+
@classmethod
|
|
52
|
+
def from_json(cls, json_str: str) -> Optional[Self]:
|
|
53
|
+
"""Create an instance of ExecuteRequest from a JSON string"""
|
|
54
|
+
return cls.from_dict(json.loads(json_str))
|
|
55
|
+
|
|
56
|
+
def to_dict(self) -> Dict[str, Any]:
|
|
57
|
+
"""Return the dictionary representation of the model using alias.
|
|
58
|
+
|
|
59
|
+
This has the following differences from calling pydantic's
|
|
60
|
+
`self.model_dump(by_alias=True)`:
|
|
61
|
+
|
|
62
|
+
* `None` is only added to the output dict for nullable fields that
|
|
63
|
+
were set at model initialization. Other fields with value `None`
|
|
64
|
+
are ignored.
|
|
65
|
+
* Fields in `self.additional_properties` are added to the output dict.
|
|
66
|
+
"""
|
|
67
|
+
excluded_fields: Set[str] = set([
|
|
68
|
+
"additional_properties",
|
|
69
|
+
])
|
|
70
|
+
|
|
71
|
+
_dict = self.model_dump(
|
|
72
|
+
by_alias=True,
|
|
73
|
+
exclude=excluded_fields,
|
|
74
|
+
exclude_none=True,
|
|
75
|
+
)
|
|
76
|
+
# puts key-value pairs in additional_properties in the top level
|
|
77
|
+
if self.additional_properties is not None:
|
|
78
|
+
for _key, _value in self.additional_properties.items():
|
|
79
|
+
_dict[_key] = _value
|
|
80
|
+
|
|
81
|
+
return _dict
|
|
82
|
+
|
|
83
|
+
@classmethod
|
|
84
|
+
def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
|
|
85
|
+
"""Create an instance of ExecuteRequest from a dict"""
|
|
86
|
+
if obj is None:
|
|
87
|
+
return None
|
|
88
|
+
|
|
89
|
+
if not isinstance(obj, dict):
|
|
90
|
+
return cls.model_validate(obj)
|
|
91
|
+
|
|
92
|
+
_obj = cls.model_validate({
|
|
93
|
+
"command": obj.get("command"),
|
|
94
|
+
"cwd": obj.get("cwd"),
|
|
95
|
+
"timeout": obj.get("timeout")
|
|
96
|
+
})
|
|
97
|
+
# store additional fields in additional_properties
|
|
98
|
+
for _key in obj.keys():
|
|
99
|
+
if _key not in cls.__properties:
|
|
100
|
+
_obj.additional_properties[_key] = obj.get(_key)
|
|
101
|
+
|
|
102
|
+
return _obj
|
|
103
|
+
|
|
104
|
+
|
|
@@ -0,0 +1,102 @@
|
|
|
1
|
+
# coding: utf-8
|
|
2
|
+
|
|
3
|
+
"""
|
|
4
|
+
Daytona Daemon API
|
|
5
|
+
|
|
6
|
+
Daytona Daemon API
|
|
7
|
+
|
|
8
|
+
The version of the OpenAPI document: v0.0.0-dev
|
|
9
|
+
Generated by OpenAPI Generator (https://openapi-generator.tech)
|
|
10
|
+
|
|
11
|
+
Do not edit the class manually.
|
|
12
|
+
""" # noqa: E501
|
|
13
|
+
|
|
14
|
+
|
|
15
|
+
from __future__ import annotations
|
|
16
|
+
import pprint
|
|
17
|
+
import re # noqa: F401
|
|
18
|
+
import json
|
|
19
|
+
|
|
20
|
+
from pydantic import BaseModel, ConfigDict, Field, StrictInt, StrictStr
|
|
21
|
+
from typing import Any, ClassVar, Dict, List
|
|
22
|
+
from typing import Optional, Set
|
|
23
|
+
from typing_extensions import Self
|
|
24
|
+
|
|
25
|
+
class ExecuteResponse(BaseModel):
|
|
26
|
+
"""
|
|
27
|
+
ExecuteResponse
|
|
28
|
+
""" # noqa: E501
|
|
29
|
+
exit_code: StrictInt = Field(alias="exitCode")
|
|
30
|
+
result: StrictStr
|
|
31
|
+
additional_properties: Dict[str, Any] = {}
|
|
32
|
+
__properties: ClassVar[List[str]] = ["exitCode", "result"]
|
|
33
|
+
|
|
34
|
+
model_config = ConfigDict(
|
|
35
|
+
populate_by_name=True,
|
|
36
|
+
validate_assignment=True,
|
|
37
|
+
protected_namespaces=(),
|
|
38
|
+
)
|
|
39
|
+
|
|
40
|
+
|
|
41
|
+
def to_str(self) -> str:
|
|
42
|
+
"""Returns the string representation of the model using alias"""
|
|
43
|
+
return pprint.pformat(self.model_dump(by_alias=True))
|
|
44
|
+
|
|
45
|
+
def to_json(self) -> str:
|
|
46
|
+
"""Returns the JSON representation of the model using alias"""
|
|
47
|
+
# TODO: pydantic v2: use .model_dump_json(by_alias=True, exclude_unset=True) instead
|
|
48
|
+
return json.dumps(self.to_dict())
|
|
49
|
+
|
|
50
|
+
@classmethod
|
|
51
|
+
def from_json(cls, json_str: str) -> Optional[Self]:
|
|
52
|
+
"""Create an instance of ExecuteResponse from a JSON string"""
|
|
53
|
+
return cls.from_dict(json.loads(json_str))
|
|
54
|
+
|
|
55
|
+
def to_dict(self) -> Dict[str, Any]:
|
|
56
|
+
"""Return the dictionary representation of the model using alias.
|
|
57
|
+
|
|
58
|
+
This has the following differences from calling pydantic's
|
|
59
|
+
`self.model_dump(by_alias=True)`:
|
|
60
|
+
|
|
61
|
+
* `None` is only added to the output dict for nullable fields that
|
|
62
|
+
were set at model initialization. Other fields with value `None`
|
|
63
|
+
are ignored.
|
|
64
|
+
* Fields in `self.additional_properties` are added to the output dict.
|
|
65
|
+
"""
|
|
66
|
+
excluded_fields: Set[str] = set([
|
|
67
|
+
"additional_properties",
|
|
68
|
+
])
|
|
69
|
+
|
|
70
|
+
_dict = self.model_dump(
|
|
71
|
+
by_alias=True,
|
|
72
|
+
exclude=excluded_fields,
|
|
73
|
+
exclude_none=True,
|
|
74
|
+
)
|
|
75
|
+
# puts key-value pairs in additional_properties in the top level
|
|
76
|
+
if self.additional_properties is not None:
|
|
77
|
+
for _key, _value in self.additional_properties.items():
|
|
78
|
+
_dict[_key] = _value
|
|
79
|
+
|
|
80
|
+
return _dict
|
|
81
|
+
|
|
82
|
+
@classmethod
|
|
83
|
+
def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
|
|
84
|
+
"""Create an instance of ExecuteResponse from a dict"""
|
|
85
|
+
if obj is None:
|
|
86
|
+
return None
|
|
87
|
+
|
|
88
|
+
if not isinstance(obj, dict):
|
|
89
|
+
return cls.model_validate(obj)
|
|
90
|
+
|
|
91
|
+
_obj = cls.model_validate({
|
|
92
|
+
"exitCode": obj.get("exitCode"),
|
|
93
|
+
"result": obj.get("result")
|
|
94
|
+
})
|
|
95
|
+
# store additional fields in additional_properties
|
|
96
|
+
for _key in obj.keys():
|
|
97
|
+
if _key not in cls.__properties:
|
|
98
|
+
_obj.additional_properties[_key] = obj.get(_key)
|
|
99
|
+
|
|
100
|
+
return _obj
|
|
101
|
+
|
|
102
|
+
|
|
@@ -0,0 +1,114 @@
|
|
|
1
|
+
# coding: utf-8
|
|
2
|
+
|
|
3
|
+
"""
|
|
4
|
+
Daytona Daemon API
|
|
5
|
+
|
|
6
|
+
Daytona Daemon API
|
|
7
|
+
|
|
8
|
+
The version of the OpenAPI document: v0.0.0-dev
|
|
9
|
+
Generated by OpenAPI Generator (https://openapi-generator.tech)
|
|
10
|
+
|
|
11
|
+
Do not edit the class manually.
|
|
12
|
+
""" # noqa: E501
|
|
13
|
+
|
|
14
|
+
|
|
15
|
+
from __future__ import annotations
|
|
16
|
+
import pprint
|
|
17
|
+
import re # noqa: F401
|
|
18
|
+
import json
|
|
19
|
+
|
|
20
|
+
from pydantic import BaseModel, ConfigDict, Field, StrictBool, StrictInt, StrictStr
|
|
21
|
+
from typing import Any, ClassVar, Dict, List
|
|
22
|
+
from typing import Optional, Set
|
|
23
|
+
from typing_extensions import Self
|
|
24
|
+
|
|
25
|
+
class FileInfo(BaseModel):
|
|
26
|
+
"""
|
|
27
|
+
FileInfo
|
|
28
|
+
""" # noqa: E501
|
|
29
|
+
group: StrictStr
|
|
30
|
+
is_dir: StrictBool = Field(alias="isDir")
|
|
31
|
+
mod_time: StrictStr = Field(alias="modTime")
|
|
32
|
+
mode: StrictStr
|
|
33
|
+
name: StrictStr
|
|
34
|
+
owner: StrictStr
|
|
35
|
+
permissions: StrictStr
|
|
36
|
+
size: StrictInt
|
|
37
|
+
additional_properties: Dict[str, Any] = {}
|
|
38
|
+
__properties: ClassVar[List[str]] = ["group", "isDir", "modTime", "mode", "name", "owner", "permissions", "size"]
|
|
39
|
+
|
|
40
|
+
model_config = ConfigDict(
|
|
41
|
+
populate_by_name=True,
|
|
42
|
+
validate_assignment=True,
|
|
43
|
+
protected_namespaces=(),
|
|
44
|
+
)
|
|
45
|
+
|
|
46
|
+
|
|
47
|
+
def to_str(self) -> str:
|
|
48
|
+
"""Returns the string representation of the model using alias"""
|
|
49
|
+
return pprint.pformat(self.model_dump(by_alias=True))
|
|
50
|
+
|
|
51
|
+
def to_json(self) -> str:
|
|
52
|
+
"""Returns the JSON representation of the model using alias"""
|
|
53
|
+
# TODO: pydantic v2: use .model_dump_json(by_alias=True, exclude_unset=True) instead
|
|
54
|
+
return json.dumps(self.to_dict())
|
|
55
|
+
|
|
56
|
+
@classmethod
|
|
57
|
+
def from_json(cls, json_str: str) -> Optional[Self]:
|
|
58
|
+
"""Create an instance of FileInfo from a JSON string"""
|
|
59
|
+
return cls.from_dict(json.loads(json_str))
|
|
60
|
+
|
|
61
|
+
def to_dict(self) -> Dict[str, Any]:
|
|
62
|
+
"""Return the dictionary representation of the model using alias.
|
|
63
|
+
|
|
64
|
+
This has the following differences from calling pydantic's
|
|
65
|
+
`self.model_dump(by_alias=True)`:
|
|
66
|
+
|
|
67
|
+
* `None` is only added to the output dict for nullable fields that
|
|
68
|
+
were set at model initialization. Other fields with value `None`
|
|
69
|
+
are ignored.
|
|
70
|
+
* Fields in `self.additional_properties` are added to the output dict.
|
|
71
|
+
"""
|
|
72
|
+
excluded_fields: Set[str] = set([
|
|
73
|
+
"additional_properties",
|
|
74
|
+
])
|
|
75
|
+
|
|
76
|
+
_dict = self.model_dump(
|
|
77
|
+
by_alias=True,
|
|
78
|
+
exclude=excluded_fields,
|
|
79
|
+
exclude_none=True,
|
|
80
|
+
)
|
|
81
|
+
# puts key-value pairs in additional_properties in the top level
|
|
82
|
+
if self.additional_properties is not None:
|
|
83
|
+
for _key, _value in self.additional_properties.items():
|
|
84
|
+
_dict[_key] = _value
|
|
85
|
+
|
|
86
|
+
return _dict
|
|
87
|
+
|
|
88
|
+
@classmethod
|
|
89
|
+
def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
|
|
90
|
+
"""Create an instance of FileInfo from a dict"""
|
|
91
|
+
if obj is None:
|
|
92
|
+
return None
|
|
93
|
+
|
|
94
|
+
if not isinstance(obj, dict):
|
|
95
|
+
return cls.model_validate(obj)
|
|
96
|
+
|
|
97
|
+
_obj = cls.model_validate({
|
|
98
|
+
"group": obj.get("group"),
|
|
99
|
+
"isDir": obj.get("isDir"),
|
|
100
|
+
"modTime": obj.get("modTime"),
|
|
101
|
+
"mode": obj.get("mode"),
|
|
102
|
+
"name": obj.get("name"),
|
|
103
|
+
"owner": obj.get("owner"),
|
|
104
|
+
"permissions": obj.get("permissions"),
|
|
105
|
+
"size": obj.get("size")
|
|
106
|
+
})
|
|
107
|
+
# store additional fields in additional_properties
|
|
108
|
+
for _key in obj.keys():
|
|
109
|
+
if _key not in cls.__properties:
|
|
110
|
+
_obj.additional_properties[_key] = obj.get(_key)
|
|
111
|
+
|
|
112
|
+
return _obj
|
|
113
|
+
|
|
114
|
+
|
|
@@ -0,0 +1,107 @@
|
|
|
1
|
+
# coding: utf-8
|
|
2
|
+
|
|
3
|
+
"""
|
|
4
|
+
Daytona Daemon API
|
|
5
|
+
|
|
6
|
+
Daytona Daemon API
|
|
7
|
+
|
|
8
|
+
The version of the OpenAPI document: v0.0.0-dev
|
|
9
|
+
Generated by OpenAPI Generator (https://openapi-generator.tech)
|
|
10
|
+
|
|
11
|
+
Do not edit the class manually.
|
|
12
|
+
""" # noqa: E501
|
|
13
|
+
|
|
14
|
+
|
|
15
|
+
from __future__ import annotations
|
|
16
|
+
import pprint
|
|
17
|
+
import re # noqa: F401
|
|
18
|
+
import json
|
|
19
|
+
|
|
20
|
+
from pydantic import BaseModel, ConfigDict, StrictStr
|
|
21
|
+
from typing import Any, ClassVar, Dict, List
|
|
22
|
+
from daytona_toolbox_api_client.models.status import Status
|
|
23
|
+
from typing import Optional, Set
|
|
24
|
+
from typing_extensions import Self
|
|
25
|
+
|
|
26
|
+
class FileStatus(BaseModel):
|
|
27
|
+
"""
|
|
28
|
+
FileStatus
|
|
29
|
+
""" # noqa: E501
|
|
30
|
+
extra: StrictStr
|
|
31
|
+
name: StrictStr
|
|
32
|
+
staging: Status
|
|
33
|
+
worktree: Status
|
|
34
|
+
additional_properties: Dict[str, Any] = {}
|
|
35
|
+
__properties: ClassVar[List[str]] = ["extra", "name", "staging", "worktree"]
|
|
36
|
+
|
|
37
|
+
model_config = ConfigDict(
|
|
38
|
+
populate_by_name=True,
|
|
39
|
+
validate_assignment=True,
|
|
40
|
+
protected_namespaces=(),
|
|
41
|
+
)
|
|
42
|
+
|
|
43
|
+
|
|
44
|
+
def to_str(self) -> str:
|
|
45
|
+
"""Returns the string representation of the model using alias"""
|
|
46
|
+
return pprint.pformat(self.model_dump(by_alias=True))
|
|
47
|
+
|
|
48
|
+
def to_json(self) -> str:
|
|
49
|
+
"""Returns the JSON representation of the model using alias"""
|
|
50
|
+
# TODO: pydantic v2: use .model_dump_json(by_alias=True, exclude_unset=True) instead
|
|
51
|
+
return json.dumps(self.to_dict())
|
|
52
|
+
|
|
53
|
+
@classmethod
|
|
54
|
+
def from_json(cls, json_str: str) -> Optional[Self]:
|
|
55
|
+
"""Create an instance of FileStatus from a JSON string"""
|
|
56
|
+
return cls.from_dict(json.loads(json_str))
|
|
57
|
+
|
|
58
|
+
def to_dict(self) -> Dict[str, Any]:
|
|
59
|
+
"""Return the dictionary representation of the model using alias.
|
|
60
|
+
|
|
61
|
+
This has the following differences from calling pydantic's
|
|
62
|
+
`self.model_dump(by_alias=True)`:
|
|
63
|
+
|
|
64
|
+
* `None` is only added to the output dict for nullable fields that
|
|
65
|
+
were set at model initialization. Other fields with value `None`
|
|
66
|
+
are ignored.
|
|
67
|
+
* Fields in `self.additional_properties` are added to the output dict.
|
|
68
|
+
"""
|
|
69
|
+
excluded_fields: Set[str] = set([
|
|
70
|
+
"additional_properties",
|
|
71
|
+
])
|
|
72
|
+
|
|
73
|
+
_dict = self.model_dump(
|
|
74
|
+
by_alias=True,
|
|
75
|
+
exclude=excluded_fields,
|
|
76
|
+
exclude_none=True,
|
|
77
|
+
)
|
|
78
|
+
# puts key-value pairs in additional_properties in the top level
|
|
79
|
+
if self.additional_properties is not None:
|
|
80
|
+
for _key, _value in self.additional_properties.items():
|
|
81
|
+
_dict[_key] = _value
|
|
82
|
+
|
|
83
|
+
return _dict
|
|
84
|
+
|
|
85
|
+
@classmethod
|
|
86
|
+
def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
|
|
87
|
+
"""Create an instance of FileStatus from a dict"""
|
|
88
|
+
if obj is None:
|
|
89
|
+
return None
|
|
90
|
+
|
|
91
|
+
if not isinstance(obj, dict):
|
|
92
|
+
return cls.model_validate(obj)
|
|
93
|
+
|
|
94
|
+
_obj = cls.model_validate({
|
|
95
|
+
"extra": obj.get("extra"),
|
|
96
|
+
"name": obj.get("name"),
|
|
97
|
+
"staging": obj.get("staging"),
|
|
98
|
+
"worktree": obj.get("worktree")
|
|
99
|
+
})
|
|
100
|
+
# store additional fields in additional_properties
|
|
101
|
+
for _key in obj.keys():
|
|
102
|
+
if _key not in cls.__properties:
|
|
103
|
+
_obj.additional_properties[_key] = obj.get(_key)
|
|
104
|
+
|
|
105
|
+
return _obj
|
|
106
|
+
|
|
107
|
+
|
|
@@ -0,0 +1,102 @@
|
|
|
1
|
+
# coding: utf-8
|
|
2
|
+
|
|
3
|
+
"""
|
|
4
|
+
Daytona Daemon API
|
|
5
|
+
|
|
6
|
+
Daytona Daemon API
|
|
7
|
+
|
|
8
|
+
The version of the OpenAPI document: v0.0.0-dev
|
|
9
|
+
Generated by OpenAPI Generator (https://openapi-generator.tech)
|
|
10
|
+
|
|
11
|
+
Do not edit the class manually.
|
|
12
|
+
""" # noqa: E501
|
|
13
|
+
|
|
14
|
+
|
|
15
|
+
from __future__ import annotations
|
|
16
|
+
import pprint
|
|
17
|
+
import re # noqa: F401
|
|
18
|
+
import json
|
|
19
|
+
|
|
20
|
+
from pydantic import BaseModel, ConfigDict, Field, StrictStr
|
|
21
|
+
from typing import Any, ClassVar, Dict, List
|
|
22
|
+
from typing import Optional, Set
|
|
23
|
+
from typing_extensions import Self
|
|
24
|
+
|
|
25
|
+
class GitAddRequest(BaseModel):
|
|
26
|
+
"""
|
|
27
|
+
GitAddRequest
|
|
28
|
+
""" # noqa: E501
|
|
29
|
+
files: List[StrictStr] = Field(description="files to add (use . for all files)")
|
|
30
|
+
path: StrictStr
|
|
31
|
+
additional_properties: Dict[str, Any] = {}
|
|
32
|
+
__properties: ClassVar[List[str]] = ["files", "path"]
|
|
33
|
+
|
|
34
|
+
model_config = ConfigDict(
|
|
35
|
+
populate_by_name=True,
|
|
36
|
+
validate_assignment=True,
|
|
37
|
+
protected_namespaces=(),
|
|
38
|
+
)
|
|
39
|
+
|
|
40
|
+
|
|
41
|
+
def to_str(self) -> str:
|
|
42
|
+
"""Returns the string representation of the model using alias"""
|
|
43
|
+
return pprint.pformat(self.model_dump(by_alias=True))
|
|
44
|
+
|
|
45
|
+
def to_json(self) -> str:
|
|
46
|
+
"""Returns the JSON representation of the model using alias"""
|
|
47
|
+
# TODO: pydantic v2: use .model_dump_json(by_alias=True, exclude_unset=True) instead
|
|
48
|
+
return json.dumps(self.to_dict())
|
|
49
|
+
|
|
50
|
+
@classmethod
|
|
51
|
+
def from_json(cls, json_str: str) -> Optional[Self]:
|
|
52
|
+
"""Create an instance of GitAddRequest from a JSON string"""
|
|
53
|
+
return cls.from_dict(json.loads(json_str))
|
|
54
|
+
|
|
55
|
+
def to_dict(self) -> Dict[str, Any]:
|
|
56
|
+
"""Return the dictionary representation of the model using alias.
|
|
57
|
+
|
|
58
|
+
This has the following differences from calling pydantic's
|
|
59
|
+
`self.model_dump(by_alias=True)`:
|
|
60
|
+
|
|
61
|
+
* `None` is only added to the output dict for nullable fields that
|
|
62
|
+
were set at model initialization. Other fields with value `None`
|
|
63
|
+
are ignored.
|
|
64
|
+
* Fields in `self.additional_properties` are added to the output dict.
|
|
65
|
+
"""
|
|
66
|
+
excluded_fields: Set[str] = set([
|
|
67
|
+
"additional_properties",
|
|
68
|
+
])
|
|
69
|
+
|
|
70
|
+
_dict = self.model_dump(
|
|
71
|
+
by_alias=True,
|
|
72
|
+
exclude=excluded_fields,
|
|
73
|
+
exclude_none=True,
|
|
74
|
+
)
|
|
75
|
+
# puts key-value pairs in additional_properties in the top level
|
|
76
|
+
if self.additional_properties is not None:
|
|
77
|
+
for _key, _value in self.additional_properties.items():
|
|
78
|
+
_dict[_key] = _value
|
|
79
|
+
|
|
80
|
+
return _dict
|
|
81
|
+
|
|
82
|
+
@classmethod
|
|
83
|
+
def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
|
|
84
|
+
"""Create an instance of GitAddRequest from a dict"""
|
|
85
|
+
if obj is None:
|
|
86
|
+
return None
|
|
87
|
+
|
|
88
|
+
if not isinstance(obj, dict):
|
|
89
|
+
return cls.model_validate(obj)
|
|
90
|
+
|
|
91
|
+
_obj = cls.model_validate({
|
|
92
|
+
"files": obj.get("files"),
|
|
93
|
+
"path": obj.get("path")
|
|
94
|
+
})
|
|
95
|
+
# store additional fields in additional_properties
|
|
96
|
+
for _key in obj.keys():
|
|
97
|
+
if _key not in cls.__properties:
|
|
98
|
+
_obj.additional_properties[_key] = obj.get(_key)
|
|
99
|
+
|
|
100
|
+
return _obj
|
|
101
|
+
|
|
102
|
+
|