stackit-runcommand 1.1.2__py3-none-any.whl → 1.3.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.
@@ -3,18 +3,17 @@
3
3
  # flake8: noqa
4
4
 
5
5
  """
6
- STACKIT Run Commands Service API
6
+ STACKIT Run Commands Service API
7
7
 
8
- API endpoints for the STACKIT Run Commands Service API
8
+ API endpoints for the STACKIT Run Commands Service API
9
9
 
10
- The version of the OpenAPI document: 2.0
11
- Contact: support@stackit.de
12
- Generated by OpenAPI Generator (https://openapi-generator.tech)
10
+ The version of the OpenAPI document: 2.0
11
+ Contact: support@stackit.de
12
+ Generated by OpenAPI Generator (https://openapi-generator.tech)
13
13
 
14
- Do not edit the class manually.
14
+ Do not edit the class manually.
15
15
  """ # noqa: E501
16
16
 
17
-
18
17
  __version__ = "1.0.0"
19
18
 
20
19
  # Define package exports
@@ -1,15 +1,15 @@
1
1
  # coding: utf-8
2
2
 
3
3
  """
4
- STACKIT Run Commands Service API
4
+ STACKIT Run Commands Service API
5
5
 
6
- API endpoints for the STACKIT Run Commands Service API
6
+ API endpoints for the STACKIT Run Commands Service API
7
7
 
8
- The version of the OpenAPI document: 2.0
9
- Contact: support@stackit.de
10
- Generated by OpenAPI Generator (https://openapi-generator.tech)
8
+ The version of the OpenAPI document: 2.0
9
+ Contact: support@stackit.de
10
+ Generated by OpenAPI Generator (https://openapi-generator.tech)
11
11
 
12
- Do not edit the class manually.
12
+ Do not edit the class manually.
13
13
  """ # noqa: E501
14
14
 
15
15
  from typing import Any, Dict, List, Optional, Tuple, Union
@@ -1,15 +1,15 @@
1
1
  # coding: utf-8
2
2
 
3
3
  """
4
- STACKIT Run Commands Service API
4
+ STACKIT Run Commands Service API
5
5
 
6
- API endpoints for the STACKIT Run Commands Service API
6
+ API endpoints for the STACKIT Run Commands Service API
7
7
 
8
- The version of the OpenAPI document: 2.0
9
- Contact: support@stackit.de
10
- Generated by OpenAPI Generator (https://openapi-generator.tech)
8
+ The version of the OpenAPI document: 2.0
9
+ Contact: support@stackit.de
10
+ Generated by OpenAPI Generator (https://openapi-generator.tech)
11
11
 
12
- Do not edit the class manually.
12
+ Do not edit the class manually.
13
13
  """ # noqa: E501
14
14
 
15
15
  import datetime
@@ -37,7 +37,6 @@ from stackit.runcommand.exceptions import (
37
37
  ApiException,
38
38
  )
39
39
 
40
-
41
40
  RequestSerialized = Tuple[str, str, Dict[str, str], Optional[str], List[str]]
42
41
 
43
42
 
@@ -67,6 +66,7 @@ class ApiClient:
67
66
  "date": datetime.date,
68
67
  "datetime": datetime.datetime,
69
68
  "decimal": decimal.Decimal,
69
+ "UUID": uuid.UUID,
70
70
  "object": object,
71
71
  }
72
72
  _pool = None
@@ -266,7 +266,7 @@ class ApiClient:
266
266
  response_text = None
267
267
  return_data = None
268
268
  try:
269
- if response_type == "bytearray":
269
+ if response_type in ("bytearray", "bytes"):
270
270
  return_data = response_data.data
271
271
  elif response_type == "file":
272
272
  return_data = self.__deserialize_file(response_data)
@@ -327,25 +327,20 @@ class ApiClient:
327
327
  return obj.isoformat()
328
328
  elif isinstance(obj, decimal.Decimal):
329
329
  return str(obj)
330
-
331
330
  elif isinstance(obj, dict):
332
- obj_dict = obj
331
+ return {key: self.sanitize_for_serialization(val) for key, val in obj.items()}
332
+
333
+ # Convert model obj to dict except
334
+ # attributes `openapi_types`, `attribute_map`
335
+ # and attributes which value is not None.
336
+ # Convert attribute name to json key in
337
+ # model definition for request.
338
+ if hasattr(obj, "to_dict") and callable(getattr(obj, "to_dict")): # noqa: B009
339
+ obj_dict = obj.to_dict()
333
340
  else:
334
- # Convert model obj to dict except
335
- # attributes `openapi_types`, `attribute_map`
336
- # and attributes which value is not None.
337
- # Convert attribute name to json key in
338
- # model definition for request.
339
- if hasattr(obj, "to_dict") and callable(getattr(obj, "to_dict")): # noqa: B009
340
- obj_dict = obj.to_dict()
341
- else:
342
- obj_dict = obj.__dict__
343
-
344
- if isinstance(obj_dict, list):
345
- # here we handle instances that can either be a list or something else, and only became a real list by calling to_dict() # noqa: E501
346
- return self.sanitize_for_serialization(obj_dict)
341
+ obj_dict = obj.__dict__
347
342
 
348
- return {key: self.sanitize_for_serialization(val) for key, val in obj_dict.items()}
343
+ return self.sanitize_for_serialization(obj_dict)
349
344
 
350
345
  def deserialize(self, response_text: str, response_type: str, content_type: Optional[str]):
351
346
  """Deserializes response into an object.
@@ -418,6 +413,8 @@ class ApiClient:
418
413
  return self.__deserialize_datetime(data)
419
414
  elif klass is decimal.Decimal:
420
415
  return decimal.Decimal(data)
416
+ elif klass is uuid.UUID:
417
+ return uuid.UUID(data)
421
418
  elif issubclass(klass, Enum):
422
419
  return self.__deserialize_enum(data, klass)
423
420
  else:
@@ -6,7 +6,6 @@ from typing import Generic, Mapping, Optional, TypeVar
6
6
 
7
7
  from pydantic import BaseModel, Field, StrictBytes, StrictInt
8
8
 
9
-
10
9
  T = TypeVar("T")
11
10
 
12
11
 
@@ -1,15 +1,15 @@
1
1
  # coding: utf-8
2
2
 
3
3
  """
4
- STACKIT Run Commands Service API
4
+ STACKIT Run Commands Service API
5
5
 
6
- API endpoints for the STACKIT Run Commands Service API
6
+ API endpoints for the STACKIT Run Commands Service API
7
7
 
8
- The version of the OpenAPI document: 2.0
9
- Contact: support@stackit.de
10
- Generated by OpenAPI Generator (https://openapi-generator.tech)
8
+ The version of the OpenAPI document: 2.0
9
+ Contact: support@stackit.de
10
+ Generated by OpenAPI Generator (https://openapi-generator.tech)
11
11
 
12
- Do not edit the class manually.
12
+ Do not edit the class manually.
13
13
  """ # noqa: E501
14
14
 
15
15
  import sys
@@ -19,7 +19,6 @@ from typing_extensions import NotRequired
19
19
 
20
20
  import os
21
21
 
22
-
23
22
  ServerVariablesT = Dict[str, str]
24
23
 
25
24
 
@@ -1,15 +1,15 @@
1
1
  # coding: utf-8
2
2
 
3
3
  """
4
- STACKIT Run Commands Service API
4
+ STACKIT Run Commands Service API
5
5
 
6
- API endpoints for the STACKIT Run Commands Service API
6
+ API endpoints for the STACKIT Run Commands Service API
7
7
 
8
- The version of the OpenAPI document: 2.0
9
- Contact: support@stackit.de
10
- Generated by OpenAPI Generator (https://openapi-generator.tech)
8
+ The version of the OpenAPI document: 2.0
9
+ Contact: support@stackit.de
10
+ Generated by OpenAPI Generator (https://openapi-generator.tech)
11
11
 
12
- Do not edit the class manually.
12
+ Do not edit the class manually.
13
13
  """ # noqa: E501
14
14
 
15
15
  from typing import Any, Optional
@@ -2,15 +2,15 @@
2
2
 
3
3
  # flake8: noqa
4
4
  """
5
- STACKIT Run Commands Service API
5
+ STACKIT Run Commands Service API
6
6
 
7
- API endpoints for the STACKIT Run Commands Service API
7
+ API endpoints for the STACKIT Run Commands Service API
8
8
 
9
- The version of the OpenAPI document: 2.0
10
- Contact: support@stackit.de
11
- Generated by OpenAPI Generator (https://openapi-generator.tech)
9
+ The version of the OpenAPI document: 2.0
10
+ Contact: support@stackit.de
11
+ Generated by OpenAPI Generator (https://openapi-generator.tech)
12
12
 
13
- Do not edit the class manually.
13
+ Do not edit the class manually.
14
14
  """ # noqa: E501
15
15
 
16
16
  # import models into model package
@@ -1,15 +1,15 @@
1
1
  # coding: utf-8
2
2
 
3
3
  """
4
- STACKIT Run Commands Service API
4
+ STACKIT Run Commands Service API
5
5
 
6
- API endpoints for the STACKIT Run Commands Service API
6
+ API endpoints for the STACKIT Run Commands Service API
7
7
 
8
- The version of the OpenAPI document: 2.0
9
- Contact: support@stackit.de
10
- Generated by OpenAPI Generator (https://openapi-generator.tech)
8
+ The version of the OpenAPI document: 2.0
9
+ Contact: support@stackit.de
10
+ Generated by OpenAPI Generator (https://openapi-generator.tech)
11
11
 
12
- Do not edit the class manually.
12
+ Do not edit the class manually.
13
13
  """ # noqa: E501
14
14
 
15
15
  from __future__ import annotations
@@ -19,6 +19,7 @@ import pprint
19
19
  from typing import Any, ClassVar, Dict, List, Optional, Set
20
20
 
21
21
  from pydantic import BaseModel, ConfigDict, Field, StrictInt, StrictStr, field_validator
22
+ from pydantic_core import to_jsonable_python
22
23
  from typing_extensions import Self
23
24
 
24
25
 
@@ -59,7 +60,8 @@ class CommandDetails(BaseModel):
59
60
  return value
60
61
 
61
62
  model_config = ConfigDict(
62
- populate_by_name=True,
63
+ validate_by_name=True,
64
+ validate_by_alias=True,
63
65
  validate_assignment=True,
64
66
  protected_namespaces=(),
65
67
  )
@@ -70,8 +72,7 @@ class CommandDetails(BaseModel):
70
72
 
71
73
  def to_json(self) -> str:
72
74
  """Returns the JSON representation of the model using alias"""
73
- # TODO: pydantic v2: use .model_dump_json(by_alias=True, exclude_unset=True) instead
74
- return json.dumps(self.to_dict())
75
+ return json.dumps(to_jsonable_python(self.to_dict()))
75
76
 
76
77
  @classmethod
77
78
  def from_json(cls, json_str: str) -> Optional[Self]:
@@ -1,15 +1,15 @@
1
1
  # coding: utf-8
2
2
 
3
3
  """
4
- STACKIT Run Commands Service API
4
+ STACKIT Run Commands Service API
5
5
 
6
- API endpoints for the STACKIT Run Commands Service API
6
+ API endpoints for the STACKIT Run Commands Service API
7
7
 
8
- The version of the OpenAPI document: 2.0
9
- Contact: support@stackit.de
10
- Generated by OpenAPI Generator (https://openapi-generator.tech)
8
+ The version of the OpenAPI document: 2.0
9
+ Contact: support@stackit.de
10
+ Generated by OpenAPI Generator (https://openapi-generator.tech)
11
11
 
12
- Do not edit the class manually.
12
+ Do not edit the class manually.
13
13
  """ # noqa: E501
14
14
 
15
15
  from __future__ import annotations
@@ -19,6 +19,7 @@ import pprint
19
19
  from typing import Any, ClassVar, Dict, List, Optional, Set
20
20
 
21
21
  from pydantic import BaseModel, ConfigDict, Field, StrictStr
22
+ from pydantic_core import to_jsonable_python
22
23
  from typing_extensions import Self
23
24
 
24
25
 
@@ -33,7 +34,8 @@ class CommandTemplate(BaseModel):
33
34
  __properties: ClassVar[List[str]] = ["name", "osType", "title"]
34
35
 
35
36
  model_config = ConfigDict(
36
- populate_by_name=True,
37
+ validate_by_name=True,
38
+ validate_by_alias=True,
37
39
  validate_assignment=True,
38
40
  protected_namespaces=(),
39
41
  )
@@ -44,8 +46,7 @@ class CommandTemplate(BaseModel):
44
46
 
45
47
  def to_json(self) -> str:
46
48
  """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
+ return json.dumps(to_jsonable_python(self.to_dict()))
49
50
 
50
51
  @classmethod
51
52
  def from_json(cls, json_str: str) -> Optional[Self]:
@@ -1,15 +1,15 @@
1
1
  # coding: utf-8
2
2
 
3
3
  """
4
- STACKIT Run Commands Service API
4
+ STACKIT Run Commands Service API
5
5
 
6
- API endpoints for the STACKIT Run Commands Service API
6
+ API endpoints for the STACKIT Run Commands Service API
7
7
 
8
- The version of the OpenAPI document: 2.0
9
- Contact: support@stackit.de
10
- Generated by OpenAPI Generator (https://openapi-generator.tech)
8
+ The version of the OpenAPI document: 2.0
9
+ Contact: support@stackit.de
10
+ Generated by OpenAPI Generator (https://openapi-generator.tech)
11
11
 
12
- Do not edit the class manually.
12
+ Do not edit the class manually.
13
13
  """ # noqa: E501
14
14
 
15
15
  from __future__ import annotations
@@ -19,6 +19,7 @@ import pprint
19
19
  from typing import Any, ClassVar, Dict, List, Optional, Set
20
20
 
21
21
  from pydantic import BaseModel, ConfigDict
22
+ from pydantic_core import to_jsonable_python
22
23
  from typing_extensions import Self
23
24
 
24
25
  from stackit.runcommand.models.command_template import CommandTemplate
@@ -33,7 +34,8 @@ class CommandTemplateResponse(BaseModel):
33
34
  __properties: ClassVar[List[str]] = ["items"]
34
35
 
35
36
  model_config = ConfigDict(
36
- populate_by_name=True,
37
+ validate_by_name=True,
38
+ validate_by_alias=True,
37
39
  validate_assignment=True,
38
40
  protected_namespaces=(),
39
41
  )
@@ -44,8 +46,7 @@ class CommandTemplateResponse(BaseModel):
44
46
 
45
47
  def to_json(self) -> str:
46
48
  """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
+ return json.dumps(to_jsonable_python(self.to_dict()))
49
50
 
50
51
  @classmethod
51
52
  def from_json(cls, json_str: str) -> Optional[Self]:
@@ -1,15 +1,15 @@
1
1
  # coding: utf-8
2
2
 
3
3
  """
4
- STACKIT Run Commands Service API
4
+ STACKIT Run Commands Service API
5
5
 
6
- API endpoints for the STACKIT Run Commands Service API
6
+ API endpoints for the STACKIT Run Commands Service API
7
7
 
8
- The version of the OpenAPI document: 2.0
9
- Contact: support@stackit.de
10
- Generated by OpenAPI Generator (https://openapi-generator.tech)
8
+ The version of the OpenAPI document: 2.0
9
+ Contact: support@stackit.de
10
+ Generated by OpenAPI Generator (https://openapi-generator.tech)
11
11
 
12
- Do not edit the class manually.
12
+ Do not edit the class manually.
13
13
  """ # noqa: E501
14
14
 
15
15
  from __future__ import annotations
@@ -19,6 +19,7 @@ import pprint
19
19
  from typing import Any, ClassVar, Dict, List, Optional, Set
20
20
 
21
21
  from pydantic import BaseModel, ConfigDict, Field, StrictStr
22
+ from pydantic_core import to_jsonable_python
22
23
  from typing_extensions import Self
23
24
 
24
25
  from stackit.runcommand.models.parameters_schema import ParametersSchema
@@ -37,7 +38,8 @@ class CommandTemplateSchema(BaseModel):
37
38
  __properties: ClassVar[List[str]] = ["description", "name", "osType", "parametersSchema", "title"]
38
39
 
39
40
  model_config = ConfigDict(
40
- populate_by_name=True,
41
+ validate_by_name=True,
42
+ validate_by_alias=True,
41
43
  validate_assignment=True,
42
44
  protected_namespaces=(),
43
45
  )
@@ -48,8 +50,7 @@ class CommandTemplateSchema(BaseModel):
48
50
 
49
51
  def to_json(self) -> str:
50
52
  """Returns the JSON representation of the model using alias"""
51
- # TODO: pydantic v2: use .model_dump_json(by_alias=True, exclude_unset=True) instead
52
- return json.dumps(self.to_dict())
53
+ return json.dumps(to_jsonable_python(self.to_dict()))
53
54
 
54
55
  @classmethod
55
56
  def from_json(cls, json_str: str) -> Optional[Self]:
@@ -1,15 +1,15 @@
1
1
  # coding: utf-8
2
2
 
3
3
  """
4
- STACKIT Run Commands Service API
4
+ STACKIT Run Commands Service API
5
5
 
6
- API endpoints for the STACKIT Run Commands Service API
6
+ API endpoints for the STACKIT Run Commands Service API
7
7
 
8
- The version of the OpenAPI document: 2.0
9
- Contact: support@stackit.de
10
- Generated by OpenAPI Generator (https://openapi-generator.tech)
8
+ The version of the OpenAPI document: 2.0
9
+ Contact: support@stackit.de
10
+ Generated by OpenAPI Generator (https://openapi-generator.tech)
11
11
 
12
- Do not edit the class manually.
12
+ Do not edit the class manually.
13
13
  """ # noqa: E501
14
14
 
15
15
  from __future__ import annotations
@@ -19,6 +19,7 @@ import pprint
19
19
  from typing import Any, ClassVar, Dict, List, Optional, Set
20
20
 
21
21
  from pydantic import BaseModel, ConfigDict, Field, StrictInt, StrictStr, field_validator
22
+ from pydantic_core import to_jsonable_python
22
23
  from typing_extensions import Self
23
24
 
24
25
 
@@ -53,7 +54,8 @@ class Commands(BaseModel):
53
54
  return value
54
55
 
55
56
  model_config = ConfigDict(
56
- populate_by_name=True,
57
+ validate_by_name=True,
58
+ validate_by_alias=True,
57
59
  validate_assignment=True,
58
60
  protected_namespaces=(),
59
61
  )
@@ -64,8 +66,7 @@ class Commands(BaseModel):
64
66
 
65
67
  def to_json(self) -> str:
66
68
  """Returns the JSON representation of the model using alias"""
67
- # TODO: pydantic v2: use .model_dump_json(by_alias=True, exclude_unset=True) instead
68
- return json.dumps(self.to_dict())
69
+ return json.dumps(to_jsonable_python(self.to_dict()))
69
70
 
70
71
  @classmethod
71
72
  def from_json(cls, json_str: str) -> Optional[Self]:
@@ -1,15 +1,15 @@
1
1
  # coding: utf-8
2
2
 
3
3
  """
4
- STACKIT Run Commands Service API
4
+ STACKIT Run Commands Service API
5
5
 
6
- API endpoints for the STACKIT Run Commands Service API
6
+ API endpoints for the STACKIT Run Commands Service API
7
7
 
8
- The version of the OpenAPI document: 2.0
9
- Contact: support@stackit.de
10
- Generated by OpenAPI Generator (https://openapi-generator.tech)
8
+ The version of the OpenAPI document: 2.0
9
+ Contact: support@stackit.de
10
+ Generated by OpenAPI Generator (https://openapi-generator.tech)
11
11
 
12
- Do not edit the class manually.
12
+ Do not edit the class manually.
13
13
  """ # noqa: E501
14
14
 
15
15
  from __future__ import annotations
@@ -19,6 +19,7 @@ import pprint
19
19
  from typing import Any, ClassVar, Dict, List, Optional, Set
20
20
 
21
21
  from pydantic import BaseModel, ConfigDict, Field, StrictStr
22
+ from pydantic_core import to_jsonable_python
22
23
  from typing_extensions import Self
23
24
 
24
25
 
@@ -32,7 +33,8 @@ class CreateCommandPayload(BaseModel):
32
33
  __properties: ClassVar[List[str]] = ["commandTemplateName", "parameters"]
33
34
 
34
35
  model_config = ConfigDict(
35
- populate_by_name=True,
36
+ validate_by_name=True,
37
+ validate_by_alias=True,
36
38
  validate_assignment=True,
37
39
  protected_namespaces=(),
38
40
  )
@@ -43,8 +45,7 @@ class CreateCommandPayload(BaseModel):
43
45
 
44
46
  def to_json(self) -> str:
45
47
  """Returns the JSON representation of the model using alias"""
46
- # TODO: pydantic v2: use .model_dump_json(by_alias=True, exclude_unset=True) instead
47
- return json.dumps(self.to_dict())
48
+ return json.dumps(to_jsonable_python(self.to_dict()))
48
49
 
49
50
  @classmethod
50
51
  def from_json(cls, json_str: str) -> Optional[Self]:
@@ -1,15 +1,15 @@
1
1
  # coding: utf-8
2
2
 
3
3
  """
4
- STACKIT Run Commands Service API
4
+ STACKIT Run Commands Service API
5
5
 
6
- API endpoints for the STACKIT Run Commands Service API
6
+ API endpoints for the STACKIT Run Commands Service API
7
7
 
8
- The version of the OpenAPI document: 2.0
9
- Contact: support@stackit.de
10
- Generated by OpenAPI Generator (https://openapi-generator.tech)
8
+ The version of the OpenAPI document: 2.0
9
+ Contact: support@stackit.de
10
+ Generated by OpenAPI Generator (https://openapi-generator.tech)
11
11
 
12
- Do not edit the class manually.
12
+ Do not edit the class manually.
13
13
  """ # noqa: E501
14
14
 
15
15
  from __future__ import annotations
@@ -19,6 +19,7 @@ import pprint
19
19
  from typing import Any, ClassVar, Dict, List, Optional, Set
20
20
 
21
21
  from pydantic import BaseModel, ConfigDict, Field, StrictStr
22
+ from pydantic_core import to_jsonable_python
22
23
  from typing_extensions import Self
23
24
 
24
25
 
@@ -34,7 +35,8 @@ class ErrorResponse(BaseModel):
34
35
  __properties: ClassVar[List[str]] = ["message", "status"]
35
36
 
36
37
  model_config = ConfigDict(
37
- populate_by_name=True,
38
+ validate_by_name=True,
39
+ validate_by_alias=True,
38
40
  validate_assignment=True,
39
41
  protected_namespaces=(),
40
42
  )
@@ -45,8 +47,7 @@ class ErrorResponse(BaseModel):
45
47
 
46
48
  def to_json(self) -> str:
47
49
  """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
+ return json.dumps(to_jsonable_python(self.to_dict()))
50
51
 
51
52
  @classmethod
52
53
  def from_json(cls, json_str: str) -> Optional[Self]:
@@ -1,15 +1,15 @@
1
1
  # coding: utf-8
2
2
 
3
3
  """
4
- STACKIT Run Commands Service API
4
+ STACKIT Run Commands Service API
5
5
 
6
- API endpoints for the STACKIT Run Commands Service API
6
+ API endpoints for the STACKIT Run Commands Service API
7
7
 
8
- The version of the OpenAPI document: 2.0
9
- Contact: support@stackit.de
10
- Generated by OpenAPI Generator (https://openapi-generator.tech)
8
+ The version of the OpenAPI document: 2.0
9
+ Contact: support@stackit.de
10
+ Generated by OpenAPI Generator (https://openapi-generator.tech)
11
11
 
12
- Do not edit the class manually.
12
+ Do not edit the class manually.
13
13
  """ # noqa: E501
14
14
 
15
15
  from __future__ import annotations
@@ -19,6 +19,7 @@ import pprint
19
19
  from typing import Any, ClassVar, Dict, List, Optional, Set
20
20
 
21
21
  from pydantic import BaseModel, ConfigDict
22
+ from pydantic_core import to_jsonable_python
22
23
  from typing_extensions import Self
23
24
 
24
25
  from stackit.runcommand.models.commands import Commands
@@ -33,7 +34,8 @@ class GetCommandsResponse(BaseModel):
33
34
  __properties: ClassVar[List[str]] = ["items"]
34
35
 
35
36
  model_config = ConfigDict(
36
- populate_by_name=True,
37
+ validate_by_name=True,
38
+ validate_by_alias=True,
37
39
  validate_assignment=True,
38
40
  protected_namespaces=(),
39
41
  )
@@ -44,8 +46,7 @@ class GetCommandsResponse(BaseModel):
44
46
 
45
47
  def to_json(self) -> str:
46
48
  """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
+ return json.dumps(to_jsonable_python(self.to_dict()))
49
50
 
50
51
  @classmethod
51
52
  def from_json(cls, json_str: str) -> Optional[Self]:
@@ -1,15 +1,15 @@
1
1
  # coding: utf-8
2
2
 
3
3
  """
4
- STACKIT Run Commands Service API
4
+ STACKIT Run Commands Service API
5
5
 
6
- API endpoints for the STACKIT Run Commands Service API
6
+ API endpoints for the STACKIT Run Commands Service API
7
7
 
8
- The version of the OpenAPI document: 2.0
9
- Contact: support@stackit.de
10
- Generated by OpenAPI Generator (https://openapi-generator.tech)
8
+ The version of the OpenAPI document: 2.0
9
+ Contact: support@stackit.de
10
+ Generated by OpenAPI Generator (https://openapi-generator.tech)
11
11
 
12
- Do not edit the class manually.
12
+ Do not edit the class manually.
13
13
  """ # noqa: E501
14
14
 
15
15
  from __future__ import annotations
@@ -26,6 +26,7 @@ from pydantic import (
26
26
  StrictInt,
27
27
  StrictStr,
28
28
  )
29
+ from pydantic_core import to_jsonable_python
29
30
  from typing_extensions import Self
30
31
 
31
32
 
@@ -44,7 +45,8 @@ class ModelField(BaseModel):
44
45
  __properties: ClassVar[List[str]] = ["default", "description", "maxLen", "minLen", "readOnly", "title", "type"]
45
46
 
46
47
  model_config = ConfigDict(
47
- populate_by_name=True,
48
+ validate_by_name=True,
49
+ validate_by_alias=True,
48
50
  validate_assignment=True,
49
51
  protected_namespaces=(),
50
52
  )
@@ -55,8 +57,7 @@ class ModelField(BaseModel):
55
57
 
56
58
  def to_json(self) -> str:
57
59
  """Returns the JSON representation of the model using alias"""
58
- # TODO: pydantic v2: use .model_dump_json(by_alias=True, exclude_unset=True) instead
59
- return json.dumps(self.to_dict())
60
+ return json.dumps(to_jsonable_python(self.to_dict()))
60
61
 
61
62
  @classmethod
62
63
  def from_json(cls, json_str: str) -> Optional[Self]:
@@ -1,15 +1,15 @@
1
1
  # coding: utf-8
2
2
 
3
3
  """
4
- STACKIT Run Commands Service API
4
+ STACKIT Run Commands Service API
5
5
 
6
- API endpoints for the STACKIT Run Commands Service API
6
+ API endpoints for the STACKIT Run Commands Service API
7
7
 
8
- The version of the OpenAPI document: 2.0
9
- Contact: support@stackit.de
10
- Generated by OpenAPI Generator (https://openapi-generator.tech)
8
+ The version of the OpenAPI document: 2.0
9
+ Contact: support@stackit.de
10
+ Generated by OpenAPI Generator (https://openapi-generator.tech)
11
11
 
12
- Do not edit the class manually.
12
+ Do not edit the class manually.
13
13
  """ # noqa: E501
14
14
 
15
15
  from __future__ import annotations
@@ -19,6 +19,7 @@ import pprint
19
19
  from typing import Any, ClassVar, Dict, List, Optional, Set
20
20
 
21
21
  from pydantic import BaseModel, ConfigDict, StrictInt
22
+ from pydantic_core import to_jsonable_python
22
23
  from typing_extensions import Self
23
24
 
24
25
 
@@ -31,7 +32,8 @@ class NewCommandResponse(BaseModel):
31
32
  __properties: ClassVar[List[str]] = ["id"]
32
33
 
33
34
  model_config = ConfigDict(
34
- populate_by_name=True,
35
+ validate_by_name=True,
36
+ validate_by_alias=True,
35
37
  validate_assignment=True,
36
38
  protected_namespaces=(),
37
39
  )
@@ -42,8 +44,7 @@ class NewCommandResponse(BaseModel):
42
44
 
43
45
  def to_json(self) -> str:
44
46
  """Returns the JSON representation of the model using alias"""
45
- # TODO: pydantic v2: use .model_dump_json(by_alias=True, exclude_unset=True) instead
46
- return json.dumps(self.to_dict())
47
+ return json.dumps(to_jsonable_python(self.to_dict()))
47
48
 
48
49
  @classmethod
49
50
  def from_json(cls, json_str: str) -> Optional[Self]:
@@ -1,15 +1,15 @@
1
1
  # coding: utf-8
2
2
 
3
3
  """
4
- STACKIT Run Commands Service API
4
+ STACKIT Run Commands Service API
5
5
 
6
- API endpoints for the STACKIT Run Commands Service API
6
+ API endpoints for the STACKIT Run Commands Service API
7
7
 
8
- The version of the OpenAPI document: 2.0
9
- Contact: support@stackit.de
10
- Generated by OpenAPI Generator (https://openapi-generator.tech)
8
+ The version of the OpenAPI document: 2.0
9
+ Contact: support@stackit.de
10
+ Generated by OpenAPI Generator (https://openapi-generator.tech)
11
11
 
12
- Do not edit the class manually.
12
+ Do not edit the class manually.
13
13
  """ # noqa: E501
14
14
 
15
15
  from __future__ import annotations
@@ -19,6 +19,7 @@ import pprint
19
19
  from typing import Any, ClassVar, Dict, List, Optional, Set
20
20
 
21
21
  from pydantic import BaseModel, ConfigDict
22
+ from pydantic_core import to_jsonable_python
22
23
  from typing_extensions import Self
23
24
 
24
25
  from stackit.runcommand.models.properties import Properties
@@ -33,7 +34,8 @@ class ParametersSchema(BaseModel):
33
34
  __properties: ClassVar[List[str]] = ["properties"]
34
35
 
35
36
  model_config = ConfigDict(
36
- populate_by_name=True,
37
+ validate_by_name=True,
38
+ validate_by_alias=True,
37
39
  validate_assignment=True,
38
40
  protected_namespaces=(),
39
41
  )
@@ -44,8 +46,7 @@ class ParametersSchema(BaseModel):
44
46
 
45
47
  def to_json(self) -> str:
46
48
  """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
+ return json.dumps(to_jsonable_python(self.to_dict()))
49
50
 
50
51
  @classmethod
51
52
  def from_json(cls, json_str: str) -> Optional[Self]:
@@ -1,15 +1,15 @@
1
1
  # coding: utf-8
2
2
 
3
3
  """
4
- STACKIT Run Commands Service API
4
+ STACKIT Run Commands Service API
5
5
 
6
- API endpoints for the STACKIT Run Commands Service API
6
+ API endpoints for the STACKIT Run Commands Service API
7
7
 
8
- The version of the OpenAPI document: 2.0
9
- Contact: support@stackit.de
10
- Generated by OpenAPI Generator (https://openapi-generator.tech)
8
+ The version of the OpenAPI document: 2.0
9
+ Contact: support@stackit.de
10
+ Generated by OpenAPI Generator (https://openapi-generator.tech)
11
11
 
12
- Do not edit the class manually.
12
+ Do not edit the class manually.
13
13
  """ # noqa: E501
14
14
 
15
15
  from __future__ import annotations
@@ -19,6 +19,7 @@ import pprint
19
19
  from typing import Any, ClassVar, Dict, List, Optional, Set
20
20
 
21
21
  from pydantic import BaseModel, ConfigDict, Field, StrictStr
22
+ from pydantic_core import to_jsonable_python
22
23
  from typing_extensions import Self
23
24
 
24
25
  from stackit.runcommand.models.model_field import ModelField
@@ -38,7 +39,8 @@ class Properties(BaseModel):
38
39
  __properties: ClassVar[List[str]] = ["ConfirmPassword", "Password", "Script", "Username", "required", "type"]
39
40
 
40
41
  model_config = ConfigDict(
41
- populate_by_name=True,
42
+ validate_by_name=True,
43
+ validate_by_alias=True,
42
44
  validate_assignment=True,
43
45
  protected_namespaces=(),
44
46
  )
@@ -49,8 +51,7 @@ class Properties(BaseModel):
49
51
 
50
52
  def to_json(self) -> str:
51
53
  """Returns the JSON representation of the model using alias"""
52
- # TODO: pydantic v2: use .model_dump_json(by_alias=True, exclude_unset=True) instead
53
- return json.dumps(self.to_dict())
54
+ return json.dumps(to_jsonable_python(self.to_dict()))
54
55
 
55
56
  @classmethod
56
57
  def from_json(cls, json_str: str) -> Optional[Self]:
@@ -1,15 +1,15 @@
1
1
  # coding: utf-8
2
2
 
3
3
  """
4
- STACKIT Run Commands Service API
4
+ STACKIT Run Commands Service API
5
5
 
6
- API endpoints for the STACKIT Run Commands Service API
6
+ API endpoints for the STACKIT Run Commands Service API
7
7
 
8
- The version of the OpenAPI document: 2.0
9
- Contact: support@stackit.de
10
- Generated by OpenAPI Generator (https://openapi-generator.tech)
8
+ The version of the OpenAPI document: 2.0
9
+ Contact: support@stackit.de
10
+ Generated by OpenAPI Generator (https://openapi-generator.tech)
11
11
 
12
- Do not edit the class manually.
12
+ Do not edit the class manually.
13
13
  """ # noqa: E501
14
14
 
15
15
  import io
@@ -22,7 +22,6 @@ from stackit.core.configuration import Configuration
22
22
 
23
23
  from stackit.runcommand.exceptions import ApiException, ApiValueError
24
24
 
25
-
26
25
  RESTResponseType = requests.Response
27
26
 
28
27
 
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: stackit-runcommand
3
- Version: 1.1.2
3
+ Version: 1.3.0
4
4
  Summary: STACKIT Run Commands Service API
5
5
  Project-URL: Homepage, https://github.com/stackitcloud/stackit-sdk-python
6
6
  Project-URL: Issues, https://github.com/stackitcloud/stackit-sdk-python/issues
@@ -10,16 +10,15 @@ License-File: NOTICE.txt
10
10
  Classifier: License :: OSI Approved :: Apache Software License
11
11
  Classifier: Operating System :: OS Independent
12
12
  Classifier: Programming Language :: Python :: 3
13
- Classifier: Programming Language :: Python :: 3.9
14
13
  Classifier: Programming Language :: Python :: 3.10
15
14
  Classifier: Programming Language :: Python :: 3.11
16
15
  Classifier: Programming Language :: Python :: 3.12
17
16
  Classifier: Programming Language :: Python :: 3.13
18
17
  Classifier: Programming Language :: Python :: 3.14
19
- Requires-Python: <4.0,>=3.9
18
+ Requires-Python: <4.0,>=3.10
20
19
  Requires-Dist: pydantic>=2.9.2
21
20
  Requires-Dist: python-dateutil>=2.9.0.post0
22
- Requires-Dist: requests>=2.32.3
21
+ Requires-Dist: requests>=2.33.0
23
22
  Requires-Dist: stackit-core>=0.0.1a
24
23
  Description-Content-Type: text/markdown
25
24
 
@@ -0,0 +1,27 @@
1
+ stackit/runcommand/__init__.py,sha256=aG3mAsb33a_Sm2MXq0RPunFZTJf-MnXpJISn1T7P8AI,2854
2
+ stackit/runcommand/api_client.py,sha256=z2L4y_16z9v18abLeHS812MU8AaHPNeivnBvg5yJeqc,23729
3
+ stackit/runcommand/api_response.py,sha256=rSuCVGY-HE8X_WwteQP5wyANIuS-L5AmtZEUOwTicak,641
4
+ stackit/runcommand/configuration.py,sha256=EfNIYcNGfSS31YdD1aY2GBW2m-YSvThG_mmRe3dmQxo,5678
5
+ stackit/runcommand/exceptions.py,sha256=wh9UqQ4FbwhOrNiXHfhYyD2sUGN5kPTFWzCnJgB6MwQ,6396
6
+ stackit/runcommand/py.typed,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
7
+ stackit/runcommand/rest.py,sha256=aYzlHFyU-OIEkSQlnQDfA7KICJOq_XmgWhcvNa5OU0Y,6388
8
+ stackit/runcommand/api/__init__.py,sha256=O-WDFpOgx6B55T02W-JUoG02zuSKFHZcszlw16eLV04,105
9
+ stackit/runcommand/api/default_api.py,sha256=hjV_098XkdpDUKWR3SJ7jxHfz6isulDog6PQ-BAWWz4,60604
10
+ stackit/runcommand/models/__init__.py,sha256=U_min8l7bVH-tYoOBk5qIyim1HN6zkA11-n1Y7K3C2w,1215
11
+ stackit/runcommand/models/command_details.py,sha256=v6fL4ksos0NCir_Sp5OT8BXkBm6gIPb4TBORRpjtYvY,4013
12
+ stackit/runcommand/models/command_template.py,sha256=xkXqpACPZSckAnXyjwHxWeja0s4G1Tx2s8oAaKpafw0,2600
13
+ stackit/runcommand/models/command_template_response.py,sha256=kTBkanZa7bt3OTFHEIji0yyu3RHyYHz8sgcmXKDGCvM,3045
14
+ stackit/runcommand/models/command_template_schema.py,sha256=9F_IrGvWCT7dYby16EdgFz9XCknItKuiQeVxd7yJFgc,3441
15
+ stackit/runcommand/models/commands.py,sha256=YIAXj9XXfJJS6LmeJN5my-jn4KTzYiA4WdqTQCRe7D0,3641
16
+ stackit/runcommand/models/create_command_payload.py,sha256=Aq1EhpTqP2oaJvFPpi4Cd-HccGLVSTftHQ3QHHA_3jo,2639
17
+ stackit/runcommand/models/error_response.py,sha256=tXlbv9iQpxI9g1D6Fe5reSdusIkCdS1Dh8zgi4UMuOA,2627
18
+ stackit/runcommand/models/get_commands_response.py,sha256=SzV3TTqju9chXfbNLPdDffJQgTnvxtysSCwug1pLOUQ,2890
19
+ stackit/runcommand/models/model_field.py,sha256=yvmIgy0xcGeiaUwx_Z4JUasLWdjmV_IraIzAv3-Tkl0,3186
20
+ stackit/runcommand/models/new_command_response.py,sha256=xEPtZ7cb91g44h0G6aE0oRTQi82-OIsmlr-uPlIyTHc,2407
21
+ stackit/runcommand/models/parameters_schema.py,sha256=g5KBzCW7NZmg7TcO38or26ZNDRF0eijnnHaui_EwN0U,2746
22
+ stackit/runcommand/models/properties.py,sha256=Bp7BRbDi3L4nSimk1jg-e3gmogqHk-2fYwjsREjqbcc,4179
23
+ stackit_runcommand-1.3.0.dist-info/METADATA,sha256=nWxMVjjfKbG3ng0ObffGOw53WJp-zrjH2QVccuYtkgg,1643
24
+ stackit_runcommand-1.3.0.dist-info/WHEEL,sha256=lCkmxWfQsSc9CfIClYeavTdQeEX2toPqufh9gI35EQA,87
25
+ stackit_runcommand-1.3.0.dist-info/licenses/LICENSE.md,sha256=3dF8Tb7yZn2tS4zyNa-yNe-68pH8qyWdGz4ioMd3MgE,10933
26
+ stackit_runcommand-1.3.0.dist-info/licenses/NOTICE.txt,sha256=daK6MxvxH3YFeiVhow8N_fl9s-5sENiXgnGwgEgWPfw,63
27
+ stackit_runcommand-1.3.0.dist-info/RECORD,,
@@ -1,4 +1,4 @@
1
1
  Wheel-Version: 1.0
2
- Generator: hatchling 1.27.0
2
+ Generator: hatchling 1.31.0
3
3
  Root-Is-Purelib: true
4
4
  Tag: py3-none-any
@@ -1,27 +0,0 @@
1
- stackit/runcommand/__init__.py,sha256=hGt28Yt1GUrXvKoBqfnQpo2HKMRZcCmTgeszZXJat9I,2879
2
- stackit/runcommand/api_client.py,sha256=1vcV8w1hvZ0ATPOWrlO1fs0Cb1BwpOVV1ECHHCmrg4c,23916
3
- stackit/runcommand/api_response.py,sha256=HRYkVqMNIlfODacTQPTbiVj2YdcnutpQrKJdeAoCSpM,642
4
- stackit/runcommand/configuration.py,sha256=aCyt9z-HhMt3YCq_Zv8vO7dervXQs_Kz2kvzKrUUUT8,5703
5
- stackit/runcommand/exceptions.py,sha256=5EHd1-lZWDoSmwTR2S93BSU-lVkkNNC_40g9JM7WXWI,6420
6
- stackit/runcommand/py.typed,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
7
- stackit/runcommand/rest.py,sha256=KerHWEoIwGlQsp2Lo5C3dqSKF3HtCi4WwbCqRA9PQUg,6413
8
- stackit/runcommand/api/__init__.py,sha256=O-WDFpOgx6B55T02W-JUoG02zuSKFHZcszlw16eLV04,105
9
- stackit/runcommand/api/default_api.py,sha256=B-P2UAbtmpF9ZQEAuPIynew72m4QnjSu56QBFktpzHo,60628
10
- stackit/runcommand/models/__init__.py,sha256=YiZo6DNnSDhlocl4uFhR0nDZUJwE8NRx1X_E1krqqx8,1239
11
- stackit/runcommand/models/command_details.py,sha256=HPA4q4Z6v13iwAMQ2JLEYHoJl7RTkqmjuRNenCNIas0,4033
12
- stackit/runcommand/models/command_template.py,sha256=QIoUmYvq1PAjaSSBu3EPQjtTQUTqggRsXO4SZnxUFvg,2620
13
- stackit/runcommand/models/command_template_response.py,sha256=RoCnU6uIPx3HYrNsJi269znZgvMczbKKyfZqZgCb_r0,3065
14
- stackit/runcommand/models/command_template_schema.py,sha256=4bqvJ3Se5qcD93SMhYNNFpeSc8TsWiD3-0ggiPOm7do,3461
15
- stackit/runcommand/models/commands.py,sha256=lxz_DvGBoR1yU-3qOui6RP-C-yEKYTL1-SDXOXy78Nk,3661
16
- stackit/runcommand/models/create_command_payload.py,sha256=N3drh2OnqxMtw-W_FK5zF1Q723mn8xCtcN547Q2M-sI,2659
17
- stackit/runcommand/models/error_response.py,sha256=20AnQiIvV4CPvbYrMedl3TDENPq-GIadrWX1yTo3poI,2647
18
- stackit/runcommand/models/get_commands_response.py,sha256=kklrjcW8qHMXB4alLZIvqslxSfUdic5J4kH7KbP5Jcc,2910
19
- stackit/runcommand/models/model_field.py,sha256=_er9L8RH3DNRlrIz0OKv4rvUTDBAn1gnYtHzA7IlOE4,3206
20
- stackit/runcommand/models/new_command_response.py,sha256=naWeB_fMrj8pI9d3dNFvDQfgolO6LUlaaiFhORps0rM,2427
21
- stackit/runcommand/models/parameters_schema.py,sha256=e2TAAxFEV63gabsntL5qfFPhjxd_EPLruIU5E4oZtAA,2766
22
- stackit/runcommand/models/properties.py,sha256=yQUPHBp8DiPNlPj0b4NpwayMCIcBc7UHuOQN-YYCC8U,4199
23
- stackit_runcommand-1.1.2.dist-info/METADATA,sha256=VdZPUiRsI13_WUIpXA2ILBHacLd92qVrgmXeSDTTcSs,1692
24
- stackit_runcommand-1.1.2.dist-info/WHEEL,sha256=qtCwoSJWgHk21S1Kb4ihdzI2rlJ1ZKaIurTj_ngOhyQ,87
25
- stackit_runcommand-1.1.2.dist-info/licenses/LICENSE.md,sha256=3dF8Tb7yZn2tS4zyNa-yNe-68pH8qyWdGz4ioMd3MgE,10933
26
- stackit_runcommand-1.1.2.dist-info/licenses/NOTICE.txt,sha256=daK6MxvxH3YFeiVhow8N_fl9s-5sENiXgnGwgEgWPfw,63
27
- stackit_runcommand-1.1.2.dist-info/RECORD,,