Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 0 additions & 1 deletion services/runcommand/src/stackit/runcommand/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,6 @@
Do not edit the class manually.
""" # noqa: E501


__version__ = "1.0.0"

# Define package exports
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,6 @@
Do not edit the class manually.
""" # noqa: E501


# import models into model package
from stackit.runcommand.models.command_details import CommandDetails
from stackit.runcommand.models.command_template import CommandTemplate
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -32,9 +32,9 @@ class CommandTemplateSchema(BaseModel):
description: Optional[StrictStr] = None
name: Optional[StrictStr] = None
os_type: Optional[List[StrictStr]] = Field(default=None, alias="osType")
parameter_schema: Optional[ParametersSchema] = Field(default=None, alias="parameterSchema")
parameters_schema: Optional[ParametersSchema] = Field(default=None, alias="parametersSchema")
title: Optional[StrictStr] = None
__properties: ClassVar[List[str]] = ["description", "name", "osType", "parameterSchema", "title"]
__properties: ClassVar[List[str]] = ["description", "name", "osType", "parametersSchema", "title"]

model_config = ConfigDict(
populate_by_name=True,
Expand Down Expand Up @@ -73,9 +73,9 @@ def to_dict(self) -> Dict[str, Any]:
exclude=excluded_fields,
exclude_none=True,
)
# override the default output from pydantic by calling `to_dict()` of parameter_schema
if self.parameter_schema:
_dict["parameterSchema"] = self.parameter_schema.to_dict()
# override the default output from pydantic by calling `to_dict()` of parameters_schema
if self.parameters_schema:
_dict["parametersSchema"] = self.parameters_schema.to_dict()
return _dict

@classmethod
Expand All @@ -92,9 +92,9 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
"description": obj.get("description"),
"name": obj.get("name"),
"osType": obj.get("osType"),
"parameterSchema": (
ParametersSchema.from_dict(obj["parameterSchema"])
if obj.get("parameterSchema") is not None
"parametersSchema": (
ParametersSchema.from_dict(obj["parametersSchema"])
if obj.get("parametersSchema") is not None
else None
),
"title": obj.get("title"),
Expand Down