zscaler.ziacloud.zia_cloud_app_control_rule_actions_info module – Get available Cloud App Control rule actions by rule type
Note
This module is part of the zscaler.ziacloud collection (version 2.2.3).
It is not included in ansible-core.
To check whether it is installed, run ansible-galaxy collection list.
To install it, use: ansible-galaxy collection install zscaler.ziacloud.
You need further requirements to be able to use this module,
see Requirements for details.
To use it in a playbook, specify: zscaler.ziacloud.zia_cloud_app_control_rule_actions_info.
New in zscaler.ziacloud 1.0.0
Synopsis
Retrieves granular actions supported for a specific Cloud App Control rule type and cloud applications.
Equivalent to the Terraform
zia_cloud_app_control_rule_actionsdatasource.
Requirements
The below requirements are needed on the host that executes this module.
Zscaler SDK Python can be obtained from PyPI https://pypi.org/project/zscaler-sdk-python/
Parameters
Parameter |
Comments |
|---|---|
Optional list of action prefixes to filter results. Valid values include An underscore is automatically appended if not present. Only actions starting with these prefixes are included in |
|
A string that contains the obfuscated API key. |
|
The client ID for OAuth2 authentication. |
|
The client secret for OAuth2 authentication. |
|
The Zscaler cloud name provisioned for your organization. Choices:
|
|
List of cloud application names to retrieve available actions for. |
|
A string that contains the password for the API admin. |
|
The private key for JWT-based OAuth2 authentication. |
|
A dict containing authentication credentials. |
|
Obfuscated API key. |
|
OAuth2 client ID. |
|
OAuth2 client secret. |
|
Zscaler cloud name. Choices:
|
|
Password for the API admin. |
|
Private key for OAuth2 JWT. |
|
Sandbox Cloud environment. |
|
Sandbox API Key. |
|
Whether to use the legacy Zscaler API client. Choices:
|
|
Email ID of the API admin. |
|
Vanity domain for OAuth2. |
|
An optional JMESPath expression applied locally to the flat list of action strings returned by the API. Use this for advanced client-side filtering/projection when The expression operates on a list of strings, so reference the current element with Applied before the derived action lists are computed. See https://jmespath.org/ for the syntax. |
|
The Sandbox cloud environment for API access. |
|
A string that contains the Sandbox API Key. |
|
The rule type for the Cloud App Control policy (e.g., |
|
Whether to use the legacy Zscaler API client. Choices:
|
|
A string that contains the email ID of the API admin. |
|
The vanity domain provisioned by Zscaler for OAuth2 flows. |
Notes
Note
Check mode is not supported.
query(JMESPath) is applied locally to the retrieved list of actions before the derivedavailable_actions,available_actions_without_isolate,isolate_actionsandfiltered_actionsoutputs are computed.
Examples
- name: Get all available actions for WEBMAIL and AOL_MAIL
zscaler.ziacloud.zia_cloud_app_control_rule_actions_info:
provider: '{{ provider }}'
type: "WEBMAIL"
cloud_apps:
- "AOL_MAIL"
register: result
- name: Get available actions filtered by prefix
zscaler.ziacloud.zia_cloud_app_control_rule_actions_info:
provider: '{{ provider }}'
type: "STREAMING_MEDIA"
cloud_apps:
- "DROPBOX"
action_prefixes:
- "ALLOW"
- "BLOCK"
register: result
- name: Get only ALLOW actions using a JMESPath query
zscaler.ziacloud.zia_cloud_app_control_rule_actions_info:
provider: '{{ provider }}'
type: "STREAMING_MEDIA"
cloud_apps:
- "DROPBOX"
query: "[?starts_with(@, 'ALLOW')]"
register: result
- name: Exclude ISOLATE actions using a JMESPath query
zscaler.ziacloud.zia_cloud_app_control_rule_actions_info:
provider: '{{ provider }}'
type: "WEBMAIL"
cloud_apps:
- "AOL_MAIL"
query: "[?!starts_with(@, 'ISOLATE')]"
register: result
Return Values
Common return values are documented here, the following are the fields unique to this module:
Key |
Description |
|---|---|
List of all available actions for the specified cloud applications and rule type (includes ISOLATE actions). When Returned: always |
|
List of available actions excluding ISOLATE actions. Use for standard rules. ISOLATE actions cannot be mixed with other actions. Returned: always |
|
List of actions filtered by Returned: always |
|
List of only ISOLATE actions. Use for Cloud Browser Isolation rules. ISOLATE actions require cbi_profile configuration and cannot be mixed with other actions. Returned: always |