Skip to content

Commit 0925597

Browse files
feat(api): api update
1 parent 2a6d6ab commit 0925597

File tree

2 files changed

+47
-49
lines changed

2 files changed

+47
-49
lines changed

.stats.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
11
configured_endpoints: 1777
2-
openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/cloudflare%2Fcloudflare-7484ce9010ed66c1828f97b181539a0b5418d1a4cb6be789a12e06a00f4faa0c.yml
3-
openapi_spec_hash: 6a8937b703b594465742ddf82652e181
2+
openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/cloudflare%2Fcloudflare-19d313507009812541708ad5f07abc94e1b76a04125edbb739349275e00200ee.yml
3+
openapi_spec_hash: 913c40ac2c619698530376e0da8d6a6b
44
config_hash: a35e9eb0436652c704bebf7c0a38085b

src/cloudflare/types/zero_trust/gateway/gateway_rule.py

Lines changed: 45 additions & 47 deletions
Original file line numberDiff line numberDiff line change
@@ -36,34 +36,56 @@ class Expiration(BaseModel):
3636

3737

3838
class GatewayRule(BaseModel):
39-
id: Optional[str] = None
40-
"""The API resource UUID."""
41-
42-
action: Optional[
43-
Literal[
44-
"on",
45-
"off",
46-
"allow",
47-
"block",
48-
"scan",
49-
"noscan",
50-
"safesearch",
51-
"ytrestricted",
52-
"isolate",
53-
"noisolate",
54-
"override",
55-
"l4_override",
56-
"egress",
57-
"resolve",
58-
"quarantine",
59-
"redirect",
60-
]
61-
] = None
39+
action: Literal[
40+
"on",
41+
"off",
42+
"allow",
43+
"block",
44+
"scan",
45+
"noscan",
46+
"safesearch",
47+
"ytrestricted",
48+
"isolate",
49+
"noisolate",
50+
"override",
51+
"l4_override",
52+
"egress",
53+
"resolve",
54+
"quarantine",
55+
"redirect",
56+
]
6257
"""
6358
The action to perform when the associated traffic, identity, and device posture
6459
expressions are either absent or evaluate to `true`.
6560
"""
6661

62+
enabled: bool
63+
"""True if the rule is enabled."""
64+
65+
filters: List[GatewayFilter]
66+
"""
67+
The protocol or layer to evaluate the traffic, identity, and device posture
68+
expressions.
69+
"""
70+
71+
name: str
72+
"""The name of the rule."""
73+
74+
precedence: int
75+
"""Precedence sets the order of your rules.
76+
77+
Lower values indicate higher precedence. At each processing phase, applicable
78+
rules are evaluated in ascending order of this value. Refer to
79+
[Order of enforcement](http://developers.cloudflare.com/learning-paths/secure-internet-traffic/understand-policies/order-of-enforcement/#manage-precedence-with-terraform)
80+
docs on how to manage precedence via Terraform.
81+
"""
82+
83+
traffic: str
84+
"""The wirefilter expression used for traffic matching."""
85+
86+
id: Optional[str] = None
87+
"""The API resource UUID."""
88+
6789
created_at: Optional[datetime] = None
6890

6991
deleted_at: Optional[datetime] = None
@@ -75,9 +97,6 @@ class GatewayRule(BaseModel):
7597
device_posture: Optional[str] = None
7698
"""The wirefilter expression used for device posture check matching."""
7799

78-
enabled: Optional[bool] = None
79-
"""True if the rule is enabled."""
80-
81100
expiration: Optional[Expiration] = None
82101
"""The expiration time stamp and default duration of a DNS policy.
83102
@@ -86,30 +105,12 @@ class GatewayRule(BaseModel):
86105
This does not apply to HTTP or network policies.
87106
"""
88107

89-
filters: Optional[List[GatewayFilter]] = None
90-
"""
91-
The protocol or layer to evaluate the traffic, identity, and device posture
92-
expressions.
93-
"""
94-
95108
identity: Optional[str] = None
96109
"""The wirefilter expression used for identity matching."""
97110

98-
name: Optional[str] = None
99-
"""The name of the rule."""
100-
101111
not_sharable: Optional[bool] = None
102112
"""The rule cannot be shared via the Orgs API"""
103113

104-
precedence: Optional[int] = None
105-
"""Precedence sets the order of your rules.
106-
107-
Lower values indicate higher precedence. At each processing phase, applicable
108-
rules are evaluated in ascending order of this value. Refer to
109-
[Order of enforcement](http://developers.cloudflare.com/learning-paths/secure-internet-traffic/understand-policies/order-of-enforcement/#manage-precedence-with-terraform)
110-
docs on how to manage precedence via Terraform.
111-
"""
112-
113114
read_only: Optional[bool] = None
114115
"""
115116
The rule was shared via the Orgs API and cannot be edited by the current account
@@ -127,9 +128,6 @@ class GatewayRule(BaseModel):
127128
source_account: Optional[str] = None
128129
"""account tag of account that created the rule"""
129130

130-
traffic: Optional[str] = None
131-
"""The wirefilter expression used for traffic matching."""
132-
133131
updated_at: Optional[datetime] = None
134132

135133
version: Optional[int] = None

0 commit comments

Comments
 (0)