daytona_api_client 0.25.5__py3-none-any.whl → 0.26.0__py3-none-any.whl

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.

Potentially problematic release.


This version of daytona_api_client might be problematic. Click here for more details.

Files changed (50) hide show
  1. daytona_api_client/__init__.py +12 -1
  2. daytona_api_client/api/__init__.py +2 -0
  3. daytona_api_client/api/default_api.py +1884 -0
  4. daytona_api_client/api/health_api.py +282 -0
  5. daytona_api_client/api/organizations_api.py +6 -6
  6. daytona_api_client/api/sandbox_api.py +855 -2
  7. daytona_api_client/api/webhooks_api.py +1704 -0
  8. daytona_api_client/models/__init__.py +10 -1
  9. daytona_api_client/models/create_audit_log.py +2 -2
  10. daytona_api_client/models/create_sandbox.py +5 -1
  11. daytona_api_client/models/health_controller_check200_response.py +154 -0
  12. daytona_api_client/models/{account_provider_dto.py → health_controller_check200_response_info_value.py} +23 -23
  13. daytona_api_client/models/health_controller_check503_response.py +154 -0
  14. daytona_api_client/models/{usage_overview.py → organization_usage_overview.py} +14 -8
  15. daytona_api_client/models/sandbox.py +5 -1
  16. daytona_api_client/models/sandbox_created_post_request.py +110 -0
  17. daytona_api_client/models/sandbox_created_post_request_data.py +152 -0
  18. daytona_api_client/models/sandbox_state.py +1 -1
  19. daytona_api_client/models/sandbox_state_updated_post_request.py +110 -0
  20. daytona_api_client/models/sandbox_state_updated_post_request_data.py +129 -0
  21. daytona_api_client/models/sandbox_state_updated_post_request_data_sandbox.py +115 -0
  22. daytona_api_client/models/send_webhook_dto.py +105 -0
  23. daytona_api_client/models/snapshot_created_post_request.py +110 -0
  24. daytona_api_client/models/snapshot_created_post_request_data.py +136 -0
  25. daytona_api_client/models/{get_build_logs400_response.py → snapshot_removed_post_request.py} +31 -26
  26. daytona_api_client/models/snapshot_state_updated_post_request.py +110 -0
  27. daytona_api_client/models/snapshot_state_updated_post_request_data.py +129 -0
  28. daytona_api_client/models/snapshot_state_updated_post_request_data_snapshot.py +115 -0
  29. daytona_api_client/models/ssh_access_dto.py +112 -0
  30. daytona_api_client/models/ssh_access_validation_dto.py +107 -0
  31. daytona_api_client/models/volume_created_post_request.py +110 -0
  32. daytona_api_client/models/{volume.py → volume_created_post_request_data.py} +48 -55
  33. daytona_api_client/models/volume_state_updated_post_request.py +110 -0
  34. daytona_api_client/models/volume_state_updated_post_request_data.py +129 -0
  35. daytona_api_client/models/volume_state_updated_post_request_data_volume.py +115 -0
  36. daytona_api_client/models/{download_files.py → webhook_app_portal_access.py} +7 -7
  37. daytona_api_client/models/{upload_file.py → webhook_controller_get_app_portal_access200_response.py} +26 -26
  38. daytona_api_client/models/webhook_controller_get_initialization_status200_response.py +118 -0
  39. daytona_api_client/models/{toggle_state.py → webhook_controller_get_status200_response.py} +7 -7
  40. daytona_api_client/models/webhook_initialization_status.py +121 -0
  41. daytona_api_client/models/workspace.py +5 -1
  42. {daytona_api_client-0.25.5.dist-info → daytona_api_client-0.26.0.dist-info}/METADATA +1 -1
  43. {daytona_api_client-0.25.5.dist-info → daytona_api_client-0.26.0.dist-info}/RECORD +46 -26
  44. daytona_api_client/models/build_snapshot.py +0 -118
  45. daytona_api_client/models/upload_file_dto.py +0 -101
  46. daytona_api_client/models/upload_file_request_file.py +0 -159
  47. daytona_api_client/models/upload_files_multi_request_files_inner.py +0 -101
  48. {daytona_api_client-0.25.5.dist-info → daytona_api_client-0.26.0.dist-info}/WHEEL +0 -0
  49. {daytona_api_client-0.25.5.dist-info → daytona_api_client-0.26.0.dist-info}/licenses/LICENSE +0 -0
  50. {daytona_api_client-0.25.5.dist-info → daytona_api_client-0.26.0.dist-info}/top_level.txt +0 -0
@@ -1,101 +0,0 @@
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
-
18
- import json
19
- import pprint
20
- import re # noqa: F401
21
- from typing import Any, ClassVar, Dict, List, Optional, Set, Tuple, Union
22
-
23
- from pydantic import BaseModel, ConfigDict, StrictBytes, StrictStr
24
- from typing_extensions import Self
25
-
26
-
27
- class UploadFileDto(BaseModel):
28
- """
29
- UploadFileDto
30
- """ # noqa: E501
31
-
32
- file: Union[StrictBytes, StrictStr, Tuple[StrictStr, StrictBytes]]
33
- path: StrictStr
34
- additional_properties: Dict[str, Any] = {}
35
- __properties: ClassVar[List[str]] = ["file", "path"]
36
-
37
- model_config = ConfigDict(
38
- populate_by_name=True,
39
- validate_assignment=True,
40
- protected_namespaces=(),
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 UploadFileDto 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
- [
70
- "additional_properties",
71
- ]
72
- )
73
-
74
- _dict = self.model_dump(
75
- by_alias=True,
76
- exclude=excluded_fields,
77
- exclude_none=True,
78
- )
79
- # puts key-value pairs in additional_properties in the top level
80
- if self.additional_properties is not None:
81
- for _key, _value in self.additional_properties.items():
82
- _dict[_key] = _value
83
-
84
- return _dict
85
-
86
- @classmethod
87
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
88
- """Create an instance of UploadFileDto from a dict"""
89
- if obj is None:
90
- return None
91
-
92
- if not isinstance(obj, dict):
93
- return cls.model_validate(obj)
94
-
95
- _obj = cls.model_validate({"file": obj.get("file"), "path": obj.get("path")})
96
- # store additional fields in additional_properties
97
- for _key in obj.keys():
98
- if _key not in cls.__properties:
99
- _obj.additional_properties[_key] = obj.get(_key)
100
-
101
- return _obj
@@ -1,159 +0,0 @@
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
-
18
- import json
19
- import pprint
20
- from typing import Any, Dict, List, Optional, Set, Tuple, Union
21
-
22
- from pydantic import BaseModel, ConfigDict, Field, StrictBytes, StrictStr, ValidationError, field_validator
23
- from typing_extensions import Literal, Self
24
-
25
- UPLOADFILEREQUESTFILE_ONE_OF_SCHEMAS = ["Dict[str, object]", "bytearray"]
26
-
27
-
28
- class UploadFileRequestFile(BaseModel):
29
- """
30
- File to upload. Supports file streaming and various file object types.
31
- """
32
-
33
- # data type: bytearray
34
- oneof_schema_1_validator: Optional[Union[StrictBytes, StrictStr, Tuple[StrictStr, StrictBytes]]] = Field(
35
- default=None, description="Binary file content"
36
- )
37
- # data type: Dict[str, object]
38
- oneof_schema_2_validator: Optional[Dict[str, Any]] = Field(
39
- default=None, description="File object that supports read operations"
40
- )
41
- actual_instance: Optional[Union[Dict[str, object], bytearray]] = None
42
- one_of_schemas: Set[str] = {"Dict[str, object]", "bytearray"}
43
-
44
- model_config = ConfigDict(
45
- validate_assignment=True,
46
- protected_namespaces=(),
47
- )
48
-
49
- def __init__(self, *args, **kwargs) -> None:
50
- if args:
51
- if len(args) > 1:
52
- raise ValueError("If a position argument is used, only 1 is allowed to set `actual_instance`")
53
- if kwargs:
54
- raise ValueError("If a position argument is used, keyword arguments cannot be used.")
55
- super().__init__(actual_instance=args[0])
56
- else:
57
- super().__init__(**kwargs)
58
-
59
- @field_validator("actual_instance")
60
- def actual_instance_must_validate_oneof(cls, v):
61
- instance = UploadFileRequestFile.model_construct()
62
- error_messages = []
63
- match = 0
64
- # validate data type: bytearray
65
- try:
66
- instance.oneof_schema_1_validator = v
67
- match += 1
68
- except (ValidationError, ValueError) as e:
69
- error_messages.append(str(e))
70
- # validate data type: Dict[str, object]
71
- try:
72
- instance.oneof_schema_2_validator = v
73
- match += 1
74
- except (ValidationError, ValueError) as e:
75
- error_messages.append(str(e))
76
- if match > 1:
77
- # more than 1 match
78
- raise ValueError(
79
- "Multiple matches found when setting `actual_instance` in UploadFileRequestFile with oneOf schemas: Dict[str, object], bytearray. Details: "
80
- + ", ".join(error_messages)
81
- )
82
- elif match == 0:
83
- # no match
84
- raise ValueError(
85
- "No match found when setting `actual_instance` in UploadFileRequestFile with oneOf schemas: Dict[str, object], bytearray. Details: "
86
- + ", ".join(error_messages)
87
- )
88
- else:
89
- return v
90
-
91
- @classmethod
92
- def from_dict(cls, obj: Union[str, Dict[str, Any]]) -> Self:
93
- return cls.from_json(json.dumps(obj))
94
-
95
- @classmethod
96
- def from_json(cls, json_str: str) -> Self:
97
- """Returns the object represented by the json string"""
98
- instance = cls.model_construct()
99
- error_messages = []
100
- match = 0
101
-
102
- # deserialize data into bytearray
103
- try:
104
- # validation
105
- instance.oneof_schema_1_validator = json.loads(json_str)
106
- # assign value to actual_instance
107
- instance.actual_instance = instance.oneof_schema_1_validator
108
- match += 1
109
- except (ValidationError, ValueError) as e:
110
- error_messages.append(str(e))
111
- # deserialize data into Dict[str, object]
112
- try:
113
- # validation
114
- instance.oneof_schema_2_validator = json.loads(json_str)
115
- # assign value to actual_instance
116
- instance.actual_instance = instance.oneof_schema_2_validator
117
- match += 1
118
- except (ValidationError, ValueError) as e:
119
- error_messages.append(str(e))
120
-
121
- if match > 1:
122
- # more than 1 match
123
- raise ValueError(
124
- "Multiple matches found when deserializing the JSON string into UploadFileRequestFile with oneOf schemas: Dict[str, object], bytearray. Details: "
125
- + ", ".join(error_messages)
126
- )
127
- elif match == 0:
128
- # no match
129
- raise ValueError(
130
- "No match found when deserializing the JSON string into UploadFileRequestFile with oneOf schemas: Dict[str, object], bytearray. Details: "
131
- + ", ".join(error_messages)
132
- )
133
- else:
134
- return instance
135
-
136
- def to_json(self) -> str:
137
- """Returns the JSON representation of the actual instance"""
138
- if self.actual_instance is None:
139
- return "null"
140
-
141
- if hasattr(self.actual_instance, "to_json") and callable(self.actual_instance.to_json):
142
- return self.actual_instance.to_json()
143
- else:
144
- return json.dumps(self.actual_instance)
145
-
146
- def to_dict(self) -> Optional[Union[Dict[str, Any], Dict[str, object], bytearray]]:
147
- """Returns the dict representation of the actual instance"""
148
- if self.actual_instance is None:
149
- return None
150
-
151
- if hasattr(self.actual_instance, "to_dict") and callable(self.actual_instance.to_dict):
152
- return self.actual_instance.to_dict()
153
- else:
154
- # primitive type
155
- return self.actual_instance
156
-
157
- def to_str(self) -> str:
158
- """Returns the string representation of the actual instance"""
159
- return pprint.pformat(self.model_dump())
@@ -1,101 +0,0 @@
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
-
18
- import json
19
- import pprint
20
- import re # noqa: F401
21
- from typing import Any, ClassVar, Dict, List, Optional, Set, Tuple, Union
22
-
23
- from pydantic import BaseModel, ConfigDict, StrictBytes, StrictStr
24
- from typing_extensions import Self
25
-
26
-
27
- class UploadFilesMultiRequestFilesInner(BaseModel):
28
- """
29
- UploadFilesMultiRequestFilesInner
30
- """ # noqa: E501
31
-
32
- path: Optional[StrictStr] = None
33
- file: Optional[Union[StrictBytes, StrictStr, Tuple[StrictStr, StrictBytes]]] = None
34
- additional_properties: Dict[str, Any] = {}
35
- __properties: ClassVar[List[str]] = ["path", "file"]
36
-
37
- model_config = ConfigDict(
38
- populate_by_name=True,
39
- validate_assignment=True,
40
- protected_namespaces=(),
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 UploadFilesMultiRequestFilesInner 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
- [
70
- "additional_properties",
71
- ]
72
- )
73
-
74
- _dict = self.model_dump(
75
- by_alias=True,
76
- exclude=excluded_fields,
77
- exclude_none=True,
78
- )
79
- # puts key-value pairs in additional_properties in the top level
80
- if self.additional_properties is not None:
81
- for _key, _value in self.additional_properties.items():
82
- _dict[_key] = _value
83
-
84
- return _dict
85
-
86
- @classmethod
87
- def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
88
- """Create an instance of UploadFilesMultiRequestFilesInner from a dict"""
89
- if obj is None:
90
- return None
91
-
92
- if not isinstance(obj, dict):
93
- return cls.model_validate(obj)
94
-
95
- _obj = cls.model_validate({"path": obj.get("path"), "file": obj.get("file")})
96
- # store additional fields in additional_properties
97
- for _key in obj.keys():
98
- if _key not in cls.__properties:
99
- _obj.additional_properties[_key] = obj.get(_key)
100
-
101
- return _obj