Skip to content

Commit 26e2711

Browse files
feat(api): api update
1 parent 1a0f354 commit 26e2711

File tree

4 files changed

+18
-12
lines changed

4 files changed

+18
-12
lines changed

.stats.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
11
configured_endpoints: 1739
2-
openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/cloudflare%2Fcloudflare-6628615966131e403843a8da818ac703681cb500f11cf538817bc71f62697fa3.yml
3-
openapi_spec_hash: 919b4ec960fd965713ecbe1d25325101
2+
openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/cloudflare%2Fcloudflare-9857be0927e6cba632460d5462781d00654afd0bfa8741a82afc829a1c3032ee.yml
3+
openapi_spec_hash: 66d5f4502fe33e80b961ae4973f77493
44
config_hash: 0f5bba597978f176d865d8c693d49507

src/cloudflare/resources/cloudforce_one/threat_events/threat_events.py

Lines changed: 12 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -273,6 +273,7 @@ def list(
273273
*,
274274
account_id: float,
275275
dataset_id: List[str] | NotGiven = NOT_GIVEN,
276+
force_refresh: bool | NotGiven = NOT_GIVEN,
276277
order: Literal["asc", "desc"] | NotGiven = NOT_GIVEN,
277278
order_by: str | NotGiven = NOT_GIVEN,
278279
page: float | NotGiven = NOT_GIVEN,
@@ -285,12 +286,11 @@ def list(
285286
extra_body: Body | None = None,
286287
timeout: float | httpx.Timeout | None | NotGiven = NOT_GIVEN,
287288
) -> ThreatEventListResponse:
288-
"""The `datasetId` parameter must be defined.
289-
290-
Must provide query parameters. To
291-
list existing datasets (and their IDs), use the
289+
"""
290+
The `datasetId` must be defined (to list existing datasets (and their IDs), use
291+
the
292292
[`List Datasets`](https://developers.cloudflare.com/api/resources/cloudforce_one/subresources/threat_events/subresources/datasets/methods/list/)
293-
endpoint.
293+
endpoint). Also, must provide query parameters.
294294
295295
Args:
296296
account_id: Account ID.
@@ -313,6 +313,7 @@ def list(
313313
query=maybe_transform(
314314
{
315315
"dataset_id": dataset_id,
316+
"force_refresh": force_refresh,
316317
"order": order,
317318
"order_by": order_by,
318319
"page": page,
@@ -657,6 +658,7 @@ async def list(
657658
*,
658659
account_id: float,
659660
dataset_id: List[str] | NotGiven = NOT_GIVEN,
661+
force_refresh: bool | NotGiven = NOT_GIVEN,
660662
order: Literal["asc", "desc"] | NotGiven = NOT_GIVEN,
661663
order_by: str | NotGiven = NOT_GIVEN,
662664
page: float | NotGiven = NOT_GIVEN,
@@ -669,12 +671,11 @@ async def list(
669671
extra_body: Body | None = None,
670672
timeout: float | httpx.Timeout | None | NotGiven = NOT_GIVEN,
671673
) -> ThreatEventListResponse:
672-
"""The `datasetId` parameter must be defined.
673-
674-
Must provide query parameters. To
675-
list existing datasets (and their IDs), use the
674+
"""
675+
The `datasetId` must be defined (to list existing datasets (and their IDs), use
676+
the
676677
[`List Datasets`](https://developers.cloudflare.com/api/resources/cloudforce_one/subresources/threat_events/subresources/datasets/methods/list/)
677-
endpoint.
678+
endpoint). Also, must provide query parameters.
678679
679680
Args:
680681
account_id: Account ID.
@@ -697,6 +698,7 @@ async def list(
697698
query=await async_maybe_transform(
698699
{
699700
"dataset_id": dataset_id,
701+
"force_refresh": force_refresh,
700702
"order": order,
701703
"order_by": order_by,
702704
"page": page,

src/cloudflare/types/cloudforce_one/threat_event_list_params.py

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -16,6 +16,8 @@ class ThreatEventListParams(TypedDict, total=False):
1616

1717
dataset_id: Annotated[List[str], PropertyInfo(alias="datasetId")]
1818

19+
force_refresh: Annotated[bool, PropertyInfo(alias="forceRefresh")]
20+
1921
order: Literal["asc", "desc"]
2022

2123
order_by: Annotated[str, PropertyInfo(alias="orderBy")]

tests/api_resources/cloudforce_one/test_threat_events.py

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -123,6 +123,7 @@ def test_method_list_with_all_params(self, client: Cloudflare) -> None:
123123
threat_event = client.cloudforce_one.threat_events.list(
124124
account_id=0,
125125
dataset_id=["string"],
126+
force_refresh=True,
126127
order="asc",
127128
order_by="orderBy",
128129
page=0,
@@ -495,6 +496,7 @@ async def test_method_list_with_all_params(self, async_client: AsyncCloudflare)
495496
threat_event = await async_client.cloudforce_one.threat_events.list(
496497
account_id=0,
497498
dataset_id=["string"],
499+
force_refresh=True,
498500
order="asc",
499501
order_by="orderBy",
500502
page=0,

0 commit comments

Comments
 (0)