Skip to content

Commit

Permalink
feat(api): OpenAPI spec update via Stainless API (#751)
Browse files Browse the repository at this point in the history
  • Loading branch information
stainless-app[bot] authored May 31, 2024
1 parent 15db695 commit d412c9f
Show file tree
Hide file tree
Showing 22 changed files with 350 additions and 313 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: 1321
openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/cloudflare%2Fcloudflare-a18a8d7f1f80a39beb83a6541eb29dea4a69df37444aeb85493c94256c11d3a6.yml
openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/cloudflare%2Fcloudflare-7080386fb1d04dafc80523803a44e41bab56e2907c13694ced938d02a3abb9d5.yml
24 changes: 12 additions & 12 deletions src/cloudflare/resources/zero_trust/dex/colos.py
Original file line number Diff line number Diff line change
Expand Up @@ -39,8 +39,8 @@ def list(
self,
*,
account_id: str,
time_end: str,
time_start: str,
from_: str,
to: str,
sort_by: Literal["fleet-status-usage", "application-tests-usage"] | 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.
Expand All @@ -55,9 +55,9 @@ def list(
are also returned and sorted alphabetically.
Args:
time_end: End time for connection period in RFC3339 (ISO 8601) format.
from_: Start time for connection period in RFC3339 (ISO 8601) format.
time_start: Start time for connection period in RFC3339 (ISO 8601) format.
to: End time for connection period in RFC3339 (ISO 8601) format.
sort_by: Type of usage that colos should be sorted by. If unspecified, returns all
Cloudflare colos sorted alphabetically.
Expand All @@ -82,8 +82,8 @@ def list(
timeout=timeout,
query=maybe_transform(
{
"time_end": time_end,
"time_start": time_start,
"from_": from_,
"to": to,
"sort_by": sort_by,
},
colo_list_params.ColoListParams,
Expand All @@ -106,8 +106,8 @@ def list(
self,
*,
account_id: str,
time_end: str,
time_start: str,
from_: str,
to: str,
sort_by: Literal["fleet-status-usage", "application-tests-usage"] | 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.
Expand All @@ -122,9 +122,9 @@ def list(
are also returned and sorted alphabetically.
Args:
time_end: End time for connection period in RFC3339 (ISO 8601) format.
from_: Start time for connection period in RFC3339 (ISO 8601) format.
time_start: Start time for connection period in RFC3339 (ISO 8601) format.
to: End time for connection period in RFC3339 (ISO 8601) format.
sort_by: Type of usage that colos should be sorted by. If unspecified, returns all
Cloudflare colos sorted alphabetically.
Expand All @@ -149,8 +149,8 @@ def list(
timeout=timeout,
query=maybe_transform(
{
"time_end": time_end,
"time_start": time_start,
"from_": from_,
"to": to,
"sort_by": sort_by,
},
colo_list_params.ColoListParams,
Expand Down
42 changes: 30 additions & 12 deletions src/cloudflare/resources/zero_trust/dex/fleet_status/devices.py
Original file line number Diff line number Diff line change
Expand Up @@ -40,10 +40,11 @@ def list(
self,
*,
account_id: str,
from_: str,
page: float,
per_page: float,
time_end: str,
time_start: str,
source: Literal["last_seen", "hourly", "raw"],
to: str,
colo: str | NotGiven = NOT_GIVEN,
device_id: str | NotGiven = NOT_GIVEN,
mode: str | NotGiven = NOT_GIVEN,
Expand All @@ -63,13 +64,20 @@ def list(
List details for devices using WARP
Args:
from_: Timestamp in ISO format
page: Page number of paginated results
per_page: Number of items per page
time_end: Timestamp in ISO format
source:
Source:
- `hourly` - device details aggregated hourly, up to 7 days prior
- `last_seen` - device details, up to 24 hours prior
- `raw` - device details, up to 7 days prior
time_start: Timestamp in ISO format
to: Timestamp in ISO format
colo: Cloudflare colo
Expand Down Expand Up @@ -105,10 +113,11 @@ def list(
timeout=timeout,
query=maybe_transform(
{
"from_": from_,
"page": page,
"per_page": per_page,
"time_end": time_end,
"time_start": time_start,
"source": source,
"to": to,
"colo": colo,
"device_id": device_id,
"mode": mode,
Expand Down Expand Up @@ -137,10 +146,11 @@ def list(
self,
*,
account_id: str,
from_: str,
page: float,
per_page: float,
time_end: str,
time_start: str,
source: Literal["last_seen", "hourly", "raw"],
to: str,
colo: str | NotGiven = NOT_GIVEN,
device_id: str | NotGiven = NOT_GIVEN,
mode: str | NotGiven = NOT_GIVEN,
Expand All @@ -160,13 +170,20 @@ def list(
List details for devices using WARP
Args:
from_: Timestamp in ISO format
page: Page number of paginated results
per_page: Number of items per page
time_end: Timestamp in ISO format
source:
Source:
- `hourly` - device details aggregated hourly, up to 7 days prior
- `last_seen` - device details, up to 24 hours prior
- `raw` - device details, up to 7 days prior
time_start: Timestamp in ISO format
to: Timestamp in ISO format
colo: Cloudflare colo
Expand Down Expand Up @@ -202,10 +219,11 @@ def list(
timeout=timeout,
query=maybe_transform(
{
"from_": from_,
"page": page,
"per_page": per_page,
"time_end": time_end,
"time_start": time_start,
"source": source,
"to": to,
"colo": colo,
"device_id": device_id,
"mode": mode,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -95,8 +95,8 @@ def over_time(
self,
*,
account_id: str,
time_end: str,
time_start: str,
from_: str,
to: str,
colo: str | NotGiven = NOT_GIVEN,
device_id: str | NotGiven = NOT_GIVEN,
# Use the following arguments if you need to pass additional parameters to the API that aren't available via kwargs.
Expand All @@ -110,9 +110,9 @@ def over_time(
List details for devices using WARP, up to 7 days
Args:
time_end: Timestamp in ISO format
from_: Timestamp in ISO format
time_start: Timestamp in ISO format
to: Timestamp in ISO format
colo: Cloudflare colo
Expand All @@ -138,8 +138,8 @@ def over_time(
timeout=timeout,
query=maybe_transform(
{
"time_end": time_end,
"time_start": time_start,
"from_": from_,
"to": to,
"colo": colo,
"device_id": device_id,
},
Expand Down Expand Up @@ -210,8 +210,8 @@ async def over_time(
self,
*,
account_id: str,
time_end: str,
time_start: str,
from_: str,
to: str,
colo: str | NotGiven = NOT_GIVEN,
device_id: str | NotGiven = NOT_GIVEN,
# Use the following arguments if you need to pass additional parameters to the API that aren't available via kwargs.
Expand All @@ -225,9 +225,9 @@ async def over_time(
List details for devices using WARP, up to 7 days
Args:
time_end: Timestamp in ISO format
from_: Timestamp in ISO format
time_start: Timestamp in ISO format
to: Timestamp in ISO format
colo: Cloudflare colo
Expand All @@ -253,8 +253,8 @@ async def over_time(
timeout=timeout,
query=await async_maybe_transform(
{
"time_end": time_end,
"time_start": time_start,
"from_": from_,
"to": to,
"colo": colo,
"device_id": device_id,
},
Expand Down
28 changes: 14 additions & 14 deletions src/cloudflare/resources/zero_trust/dex/http_tests/http_tests.py
Original file line number Diff line number Diff line change
Expand Up @@ -56,9 +56,9 @@ def get(
test_id: str,
*,
account_id: str,
from_: str,
interval: Literal["minute", "hour"],
time_end: str,
time_start: str,
to: str,
colo: str | NotGiven = NOT_GIVEN,
device_id: List[str] | NotGiven = NOT_GIVEN,
# Use the following arguments if you need to pass additional parameters to the API that aren't available via kwargs.
Expand All @@ -75,11 +75,11 @@ def get(
Args:
test_id: API Resource UUID tag.
interval: Time interval for aggregate time slots.
from_: Start time for aggregate metrics in ISO ms
time_end: End time for aggregate metrics in ISO ms
interval: Time interval for aggregate time slots.
time_start: Start time for aggregate metrics in ISO ms
to: End time for aggregate metrics in ISO ms
colo: Optionally filter result stats to a Cloudflare colo. Cannot be used in
combination with deviceId param.
Expand Down Expand Up @@ -108,9 +108,9 @@ def get(
timeout=timeout,
query=maybe_transform(
{
"from_": from_,
"interval": interval,
"time_end": time_end,
"time_start": time_start,
"to": to,
"colo": colo,
"device_id": device_id,
},
Expand Down Expand Up @@ -140,9 +140,9 @@ async def get(
test_id: str,
*,
account_id: str,
from_: str,
interval: Literal["minute", "hour"],
time_end: str,
time_start: str,
to: str,
colo: str | NotGiven = NOT_GIVEN,
device_id: List[str] | NotGiven = NOT_GIVEN,
# Use the following arguments if you need to pass additional parameters to the API that aren't available via kwargs.
Expand All @@ -159,11 +159,11 @@ async def get(
Args:
test_id: API Resource UUID tag.
interval: Time interval for aggregate time slots.
from_: Start time for aggregate metrics in ISO ms
time_end: End time for aggregate metrics in ISO ms
interval: Time interval for aggregate time slots.
time_start: Start time for aggregate metrics in ISO ms
to: End time for aggregate metrics in ISO ms
colo: Optionally filter result stats to a Cloudflare colo. Cannot be used in
combination with deviceId param.
Expand Down Expand Up @@ -192,9 +192,9 @@ async def get(
timeout=timeout,
query=await async_maybe_transform(
{
"from_": from_,
"interval": interval,
"time_end": time_end,
"time_start": time_start,
"to": to,
"colo": colo,
"device_id": device_id,
},
Expand Down
24 changes: 12 additions & 12 deletions src/cloudflare/resources/zero_trust/dex/http_tests/percentiles.py
Original file line number Diff line number Diff line change
Expand Up @@ -43,8 +43,8 @@ def get(
test_id: str,
*,
account_id: str,
time_end: str,
time_start: str,
from_: str,
to: str,
colo: str | NotGiven = NOT_GIVEN,
device_id: List[str] | NotGiven = NOT_GIVEN,
# Use the following arguments if you need to pass additional parameters to the API that aren't available via kwargs.
Expand All @@ -61,9 +61,9 @@ def get(
Args:
test_id: API Resource UUID tag.
time_end: End time for aggregate metrics in ISO format
from_: Start time for aggregate metrics in ISO format
time_start: Start time for aggregate metrics in ISO format
to: End time for aggregate metrics in ISO format
colo: Optionally filter result stats to a Cloudflare colo. Cannot be used in
combination with deviceId param.
Expand Down Expand Up @@ -92,8 +92,8 @@ def get(
timeout=timeout,
query=maybe_transform(
{
"time_end": time_end,
"time_start": time_start,
"from_": from_,
"to": to,
"colo": colo,
"device_id": device_id,
},
Expand All @@ -119,8 +119,8 @@ async def get(
test_id: str,
*,
account_id: str,
time_end: str,
time_start: str,
from_: str,
to: str,
colo: str | NotGiven = NOT_GIVEN,
device_id: List[str] | NotGiven = NOT_GIVEN,
# Use the following arguments if you need to pass additional parameters to the API that aren't available via kwargs.
Expand All @@ -137,9 +137,9 @@ async def get(
Args:
test_id: API Resource UUID tag.
time_end: End time for aggregate metrics in ISO format
from_: Start time for aggregate metrics in ISO format
time_start: Start time for aggregate metrics in ISO format
to: End time for aggregate metrics in ISO format
colo: Optionally filter result stats to a Cloudflare colo. Cannot be used in
combination with deviceId param.
Expand Down Expand Up @@ -168,8 +168,8 @@ async def get(
timeout=timeout,
query=await async_maybe_transform(
{
"time_end": time_end,
"time_start": time_start,
"from_": from_,
"to": to,
"colo": colo,
"device_id": device_id,
},
Expand Down
Loading

0 comments on commit d412c9f

Please sign in to comment.