Skip to content
Start here

UA Rules

List User Agent Blocking rules
firewall.ua_rules.list(UARuleListParams**kwargs) -> SyncV4PagePaginationArray[UARuleListResponse]
GET/zones/{zone_id}/firewall/ua_rules
Get a User Agent Blocking rule
firewall.ua_rules.get(strua_rule_id, UARuleGetParams**kwargs) -> UARuleGetResponse
GET/zones/{zone_id}/firewall/ua_rules/{ua_rule_id}
Create a User Agent Blocking rule
firewall.ua_rules.create(UARuleCreateParams**kwargs) -> UARuleCreateResponse
POST/zones/{zone_id}/firewall/ua_rules
Update a User Agent Blocking rule
firewall.ua_rules.update(strua_rule_id, UARuleUpdateParams**kwargs) -> UARuleUpdateResponse
PUT/zones/{zone_id}/firewall/ua_rules/{ua_rule_id}
Delete a User Agent Blocking rule
firewall.ua_rules.delete(strua_rule_id, UARuleDeleteParams**kwargs) -> UARuleDeleteResponse
DELETE/zones/{zone_id}/firewall/ua_rules/{ua_rule_id}
ModelsExpand Collapse
class UARuleListResponse:
id: Optional[str]

The unique identifier of the User Agent Blocking rule.

maxLength32
configuration: Optional[Configuration]

The configuration object for the current rule.

target: Optional[str]

The configuration target for this rule. You must set the target to ua for User Agent Blocking rules.

value: Optional[str]

The exact user agent string to match. This value will be compared to the received User-Agent HTTP header value.

description: Optional[str]

An informative summary of the rule.

maxLength1024
mode: Optional[Literal["block", "challenge", "js_challenge", "managed_challenge"]]

The action to apply to a matched request.

maxLength12
One of the following:
"block"
"challenge"
"js_challenge"
"managed_challenge"
paused: Optional[bool]

When true, indicates that the rule is currently paused.

class UARuleGetResponse:
id: Optional[str]

The unique identifier of the User Agent Blocking rule.

maxLength32
configuration: Optional[Configuration]

The configuration object for the current rule.

target: Optional[str]

The configuration target for this rule. You must set the target to ua for User Agent Blocking rules.

value: Optional[str]

The exact user agent string to match. This value will be compared to the received User-Agent HTTP header value.

description: Optional[str]

An informative summary of the rule.

maxLength1024
mode: Optional[Literal["block", "challenge", "js_challenge", "managed_challenge"]]

The action to apply to a matched request.

maxLength12
One of the following:
"block"
"challenge"
"js_challenge"
"managed_challenge"
paused: Optional[bool]

When true, indicates that the rule is currently paused.

class UARuleCreateResponse:
id: Optional[str]

The unique identifier of the User Agent Blocking rule.

maxLength32
configuration: Optional[Configuration]

The configuration object for the current rule.

target: Optional[str]

The configuration target for this rule. You must set the target to ua for User Agent Blocking rules.

value: Optional[str]

The exact user agent string to match. This value will be compared to the received User-Agent HTTP header value.

description: Optional[str]

An informative summary of the rule.

maxLength1024
mode: Optional[Literal["block", "challenge", "js_challenge", "managed_challenge"]]

The action to apply to a matched request.

maxLength12
One of the following:
"block"
"challenge"
"js_challenge"
"managed_challenge"
paused: Optional[bool]

When true, indicates that the rule is currently paused.

class UARuleUpdateResponse:
id: Optional[str]

The unique identifier of the User Agent Blocking rule.

maxLength32
configuration: Optional[Configuration]

The configuration object for the current rule.

target: Optional[str]

The configuration target for this rule. You must set the target to ua for User Agent Blocking rules.

value: Optional[str]

The exact user agent string to match. This value will be compared to the received User-Agent HTTP header value.

description: Optional[str]

An informative summary of the rule.

maxLength1024
mode: Optional[Literal["block", "challenge", "js_challenge", "managed_challenge"]]

The action to apply to a matched request.

maxLength12
One of the following:
"block"
"challenge"
"js_challenge"
"managed_challenge"
paused: Optional[bool]

When true, indicates that the rule is currently paused.

class UARuleDeleteResponse:
id: Optional[str]

The unique identifier of the User Agent Blocking rule.

maxLength32
configuration: Optional[Configuration]

The configuration object for the current rule.

target: Optional[str]

The configuration target for this rule. You must set the target to ua for User Agent Blocking rules.

value: Optional[str]

The exact user agent string to match. This value will be compared to the received User-Agent HTTP header value.

description: Optional[str]

An informative summary of the rule.

maxLength1024
mode: Optional[Literal["block", "challenge", "js_challenge", "managed_challenge"]]

The action to apply to a matched request.

maxLength12
One of the following:
"block"
"challenge"
"js_challenge"
"managed_challenge"
paused: Optional[bool]

When true, indicates that the rule is currently paused.