Skip to content

Commit 094a1c0

Browse files
feat(api): api update
1 parent bf0fafe commit 094a1c0

8 files changed

Lines changed: 34 additions & 6 deletions

File tree

.stats.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
11
configured_endpoints: 1775
2-
openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/cloudflare%2Fcloudflare-7041628cf0d2afed7b64536d404b91abad90d4203c64c6289c02c5d65aa2f8c8.yml
3-
openapi_spec_hash: fc297d0a0a93df81a66c090a3d1ac374
2+
openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/cloudflare%2Fcloudflare-f759309b015ca845e3ba5577121deedfa5cce762cb1df35e6bf2d846f485cf59.yml
3+
openapi_spec_hash: 5fcc8f88643596819d2afd717be92c53
44
config_hash: 4a37da9893560914a7ac1a75cc01202a

src/cloudflare/types/rulesets/rule_create_params.py

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2102,6 +2102,12 @@ class SkipRule(TypedDict, total=False):
21022102

21032103

21042104
class SkipRuleActionParameters(TypedDict, total=False):
2105+
phase: Literal["current"]
2106+
"""A phase to skip the execution of.
2107+
2108+
This property is only compatible with products.
2109+
"""
2110+
21052111
phases: List[Phase]
21062112
"""A list of phases to skip the execution of.
21072113
@@ -2250,7 +2256,7 @@ class SetCacheSettingsRule(TypedDict, total=False):
22502256

22512257

22522258
class SetCacheSettingsRuleActionParametersBrowserTTL(TypedDict, total=False):
2253-
mode: Required[Literal["respect_origin", "bypass_by_default", "override_origin"]]
2259+
mode: Required[Literal["respect_origin", "bypass_by_default", "override_origin", "bypass"]]
22542260
"""Determines which browser ttl mode to use."""
22552261

22562262
default: int

src/cloudflare/types/rulesets/rule_edit_params.py

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2144,6 +2144,12 @@ class SkipRule(TypedDict, total=False):
21442144

21452145

21462146
class SkipRuleActionParameters(TypedDict, total=False):
2147+
phase: Literal["current"]
2148+
"""A phase to skip the execution of.
2149+
2150+
This property is only compatible with products.
2151+
"""
2152+
21472153
phases: List[Phase]
21482154
"""A list of phases to skip the execution of.
21492155
@@ -2295,7 +2301,7 @@ class SetCacheSettingsRule(TypedDict, total=False):
22952301

22962302

22972303
class SetCacheSettingsRuleActionParametersBrowserTTL(TypedDict, total=False):
2298-
mode: Required[Literal["respect_origin", "bypass_by_default", "override_origin"]]
2304+
mode: Required[Literal["respect_origin", "bypass_by_default", "override_origin", "bypass"]]
22992305
"""Determines which browser ttl mode to use."""
23002306

23012307
default: int

src/cloudflare/types/rulesets/set_cache_settings_rule.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -39,7 +39,7 @@
3939

4040

4141
class ActionParametersBrowserTTL(BaseModel):
42-
mode: Literal["respect_origin", "bypass_by_default", "override_origin"]
42+
mode: Literal["respect_origin", "bypass_by_default", "override_origin", "bypass"]
4343
"""Determines which browser ttl mode to use."""
4444

4545
default: Optional[int] = None

src/cloudflare/types/rulesets/set_cache_settings_rule_param.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -37,7 +37,7 @@
3737

3838

3939
class ActionParametersBrowserTTL(TypedDict, total=False):
40-
mode: Required[Literal["respect_origin", "bypass_by_default", "override_origin"]]
40+
mode: Required[Literal["respect_origin", "bypass_by_default", "override_origin", "bypass"]]
4141
"""Determines which browser ttl mode to use."""
4242

4343
default: int

src/cloudflare/types/rulesets/skip_rule.py

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -12,6 +12,12 @@
1212

1313

1414
class ActionParameters(BaseModel):
15+
phase: Optional[Literal["current"]] = None
16+
"""A phase to skip the execution of.
17+
18+
This property is only compatible with products.
19+
"""
20+
1521
phases: Optional[List[Phase]] = None
1622
"""A list of phases to skip the execution of.
1723

src/cloudflare/types/rulesets/skip_rule_param.py

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -12,6 +12,12 @@
1212

1313

1414
class ActionParameters(TypedDict, total=False):
15+
phase: Literal["current"]
16+
"""A phase to skip the execution of.
17+
18+
This property is only compatible with products.
19+
"""
20+
1521
phases: List[Phase]
1622
"""A list of phases to skip the execution of.
1723

tests/api_resources/rulesets/test_rules.py

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1294,6 +1294,7 @@ def test_method_create_with_all_params_overload_14(self, client: Cloudflare) ->
12941294
id="3a03d665bac047339bb530ecb439a90d",
12951295
action="skip",
12961296
action_parameters={
1297+
"phase": "current",
12971298
"phases": ["http_request_firewall_custom"],
12981299
"products": ["bic"],
12991300
"rules": {"4814384a9e5d4991b9815dcfc25d2f1f": ["8ac8bc2a661e475d940980f9317f28e1"]},
@@ -3340,6 +3341,7 @@ def test_method_edit_with_all_params_overload_14(self, client: Cloudflare) -> No
33403341
id="3a03d665bac047339bb530ecb439a90d",
33413342
action="skip",
33423343
action_parameters={
3344+
"phase": "current",
33433345
"phases": ["http_request_firewall_custom"],
33443346
"products": ["bic"],
33453347
"rules": {"4814384a9e5d4991b9815dcfc25d2f1f": ["8ac8bc2a661e475d940980f9317f28e1"]},
@@ -5195,6 +5197,7 @@ async def test_method_create_with_all_params_overload_14(self, async_client: Asy
51955197
id="3a03d665bac047339bb530ecb439a90d",
51965198
action="skip",
51975199
action_parameters={
5200+
"phase": "current",
51985201
"phases": ["http_request_firewall_custom"],
51995202
"products": ["bic"],
52005203
"rules": {"4814384a9e5d4991b9815dcfc25d2f1f": ["8ac8bc2a661e475d940980f9317f28e1"]},
@@ -7241,6 +7244,7 @@ async def test_method_edit_with_all_params_overload_14(self, async_client: Async
72417244
id="3a03d665bac047339bb530ecb439a90d",
72427245
action="skip",
72437246
action_parameters={
7247+
"phase": "current",
72447248
"phases": ["http_request_firewall_custom"],
72457249
"products": ["bic"],
72467250
"rules": {"4814384a9e5d4991b9815dcfc25d2f1f": ["8ac8bc2a661e475d940980f9317f28e1"]},

0 commit comments

Comments
 (0)