Skip to content

Commit

Permalink
feat(api): OpenAPI spec update via Stainless API (#189)
Browse files Browse the repository at this point in the history
  • Loading branch information
stainless-app[bot] authored Mar 28, 2024
1 parent 0c3e739 commit 6c96917
Show file tree
Hide file tree
Showing 3 changed files with 13 additions and 0 deletions.
8 changes: 8 additions & 0 deletions src/cloudflare/resources/radar/bgp/routes.py
Original file line number Diff line number Diff line change
Expand Up @@ -239,6 +239,7 @@ def timeseries(
| NotGiven = NOT_GIVEN,
date_start: Union[str, datetime] | NotGiven = NOT_GIVEN,
format: Literal["JSON", "CSV"] | NotGiven = NOT_GIVEN,
location: str | NotGiven = NOT_GIVEN,
# Use the following arguments if you need to pass additional parameters to the API that aren't available via kwargs.
# The extra values given here take precedence over values defined on the client or passed to this method.
extra_headers: Headers | None = None,
Expand All @@ -262,6 +263,8 @@ def timeseries(
format: Format results are returned in.
location: Location Alpha2 code.
extra_headers: Send extra headers
extra_query: Add additional query parameters to the request
Expand All @@ -284,6 +287,7 @@ def timeseries(
"date_range": date_range,
"date_start": date_start,
"format": format,
"location": location,
},
route_timeseries_params.RouteTimeseriesParams,
),
Expand Down Expand Up @@ -493,6 +497,7 @@ async def timeseries(
| NotGiven = NOT_GIVEN,
date_start: Union[str, datetime] | NotGiven = NOT_GIVEN,
format: Literal["JSON", "CSV"] | NotGiven = NOT_GIVEN,
location: str | NotGiven = NOT_GIVEN,
# Use the following arguments if you need to pass additional parameters to the API that aren't available via kwargs.
# The extra values given here take precedence over values defined on the client or passed to this method.
extra_headers: Headers | None = None,
Expand All @@ -516,6 +521,8 @@ async def timeseries(
format: Format results are returned in.
location: Location Alpha2 code.
extra_headers: Send extra headers
extra_query: Add additional query parameters to the request
Expand All @@ -538,6 +545,7 @@ async def timeseries(
"date_range": date_range,
"date_start": date_start,
"format": format,
"location": location,
},
route_timeseries_params.RouteTimeseriesParams,
),
Expand Down
3 changes: 3 additions & 0 deletions src/cloudflare/types/radar/bgp/route_timeseries_params.py
Original file line number Diff line number Diff line change
Expand Up @@ -48,3 +48,6 @@ class RouteTimeseriesParams(TypedDict, total=False):

format: Literal["JSON", "CSV"]
"""Format results are returned in."""

location: str
"""Location Alpha2 code."""
2 changes: 2 additions & 0 deletions tests/api_resources/radar/bgp/test_routes.py
Original file line number Diff line number Diff line change
Expand Up @@ -155,6 +155,7 @@ def test_method_timeseries_with_all_params(self, client: Cloudflare) -> None:
date_range="7d",
date_start=parse_datetime("2023-09-01T11:41:33.782Z"),
format="JSON",
location="US",
)
assert_matches_type(RouteTimeseriesResponse, route, path=["response"])

Expand Down Expand Up @@ -316,6 +317,7 @@ async def test_method_timeseries_with_all_params(self, async_client: AsyncCloudf
date_range="7d",
date_start=parse_datetime("2023-09-01T11:41:33.782Z"),
format="JSON",
location="US",
)
assert_matches_type(RouteTimeseriesResponse, route, path=["response"])

Expand Down

0 comments on commit 6c96917

Please sign in to comment.