Skip to content

Commit

Permalink
feat(api): update via SDK Studio (#775)
Browse files Browse the repository at this point in the history
  • Loading branch information
stainless-app[bot] authored Jun 3, 2024
1 parent 7b20668 commit c3fa7ab
Show file tree
Hide file tree
Showing 44 changed files with 6,216 additions and 2 deletions.
4 changes: 2 additions & 2 deletions .stats.yml
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
configured_endpoints: 1321
openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/cloudflare%2Fcloudflare-e83b5eb5706ca8b525141f506338cd1d465eb133815b9ddc53df612ea4a2ecef.yml
configured_endpoints: 1335
openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/cloudflare%2Fcloudflare-ac33a501d722d88a0ebf590d74e32c77066a57b327cb3a2fae156558b6e7b75c.yml
76 changes: 76 additions & 0 deletions api.md
Original file line number Diff line number Diff line change
Expand Up @@ -3361,6 +3361,40 @@ Methods:

# Addressing

## RegionalHostnames

Types:

```python
from cloudflare.types.addressing import (
RegionalHostnameCreateResponse,
RegionalHostnameListResponse,
RegionalHostnameDeleteResponse,
RegionalHostnameEditResponse,
RegionalHostnameGetResponse,
)
```

Methods:

- <code title="post /zones/{zone_id}/addressing/regional_hostnames">client.addressing.regional_hostnames.<a href="./src/cloudflare/resources/addressing/regional_hostnames/regional_hostnames.py">create</a>(\*, zone_id, \*\*<a href="src/cloudflare/types/addressing/regional_hostname_create_params.py">params</a>) -> <a href="./src/cloudflare/types/addressing/regional_hostname_create_response.py">Optional</a></code>
- <code title="get /zones/{zone_id}/addressing/regional_hostnames">client.addressing.regional_hostnames.<a href="./src/cloudflare/resources/addressing/regional_hostnames/regional_hostnames.py">list</a>(\*, zone_id) -> <a href="./src/cloudflare/types/addressing/regional_hostname_list_response.py">SyncSinglePage[RegionalHostnameListResponse]</a></code>
- <code title="delete /zones/{zone_id}/addressing/regional_hostnames/{hostname}">client.addressing.regional_hostnames.<a href="./src/cloudflare/resources/addressing/regional_hostnames/regional_hostnames.py">delete</a>(hostname, \*, zone_id) -> <a href="./src/cloudflare/types/addressing/regional_hostname_delete_response.py">RegionalHostnameDeleteResponse</a></code>
- <code title="patch /zones/{zone_id}/addressing/regional_hostnames/{hostname}">client.addressing.regional_hostnames.<a href="./src/cloudflare/resources/addressing/regional_hostnames/regional_hostnames.py">edit</a>(hostname, \*, zone_id, \*\*<a href="src/cloudflare/types/addressing/regional_hostname_edit_params.py">params</a>) -> <a href="./src/cloudflare/types/addressing/regional_hostname_edit_response.py">Optional</a></code>
- <code title="get /zones/{zone_id}/addressing/regional_hostnames/{hostname}">client.addressing.regional_hostnames.<a href="./src/cloudflare/resources/addressing/regional_hostnames/regional_hostnames.py">get</a>(hostname, \*, zone_id) -> <a href="./src/cloudflare/types/addressing/regional_hostname_get_response.py">Optional</a></code>

### Regions

Types:

```python
from cloudflare.types.addressing.regional_hostnames import RegionListResponse
```

Methods:

- <code title="get /accounts/{account_id}/addressing/regional_hostnames/regions">client.addressing.regional_hostnames.regions.<a href="./src/cloudflare/resources/addressing/regional_hostnames/regions.py">list</a>(\*, account_id) -> <a href="./src/cloudflare/types/addressing/regional_hostnames/region_list_response.py">SyncSinglePage[RegionListResponse]</a></code>

## Services

Types:
Expand Down Expand Up @@ -3907,6 +3941,26 @@ Types:
from cloudflare.types.magic_transit import HealthCheck, HealthCheckRate, HealthCheckType
```

## Apps

Types:

```python
from cloudflare.types.magic_transit import (
AppCreateResponse,
AppUpdateResponse,
AppListResponse,
AppDeleteResponse,
)
```

Methods:

- <code title="post /accounts/{account_id}/magic/apps">client.magic_transit.apps.<a href="./src/cloudflare/resources/magic_transit/apps.py">create</a>(\*, account_id, \*\*<a href="src/cloudflare/types/magic_transit/app_create_params.py">params</a>) -> <a href="./src/cloudflare/types/magic_transit/app_create_response.py">Optional</a></code>
- <code title="put /accounts/{account_id}/magic/apps/{account_app_id}">client.magic_transit.apps.<a href="./src/cloudflare/resources/magic_transit/apps.py">update</a>(account_app_id, \*, account_id, \*\*<a href="src/cloudflare/types/magic_transit/app_update_params.py">params</a>) -> <a href="./src/cloudflare/types/magic_transit/app_update_response.py">Optional</a></code>
- <code title="get /accounts/{account_id}/magic/apps">client.magic_transit.apps.<a href="./src/cloudflare/resources/magic_transit/apps.py">list</a>(\*, account_id) -> <a href="./src/cloudflare/types/magic_transit/app_list_response.py">SyncSinglePage[AppListResponse]</a></code>
- <code title="delete /accounts/{account_id}/magic/apps/{account_app_id}">client.magic_transit.apps.<a href="./src/cloudflare/resources/magic_transit/apps.py">delete</a>(account_app_id, \*, account_id) -> <a href="./src/cloudflare/types/magic_transit/app_delete_response.py">Optional</a></code>

## CfInterconnects

Types:
Expand Down Expand Up @@ -4073,6 +4127,28 @@ Methods:
- <code title="patch /accounts/{account_id}/magic/sites/{site_id}/wans/{wan_id}">client.magic_transit.sites.wans.<a href="./src/cloudflare/resources/magic_transit/sites/wans.py">edit</a>(wan_id, \*, account_id, site_id, \*\*<a href="src/cloudflare/types/magic_transit/sites/wan_edit_params.py">params</a>) -> <a href="./src/cloudflare/types/magic_transit/sites/wan.py">WAN</a></code>
- <code title="get /accounts/{account_id}/magic/sites/{site_id}/wans/{wan_id}">client.magic_transit.sites.wans.<a href="./src/cloudflare/resources/magic_transit/sites/wans.py">get</a>(wan_id, \*, account_id, site_id) -> <a href="./src/cloudflare/types/magic_transit/sites/wan.py">WAN</a></code>

### Sites

#### AppConfiguration

Types:

```python
from cloudflare.types.magic_transit.sites.sites import (
AppConfigurationCreateResponse,
AppConfigurationUpdateResponse,
AppConfigurationListResponse,
AppConfigurationDeleteResponse,
)
```

Methods:

- <code title="post /accounts/{account_id}/magic/sites/{site_id}/app_configs">client.magic_transit.sites.sites.app_configuration.<a href="./src/cloudflare/resources/magic_transit/sites/sites/app_configuration.py">create</a>(site_id, \*, account_id, \*\*<a href="src/cloudflare/types/magic_transit/sites/sites/app_configuration_create_params.py">params</a>) -> <a href="./src/cloudflare/types/magic_transit/sites/sites/app_configuration_create_response.py">Optional</a></code>
- <code title="put /accounts/{account_id}/magic/sites/{site_id}/app_configs/{app_config_id}">client.magic_transit.sites.sites.app_configuration.<a href="./src/cloudflare/resources/magic_transit/sites/sites/app_configuration.py">update</a>(app_config_id, \*, account_id, site_id, \*\*<a href="src/cloudflare/types/magic_transit/sites/sites/app_configuration_update_params.py">params</a>) -> <a href="./src/cloudflare/types/magic_transit/sites/sites/app_configuration_update_response.py">Optional</a></code>
- <code title="get /accounts/{account_id}/magic/sites/{site_id}/app_configs">client.magic_transit.sites.sites.app_configuration.<a href="./src/cloudflare/resources/magic_transit/sites/sites/app_configuration.py">list</a>(site_id, \*, account_id) -> <a href="./src/cloudflare/types/magic_transit/sites/sites/app_configuration_list_response.py">SyncSinglePage[AppConfigurationListResponse]</a></code>
- <code title="delete /accounts/{account_id}/magic/sites/{site_id}/app_configs/{app_config_id}">client.magic_transit.sites.sites.app_configuration.<a href="./src/cloudflare/resources/magic_transit/sites/sites/app_configuration.py">delete</a>(app_config_id, \*, account_id, site_id) -> <a href="./src/cloudflare/types/magic_transit/sites/sites/app_configuration_delete_response.py">Optional</a></code>

## Connectors

Types:
Expand Down
14 changes: 14 additions & 0 deletions src/cloudflare/resources/addressing/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -40,8 +40,22 @@
LOADocumentsResourceWithStreamingResponse,
AsyncLOADocumentsResourceWithStreamingResponse,
)
from .regional_hostnames import (
RegionalHostnamesResource,
AsyncRegionalHostnamesResource,
RegionalHostnamesResourceWithRawResponse,
AsyncRegionalHostnamesResourceWithRawResponse,
RegionalHostnamesResourceWithStreamingResponse,
AsyncRegionalHostnamesResourceWithStreamingResponse,
)

__all__ = [
"RegionalHostnamesResource",
"AsyncRegionalHostnamesResource",
"RegionalHostnamesResourceWithRawResponse",
"AsyncRegionalHostnamesResourceWithRawResponse",
"RegionalHostnamesResourceWithStreamingResponse",
"AsyncRegionalHostnamesResourceWithStreamingResponse",
"ServicesResource",
"AsyncServicesResource",
"ServicesResourceWithRawResponse",
Expand Down
33 changes: 33 additions & 0 deletions src/cloudflare/resources/addressing/addressing.py
Original file line number Diff line number Diff line change
Expand Up @@ -37,13 +37,26 @@
AsyncLOADocumentsResourceWithStreamingResponse,
)
from .prefixes.prefixes import PrefixesResource, AsyncPrefixesResource
from .regional_hostnames import (
RegionalHostnamesResource,
AsyncRegionalHostnamesResource,
RegionalHostnamesResourceWithRawResponse,
AsyncRegionalHostnamesResourceWithRawResponse,
RegionalHostnamesResourceWithStreamingResponse,
AsyncRegionalHostnamesResourceWithStreamingResponse,
)
from .address_maps.address_maps import AddressMapsResource, AsyncAddressMapsResource
from .loa_documents.loa_documents import LOADocumentsResource, AsyncLOADocumentsResource
from .regional_hostnames.regional_hostnames import RegionalHostnamesResource, AsyncRegionalHostnamesResource

__all__ = ["AddressingResource", "AsyncAddressingResource"]


class AddressingResource(SyncAPIResource):
@cached_property
def regional_hostnames(self) -> RegionalHostnamesResource:
return RegionalHostnamesResource(self._client)

@cached_property
def services(self) -> ServicesResource:
return ServicesResource(self._client)
Expand All @@ -70,6 +83,10 @@ def with_streaming_response(self) -> AddressingResourceWithStreamingResponse:


class AsyncAddressingResource(AsyncAPIResource):
@cached_property
def regional_hostnames(self) -> AsyncRegionalHostnamesResource:
return AsyncRegionalHostnamesResource(self._client)

@cached_property
def services(self) -> AsyncServicesResource:
return AsyncServicesResource(self._client)
Expand Down Expand Up @@ -99,6 +116,10 @@ class AddressingResourceWithRawResponse:
def __init__(self, addressing: AddressingResource) -> None:
self._addressing = addressing

@cached_property
def regional_hostnames(self) -> RegionalHostnamesResourceWithRawResponse:
return RegionalHostnamesResourceWithRawResponse(self._addressing.regional_hostnames)

@cached_property
def services(self) -> ServicesResourceWithRawResponse:
return ServicesResourceWithRawResponse(self._addressing.services)
Expand All @@ -120,6 +141,10 @@ class AsyncAddressingResourceWithRawResponse:
def __init__(self, addressing: AsyncAddressingResource) -> None:
self._addressing = addressing

@cached_property
def regional_hostnames(self) -> AsyncRegionalHostnamesResourceWithRawResponse:
return AsyncRegionalHostnamesResourceWithRawResponse(self._addressing.regional_hostnames)

@cached_property
def services(self) -> AsyncServicesResourceWithRawResponse:
return AsyncServicesResourceWithRawResponse(self._addressing.services)
Expand All @@ -141,6 +166,10 @@ class AddressingResourceWithStreamingResponse:
def __init__(self, addressing: AddressingResource) -> None:
self._addressing = addressing

@cached_property
def regional_hostnames(self) -> RegionalHostnamesResourceWithStreamingResponse:
return RegionalHostnamesResourceWithStreamingResponse(self._addressing.regional_hostnames)

@cached_property
def services(self) -> ServicesResourceWithStreamingResponse:
return ServicesResourceWithStreamingResponse(self._addressing.services)
Expand All @@ -162,6 +191,10 @@ class AsyncAddressingResourceWithStreamingResponse:
def __init__(self, addressing: AsyncAddressingResource) -> None:
self._addressing = addressing

@cached_property
def regional_hostnames(self) -> AsyncRegionalHostnamesResourceWithStreamingResponse:
return AsyncRegionalHostnamesResourceWithStreamingResponse(self._addressing.regional_hostnames)

@cached_property
def services(self) -> AsyncServicesResourceWithStreamingResponse:
return AsyncServicesResourceWithStreamingResponse(self._addressing.services)
Expand Down
33 changes: 33 additions & 0 deletions src/cloudflare/resources/addressing/regional_hostnames/__init__.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,33 @@
# File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.

from .regions import (
RegionsResource,
AsyncRegionsResource,
RegionsResourceWithRawResponse,
AsyncRegionsResourceWithRawResponse,
RegionsResourceWithStreamingResponse,
AsyncRegionsResourceWithStreamingResponse,
)
from .regional_hostnames import (
RegionalHostnamesResource,
AsyncRegionalHostnamesResource,
RegionalHostnamesResourceWithRawResponse,
AsyncRegionalHostnamesResourceWithRawResponse,
RegionalHostnamesResourceWithStreamingResponse,
AsyncRegionalHostnamesResourceWithStreamingResponse,
)

__all__ = [
"RegionsResource",
"AsyncRegionsResource",
"RegionsResourceWithRawResponse",
"AsyncRegionsResourceWithRawResponse",
"RegionsResourceWithStreamingResponse",
"AsyncRegionsResourceWithStreamingResponse",
"RegionalHostnamesResource",
"AsyncRegionalHostnamesResource",
"RegionalHostnamesResourceWithRawResponse",
"AsyncRegionalHostnamesResourceWithRawResponse",
"RegionalHostnamesResourceWithStreamingResponse",
"AsyncRegionalHostnamesResourceWithStreamingResponse",
]
Loading

0 comments on commit c3fa7ab

Please sign in to comment.