WebDlpRule
Web Dlp Rule resource for Zscaler Internet Access.
This resource supports the following standard methods: create(), load(), update(), delete(). They operate on the instance state — set properties with dot notation, then call the method with no arguments.
Quick Start
import zssdk
import logging
# Enable debug logging for WebDlpRule
logging.getLogger('zssdk.zia').setLevel(logging.DEBUG)
logging.basicConfig(level=logging.DEBUG)
session = zssdk.Session(
vanity_domain="your-vanity-domain",
client_id="your-client-id",
client_secret="your-client-secret",
)
# Get a specific WebDlpRule
resource = session.zia.WebDlpRule(id="your-resource-id")
resource.load()
print(resource)
# Debug output shows HTTP request/response details
Identifiers
| Name | Type | Description |
|---|---|---|
id | string | Unique identifier |
Actions
create()
Creates a new WebDlpRule. Set properties on the resource instance, then call create() — this method takes no arguments.
Properties for creation:
| Name | Type | Required | Description |
|---|---|---|---|
access_control | string | No | - |
action | string | No | - |
auditor | EntityReference | No | - |
cloud_app_instances | CloudApplicationInstanceLiteWrapperCollection | No | - |
cloud_applications | stringCollection | No | - |
departments | EntityReferenceWrapperCollection | No | - |
description | string | No | - |
dlp_content_locations_scopes | DlpContentLocationsScopesEnumCollection | No | - |
dlp_download_scan_enabled | boolean | No | - |
dlp_engines | EntityReferenceWrapperCollection | No | - |
eun_template_id | integer | No | - |
excluded_departments | EntityReferenceWrapperCollection | No | - |
excluded_domain_profiles | EntityReferenceWrapperCollection | No | - |
excluded_groups | EntityReferenceWrapperCollection | No | - |
excluded_users | EntityReferenceWrapperCollection | No | - |
external_auditor_email | string | No | - |
file_type_categories | FileTypeCategoryWrapperCollection | No | - |
file_types | stringCollection | No | - |
groups | EntityReferenceWrapperCollection | No | - |
id | integer | No | - |
included_domain_profiles | EntityReferenceWrapperCollection | No | - |
inspect_http_get_enabled | boolean | No | - |
labels | EntityReferenceWrapperCollection | No | - |
last_modified_by | EntityReference | No | - |
last_modified_time | integer | No | - |
location_groups | EntityReferenceWrapperCollection | No | - |
locations | EntityReferenceWrapperCollection | No | - |
match_only | boolean | No | - |
min_size | integer | No | - |
name | string | No | - |
notification_template | EntityReference | No | - |
order | integer | No | - |
parent_rule | integer | No | - |
protocols | WebDlpRuleProtocolsEnumCollection | No | - |
rank | integer | No | - |
receiver | IncidentReceiverReference | No | - |
severity | string | No | - |
source_ip_groups | EntityReferenceWrapperCollection | No | - |
state | string | No | - |
sub_rules | WebDlpRuleWrapperCollection | No | - |
template_synced_rule_flag | string | No | - |
time_windows | EntityReferenceWrapperCollection | No | - |
uc_template_id | integer | No | - |
url_categories | EntityReferenceWrapperCollection | No | - |
user_risk_score_levels | UserRiskScoreLevelsEnumCollection | No | - |
users | EntityReferenceWrapperCollection | No | - |
without_content_inspection | boolean | No | - |
workload_groups | WorkloadGroupWrapperCollection | No | - |
zcc_notifications_enabled | boolean | No | - |
zpa_app_segments | AppSegmentWrapperCollection | No | - |
Returns: WebDlpRule
Example:
resource = session.zia.WebDlpRule()
resource.access_control = "value"
resource.action = "value"
resource.auditor = {"association_time": 3600, "deleted": True, "extensions": {"key1": "value", "key2": "value"}, "external_id": "resource-id"}
resource.create()
print(f"Created with ID: {resource.id}")
delete()
Deletes a WebDlpRule by id. Only the id identifier is required; delete() takes no other arguments.
Example:
resource = session.zia.WebDlpRule(id="your-resource-id")
resource.delete()
load()
Fetches an existing WebDlpRule by id. Only the id identifier is required; load() takes no other arguments.
Returns: WebDlpRule
Example:
resource = session.zia.WebDlpRule(id="your-resource-id")
resource.load()
print(resource.name)
update()
Updates an existing WebDlpRule. Call load() first, modify properties, then call update() — this method takes no arguments.
Properties for update:
| Name | Type | Required | Description |
|---|---|---|---|
access_control | string | No | - |
action | string | No | - |
auditor | EntityReference | No | - |
cloud_app_instances | CloudApplicationInstanceLiteWrapperCollection | No | - |
cloud_applications | stringCollection | No | - |
departments | EntityReferenceWrapperCollection | No | - |
description | string | No | - |
dlp_content_locations_scopes | DlpContentLocationsScopesEnumCollection | No | - |
dlp_download_scan_enabled | boolean | No | - |
dlp_engines | EntityReferenceWrapperCollection | No | - |
eun_template_id | integer | No | - |
excluded_departments | EntityReferenceWrapperCollection | No | - |
excluded_domain_profiles | EntityReferenceWrapperCollection | No | - |
excluded_groups | EntityReferenceWrapperCollection | No | - |
excluded_users | EntityReferenceWrapperCollection | No | - |
external_auditor_email | string | No | - |
file_type_categories | FileTypeCategoryWrapperCollection | No | - |
file_types | stringCollection | No | - |
groups | EntityReferenceWrapperCollection | No | - |
id | integer | Yes | - |
included_domain_profiles | EntityReferenceWrapperCollection | No | - |
inspect_http_get_enabled | boolean | No | - |
labels | EntityReferenceWrapperCollection | No | - |
last_modified_by | EntityReference | No | - |
last_modified_time | integer | No | - |
location_groups | EntityReferenceWrapperCollection | No | - |
locations | EntityReferenceWrapperCollection | No | - |
match_only | boolean | No | - |
min_size | integer | No | - |
name | string | No | - |
notification_template | EntityReference | No | - |
order | integer | No | - |
parent_rule | integer | No | - |
protocols | WebDlpRuleProtocolsEnumCollection | No | - |
rank | integer | No | - |
receiver | IncidentReceiverReference | No | - |
severity | string | No | - |
source_ip_groups | EntityReferenceWrapperCollection | No | - |
state | string | No | - |
sub_rules | WebDlpRuleWrapperCollection | No | - |
template_synced_rule_flag | string | No | - |
time_windows | EntityReferenceWrapperCollection | No | - |
uc_template_id | integer | No | - |
url_categories | EntityReferenceWrapperCollection | No | - |
user_risk_score_levels | UserRiskScoreLevelsEnumCollection | No | - |
users | EntityReferenceWrapperCollection | No | - |
without_content_inspection | boolean | No | - |
workload_groups | WorkloadGroupWrapperCollection | No | - |
zcc_notifications_enabled | boolean | No | - |
zpa_app_segments | AppSegmentWrapperCollection | No | - |
Returns: WebDlpRule
Example:
resource = session.zia.WebDlpRule(id="your-resource-id")
resource.load()
resource.name = "Updated value"
resource.update()
Attributes
| Name | Type | Required | Description |
|---|---|---|---|
access_control | string | No | - |
action | string | No | - |
auditor | EntityReference | No | - |
cloud_app_instances | CloudApplicationInstanceLiteWrapperCollection | No | - |
cloud_applications | stringCollection | No | - |
departments | EntityReferenceWrapperCollection | No | - |
description | string | No | - |
dlp_content_locations_scopes | DlpContentLocationsScopesEnumCollection | No | - |
dlp_download_scan_enabled | boolean | No | - |
dlp_engines | EntityReferenceWrapperCollection | No | - |
eun_template_id | integer | No | - |
excluded_departments | EntityReferenceWrapperCollection | No | - |
excluded_domain_profiles | EntityReferenceWrapperCollection | No | - |
excluded_groups | EntityReferenceWrapperCollection | No | - |
excluded_users | EntityReferenceWrapperCollection | No | - |
external_auditor_email | string | No | - |
file_type_categories | FileTypeCategoryWrapperCollection | No | - |
file_types | stringCollection | No | - |
groups | EntityReferenceWrapperCollection | No | - |
id | integer | No | - |
included_domain_profiles | EntityReferenceWrapperCollection | No | - |
inspect_http_get_enabled | boolean | No | - |
labels | EntityReferenceWrapperCollection | No | - |
last_modified_by | EntityReference | No | - |
last_modified_time | integer | No | - |
location_groups | EntityReferenceWrapperCollection | No | - |
locations | EntityReferenceWrapperCollection | No | - |
match_only | boolean | No | - |
min_size | integer | No | - |
name | string | No | - |
notification_template | EntityReference | No | - |
order | integer | No | - |
parent_rule | integer | No | - |
protocols | WebDlpRuleProtocolsEnumCollection | No | - |
rank | integer | No | - |
receiver | IncidentReceiverReference | No | - |
severity | string | No | - |
source_ip_groups | EntityReferenceWrapperCollection | No | - |
state | string | No | - |
sub_rules | WebDlpRuleWrapperCollection | No | - |
template_synced_rule_flag | string | No | - |
time_windows | EntityReferenceWrapperCollection | No | - |
uc_template_id | integer | No | - |
url_categories | EntityReferenceWrapperCollection | No | - |
user_risk_score_levels | UserRiskScoreLevelsEnumCollection | No | - |
users | EntityReferenceWrapperCollection | No | - |
without_content_inspection | boolean | No | - |
workload_groups | WorkloadGroupWrapperCollection | No | - |
zcc_notifications_enabled | boolean | No | - |
zpa_app_segments | AppSegmentWrapperCollection | No | - |
Related
- WebDlpRule - Data structure definition
- Logging guide - enable verbose logs while debugging this resource