Skip to content
2 changes: 1 addition & 1 deletion .release-please-manifest.json
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
{
".": "5.0.0"
".": "5.1.0"
}
6 changes: 3 additions & 3 deletions .stats.yml
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
configured_endpoints: 2195
configured_endpoints: 2204
openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/cloudflare%2Fcloudflare-a6c352830d1270d0abb5bb983058ea21815e1bb7d2e163965335dcb0e706f057.yml
openapi_spec_hash: aa452e4dfaec546a7e50ef8665bd39f4
config_hash: d3379006654eb5479a62d9576648acc5
openapi_spec_hash: e722ad1f58e3dfb3a928cf9890d48da4
config_hash: ff549978909de2badc92845fea964f4b
177 changes: 0 additions & 177 deletions CHANGELOG-v5.0.0-beta.2.md

This file was deleted.

61 changes: 61 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,66 @@
# Changelog

## 5.1.0 (2026-05-06)

Full Changelog: [v5.0.0...v5.1.0](https://github.com/cloudflare/cloudflare-python/compare/v5.0.0...v5.1.0)

### Features

* **security_center:** add `audit_logs`, `classification`, and `context` sub-resources to insights ([ed7d261](https://github.com/cloudflare/cloudflare-python/commit/ed7d261e6))
* **zero_trust:** add `deployment_groups` sub-resource to devices ([7121a55](https://github.com/cloudflare/cloudflare-python/commit/7121a55d3))
* **aisearch:** update generated types and methods ([54b87759](https://github.com/cloudflare/cloudflare-python/commit/54b87759b))
* **email_security:** update generated types and methods ([23a979df](https://github.com/cloudflare/cloudflare-python/commit/23a979df2))
* **radar:** update generated types and methods ([b48274ef](https://github.com/cloudflare/cloudflare-python/commit/b48274ef7))
* **zones:** update generated types and methods ([f0a54099](https://github.com/cloudflare/cloudflare-python/commit/f0a540997))

#### Security Center - New Insights Sub-Resources

**AuditLogs** (`client.security_center.insights.audit_logs`)

- `list(*, account_id, zone_id, **params) -> SyncCursorPagination[AuditLogListResponse]`
- `list_by_insight(issue_id, *, account_id, zone_id, **params) -> SyncCursorPagination[AuditLogListByInsightResponse]`

New types:
```python
from cloudflare.types.security_center.insights import (
AuditLogListResponse,
AuditLogListByInsightResponse,
)
```

**Classification** (`client.security_center.insights.classification`)

- `update(issue_id, *, account_id, zone_id, **params) -> ClassificationUpdateResponse`

New types:
```python
from cloudflare.types.security_center.insights import ClassificationUpdateResponse
```

**Context** (`client.security_center.insights.context`)

- `get(issue_id, *, account_id) -> Optional[ContextGetResponse]`

New types:
```python
from cloudflare.types.security_center.insights import ContextGetResponse
```

#### Zero Trust - Device Deployment Groups

New sub-resource `client.zero_trust.devices.deployment_groups`:

- `create(*, account_id, **params) -> DeploymentGroup`
- `list(*, account_id, **params) -> SyncV4PagePaginationArray[DeploymentGroup]`
- `delete(group_id, *, account_id) -> DeploymentGroupDeleteResponse`
- `edit(group_id, *, account_id, **params) -> DeploymentGroup`
- `get(group_id, *, account_id) -> DeploymentGroup`

New types:
```python
from cloudflare.types.zero_trust.devices import DeploymentGroup, DeploymentGroupDeleteResponse
```

## 5.0.0 (2026-04-30)

Full Changelog: [v4.3.1...v5.0.0](https://github.com/cloudflare/cloudflare-python/compare/v4.3.1...v5.0.0)
Expand Down
2 changes: 1 addition & 1 deletion pyproject.toml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[project]
name = "cloudflare"
version = "5.0.0"
version = "5.1.0"
description = "The official Python library for the cloudflare API"
dynamic = ["readme"]
license = "Apache-2.0"
Expand Down
2 changes: 1 addition & 1 deletion src/cloudflare/_version.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
# File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.

__title__ = "cloudflare"
__version__ = "5.0.0" # x-release-please-version
__version__ = "5.1.0" # x-release-please-version
34 changes: 30 additions & 4 deletions src/cloudflare/resources/aisearch/instances/instances.py
Original file line number Diff line number Diff line change
Expand Up @@ -115,6 +115,7 @@ def create(
cache: bool | Omit = omit,
cache_threshold: Literal["super_strict_match", "close_enough", "flexible_friend", "anything_goes"]
| Omit = omit,
cache_ttl: Literal[600, 1800, 3600, 7200, 21600, 43200, 86400, 172800, 259200, 518400] | Omit = omit,
chunk: bool | Omit = omit,
chunk_overlap: int | Omit = omit,
chunk_size: int | Omit = omit,
Expand Down Expand Up @@ -199,6 +200,10 @@ def create(
Lowercase alphanumeric, hyphens, and underscores.
cache_ttl: Cache entry TTL in seconds. Allowed values: 600 (10min), 1800 (30min), 3600
(1h), 7200 (2h), 21600 (6h), 43200 (12h), 86400 (24h), 172800 (48h), 259200
(72h), 518400 (6d).
hybrid_search_enabled: Deprecated — use index_method instead.
index_method: Controls which storage backends are used during indexing. Defaults to
Expand Down Expand Up @@ -226,6 +231,7 @@ def create(
"aisearch_model": aisearch_model,
"cache": cache,
"cache_threshold": cache_threshold,
"cache_ttl": cache_ttl,
"chunk": chunk,
"chunk_overlap": chunk_overlap,
"chunk_size": chunk_size,
Expand Down Expand Up @@ -306,6 +312,7 @@ def update(
cache: bool | Omit = omit,
cache_threshold: Literal["super_strict_match", "close_enough", "flexible_friend", "anything_goes"]
| Omit = omit,
cache_ttl: Literal[600, 1800, 3600, 7200, 21600, 43200, 86400, 172800, 259200, 518400] | Omit = omit,
chunk: bool | Omit = omit,
chunk_overlap: int | Omit = omit,
chunk_size: int | Omit = omit,
Expand Down Expand Up @@ -420,10 +427,15 @@ def update(
extra_body: Body | None = None,
timeout: float | httpx.Timeout | None | NotGiven = not_given,
) -> InstanceUpdateResponse:
"""
Update instance.
"""Update instance.
Args:
cache_ttl: Cache entry TTL in seconds.
Allowed values: 600 (10min), 1800 (30min), 3600
(1h), 7200 (2h), 21600 (6h), 43200 (12h), 86400 (24h), 172800 (48h), 259200
(72h), 518400 (6d).
index_method: Controls which storage backends are used during indexing. Defaults to
vector-only.
Expand All @@ -450,6 +462,7 @@ def update(
"aisearch_model": aisearch_model,
"cache": cache,
"cache_threshold": cache_threshold,
"cache_ttl": cache_ttl,
"chunk": chunk,
"chunk_overlap": chunk_overlap,
"chunk_size": chunk_size,
Expand Down Expand Up @@ -889,6 +902,7 @@ async def create(
cache: bool | Omit = omit,
cache_threshold: Literal["super_strict_match", "close_enough", "flexible_friend", "anything_goes"]
| Omit = omit,
cache_ttl: Literal[600, 1800, 3600, 7200, 21600, 43200, 86400, 172800, 259200, 518400] | Omit = omit,
chunk: bool | Omit = omit,
chunk_overlap: int | Omit = omit,
chunk_size: int | Omit = omit,
Expand Down Expand Up @@ -973,6 +987,10 @@ async def create(
Lowercase alphanumeric, hyphens, and underscores.
cache_ttl: Cache entry TTL in seconds. Allowed values: 600 (10min), 1800 (30min), 3600
(1h), 7200 (2h), 21600 (6h), 43200 (12h), 86400 (24h), 172800 (48h), 259200
(72h), 518400 (6d).
hybrid_search_enabled: Deprecated — use index_method instead.
index_method: Controls which storage backends are used during indexing. Defaults to
Expand Down Expand Up @@ -1000,6 +1018,7 @@ async def create(
"aisearch_model": aisearch_model,
"cache": cache,
"cache_threshold": cache_threshold,
"cache_ttl": cache_ttl,
"chunk": chunk,
"chunk_overlap": chunk_overlap,
"chunk_size": chunk_size,
Expand Down Expand Up @@ -1080,6 +1099,7 @@ async def update(
cache: bool | Omit = omit,
cache_threshold: Literal["super_strict_match", "close_enough", "flexible_friend", "anything_goes"]
| Omit = omit,
cache_ttl: Literal[600, 1800, 3600, 7200, 21600, 43200, 86400, 172800, 259200, 518400] | Omit = omit,
chunk: bool | Omit = omit,
chunk_overlap: int | Omit = omit,
chunk_size: int | Omit = omit,
Expand Down Expand Up @@ -1194,10 +1214,15 @@ async def update(
extra_body: Body | None = None,
timeout: float | httpx.Timeout | None | NotGiven = not_given,
) -> InstanceUpdateResponse:
"""
Update instance.
"""Update instance.
Args:
cache_ttl: Cache entry TTL in seconds.
Allowed values: 600 (10min), 1800 (30min), 3600
(1h), 7200 (2h), 21600 (6h), 43200 (12h), 86400 (24h), 172800 (48h), 259200
(72h), 518400 (6d).
index_method: Controls which storage backends are used during indexing. Defaults to
vector-only.
Expand All @@ -1224,6 +1249,7 @@ async def update(
"aisearch_model": aisearch_model,
"cache": cache,
"cache_threshold": cache_threshold,
"cache_ttl": cache_ttl,
"chunk": chunk,
"chunk_overlap": chunk_overlap,
"chunk_size": chunk_size,
Expand Down
Loading
Loading