Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat(api): update via SDK Studio #862

Merged
merged 1 commit into from
Jun 6, 2024
Merged
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
2 changes: 1 addition & 1 deletion .stats.yml
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
configured_endpoints: 1336
configured_endpoints: 1343
openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/cloudflare%2Fcloudflare-efdb1c15faba015f2904e7db0946e71b5bd84a6e4b96256aed210e7e0113cf17.yml
43 changes: 35 additions & 8 deletions api.md
Original file line number Diff line number Diff line change
Expand Up @@ -303,14 +303,6 @@ Methods:

- <code title="put /zones/{zone_id}/activation_check">client.zones.activation_check.<a href="./src/cloudflare/resources/zones/activation_check.py">trigger</a>(\*, zone_id) -> <a href="./src/cloudflare/types/zones/activation_check_trigger_response.py">Optional</a></code>

## DNSSettings

Types:

```python
from cloudflare.types.zones import DNSSetting, Nameserver
```

## Settings

### ZeroRTT
Expand Down Expand Up @@ -1650,6 +1642,19 @@ Methods:
- <code title="post /zones/{zone_id}/dns_records/import">client.dns.records.<a href="./src/cloudflare/resources/dns/records.py">import\_</a>(\*, zone_id, \*\*<a href="src/cloudflare/types/dns/record_import_params.py">params</a>) -> <a href="./src/cloudflare/types/dns/record_import_response.py">Optional</a></code>
- <code title="post /zones/{zone_id}/dns_records/scan">client.dns.records.<a href="./src/cloudflare/resources/dns/records.py">scan</a>(\*, zone_id, \*\*<a href="src/cloudflare/types/dns/record_scan_params.py">params</a>) -> <a href="./src/cloudflare/types/dns/record_scan_response.py">Optional</a></code>

## Settings

Types:

```python
from cloudflare.types.dns import DNSSetting, Nameserver, SettingEditResponse, SettingGetResponse
```

Methods:

- <code title="patch /{account_or_zone}/{account_or_zone_id}/dns_settings">client.dns.settings.<a href="./src/cloudflare/resources/dns/settings.py">edit</a>(\*, account_id, zone_id, \*\*<a href="src/cloudflare/types/dns/setting_edit_params.py">params</a>) -> <a href="./src/cloudflare/types/dns/setting_edit_response.py">Optional</a></code>
- <code title="get /{account_or_zone}/{account_or_zone_id}/dns_settings">client.dns.settings.<a href="./src/cloudflare/resources/dns/settings.py">get</a>(\*, account_id, zone_id) -> <a href="./src/cloudflare/types/dns/setting_get_response.py">Optional</a></code>

## Analytics

### Reports
Expand Down Expand Up @@ -5635,6 +5640,28 @@ Methods:
- <code title="delete /accounts/{account_id}/access/tags/{tag_name}">client.zero_trust.access.tags.<a href="./src/cloudflare/resources/zero_trust/access/tags.py">delete</a>(tag_name, \*, account_id) -> <a href="./src/cloudflare/types/zero_trust/access/tag_delete_response.py">Optional</a></code>
- <code title="get /accounts/{account_id}/access/tags/{tag_name}">client.zero_trust.access.tags.<a href="./src/cloudflare/resources/zero_trust/access/tags.py">get</a>(tag_name, \*, account_id) -> <a href="./src/cloudflare/types/zero_trust/access/tag.py">Optional</a></code>

### Policies

Types:

```python
from cloudflare.types.zero_trust.access import (
PolicyCreateResponse,
PolicyUpdateResponse,
PolicyListResponse,
PolicyDeleteResponse,
PolicyGetResponse,
)
```

Methods:

- <code title="post /accounts/{account_id}/access/policies">client.zero_trust.access.policies.<a href="./src/cloudflare/resources/zero_trust/access/policies.py">create</a>(\*, account_id, \*\*<a href="src/cloudflare/types/zero_trust/access/policy_create_params.py">params</a>) -> <a href="./src/cloudflare/types/zero_trust/access/policy_create_response.py">Optional</a></code>
- <code title="put /accounts/{account_id}/access/policies/{policy_id}">client.zero_trust.access.policies.<a href="./src/cloudflare/resources/zero_trust/access/policies.py">update</a>(policy_id, \*, account_id, \*\*<a href="src/cloudflare/types/zero_trust/access/policy_update_params.py">params</a>) -> <a href="./src/cloudflare/types/zero_trust/access/policy_update_response.py">Optional</a></code>
- <code title="get /accounts/{account_id}/access/policies">client.zero_trust.access.policies.<a href="./src/cloudflare/resources/zero_trust/access/policies.py">list</a>(\*, account_id) -> <a href="./src/cloudflare/types/zero_trust/access/policy_list_response.py">SyncSinglePage[PolicyListResponse]</a></code>
- <code title="delete /accounts/{account_id}/access/policies/{policy_id}">client.zero_trust.access.policies.<a href="./src/cloudflare/resources/zero_trust/access/policies.py">delete</a>(policy_id, \*, account_id) -> <a href="./src/cloudflare/types/zero_trust/access/policy_delete_response.py">Optional</a></code>
- <code title="get /accounts/{account_id}/access/policies/{policy_id}">client.zero_trust.access.policies.<a href="./src/cloudflare/resources/zero_trust/access/policies.py">get</a>(policy_id, \*, account_id) -> <a href="./src/cloudflare/types/zero_trust/access/policy_get_response.py">Optional</a></code>

## DEX

Types:
Expand Down
14 changes: 14 additions & 0 deletions src/cloudflare/resources/dns/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,14 @@
FirewallResourceWithStreamingResponse,
AsyncFirewallResourceWithStreamingResponse,
)
from .settings import (
SettingsResource,
AsyncSettingsResource,
SettingsResourceWithRawResponse,
AsyncSettingsResourceWithRawResponse,
SettingsResourceWithStreamingResponse,
AsyncSettingsResourceWithStreamingResponse,
)
from .analytics import (
AnalyticsResource,
AsyncAnalyticsResource,
Expand All @@ -40,6 +48,12 @@
"AsyncRecordsResourceWithRawResponse",
"RecordsResourceWithStreamingResponse",
"AsyncRecordsResourceWithStreamingResponse",
"SettingsResource",
"AsyncSettingsResource",
"SettingsResourceWithRawResponse",
"AsyncSettingsResourceWithRawResponse",
"SettingsResourceWithStreamingResponse",
"AsyncSettingsResourceWithStreamingResponse",
"AnalyticsResource",
"AsyncAnalyticsResource",
"AnalyticsResourceWithRawResponse",
Expand Down
32 changes: 32 additions & 0 deletions src/cloudflare/resources/dns/dns.py
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,14 @@
FirewallResourceWithStreamingResponse,
AsyncFirewallResourceWithStreamingResponse,
)
from .settings import (
SettingsResource,
AsyncSettingsResource,
SettingsResourceWithRawResponse,
AsyncSettingsResourceWithRawResponse,
SettingsResourceWithStreamingResponse,
AsyncSettingsResourceWithStreamingResponse,
)
from ..._compat import cached_property
from .analytics import (
AnalyticsResource,
Expand All @@ -39,6 +47,10 @@ class DNSResource(SyncAPIResource):
def records(self) -> RecordsResource:
return RecordsResource(self._client)

@cached_property
def settings(self) -> SettingsResource:
return SettingsResource(self._client)

@cached_property
def analytics(self) -> AnalyticsResource:
return AnalyticsResource(self._client)
Expand All @@ -61,6 +73,10 @@ class AsyncDNSResource(AsyncAPIResource):
def records(self) -> AsyncRecordsResource:
return AsyncRecordsResource(self._client)

@cached_property
def settings(self) -> AsyncSettingsResource:
return AsyncSettingsResource(self._client)

@cached_property
def analytics(self) -> AsyncAnalyticsResource:
return AsyncAnalyticsResource(self._client)
Expand All @@ -86,6 +102,10 @@ def __init__(self, dns: DNSResource) -> None:
def records(self) -> RecordsResourceWithRawResponse:
return RecordsResourceWithRawResponse(self._dns.records)

@cached_property
def settings(self) -> SettingsResourceWithRawResponse:
return SettingsResourceWithRawResponse(self._dns.settings)

@cached_property
def analytics(self) -> AnalyticsResourceWithRawResponse:
return AnalyticsResourceWithRawResponse(self._dns.analytics)
Expand All @@ -103,6 +123,10 @@ def __init__(self, dns: AsyncDNSResource) -> None:
def records(self) -> AsyncRecordsResourceWithRawResponse:
return AsyncRecordsResourceWithRawResponse(self._dns.records)

@cached_property
def settings(self) -> AsyncSettingsResourceWithRawResponse:
return AsyncSettingsResourceWithRawResponse(self._dns.settings)

@cached_property
def analytics(self) -> AsyncAnalyticsResourceWithRawResponse:
return AsyncAnalyticsResourceWithRawResponse(self._dns.analytics)
Expand All @@ -120,6 +144,10 @@ def __init__(self, dns: DNSResource) -> None:
def records(self) -> RecordsResourceWithStreamingResponse:
return RecordsResourceWithStreamingResponse(self._dns.records)

@cached_property
def settings(self) -> SettingsResourceWithStreamingResponse:
return SettingsResourceWithStreamingResponse(self._dns.settings)

@cached_property
def analytics(self) -> AnalyticsResourceWithStreamingResponse:
return AnalyticsResourceWithStreamingResponse(self._dns.analytics)
Expand All @@ -137,6 +165,10 @@ def __init__(self, dns: AsyncDNSResource) -> None:
def records(self) -> AsyncRecordsResourceWithStreamingResponse:
return AsyncRecordsResourceWithStreamingResponse(self._dns.records)

@cached_property
def settings(self) -> AsyncSettingsResourceWithStreamingResponse:
return AsyncSettingsResourceWithStreamingResponse(self._dns.settings)

@cached_property
def analytics(self) -> AsyncAnalyticsResourceWithStreamingResponse:
return AsyncAnalyticsResourceWithStreamingResponse(self._dns.analytics)
Expand Down
Loading