zscaler.ziacloud.zia_url_categories module – Adds a new custom URL category.

Note

This module is part of the zscaler.ziacloud collection (version 1.3.1).

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_url_categories.

New in zscaler.ziacloud 1.0.0

Synopsis

  • Adds a new custom URL category.

Requirements

The below requirements are needed on the host that executes this module.

Parameters

Parameter

Comments

api_key

string

A string that contains the obfuscated API key.

cloud

string

The Zscaler cloud name was provisioned for your organization.

Choices:

  • "zscloud"

  • "zscaler"

  • "zscalerone"

  • "zscalertwo"

  • "zscalerthree"

  • "zscalerbeta"

  • "zscalergov"

  • "zscalerten"

configured_name

string

Name of the URL category. This is only required for custom URL categories.

custom_category

boolean

Set to true for custom URL category. Up to 48 custom URL categories can be added per organization.

Choices:

  • false

  • true

db_categorized_urls

list / elements=string

URLs added to a custom URL category are also retained under the original parent URL category.

i.e. the predefined category the URL previously belonged to.

The URLs entered are covered by policies that reference the original parent URL category.

If you add www.amazon.com, this URL is covered by policies that reference the custom URL category.

description

string

Description of the URL category.

editable

boolean

Value is set to false for custom URL category when due to scope user does not have edit permission

Choices:

  • false

  • true

id

string

ip_ranges

list / elements=string

Custom IP address ranges associated to a URL category.

Up to 2000 custom IP address ranges and retaining parent custom IP address ranges can be added, per organization, across all categories.

This field is available only if the option to configure custom IP ranges is enabled for your organization.

To enable this option, contact Zscaler Support.

ip_ranges_retaining_parent_category

list / elements=string

The retaining parent custom IP address ranges associated to a URL category.

Up to 2000 custom IP ranges and retaining parent custom IP address ranges can be added, per organization, across all categories.

keywords

list / elements=string

Custom keywords associated to a URL category.

Up to 2048 custom keywords can be added per organization across all categories including bandwidth classes

keywords_retaining_parent_category

list / elements=string

Retained custom keywords from the parent URL category that is associated to a URL category.

Up to 2048 retained parent keywords can be added per organization across all categories including bandwidth classes.

password

string

A string that contains the password for the API admin.

provider

dictionary

A dict object containing connection details. This is optional; credentials can also be provided directly at the top level.

api_key

string

A string that contains the obfuscated API key.

cloud

string

The Zscaler cloud name was provisioned for your organization.

Choices:

  • "zscloud"

  • "zscaler"

  • "zscalerone"

  • "zscalertwo"

  • "zscalerthree"

  • "zscalerbeta"

  • "zscalergov"

  • "zscalerten"

password

string

A string that contains the password for the API admin.

sandbox_token

string

A string that contains the Sandbox API Key.

username

string

A string that contains the email ID of the API admin.

sandbox_token

string

A string that contains the Sandbox API Key.

scopes

list / elements=dictionary

Scope of the custom categories.

scope_entities

list / elements=integer

Based on the admin scope type, the entities can be the ID/name pair of departments, locations, or location groups.

The attribute name is subject to change.

type

string

The admin scope type. The attribute name is subject to change.

Choices:

  • "ORGANIZATION"

  • "DEPARTMENT"

  • "LOCATION"

  • "LOCATION_GROUP"

state

string

Specifies the desired state of the resource.

Choices:

  • "present" ← (default)

  • "absent"

super_category

string

Super Category of the URL category.

This field is required when creating custom URL categories.

type

string

Type of the custom categories.

Choices:

  • "URL_CATEGORY"

  • "TLD_CATEGORY"

  • "ALL"

urls

list / elements=string

Retained custom keywords from the parent URL category that is associated to a URL category.

Up to 2048 retained parent keywords can be added per organization across all categories including bandwidth classes.

username

string

A string that contains the email ID of the API admin.

Notes

Note

  • Check mode is supported.

Examples

- name: Create a URL Category
  zscaler.ziacloud.zia_url_categories:
    provider: '{{ provider }}'
    super_category: USER_DEFINED
    configured_name: Example_Category
    description: Example_Category
    type: URL_CATEGORY
    keywords:
      - microsoft
    custom_category: true
    db_categorized_urls:
      - .creditkarma.com
      - .youku.com
    urls:
      - .coupons.com
      - .resource.alaskaair.net
      - .techrepublic.com
      - .dailymotion.com
      - .osiriscomm.com
      - .uefa.com
      - .Logz.io
      - .alexa.com
      - .baidu.com
      - .cnn.com
      - .level3.com

Authors

  • William Guilherme (@willguibr)