Filters

Filters

Methods

list(, ): <>
Deprecated
get/zones/{zone_id}/filters

Deprecated

The Filters API is deprecated in favour of using the Ruleset Engine. See https://developers.cloudflare.com/fundamentals/api/reference/deprecations/#firewall-rules-api-and-filters-api for full details.

Fetches filters in a zone. You can filter the results using several optional parameters.

Security

The preferred authorization scheme for interacting with the Cloudflare API. Create a token.

Example: Authorization: Bearer Sn3lZJTBX6kkg7OdcBUAxOO963GEIyGQqnFTOFYY

Accepted Permissions (at least one required)

Firewall Services Write Firewall Services Read

Parameters
zone_id: string
(maxLength: 32)

Path param: Defines an identifier.

id?: string
(maxLength: 32, minLength: 32)

Query param: The unique identifier of the filter.

description?: string

Query param: A case-insensitive string to find in the description.

expression?: string

Query param: A case-insensitive string to find in the expression.

page?: number
(minimum: 1)

Query param: Page number of paginated results.

paused?: boolean

Query param: When true, indicates that the filter is currently paused.

per_page?: number
(maximum: 100, minimum: 5)

Query param: Number of filters per page.

ref?: string

Query param: The filter ref (a short reference tag) to search for. Must be an exact match.

Returns
id?: string
(maxLength: 32, minLength: 32)

The unique identifier of the filter.

description?: string
(maxLength: 500)

An informative summary of the filter.

expression?: string

The filter expression. For more information, refer to Expressions.

paused?: boolean

When true, indicates that the filter is currently paused.

ref?: string
(maxLength: 50)

A short reference tag. Allows you to select related filters.

Request example
200Example
get(, , ):
Deprecated
get/zones/{zone_id}/filters/{filter_id}

Deprecated

The Filters API is deprecated in favour of using the Ruleset Engine. See https://developers.cloudflare.com/fundamentals/api/reference/deprecations/#firewall-rules-api-and-filters-api for full details.

Fetches the details of a filter.

create(, ): <>
Deprecated
post/zones/{zone_id}/filters

Deprecated

The Filters API is deprecated in favour of using the Ruleset Engine. See https://developers.cloudflare.com/fundamentals/api/reference/deprecations/#firewall-rules-api-and-filters-api for full details.

Creates one or more filters.

update(, , ):
Deprecated
put/zones/{zone_id}/filters/{filter_id}

Deprecated

The Filters API is deprecated in favour of using the Ruleset Engine. See https://developers.cloudflare.com/fundamentals/api/reference/deprecations/#firewall-rules-api-and-filters-api for full details.

Updates an existing filter.

delete(, , ):
Deprecated
delete/zones/{zone_id}/filters/{filter_id}

Deprecated

The Filters API is deprecated in favour of using the Ruleset Engine. See https://developers.cloudflare.com/fundamentals/api/reference/deprecations/#firewall-rules-api-and-filters-api for full details.

Deletes an existing filter.

bulkUpdate(, ): <>
Deprecated
put/zones/{zone_id}/filters

Deprecated

The Filters API is deprecated in favour of using the Ruleset Engine. See https://developers.cloudflare.com/fundamentals/api/reference/deprecations/#firewall-rules-api-and-filters-api for full details.

Updates one or more existing filters.

bulkDelete(, ): | null
Deprecated
delete/zones/{zone_id}/filters

Deprecated

The Filters API is deprecated in favour of using the Ruleset Engine. See https://developers.cloudflare.com/fundamentals/api/reference/deprecations/#firewall-rules-api-and-filters-api for full details.

Deletes one or more existing filters.

Domain types

FirewallFilter{…}