Skip to content

Commit 4ed10d9

Browse files
feat(api): api update
1 parent 334a510 commit 4ed10d9

File tree

13 files changed

+64
-60
lines changed

13 files changed

+64
-60
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: 1739
2-
openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/cloudflare%2Fcloudflare-2ce6ed58989278dcccbfe7c717fcbbb3c8be830ac0d0de20f2e255ccda719a16.yml
3-
openapi_spec_hash: dd4866fddb7b30cf5643495c95614ca3
2+
openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/cloudflare%2Fcloudflare-d91abfd9ef1b873fc9f31227f8dfe6130806a3a92d9dc841aa14064607690a7b.yml
3+
openapi_spec_hash: 119fefce95d937345b6694bbbb0d5d1e
44
config_hash: 7e270b3449efce600e3469937a344c2d

api.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6702,7 +6702,7 @@ Methods:
67026702

67036703
Methods:
67046704

6705-
- <code title="get /accounts/{account_id}/gateway/configuration/custom_certificate">client.zero_trust.gateway.configurations.custom_certificate.<a href="./src/cloudflare/resources/zero_trust/gateway/configurations/custom_certificate.py">get</a>(\*, account_id) -> <a href="./src/cloudflare/types/zero_trust/gateway/custom_certificate_settings.py">CustomCertificateSettings</a></code>
6705+
- <code title="get /accounts/{account_id}/gateway/configuration/custom_certificate">client.zero_trust.gateway.configurations.custom_certificate.<a href="./src/cloudflare/resources/zero_trust/gateway/configurations/custom_certificate.py">get</a>(\*, account_id) -> <a href="./src/cloudflare/types/zero_trust/gateway/custom_certificate_settings.py">Optional[CustomCertificateSettings]</a></code>
67066706

67076707
### Lists
67086708

src/cloudflare/resources/logs/control/cmb/config.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -62,7 +62,7 @@ def create(
6262
Args:
6363
account_id: Identifier.
6464
65-
regions: Comma-separated list of regions.
65+
regions: Name of the region.
6666
6767
extra_headers: Send extra headers
6868
@@ -204,7 +204,7 @@ async def create(
204204
Args:
205205
account_id: Identifier.
206206
207-
regions: Comma-separated list of regions.
207+
regions: Name of the region.
208208
209209
extra_headers: Send extra headers
210210

src/cloudflare/resources/zero_trust/gateway/configurations/custom_certificate.py

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,8 @@
22

33
from __future__ import annotations
44

5+
from typing import Optional
6+
57
import httpx
68

79
from ....._types import NOT_GIVEN, Body, Query, Headers, NotGiven
@@ -49,7 +51,7 @@ def get(
4951
extra_query: Query | None = None,
5052
extra_body: Body | None = None,
5153
timeout: float | httpx.Timeout | None | NotGiven = NOT_GIVEN,
52-
) -> CustomCertificateSettings:
54+
) -> Optional[CustomCertificateSettings]:
5355
"""
5456
Fetches the current Zero Trust certificate configuration.
5557
@@ -103,7 +105,7 @@ async def get(
103105
extra_query: Query | None = None,
104106
extra_body: Body | None = None,
105107
timeout: float | httpx.Timeout | None | NotGiven = NOT_GIVEN,
106-
) -> CustomCertificateSettings:
108+
) -> Optional[CustomCertificateSettings]:
107109
"""
108110
Fetches the current Zero Trust certificate configuration.
109111

src/cloudflare/resources/zero_trust/gateway/rules.py

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -75,12 +75,12 @@ def create(
7575
description: str | NotGiven = NOT_GIVEN,
7676
device_posture: str | NotGiven = NOT_GIVEN,
7777
enabled: bool | NotGiven = NOT_GIVEN,
78-
expiration: rule_create_params.Expiration | NotGiven = NOT_GIVEN,
78+
expiration: Optional[rule_create_params.Expiration] | NotGiven = NOT_GIVEN,
7979
filters: List[GatewayFilter] | NotGiven = NOT_GIVEN,
8080
identity: str | NotGiven = NOT_GIVEN,
8181
precedence: int | NotGiven = NOT_GIVEN,
8282
rule_settings: RuleSettingParam | NotGiven = NOT_GIVEN,
83-
schedule: ScheduleParam | NotGiven = NOT_GIVEN,
83+
schedule: Optional[ScheduleParam] | NotGiven = NOT_GIVEN,
8484
traffic: str | NotGiven = NOT_GIVEN,
8585
# Use the following arguments if you need to pass additional parameters to the API that aren't available via kwargs.
8686
# The extra values given here take precedence over values defined on the client or passed to this method.
@@ -193,12 +193,12 @@ def update(
193193
description: str | NotGiven = NOT_GIVEN,
194194
device_posture: str | NotGiven = NOT_GIVEN,
195195
enabled: bool | NotGiven = NOT_GIVEN,
196-
expiration: rule_update_params.Expiration | NotGiven = NOT_GIVEN,
196+
expiration: Optional[rule_update_params.Expiration] | NotGiven = NOT_GIVEN,
197197
filters: List[GatewayFilter] | NotGiven = NOT_GIVEN,
198198
identity: str | NotGiven = NOT_GIVEN,
199199
precedence: int | NotGiven = NOT_GIVEN,
200200
rule_settings: RuleSettingParam | NotGiven = NOT_GIVEN,
201-
schedule: ScheduleParam | NotGiven = NOT_GIVEN,
201+
schedule: Optional[ScheduleParam] | NotGiven = NOT_GIVEN,
202202
traffic: str | NotGiven = NOT_GIVEN,
203203
# Use the following arguments if you need to pass additional parameters to the API that aren't available via kwargs.
204204
# The extra values given here take precedence over values defined on the client or passed to this method.
@@ -499,12 +499,12 @@ async def create(
499499
description: str | NotGiven = NOT_GIVEN,
500500
device_posture: str | NotGiven = NOT_GIVEN,
501501
enabled: bool | NotGiven = NOT_GIVEN,
502-
expiration: rule_create_params.Expiration | NotGiven = NOT_GIVEN,
502+
expiration: Optional[rule_create_params.Expiration] | NotGiven = NOT_GIVEN,
503503
filters: List[GatewayFilter] | NotGiven = NOT_GIVEN,
504504
identity: str | NotGiven = NOT_GIVEN,
505505
precedence: int | NotGiven = NOT_GIVEN,
506506
rule_settings: RuleSettingParam | NotGiven = NOT_GIVEN,
507-
schedule: ScheduleParam | NotGiven = NOT_GIVEN,
507+
schedule: Optional[ScheduleParam] | NotGiven = NOT_GIVEN,
508508
traffic: str | NotGiven = NOT_GIVEN,
509509
# Use the following arguments if you need to pass additional parameters to the API that aren't available via kwargs.
510510
# The extra values given here take precedence over values defined on the client or passed to this method.
@@ -617,12 +617,12 @@ async def update(
617617
description: str | NotGiven = NOT_GIVEN,
618618
device_posture: str | NotGiven = NOT_GIVEN,
619619
enabled: bool | NotGiven = NOT_GIVEN,
620-
expiration: rule_update_params.Expiration | NotGiven = NOT_GIVEN,
620+
expiration: Optional[rule_update_params.Expiration] | NotGiven = NOT_GIVEN,
621621
filters: List[GatewayFilter] | NotGiven = NOT_GIVEN,
622622
identity: str | NotGiven = NOT_GIVEN,
623623
precedence: int | NotGiven = NOT_GIVEN,
624624
rule_settings: RuleSettingParam | NotGiven = NOT_GIVEN,
625-
schedule: ScheduleParam | NotGiven = NOT_GIVEN,
625+
schedule: Optional[ScheduleParam] | NotGiven = NOT_GIVEN,
626626
traffic: str | NotGiven = NOT_GIVEN,
627627
# Use the following arguments if you need to pass additional parameters to the API that aren't available via kwargs.
628628
# The extra values given here take precedence over values defined on the client or passed to this method.

src/cloudflare/types/logs/control/cmb/cmb_config.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,4 +9,4 @@
99

1010
class CmbConfig(BaseModel):
1111
regions: Optional[str] = None
12-
"""Comma-separated list of regions."""
12+
"""Name of the region."""

src/cloudflare/types/logs/control/cmb/config_create_params.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,4 +12,4 @@ class ConfigCreateParams(TypedDict, total=False):
1212
"""Identifier."""
1313

1414
regions: str
15-
"""Comma-separated list of regions."""
15+
"""Name of the region."""

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

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,7 @@
22

33
from __future__ import annotations
44

5+
from typing import Optional
56
from typing_extensions import TypedDict
67

78
from .notification_settings_param import NotificationSettingsParam
@@ -19,7 +20,7 @@ class AntiVirusSettingsParam(TypedDict, total=False):
1920
fail_closed: bool
2021
"""Block requests for files that cannot be scanned."""
2122

22-
notification_settings: NotificationSettingsParam
23+
notification_settings: Optional[NotificationSettingsParam]
2324
"""
2425
Configure a message to display on the user's device when an antivirus search is
2526
performed.

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

Lines changed: 14 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,7 @@
22

33
from __future__ import annotations
44

5+
from typing import Optional
56
from typing_extensions import Literal, Required, TypedDict
67

78
from .tls_settings_param import TLSSettingsParam
@@ -41,47 +42,47 @@ class Sandbox(TypedDict, total=False):
4142

4243

4344
class GatewayConfigurationSettingsParam(TypedDict, total=False):
44-
activity_log: ActivityLogSettingsParam
45+
activity_log: Optional[ActivityLogSettingsParam]
4546
"""Activity log settings."""
4647

47-
antivirus: AntiVirusSettingsParam
48+
antivirus: Optional[AntiVirusSettingsParam]
4849
"""Anti-virus settings."""
4950

50-
block_page: BlockPageSettingsParam
51+
block_page: Optional[BlockPageSettingsParam]
5152
"""Block page layout settings."""
5253

53-
body_scanning: BodyScanningSettingsParam
54+
body_scanning: Optional[BodyScanningSettingsParam]
5455
"""DLP body scanning settings."""
5556

56-
browser_isolation: BrowserIsolationSettingsParam
57+
browser_isolation: Optional[BrowserIsolationSettingsParam]
5758
"""Browser isolation settings."""
5859

59-
certificate: Certificate
60+
certificate: Optional[Certificate]
6061
"""Certificate settings for Gateway TLS interception.
6162
6263
If not specified, the Cloudflare Root CA will be used.
6364
"""
6465

65-
custom_certificate: CustomCertificateSettingsParam
66+
custom_certificate: Optional[CustomCertificateSettingsParam]
6667
"""Custom certificate settings for BYO-PKI.
6768
6869
(deprecated and replaced by `certificate`)
6970
"""
7071

71-
extended_email_matching: ExtendedEmailMatchingParam
72+
extended_email_matching: Optional[ExtendedEmailMatchingParam]
7273
"""Extended e-mail matching settings."""
7374

74-
fips: FipsSettingsParam
75+
fips: Optional[FipsSettingsParam]
7576
"""FIPS settings."""
7677

77-
host_selector: HostSelector
78+
host_selector: Optional[HostSelector]
7879
"""Setting to enable host selector in egress policies."""
7980

80-
protocol_detection: ProtocolDetectionParam
81+
protocol_detection: Optional[ProtocolDetectionParam]
8182
"""Protocol Detection settings."""
8283

83-
sandbox: Sandbox
84+
sandbox: Optional[Sandbox]
8485
"""Sandbox settings."""
8586

86-
tls_decrypt: TLSSettingsParam
87+
tls_decrypt: Optional[TLSSettingsParam]
8788
"""TLS interception settings."""

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

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22

33
from __future__ import annotations
44

5-
from typing import List, Union
5+
from typing import List, Union, Optional
66
from datetime import datetime
77
from typing_extensions import Literal, Required, Annotated, TypedDict
88

@@ -54,7 +54,7 @@ class RuleCreateParams(TypedDict, total=False):
5454
enabled: bool
5555
"""True if the rule is enabled."""
5656

57-
expiration: Expiration
57+
expiration: Optional[Expiration]
5858
"""The expiration time stamp and default duration of a DNS policy.
5959
6060
Takes precedence over the policy's `schedule` configuration, if any.
@@ -83,7 +83,7 @@ class RuleCreateParams(TypedDict, total=False):
8383
rule_settings: RuleSettingParam
8484
"""Additional settings that modify the rule's action."""
8585

86-
schedule: ScheduleParam
86+
schedule: Optional[ScheduleParam]
8787
"""The schedule for activating DNS policies.
8888
8989
This does not apply to HTTP or network policies.

0 commit comments

Comments
 (0)