Skip to content
Start here

Rules

List firewall rules
Deprecated
client.Firewall.Rules.List(ctx, params) (*V4PagePaginationArray[FirewallRule], error)
GET/zones/{zone_id}/firewall/rules
Get a firewall rule
Deprecated
client.Firewall.Rules.Get(ctx, ruleID, query) (*FirewallRule, error)
GET/zones/{zone_id}/firewall/rules/{rule_id}
Create firewall rules
Deprecated
client.Firewall.Rules.New(ctx, params) (*SinglePage[FirewallRule], error)
POST/zones/{zone_id}/firewall/rules
Update a firewall rule
Deprecated
client.Firewall.Rules.Update(ctx, ruleID, params) (*FirewallRule, error)
PUT/zones/{zone_id}/firewall/rules/{rule_id}
Update priority of a firewall rule
Deprecated
client.Firewall.Rules.Edit(ctx, ruleID, body) (*SinglePage[FirewallRule], error)
PATCH/zones/{zone_id}/firewall/rules/{rule_id}
Delete a firewall rule
Deprecated
client.Firewall.Rules.Delete(ctx, ruleID, body) (*FirewallRule, error)
DELETE/zones/{zone_id}/firewall/rules/{rule_id}
Update firewall rules
Deprecated
client.Firewall.Rules.BulkUpdate(ctx, params) (*SinglePage[FirewallRule], error)
PUT/zones/{zone_id}/firewall/rules
Update priority of firewall rules
Deprecated
client.Firewall.Rules.BulkEdit(ctx, params) (*SinglePage[FirewallRule], error)
PATCH/zones/{zone_id}/firewall/rules
Delete firewall rules
Deprecated
client.Firewall.Rules.BulkDelete(ctx, body) (*SinglePage[FirewallRule], error)
DELETE/zones/{zone_id}/firewall/rules
ModelsExpand Collapse
type DeletedFilter struct{…}
ID string

The unique identifier of the filter.

maxLength32
minLength32
Deleted bool

When true, indicates that the firewall rule was deleted.

type FirewallRule struct{…}
ID stringoptional

The unique identifier of the firewall rule.

maxLength32
Action Actionoptional

The action to apply to a matched request. The log action is only available on an Enterprise plan.

Description stringoptional

An informative summary of the firewall rule.

maxLength500
Filter FirewallRuleFilteroptional
One of the following:
type FirewallFilter struct{…}
ID stringoptional

The unique identifier of the filter.

maxLength32
minLength32
Description stringoptional

An informative summary of the filter.

maxLength500
Expression stringoptional

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

Paused booloptional

When true, indicates that the filter is currently paused.

Ref stringoptional

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

maxLength50
type DeletedFilter struct{…}
ID string

The unique identifier of the filter.

maxLength32
minLength32
Deleted bool

When true, indicates that the firewall rule was deleted.

Paused booloptional

When true, indicates that the firewall rule is currently paused.

Priority float64optional

The priority of the rule. Optional value used to define the processing order. A lower number indicates a higher priority. If not provided, rules with a defined priority will be processed before rules without a priority.

maximum2147483647
minimum0
Products []Productoptional
One of the following:
const ProductZoneLockdown Product = "zoneLockdown"
const ProductUABlock Product = "uaBlock"
const ProductBIC Product = "bic"
const ProductHot Product = "hot"
const ProductSecurityLevel Product = "securityLevel"
const ProductRateLimit Product = "rateLimit"
const ProductWAF Product = "waf"
Ref stringoptional

A short reference tag. Allows you to select related firewall rules.

maxLength50
type Product string

A list of products to bypass for a request when using the bypass action.

One of the following:
const ProductZoneLockdown Product = "zoneLockdown"
const ProductUABlock Product = "uaBlock"
const ProductBIC Product = "bic"
const ProductHot Product = "hot"
const ProductSecurityLevel Product = "securityLevel"
const ProductRateLimit Product = "rateLimit"
const ProductWAF Product = "waf"