Zscaler Internet Access (ZIA) Tools¶
The Zscaler Internet Access (ZIA) tools provide comprehensive functionality for managing internet security policies, user administration, and network configuration.
Available Tools¶
Tool Name |
Description |
|---|---|
|
Tool to check or activate ZIA configuration changes |
|
Manages the malicious URL denylist in the ZIA Advanced Threat Protection (ATP) policy |
|
Manages the list of cookie authentication exempt URLs in ZIA |
|
List ZIA Shadow IT cloud applications (analytics catalog with numeric IDs and friendly names) |
|
List ZIA Shadow IT custom tags |
|
Bulk update sanction state and/or custom tags on ZIA Shadow IT applications |
|
List the ZIA policy-engine cloud-application catalog (canonical enum strings used by Web DLP, Cloud App Control, File Type Control, Bandwidth Classes, Advanced Settings) |
|
List the ZIA cloud-application catalog scoped to SSL Inspection rules (canonical enum strings used by |
|
Manages ZIA Cloud Firewall Rules |
|
Manages ZIA Cloud Firewall DNS Rules (list/get/create/update/delete) |
|
Manages ZIA Cloud Firewall IPS Rules (list/get/create/update/delete) |
|
Manages ZIA File Type Control Rules (list/get/create/update/delete) plus |
|
Manages ZIA Sandbox Rules (list/get/create/update/delete). Distinct from |
|
Manages ZIA Time Intervals (list/get/create/update/delete). Reusable schedule objects ( |
|
Performs geographical lookup actions using the ZIA Locations API |
|
Tool for discovering available GRE internal IP ranges in ZIA |
|
Tool for managing ZIA GRE Tunnels and associated static IPs |
|
Manages ZIA IP Destination Groups |
|
Performs CRUD operations on ZIA IP Source Groups |
|
Lists and retrieves ZIA User Groups with pagination, filtering and sorting |
|
Lists and retrieves ZIA User Departments with pagination, filtering and sorting |
|
Lists and retrieves ZIA Users with filtering and pagination |
|
Tool for managing ZIA Locations |
|
Manages ZIA Network Application Groups |
|
Tool for managing ZIA Rule Labels |
|
Tool for retrieving ZIA Sandbox information |
|
Tool for managing ZIA Static IP addresses |
|
Tool for managing ZIA URL Categories |
|
Tool for managing ZIA VPN Credentials |
|
Tool for managing ZIA SSL Inspection Rules |
Tool Categories¶
Category |
Tools |
|---|---|
User Management |
Admin roles, user groups, departments, users |
Policy Management |
URL filtering rules, firewall rules, DLP engines/dictionaries |
Network Configuration |
GRE tunnels, static IPs, location management, IP groups |
Security Features |
Sandbox analysis, ATP malicious URLs, cloud applications |
Reporting |
Various reporting and analytics tools |
Tool Details¶
zia_activation¶
Tool to check or activate ZIA configuration changes.
Parameters:
- param service:
The service to use (default: “zia”)
- type service:
str
Returns: - Dictionary with activation status information
Example: .. code-block:: python
status = zia_activation()
zia_user_groups¶
Lists and retrieves ZIA User Groups with pagination, filtering and sorting.
Parameters:
- param page:
Specifies the page offset
- type page:
Optional[int]
- param page_size:
Specifies the page size
- type page_size:
Optional[int]
- param search:
The search string used to partially match
- type search:
Optional[str]
- param service:
The service to use (default: “zia”)
- type service:
str
Returns: - List of user group dictionaries
Example: .. code-block:: python
groups = zia_user_groups(page=1, page_size=50, search=”admin”)
zia_url_categories¶
Tool for managing ZIA URL Categories.
Parameters:
- param action:
The action to perform (e.g., “read”, “create”, “update”, “delete”)
- type action:
str
- param category_id:
The ID of the category for “read”, “update”, “delete” actions
- type category_id:
str, optional
- param service:
The service to use (default: “zia”)
- type service:
str
Returns: - Dictionary with category information or list of categories
Example: .. code-block:: python
categories = zia_url_categories(action=”list”)
zia_cloud_firewall_rule¶
Manages ZIA Cloud Firewall Rules.
Parameters:
- param action:
The action to perform (e.g., “read”, “create”, “update”, “delete”)
- type action:
str
- param rule_id:
The ID of the rule for “read”, “update”, “delete” actions
- type rule_id:
str, optional
- param service:
The service to use (default: “zia”)
- type service:
str
Returns: - Dictionary with rule information or list of rules
Example: .. code-block:: python
rules = zia_cloud_firewall_rule(action=”list”)
zia_sandbox_info¶
Tool for retrieving ZIA Sandbox information.
Parameters:
- param service:
The service to use (default: “zia”)
- type service:
str
Returns: - Dictionary with sandbox analysis information
Example: .. code-block:: python
sandbox_info = zia_sandbox_info()
Two Cloud-Application Catalogs¶
ZIA exposes the cloud-application catalog through two distinct API surfaces. Picking the right tool matters — the catalogs are not interchangeable.
Catalog |
Tools |
Identifier returned |
|---|---|---|
Shadow IT analytics |
|
Numeric |
Policy-engine catalog |
|
Canonical |
Policy resources — SSL Inspection, Web DLP, Cloud App Control, File Type
Control, Bandwidth Classes, Advanced Settings — accept only the canonical
app enum from the policy-engine catalog in their cloud_applications
field. Passing a Shadow IT numeric ID or a friendly display name causes ZIA
to silently coerce the value to NONE.
The SSL Inspection create/update tools (zia_create_ssl_inspection_rule,
zia_update_ssl_inspection_rule) include an in-process resolver that
auto-translates friendly names to canonical enums via
zia_list_cloud_app_ssl_policy before sending the API call. The resolution
is cached for 5 minutes and surfaced back to the caller in a
_cloud_applications_resolution field on the response. Set
resolve_cloud_apps=False to opt out.
For complete documentation of all ZIA tools, see the individual tool pages.
Authentication¶
ZIA tools authenticate through OneAPI (OAuth2 client credentials). Required environment variables:
ZSCALER_CLIENT_ID
ZSCALER_CLIENT_SECRET
ZSCALER_VANITY_DOMAIN
ZSCALER_CLOUD
Common Use Cases¶
Policy Management: Configure URL filtering and firewall rules
User Administration: Manage admin roles and user groups
Network Security: Configure GRE tunnels and static IPs
Threat Protection: Analyze files with sandbox and ATP features
Error Handling¶
All ZIA tools include comprehensive error handling:
Authentication errors: Invalid credentials or expired tokens
Permission errors: Insufficient privileges for the requested operation
Validation errors: Invalid parameters or malformed requests
Rate limiting: Automatic retry with exponential backoff
For detailed error information, check the tool response for error messages and status codes.