Skip to content

Commit

Permalink
feat(api): OpenAPI spec update via Stainless API (#388)
Browse files Browse the repository at this point in the history
  • Loading branch information
stainless-app[bot] authored and stainless-bot committed May 7, 2024
1 parent 0c45514 commit f0d079b
Show file tree
Hide file tree
Showing 10 changed files with 171 additions and 171 deletions.
2 changes: 1 addition & 1 deletion .stats.yml
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
configured_endpoints: 1259
openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/cloudflare%2Fcloudflare-543a9898a4efc4501e7101d78908dcfaa303efd8f2abb7164299dd85be87749d.yml
openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/cloudflare%2Fcloudflare-db82dd88520065dc6282d55691c415867cb115705691731e45ed70570bf0b2c4.yml
24 changes: 12 additions & 12 deletions api.md
Original file line number Diff line number Diff line change
Expand Up @@ -1727,9 +1727,9 @@ from cloudflare.types.email_routing import Settings

Methods:

- <code title="post /zones/{zone_identifier}/email/routing/disable">client.email_routing.<a href="./src/cloudflare/resources/email_routing/email_routing.py">disable</a>(zone_identifier, \*\*<a href="src/cloudflare/types/email_routing/email_routing_disable_params.py">params</a>) -> <a href="./src/cloudflare/types/email_routing/settings.py">Settings</a></code>
- <code title="post /zones/{zone_identifier}/email/routing/enable">client.email_routing.<a href="./src/cloudflare/resources/email_routing/email_routing.py">enable</a>(zone_identifier, \*\*<a href="src/cloudflare/types/email_routing/email_routing_enable_params.py">params</a>) -> <a href="./src/cloudflare/types/email_routing/settings.py">Settings</a></code>
- <code title="get /zones/{zone_identifier}/email/routing">client.email_routing.<a href="./src/cloudflare/resources/email_routing/email_routing.py">get</a>(zone_identifier) -> <a href="./src/cloudflare/types/email_routing/settings.py">Settings</a></code>
- <code title="post /zones/{zone_identifier}/email/routing/disable">client.email_routing.<a href="./src/cloudflare/resources/email_routing/email_routing.py">disable</a>(zone_identifier, \*\*<a href="src/cloudflare/types/email_routing/email_routing_disable_params.py">params</a>) -> <a href="./src/cloudflare/types/email_routing/settings.py">Optional</a></code>
- <code title="post /zones/{zone_identifier}/email/routing/enable">client.email_routing.<a href="./src/cloudflare/resources/email_routing/email_routing.py">enable</a>(zone_identifier, \*\*<a href="src/cloudflare/types/email_routing/email_routing_enable_params.py">params</a>) -> <a href="./src/cloudflare/types/email_routing/settings.py">Optional</a></code>
- <code title="get /zones/{zone_identifier}/email/routing">client.email_routing.<a href="./src/cloudflare/resources/email_routing/email_routing.py">get</a>(zone_identifier) -> <a href="./src/cloudflare/types/email_routing/settings.py">Optional</a></code>

## DNS

Expand All @@ -1753,11 +1753,11 @@ from cloudflare.types.email_routing import Action, EmailRoutingRule, Matcher

Methods:

- <code title="post /zones/{zone_identifier}/email/routing/rules">client.email_routing.rules.<a href="./src/cloudflare/resources/email_routing/rules/rules.py">create</a>(zone_identifier, \*\*<a href="src/cloudflare/types/email_routing/rule_create_params.py">params</a>) -> <a href="./src/cloudflare/types/email_routing/email_routing_rule.py">EmailRoutingRule</a></code>
- <code title="put /zones/{zone_identifier}/email/routing/rules/{rule_identifier}">client.email_routing.rules.<a href="./src/cloudflare/resources/email_routing/rules/rules.py">update</a>(rule_identifier, \*, zone_identifier, \*\*<a href="src/cloudflare/types/email_routing/rule_update_params.py">params</a>) -> <a href="./src/cloudflare/types/email_routing/email_routing_rule.py">EmailRoutingRule</a></code>
- <code title="post /zones/{zone_identifier}/email/routing/rules">client.email_routing.rules.<a href="./src/cloudflare/resources/email_routing/rules/rules.py">create</a>(zone_identifier, \*\*<a href="src/cloudflare/types/email_routing/rule_create_params.py">params</a>) -> <a href="./src/cloudflare/types/email_routing/email_routing_rule.py">Optional</a></code>
- <code title="put /zones/{zone_identifier}/email/routing/rules/{rule_identifier}">client.email_routing.rules.<a href="./src/cloudflare/resources/email_routing/rules/rules.py">update</a>(rule_identifier, \*, zone_identifier, \*\*<a href="src/cloudflare/types/email_routing/rule_update_params.py">params</a>) -> <a href="./src/cloudflare/types/email_routing/email_routing_rule.py">Optional</a></code>
- <code title="get /zones/{zone_identifier}/email/routing/rules">client.email_routing.rules.<a href="./src/cloudflare/resources/email_routing/rules/rules.py">list</a>(zone_identifier, \*\*<a href="src/cloudflare/types/email_routing/rule_list_params.py">params</a>) -> <a href="./src/cloudflare/types/email_routing/email_routing_rule.py">SyncV4PagePaginationArray[EmailRoutingRule]</a></code>
- <code title="delete /zones/{zone_identifier}/email/routing/rules/{rule_identifier}">client.email_routing.rules.<a href="./src/cloudflare/resources/email_routing/rules/rules.py">delete</a>(rule_identifier, \*, zone_identifier) -> <a href="./src/cloudflare/types/email_routing/email_routing_rule.py">EmailRoutingRule</a></code>
- <code title="get /zones/{zone_identifier}/email/routing/rules/{rule_identifier}">client.email_routing.rules.<a href="./src/cloudflare/resources/email_routing/rules/rules.py">get</a>(rule_identifier, \*, zone_identifier) -> <a href="./src/cloudflare/types/email_routing/email_routing_rule.py">EmailRoutingRule</a></code>
- <code title="delete /zones/{zone_identifier}/email/routing/rules/{rule_identifier}">client.email_routing.rules.<a href="./src/cloudflare/resources/email_routing/rules/rules.py">delete</a>(rule_identifier, \*, zone_identifier) -> <a href="./src/cloudflare/types/email_routing/email_routing_rule.py">Optional</a></code>
- <code title="get /zones/{zone_identifier}/email/routing/rules/{rule_identifier}">client.email_routing.rules.<a href="./src/cloudflare/resources/email_routing/rules/rules.py">get</a>(rule_identifier, \*, zone_identifier) -> <a href="./src/cloudflare/types/email_routing/email_routing_rule.py">Optional</a></code>

### CatchAlls

Expand All @@ -1774,8 +1774,8 @@ from cloudflare.types.email_routing.rules import (

Methods:

- <code title="put /zones/{zone_identifier}/email/routing/rules/catch_all">client.email_routing.rules.catch_alls.<a href="./src/cloudflare/resources/email_routing/rules/catch_alls.py">update</a>(zone_identifier, \*\*<a href="src/cloudflare/types/email_routing/rules/catch_all_update_params.py">params</a>) -> <a href="./src/cloudflare/types/email_routing/rules/catch_all_update_response.py">CatchAllUpdateResponse</a></code>
- <code title="get /zones/{zone_identifier}/email/routing/rules/catch_all">client.email_routing.rules.catch_alls.<a href="./src/cloudflare/resources/email_routing/rules/catch_alls.py">get</a>(zone_identifier) -> <a href="./src/cloudflare/types/email_routing/rules/catch_all_get_response.py">CatchAllGetResponse</a></code>
- <code title="put /zones/{zone_identifier}/email/routing/rules/catch_all">client.email_routing.rules.catch_alls.<a href="./src/cloudflare/resources/email_routing/rules/catch_alls.py">update</a>(zone_identifier, \*\*<a href="src/cloudflare/types/email_routing/rules/catch_all_update_params.py">params</a>) -> <a href="./src/cloudflare/types/email_routing/rules/catch_all_update_response.py">Optional</a></code>
- <code title="get /zones/{zone_identifier}/email/routing/rules/catch_all">client.email_routing.rules.catch_alls.<a href="./src/cloudflare/resources/email_routing/rules/catch_alls.py">get</a>(zone_identifier) -> <a href="./src/cloudflare/types/email_routing/rules/catch_all_get_response.py">Optional</a></code>

## Addresses

Expand All @@ -1787,10 +1787,10 @@ from cloudflare.types.email_routing import Address

Methods:

- <code title="post /accounts/{account_identifier}/email/routing/addresses">client.email_routing.addresses.<a href="./src/cloudflare/resources/email_routing/addresses.py">create</a>(account_identifier, \*\*<a href="src/cloudflare/types/email_routing/address_create_params.py">params</a>) -> <a href="./src/cloudflare/types/email_routing/address.py">Address</a></code>
- <code title="post /accounts/{account_identifier}/email/routing/addresses">client.email_routing.addresses.<a href="./src/cloudflare/resources/email_routing/addresses.py">create</a>(account_identifier, \*\*<a href="src/cloudflare/types/email_routing/address_create_params.py">params</a>) -> <a href="./src/cloudflare/types/email_routing/address.py">Optional</a></code>
- <code title="get /accounts/{account_identifier}/email/routing/addresses">client.email_routing.addresses.<a href="./src/cloudflare/resources/email_routing/addresses.py">list</a>(account_identifier, \*\*<a href="src/cloudflare/types/email_routing/address_list_params.py">params</a>) -> <a href="./src/cloudflare/types/email_routing/address.py">SyncV4PagePaginationArray[Address]</a></code>
- <code title="delete /accounts/{account_identifier}/email/routing/addresses/{destination_address_identifier}">client.email_routing.addresses.<a href="./src/cloudflare/resources/email_routing/addresses.py">delete</a>(destination_address_identifier, \*, account_identifier) -> <a href="./src/cloudflare/types/email_routing/address.py">Address</a></code>
- <code title="get /accounts/{account_identifier}/email/routing/addresses/{destination_address_identifier}">client.email_routing.addresses.<a href="./src/cloudflare/resources/email_routing/addresses.py">get</a>(destination_address_identifier, \*, account_identifier) -> <a href="./src/cloudflare/types/email_routing/address.py">Address</a></code>
- <code title="delete /accounts/{account_identifier}/email/routing/addresses/{destination_address_identifier}">client.email_routing.addresses.<a href="./src/cloudflare/resources/email_routing/addresses.py">delete</a>(destination_address_identifier, \*, account_identifier) -> <a href="./src/cloudflare/types/email_routing/address.py">Optional</a></code>
- <code title="get /accounts/{account_identifier}/email/routing/addresses/{destination_address_identifier}">client.email_routing.addresses.<a href="./src/cloudflare/resources/email_routing/addresses.py">get</a>(destination_address_identifier, \*, account_identifier) -> <a href="./src/cloudflare/types/email_routing/address.py">Optional</a></code>

# Filters

Expand Down
38 changes: 19 additions & 19 deletions src/cloudflare/resources/email_routing/addresses.py
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

from __future__ import annotations

from typing import Type, cast
from typing import Type, Optional, cast
from typing_extensions import Literal

import httpx
Expand Down Expand Up @@ -52,7 +52,7 @@ def create(
extra_query: Query | None = None,
extra_body: Body | None = None,
timeout: float | httpx.Timeout | None | NotGiven = NOT_GIVEN,
) -> Address:
) -> Optional[Address]:
"""Create a destination address to forward your emails to.
Destination addresses
Expand Down Expand Up @@ -81,9 +81,9 @@ def create(
extra_query=extra_query,
extra_body=extra_body,
timeout=timeout,
post_parser=ResultWrapper[Address]._unwrapper,
post_parser=ResultWrapper[Optional[Address]]._unwrapper,
),
cast_to=cast(Type[Address], ResultWrapper[Address]),
cast_to=cast(Type[Optional[Address]], ResultWrapper[Address]),
)

def list(
Expand Down Expand Up @@ -157,7 +157,7 @@ def delete(
extra_query: Query | None = None,
extra_body: Body | None = None,
timeout: float | httpx.Timeout | None | NotGiven = NOT_GIVEN,
) -> Address:
) -> Optional[Address]:
"""
Deletes a specific destination address.
Expand Down Expand Up @@ -187,9 +187,9 @@ def delete(
extra_query=extra_query,
extra_body=extra_body,
timeout=timeout,
post_parser=ResultWrapper[Address]._unwrapper,
post_parser=ResultWrapper[Optional[Address]]._unwrapper,
),
cast_to=cast(Type[Address], ResultWrapper[Address]),
cast_to=cast(Type[Optional[Address]], ResultWrapper[Address]),
)

def get(
Expand All @@ -203,7 +203,7 @@ def get(
extra_query: Query | None = None,
extra_body: Body | None = None,
timeout: float | httpx.Timeout | None | NotGiven = NOT_GIVEN,
) -> Address:
) -> Optional[Address]:
"""
Gets information for a specific destination email already created.
Expand Down Expand Up @@ -233,9 +233,9 @@ def get(
extra_query=extra_query,
extra_body=extra_body,
timeout=timeout,
post_parser=ResultWrapper[Address]._unwrapper,
post_parser=ResultWrapper[Optional[Address]]._unwrapper,
),
cast_to=cast(Type[Address], ResultWrapper[Address]),
cast_to=cast(Type[Optional[Address]], ResultWrapper[Address]),
)


Expand All @@ -259,7 +259,7 @@ async def create(
extra_query: Query | None = None,
extra_body: Body | None = None,
timeout: float | httpx.Timeout | None | NotGiven = NOT_GIVEN,
) -> Address:
) -> Optional[Address]:
"""Create a destination address to forward your emails to.
Destination addresses
Expand Down Expand Up @@ -288,9 +288,9 @@ async def create(
extra_query=extra_query,
extra_body=extra_body,
timeout=timeout,
post_parser=ResultWrapper[Address]._unwrapper,
post_parser=ResultWrapper[Optional[Address]]._unwrapper,
),
cast_to=cast(Type[Address], ResultWrapper[Address]),
cast_to=cast(Type[Optional[Address]], ResultWrapper[Address]),
)

def list(
Expand Down Expand Up @@ -364,7 +364,7 @@ async def delete(
extra_query: Query | None = None,
extra_body: Body | None = None,
timeout: float | httpx.Timeout | None | NotGiven = NOT_GIVEN,
) -> Address:
) -> Optional[Address]:
"""
Deletes a specific destination address.
Expand Down Expand Up @@ -394,9 +394,9 @@ async def delete(
extra_query=extra_query,
extra_body=extra_body,
timeout=timeout,
post_parser=ResultWrapper[Address]._unwrapper,
post_parser=ResultWrapper[Optional[Address]]._unwrapper,
),
cast_to=cast(Type[Address], ResultWrapper[Address]),
cast_to=cast(Type[Optional[Address]], ResultWrapper[Address]),
)

async def get(
Expand All @@ -410,7 +410,7 @@ async def get(
extra_query: Query | None = None,
extra_body: Body | None = None,
timeout: float | httpx.Timeout | None | NotGiven = NOT_GIVEN,
) -> Address:
) -> Optional[Address]:
"""
Gets information for a specific destination email already created.
Expand Down Expand Up @@ -440,9 +440,9 @@ async def get(
extra_query=extra_query,
extra_body=extra_body,
timeout=timeout,
post_parser=ResultWrapper[Address]._unwrapper,
post_parser=ResultWrapper[Optional[Address]]._unwrapper,
),
cast_to=cast(Type[Address], ResultWrapper[Address]),
cast_to=cast(Type[Optional[Address]], ResultWrapper[Address]),
)


Expand Down
38 changes: 19 additions & 19 deletions src/cloudflare/resources/email_routing/email_routing.py
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

from __future__ import annotations

from typing import Type, cast
from typing import Type, Optional, cast

import httpx

Expand Down Expand Up @@ -86,7 +86,7 @@ def disable(
extra_query: Query | None = None,
extra_body: Body | None = None,
timeout: float | httpx.Timeout | None | NotGiven = NOT_GIVEN,
) -> Settings:
) -> Optional[Settings]:
"""Disable your Email Routing zone.
Also removes additional MX records previously
Expand All @@ -113,9 +113,9 @@ def disable(
extra_query=extra_query,
extra_body=extra_body,
timeout=timeout,
post_parser=ResultWrapper[Settings]._unwrapper,
post_parser=ResultWrapper[Optional[Settings]]._unwrapper,
),
cast_to=cast(Type[Settings], ResultWrapper[Settings]),
cast_to=cast(Type[Optional[Settings]], ResultWrapper[Settings]),
)

def enable(
Expand All @@ -129,7 +129,7 @@ def enable(
extra_query: Query | None = None,
extra_body: Body | None = None,
timeout: float | httpx.Timeout | None | NotGiven = NOT_GIVEN,
) -> Settings:
) -> Optional[Settings]:
"""Enable you Email Routing zone.
Add and lock the necessary MX and SPF records.
Expand All @@ -155,9 +155,9 @@ def enable(
extra_query=extra_query,
extra_body=extra_body,
timeout=timeout,
post_parser=ResultWrapper[Settings]._unwrapper,
post_parser=ResultWrapper[Optional[Settings]]._unwrapper,
),
cast_to=cast(Type[Settings], ResultWrapper[Settings]),
cast_to=cast(Type[Optional[Settings]], ResultWrapper[Settings]),
)

def get(
Expand All @@ -170,7 +170,7 @@ def get(
extra_query: Query | None = None,
extra_body: Body | None = None,
timeout: float | httpx.Timeout | None | NotGiven = NOT_GIVEN,
) -> Settings:
) -> Optional[Settings]:
"""
Get information about the settings for your Email Routing zone.
Expand All @@ -194,9 +194,9 @@ def get(
extra_query=extra_query,
extra_body=extra_body,
timeout=timeout,
post_parser=ResultWrapper[Settings]._unwrapper,
post_parser=ResultWrapper[Optional[Settings]]._unwrapper,
),
cast_to=cast(Type[Settings], ResultWrapper[Settings]),
cast_to=cast(Type[Optional[Settings]], ResultWrapper[Settings]),
)


Expand Down Expand Up @@ -232,7 +232,7 @@ async def disable(
extra_query: Query | None = None,
extra_body: Body | None = None,
timeout: float | httpx.Timeout | None | NotGiven = NOT_GIVEN,
) -> Settings:
) -> Optional[Settings]:
"""Disable your Email Routing zone.
Also removes additional MX records previously
Expand All @@ -259,9 +259,9 @@ async def disable(
extra_query=extra_query,
extra_body=extra_body,
timeout=timeout,
post_parser=ResultWrapper[Settings]._unwrapper,
post_parser=ResultWrapper[Optional[Settings]]._unwrapper,
),
cast_to=cast(Type[Settings], ResultWrapper[Settings]),
cast_to=cast(Type[Optional[Settings]], ResultWrapper[Settings]),
)

async def enable(
Expand All @@ -275,7 +275,7 @@ async def enable(
extra_query: Query | None = None,
extra_body: Body | None = None,
timeout: float | httpx.Timeout | None | NotGiven = NOT_GIVEN,
) -> Settings:
) -> Optional[Settings]:
"""Enable you Email Routing zone.
Add and lock the necessary MX and SPF records.
Expand All @@ -301,9 +301,9 @@ async def enable(
extra_query=extra_query,
extra_body=extra_body,
timeout=timeout,
post_parser=ResultWrapper[Settings]._unwrapper,
post_parser=ResultWrapper[Optional[Settings]]._unwrapper,
),
cast_to=cast(Type[Settings], ResultWrapper[Settings]),
cast_to=cast(Type[Optional[Settings]], ResultWrapper[Settings]),
)

async def get(
Expand All @@ -316,7 +316,7 @@ async def get(
extra_query: Query | None = None,
extra_body: Body | None = None,
timeout: float | httpx.Timeout | None | NotGiven = NOT_GIVEN,
) -> Settings:
) -> Optional[Settings]:
"""
Get information about the settings for your Email Routing zone.
Expand All @@ -340,9 +340,9 @@ async def get(
extra_query=extra_query,
extra_body=extra_body,
timeout=timeout,
post_parser=ResultWrapper[Settings]._unwrapper,
post_parser=ResultWrapper[Optional[Settings]]._unwrapper,
),
cast_to=cast(Type[Settings], ResultWrapper[Settings]),
cast_to=cast(Type[Optional[Settings]], ResultWrapper[Settings]),
)


Expand Down
Loading

0 comments on commit f0d079b

Please sign in to comment.