Skip to content

Commit 27c5beb

Browse files
Generate ufw
1 parent f57da4e commit 27c5beb

2 files changed

Lines changed: 14 additions & 1 deletion

File tree

‎services/ufw/oas_commit‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
d3f51a99ec81d4226be8c6d4826ed2547014edb0
1+
2cac55e8befab5efab8fb3e9d5f0ac99509bc0fb

‎services/ufw/src/stackit/ufw/models/rule_response.py‎

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -56,6 +56,7 @@ class RuleResponse(BaseModel):
5656
source_ip: StrictStr = Field(alias="sourceIP")
5757
stateful: Optional[StrictBool] = None
5858
status: StrictStr = Field(description="The current state of the resource.")
59+
sync_status: Optional[StrictStr] = Field(default=None, alias="syncStatus")
5960
type: StrictStr = Field(description='The type of the rule (e.g., "ACL", "SecurityRule").')
6061
__properties: ClassVar[List[str]] = [
6162
"description",
@@ -78,6 +79,7 @@ class RuleResponse(BaseModel):
7879
"sourceIP",
7980
"stateful",
8081
"status",
82+
"syncStatus",
8183
"type",
8284
]
8385

@@ -90,6 +92,16 @@ def status_validate_enum(cls, value):
9092
)
9193
return value
9294

95+
@field_validator("sync_status")
96+
def sync_status_validate_enum(cls, value):
97+
"""Validates the enum"""
98+
if value is None:
99+
return value
100+
101+
if value not in set(["SYNCED", "NOT_SYNCED"]):
102+
raise ValueError("must be one of enum values ('SYNCED', 'NOT_SYNCED')")
103+
return value
104+
93105
@field_validator("type")
94106
def type_validate_enum(cls, value):
95107
"""Validates the enum"""
@@ -167,6 +179,7 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
167179
"sourceIP": obj.get("sourceIP"),
168180
"stateful": obj.get("stateful"),
169181
"status": obj.get("status"),
182+
"syncStatus": obj.get("syncStatus"),
170183
"type": obj.get("type"),
171184
}
172185
)

0 commit comments

Comments
 (0)