.. Document meta :orphan: .. |antsibull-internal-nbsp| unicode:: 0xA0 :trim: .. role:: ansible-attribute-support-label .. role:: ansible-attribute-support-property .. role:: ansible-attribute-support-full .. role:: ansible-attribute-support-partial .. role:: ansible-attribute-support-none .. role:: ansible-attribute-support-na .. role:: ansible-option-type .. role:: ansible-option-elements .. role:: ansible-option-required .. role:: ansible-option-versionadded .. role:: ansible-option-aliases .. role:: ansible-option-choices .. role:: ansible-option-choices-default-mark .. role:: ansible-option-default-bold .. role:: ansible-option-configuration .. role:: ansible-option-returned-bold .. role:: ansible-option-sample-bold .. Anchors .. _ansible_collections.cisco.catalystcenter.device_credential_playbook_config_generator_module: .. Anchors: short name for ansible.builtin .. Anchors: aliases .. Title cisco.catalystcenter.device_credential_playbook_config_generator module -- Generate YAML configurations playbook for 'device\_credential\_workflow\_manager' module. ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ .. Collection note .. note:: This module is part of the `cisco.catalystcenter collection `_ (version 2.10.0). To install it, use: :code:`ansible-galaxy collection install cisco.catalystcenter`. You need further requirements to be able to use this module, see :ref:`Requirements ` for details. To use it in a playbook, specify: :code:`cisco.catalystcenter.device_credential_playbook_config_generator`. .. version_added .. rst-class:: ansible-version-added New in cisco.catalystcenter 6.44.0 .. contents:: :local: :depth: 1 .. Deprecated Synopsis -------- .. Description - Automates brownfield YAML playbook generation for device credential configurations deployed in Cisco Catalyst Center infrastructure. - Extracts global device credentials (CLI, HTTPS Read/Write, SNMPv2c Read/Write, SNMPv3) and site-specific credential assignments via REST APIs. - Generates YAML files compatible with device\_credential\_workflow\_manager module for configuration documentation, credential auditing, disaster recovery, and multi-site credential standardization. - Supports auto-discovery mode for complete credential infrastructure extraction or component-based filtering for targeted extraction (global credentials, site assignments). - Masks sensitive fields (passwords, community strings, auth credentials) with Jinja2 variable placeholders for secure playbook generation. - Transforms camelCase API responses to snake\_case YAML format with comprehensive header comments and metadata. .. Aliases .. Requirements .. _ansible_collections.cisco.catalystcenter.device_credential_playbook_config_generator_module_requirements: Requirements ------------ The below requirements are needed on the host that executes this module. - catalystcentersdk \>= 3.1.6.0.2 - python \>= 3.12 - PyYAML \>= 5.1 .. Options Parameters ---------- .. rst-class:: ansible-option-table .. list-table:: :width: 100% :widths: auto :header-rows: 1 * - Parameter - Comments * - .. raw:: html
.. _ansible_collections.cisco.catalystcenter.device_credential_playbook_config_generator_module__parameter-catalystcenter_api_task_timeout: .. _ansible_collections.cisco.catalystcenter.device_credential_playbook_config_generator_module__parameter-dnac_api_task_timeout: .. rst-class:: ansible-option-title **catalystcenter_api_task_timeout** .. raw:: html .. rst-class:: ansible-option-type-line :ansible-option-aliases:`aliases: dnac_api_task_timeout` .. rst-class:: ansible-option-type-line :ansible-option-type:`integer` .. raw:: html
- .. raw:: html
Defines the timeout in seconds for API calls to retrieve task details. If the task details are not received within this period, the process will end, and a timeout notification will be logged. .. rst-class:: ansible-option-line :ansible-option-default-bold:`Default:` :ansible-option-default:`1200` .. raw:: html
* - .. raw:: html
.. _ansible_collections.cisco.catalystcenter.device_credential_playbook_config_generator_module__parameter-catalystcenter_debug: .. _ansible_collections.cisco.catalystcenter.device_credential_playbook_config_generator_module__parameter-dnac_debug: .. rst-class:: ansible-option-title **catalystcenter_debug** .. raw:: html .. rst-class:: ansible-option-type-line :ansible-option-aliases:`aliases: dnac_debug` .. rst-class:: ansible-option-type-line :ansible-option-type:`boolean` .. raw:: html
- .. raw:: html
Indicates whether debugging is enabled in the Cisco Catalyst Center SDK. .. rst-class:: ansible-option-line :ansible-option-choices:`Choices:` - :ansible-option-choices-entry-default:`false` :ansible-option-choices-default-mark:`← (default)` - :ansible-option-choices-entry:`true` .. raw:: html
* - .. raw:: html
.. _ansible_collections.cisco.catalystcenter.device_credential_playbook_config_generator_module__parameter-catalystcenter_host: .. _ansible_collections.cisco.catalystcenter.device_credential_playbook_config_generator_module__parameter-dnac_host: .. rst-class:: ansible-option-title **catalystcenter_host** .. raw:: html .. rst-class:: ansible-option-type-line :ansible-option-aliases:`aliases: dnac_host` .. rst-class:: ansible-option-type-line :ansible-option-type:`string` / :ansible-option-required:`required` .. raw:: html
- .. raw:: html
The hostname of the Cisco Catalyst Center. .. raw:: html
* - .. raw:: html
.. _ansible_collections.cisco.catalystcenter.device_credential_playbook_config_generator_module__parameter-catalystcenter_log: .. _ansible_collections.cisco.catalystcenter.device_credential_playbook_config_generator_module__parameter-dnac_log: .. rst-class:: ansible-option-title **catalystcenter_log** .. raw:: html .. rst-class:: ansible-option-type-line :ansible-option-aliases:`aliases: dnac_log` .. rst-class:: ansible-option-type-line :ansible-option-type:`boolean` .. raw:: html
- .. raw:: html
Flag to enable/disable playbook execution logging. When true and catalystcenter\_log\_file\_path is provided, - Create the log file at the execution location with the specified name. When true and catalystcenter\_log\_file\_path is not provided, - Create the log file at the execution location with the name 'catalystcenter.log'. When false, - Logging is disabled. If the log file doesn't exist, - It is created in append or write mode based on the "catalystcenter\_log\_append" flag. If the log file exists, - It is overwritten or appended based on the "catalystcenter\_log\_append" flag. .. rst-class:: ansible-option-line :ansible-option-choices:`Choices:` - :ansible-option-choices-entry-default:`false` :ansible-option-choices-default-mark:`← (default)` - :ansible-option-choices-entry:`true` .. raw:: html
* - .. raw:: html
.. _ansible_collections.cisco.catalystcenter.device_credential_playbook_config_generator_module__parameter-catalystcenter_log_append: .. _ansible_collections.cisco.catalystcenter.device_credential_playbook_config_generator_module__parameter-dnac_log_append: .. rst-class:: ansible-option-title **catalystcenter_log_append** .. raw:: html .. rst-class:: ansible-option-type-line :ansible-option-aliases:`aliases: dnac_log_append` .. rst-class:: ansible-option-type-line :ansible-option-type:`boolean` .. raw:: html
- .. raw:: html
Determines the mode of the file. Set to True for 'append' mode. Set to False for 'write' mode. .. rst-class:: ansible-option-line :ansible-option-choices:`Choices:` - :ansible-option-choices-entry:`false` - :ansible-option-choices-entry-default:`true` :ansible-option-choices-default-mark:`← (default)` .. raw:: html
* - .. raw:: html
.. _ansible_collections.cisco.catalystcenter.device_credential_playbook_config_generator_module__parameter-catalystcenter_log_file_path: .. _ansible_collections.cisco.catalystcenter.device_credential_playbook_config_generator_module__parameter-dnac_log_file_path: .. rst-class:: ansible-option-title **catalystcenter_log_file_path** .. raw:: html .. rst-class:: ansible-option-type-line :ansible-option-aliases:`aliases: dnac_log_file_path` .. rst-class:: ansible-option-type-line :ansible-option-type:`string` .. raw:: html
- .. raw:: html
Governs logging. Logs are recorded if catalystcenter\_log is True. If path is not specified, - When 'catalystcenter\_log\_append' is True, 'catalystcenter.log' is generated in the current Ansible directory; logs are appended. - When 'catalystcenter\_log\_append' is False, 'catalystcenter.log' is generated; logs are overwritten. If path is specified, - When 'catalystcenter\_log\_append' is True, the file opens in append mode. - When 'catalystcenter\_log\_append' is False, the file opens in write (w) mode. - In shared file scenarios, without append mode, content is overwritten after each module execution. - For a shared log file, set append to False for the 1st module (to overwrite); for subsequent modules, set append to True. .. rst-class:: ansible-option-line :ansible-option-default-bold:`Default:` :ansible-option-default:`"catalystcenter.log"` .. raw:: html
* - .. raw:: html
.. _ansible_collections.cisco.catalystcenter.device_credential_playbook_config_generator_module__parameter-catalystcenter_log_level: .. _ansible_collections.cisco.catalystcenter.device_credential_playbook_config_generator_module__parameter-dnac_log_level: .. rst-class:: ansible-option-title **catalystcenter_log_level** .. raw:: html .. rst-class:: ansible-option-type-line :ansible-option-aliases:`aliases: dnac_log_level` .. rst-class:: ansible-option-type-line :ansible-option-type:`string` .. raw:: html
- .. raw:: html
Sets the threshold for log level. Messages with a level equal to or higher than this will be logged. Levels are listed in order of severity [CRITICAL, ERROR, WARNING, INFO, DEBUG]. CRITICAL indicates serious errors halting the program. Displays only CRITICAL messages. ERROR indicates problems preventing a function. Displays ERROR and CRITICAL messages. WARNING indicates potential future issues. Displays WARNING, ERROR, CRITICAL messages. INFO tracks normal operation. Displays INFO, WARNING, ERROR, CRITICAL messages. DEBUG provides detailed diagnostic info. Displays all log messages. .. rst-class:: ansible-option-line :ansible-option-default-bold:`Default:` :ansible-option-default:`"WARNING"` .. raw:: html
* - .. raw:: html
.. _ansible_collections.cisco.catalystcenter.device_credential_playbook_config_generator_module__parameter-catalystcenter_password: .. _ansible_collections.cisco.catalystcenter.device_credential_playbook_config_generator_module__parameter-dnac_password: .. rst-class:: ansible-option-title **catalystcenter_password** .. raw:: html .. rst-class:: ansible-option-type-line :ansible-option-aliases:`aliases: dnac_password` .. rst-class:: ansible-option-type-line :ansible-option-type:`string` .. raw:: html
- .. raw:: html
The password for authentication at the Cisco Catalyst Center. .. raw:: html
* - .. raw:: html
.. _ansible_collections.cisco.catalystcenter.device_credential_playbook_config_generator_module__parameter-catalystcenter_api_port: .. _ansible_collections.cisco.catalystcenter.device_credential_playbook_config_generator_module__parameter-catalystcenter_port: .. _ansible_collections.cisco.catalystcenter.device_credential_playbook_config_generator_module__parameter-dnac_port: .. rst-class:: ansible-option-title **catalystcenter_port** .. raw:: html .. rst-class:: ansible-option-type-line :ansible-option-aliases:`aliases: dnac_port, catalystcenter_api_port` .. rst-class:: ansible-option-type-line :ansible-option-type:`string` .. raw:: html
- .. raw:: html
Specifies the port number associated with the Cisco Catalyst Center. .. rst-class:: ansible-option-line :ansible-option-default-bold:`Default:` :ansible-option-default:`"443"` .. raw:: html
* - .. raw:: html
.. _ansible_collections.cisco.catalystcenter.device_credential_playbook_config_generator_module__parameter-catalystcenter_task_poll_interval: .. _ansible_collections.cisco.catalystcenter.device_credential_playbook_config_generator_module__parameter-dnac_task_poll_interval: .. rst-class:: ansible-option-title **catalystcenter_task_poll_interval** .. raw:: html .. rst-class:: ansible-option-type-line :ansible-option-aliases:`aliases: dnac_task_poll_interval` .. rst-class:: ansible-option-type-line :ansible-option-type:`integer` .. raw:: html
- .. raw:: html
Specifies the interval in seconds between successive calls to the API to retrieve task details. .. rst-class:: ansible-option-line :ansible-option-default-bold:`Default:` :ansible-option-default:`2` .. raw:: html
* - .. raw:: html
.. _ansible_collections.cisco.catalystcenter.device_credential_playbook_config_generator_module__parameter-catalystcenter_username: .. _ansible_collections.cisco.catalystcenter.device_credential_playbook_config_generator_module__parameter-dnac_username: .. _ansible_collections.cisco.catalystcenter.device_credential_playbook_config_generator_module__parameter-user: .. rst-class:: ansible-option-title **catalystcenter_username** .. raw:: html .. rst-class:: ansible-option-type-line :ansible-option-aliases:`aliases: dnac_username, user` .. rst-class:: ansible-option-type-line :ansible-option-type:`string` .. raw:: html
- .. raw:: html
The username for authentication at the Cisco Catalyst Center. .. rst-class:: ansible-option-line :ansible-option-default-bold:`Default:` :ansible-option-default:`"admin"` .. raw:: html
* - .. raw:: html
.. _ansible_collections.cisco.catalystcenter.device_credential_playbook_config_generator_module__parameter-catalystcenter_verify: .. _ansible_collections.cisco.catalystcenter.device_credential_playbook_config_generator_module__parameter-dnac_verify: .. rst-class:: ansible-option-title **catalystcenter_verify** .. raw:: html .. rst-class:: ansible-option-type-line :ansible-option-aliases:`aliases: dnac_verify` .. rst-class:: ansible-option-type-line :ansible-option-type:`boolean` .. raw:: html
- .. raw:: html
Flag to enable or disable SSL certificate verification. .. rst-class:: ansible-option-line :ansible-option-choices:`Choices:` - :ansible-option-choices-entry:`false` - :ansible-option-choices-entry-default:`true` :ansible-option-choices-default-mark:`← (default)` .. raw:: html
* - .. raw:: html
.. _ansible_collections.cisco.catalystcenter.device_credential_playbook_config_generator_module__parameter-catalystcenter_version: .. _ansible_collections.cisco.catalystcenter.device_credential_playbook_config_generator_module__parameter-dnac_version: .. rst-class:: ansible-option-title **catalystcenter_version** .. raw:: html .. rst-class:: ansible-option-type-line :ansible-option-aliases:`aliases: dnac_version` .. rst-class:: ansible-option-type-line :ansible-option-type:`string` .. raw:: html
- .. raw:: html
Specifies the version of the Cisco Catalyst Center that the SDK should use. .. rst-class:: ansible-option-line :ansible-option-default-bold:`Default:` :ansible-option-default:`"2.3.7.6"` .. raw:: html
* - .. raw:: html
.. _ansible_collections.cisco.catalystcenter.device_credential_playbook_config_generator_module__parameter-config: .. rst-class:: ansible-option-title **config** .. raw:: html .. rst-class:: ansible-option-type-line :ansible-option-type:`dictionary` .. raw:: html
- .. raw:: html
Top-level configuration block that controls the scope and filtering of the generated YAML playbook for the \ :literal:`device\_credential\_workflow\_manager`\ module. Contains \ :literal:`component\_specific\_filters`\ to select which credential components (global credentials, site assignments) and which individual credentials are included in the output. If \ :literal:`config`\ is not provided or is empty, all global credentials and all site credential assignments are extracted (auto-discovery mode). This is useful for complete brownfield infrastructure discovery and documentation. .. raw:: html
* - .. raw:: html
.. _ansible_collections.cisco.catalystcenter.device_credential_playbook_config_generator_module__parameter-config/component_specific_filters: .. rst-class:: ansible-option-title **component_specific_filters** .. raw:: html .. rst-class:: ansible-option-type-line :ansible-option-type:`dictionary` .. raw:: html
- .. raw:: html
Container for all component-level and credential-level filters that control what is included in the generated YAML playbook. Holds \ :literal:`components\_list`\ to select which top-level components to extract, and optional per-component filters (\ :literal:`global\_credential\_details`\ , \ :literal:`assign\_credentials\_to\_site`\ ) for fine-grained credential or site selection. If \ :literal:`components\_list`\ is specified, only the listed components are included regardless of other filters. If per-component filters are provided without explicitly including them in \ :literal:`components\_list`\ , those components are automatically added to \ :literal:`components\_list`\ . At least one of \ :literal:`components\_list`\ or per-component filters must be provided. .. raw:: html
* - .. raw:: html
.. _ansible_collections.cisco.catalystcenter.device_credential_playbook_config_generator_module__parameter-config/component_specific_filters/assign_credentials_to_site: .. rst-class:: ansible-option-title **assign_credentials_to_site** .. raw:: html .. rst-class:: ansible-option-type-line :ansible-option-type:`list` / :ansible-option-elements:`elements=string` .. raw:: html
- .. raw:: html
Site-level credential assignments that map global credentials to specific sites in the Catalyst Center site hierarchy. This parameter accepts a list of site hierarchical path strings to control which site assignments are extracted into the generated YAML playbook. Each string must be a full hierarchical site path starting from "Global" (e.g., "Global/Region/Building"). Site names are case-sensitive and must match exact paths configured in Catalyst Center. If not specified when component is included in \ :literal:`components\_list`\ , extracts all site credential assignments. For example: ["Global/India/Assam", "Global/India/Haryana"] .. raw:: html
* - .. raw:: html
.. _ansible_collections.cisco.catalystcenter.device_credential_playbook_config_generator_module__parameter-config/component_specific_filters/components_list: .. rst-class:: ansible-option-title **components_list** .. raw:: html .. rst-class:: ansible-option-type-line :ansible-option-type:`list` / :ansible-option-elements:`elements=string` .. raw:: html
- .. raw:: html
Selector that determines which top-level credential components are extracted from Catalyst Center and written to the YAML playbook. Valid values are \ :literal:`global\_credential\_details`\ for global credentials and \ :literal:`assign\_credentials\_to\_site`\ for site-specific credential assignments. If specified, only the listed components are included in the generated YAML file. If not specified but per-component filters (\ :literal:`global\_credential\_details`\ or \ :literal:`assign\_credentials\_to\_site`\ ) are provided, those components are automatically added to this list. If neither \ :literal:`components\_list`\ nor any per-component filters are provided, an error is raised. .. rst-class:: ansible-option-line :ansible-option-choices:`Choices:` - :ansible-option-choices-entry:`"global\_credential\_details"` - :ansible-option-choices-entry:`"assign\_credentials\_to\_site"` .. raw:: html
* - .. raw:: html
.. _ansible_collections.cisco.catalystcenter.device_credential_playbook_config_generator_module__parameter-config/component_specific_filters/global_credential_details: .. rst-class:: ansible-option-title **global_credential_details** .. raw:: html .. rst-class:: ansible-option-type-line :ansible-option-type:`list` / :ansible-option-elements:`elements=dictionary` .. raw:: html
- .. raw:: html
List of credential filter entries for global device credential extraction. Each entry specifies a credential \ :literal:`type`\ and an optional \ :literal:`description`\ . \ :literal:`description`\ is a list of strings; each value must match a Catalyst Center credential description exactly (case-sensitive). If \ :literal:`description`\ is omitted (or empty) for a given \ :literal:`type`\ , all credentials of that type are extracted. When multiple entries with different \ :literal:`type`\ values are provided, each type is filtered independently (AND logic across types). If \ :literal:`global\_credential\_details`\ is omitted entirely but \ :literal:`global\_credential\_details`\ is present in \ :literal:`components\_list`\ , all credentials of all types are extracted without filtering. For example, [{"type": "cli\_credential", "description": ["WLC", "Router\_CLI"]}, {"type": "https\_read"}, {"type": "snmp\_v3", "description": ["SNMPv3\_Admin"]}] .. raw:: html
* - .. raw:: html
.. _ansible_collections.cisco.catalystcenter.device_credential_playbook_config_generator_module__parameter-config/component_specific_filters/global_credential_details/description: .. rst-class:: ansible-option-title **description** .. raw:: html .. rst-class:: ansible-option-type-line :ansible-option-type:`list` / :ansible-option-elements:`elements=string` .. raw:: html
- .. raw:: html
Human-readable labels assigned to credentials in Catalyst Center, used here as filter values to select specific credentials of the given \ :literal:`type`\ . Each value must match a Catalyst Center credential description exactly (case-sensitive). If omitted or empty, all credentials of the specified \ :literal:`type`\ are extracted. When multiple entries share the same \ :literal:`type`\ , their \ :literal:`description`\ lists are merged (union). For example: ["WLC", "Router\_CLI"] .. raw:: html
* - .. raw:: html
.. _ansible_collections.cisco.catalystcenter.device_credential_playbook_config_generator_module__parameter-config/component_specific_filters/global_credential_details/type: .. rst-class:: ansible-option-title **type** .. raw:: html .. rst-class:: ansible-option-type-line :ansible-option-type:`string` / :ansible-option-required:`required` .. raw:: html
- .. raw:: html
Credential type to filter. Must be one of cli\_credential, https\_read, https\_write, snmp\_v2c\_read, snmp\_v2c\_write, snmp\_v3. .. rst-class:: ansible-option-line :ansible-option-choices:`Choices:` - :ansible-option-choices-entry:`"cli\_credential"` - :ansible-option-choices-entry:`"https\_read"` - :ansible-option-choices-entry:`"https\_write"` - :ansible-option-choices-entry:`"snmp\_v2c\_read"` - :ansible-option-choices-entry:`"snmp\_v2c\_write"` - :ansible-option-choices-entry:`"snmp\_v3"` .. raw:: html
* - .. raw:: html
.. _ansible_collections.cisco.catalystcenter.device_credential_playbook_config_generator_module__parameter-file_mode: .. rst-class:: ansible-option-title **file_mode** .. raw:: html .. rst-class:: ansible-option-type-line :ansible-option-type:`string` .. raw:: html
- .. raw:: html
Controls how config is written to the YAML file. \ :literal:`overwrite`\ replaces existing file content. \ :literal:`append`\ appends generated YAML content to the existing file. .. rst-class:: ansible-option-line :ansible-option-choices:`Choices:` - :ansible-option-choices-entry-default:`"overwrite"` :ansible-option-choices-default-mark:`← (default)` - :ansible-option-choices-entry:`"append"` .. raw:: html
* - .. raw:: html
.. _ansible_collections.cisco.catalystcenter.device_credential_playbook_config_generator_module__parameter-file_path: .. rst-class:: ansible-option-title **file_path** .. raw:: html .. rst-class:: ansible-option-type-line :ansible-option-type:`string` .. raw:: html
- .. raw:: html
Absolute or relative path for YAML configuration file output. If not provided, generates default filename in current working directory with pattern \ :literal:`device\_credential\_playbook\_config\_\.yml`\ . Example default filename \ :literal:`device\_credential\_playbook\_config\_2026-01-24\_12-33-20.yml`\ . Directory created automatically if path does not exist. Supports YAML file extension (.yml or .yaml). .. raw:: html
* - .. raw:: html
.. _ansible_collections.cisco.catalystcenter.device_credential_playbook_config_generator_module__parameter-state: .. rst-class:: ansible-option-title **state** .. raw:: html .. rst-class:: ansible-option-type-line :ansible-option-type:`string` .. raw:: html
- .. raw:: html
Desired state for YAML playbook generation workflow. Only 'gathered' state supported for brownfield credential extraction. .. rst-class:: ansible-option-line :ansible-option-choices:`Choices:` - :ansible-option-choices-entry-default:`"gathered"` :ansible-option-choices-default-mark:`← (default)` .. raw:: html
* - .. raw:: html
.. _ansible_collections.cisco.catalystcenter.device_credential_playbook_config_generator_module__parameter-validate_response_schema: .. rst-class:: ansible-option-title **validate_response_schema** .. raw:: html .. rst-class:: ansible-option-type-line :ansible-option-type:`boolean` .. raw:: html
- .. raw:: html
Flag for Cisco Catalyst Center SDK to enable the validation of request bodies against a JSON schema. .. rst-class:: ansible-option-line :ansible-option-choices:`Choices:` - :ansible-option-choices-entry:`false` - :ansible-option-choices-entry-default:`true` :ansible-option-choices-default-mark:`← (default)` .. raw:: html
.. Attributes .. Notes Notes ----- .. note:: - SDK methods utilized - discovery.get\_all\_global\_credentials, site\_design.get\_sites, network\_settings.get\_device\_credential\_settings\_for\_a\_site - API paths utilized - GET /dna/intent/api/v2/global-credential, GET /dna/intent/api/v1/sites, GET /dna/intent/api/v1/sites/${id}/deviceCredentials - Module is idempotent; multiple runs generate identical YAML content except timestamp in header comments. - Check mode supported; validates parameters without file generation. - Sensitive credential fields (passwords, community strings, auth credentials) masked with Jinja2 variable placeholders (e.g., {{ cli\_credential\_wlc\_password }}). - Generated YAML uses OrderedDumper for consistent key ordering enabling version control. - Description-based filtering is case-sensitive and requires exact matches. - Site hierarchical paths must match exact Catalyst Center site structure. - Auto-population of components\_list: If component-specific filters (such as global\_credential\_details or assign\_credentials\_to\_site) are provided without explicitly including them in components\_list, those components will be automatically added to components\_list. This simplifies configuration by eliminating the need to redundantly specify components in both places. - Example of auto-population behavior: If you provide filters for global\_credential\_details without including global\_credential\_details in components\_list, the module will automatically add global\_credential\_details to components\_list before processing. This allows you to write more concise playbooks. - Validation requirements: If component\_specific\_filters is provided, at least one of the following must be true - (1) components\_list contains at least one component, OR (2) Component-specific filters (e.g., global\_credential\_details, assign\_credentials\_to\_site) are provided. If neither condition is met, the module will fail with a validation error. - Does not support \ :literal:`check\_mode`\ - The plugin runs on the control node and does not use any ansible connection plugins instead embedded connection manager from Cisco Catalyst Center SDK .. Seealso See Also -------- .. seealso:: \ :ref:`cisco.catalystcenter.device\_credential\_workflow\_manager `\ Module for managing device credential workflows in Cisco Catalyst Center. .. Examples Examples -------- .. code-block:: yaml+jinja - name: Generate YAML playbook for device credential workflow manager which includes all global credentials and site assignments cisco.catalystcenter.device_credential_playbook_config_generator: catalystcenter_host: "{{ catalystcenter_host }}" catalystcenter_username: "{{ catalystcenter_username }}" catalystcenter_password: "{{ catalystcenter_password }}" catalystcenter_verify: "{{ catalystcenter_verify }}" catalystcenter_port: "{{ catalystcenter_port }}" catalystcenter_version: "{{ catalystcenter_version }}" catalystcenter_debug: "{{ catalystcenter_debug }}" catalystcenter_log: true catalystcenter_log_level: DEBUG state: gathered file_mode: "overwrite" - name: Generate YAML Configuration with File Path specified cisco.catalystcenter.device_credential_playbook_config_generator: catalystcenter_host: "{{ catalystcenter_host }}" catalystcenter_username: "{{ catalystcenter_username }}" catalystcenter_password: "{{ catalystcenter_password }}" catalystcenter_verify: "{{ catalystcenter_verify }}" catalystcenter_port: "{{ catalystcenter_port }}" catalystcenter_version: "{{ catalystcenter_version }}" catalystcenter_debug: "{{ catalystcenter_debug }}" catalystcenter_log: true catalystcenter_log_level: DEBUG state: gathered file_mode: "append" file_path: "device_credential_config.yml" - name: Generate YAML Configuration with specific component global credential filters cisco.catalystcenter.device_credential_playbook_config_generator: catalystcenter_host: "{{ catalystcenter_host }}" catalystcenter_username: "{{ catalystcenter_username }}" catalystcenter_password: "{{ catalystcenter_password }}" catalystcenter_verify: "{{ catalystcenter_verify }}" catalystcenter_port: "{{ catalystcenter_port }}" catalystcenter_version: "{{ catalystcenter_version }}" catalystcenter_debug: "{{ catalystcenter_debug }}" catalystcenter_log: true catalystcenter_log_level: DEBUG state: gathered file_path: "device_credential_config.yml" file_mode: "overwrite" config: component_specific_filters: components_list: ["global_credential_details"] global_credential_details: - type: cli_credential description: - WLC - Router_CLI - type: https_read description: - http_read - type: https_write description: - http_write - type: snmp_v2c_read - type: snmp_v2c_write - type: snmp_v3 - name: Generate YAML Configuration with specific component assign credentials to site filters cisco.catalystcenter.device_credential_playbook_config_generator: catalystcenter_host: "{{ catalystcenter_host }}" catalystcenter_username: "{{ catalystcenter_username }}" catalystcenter_password: "{{ catalystcenter_password }}" catalystcenter_verify: "{{ catalystcenter_verify }}" catalystcenter_port: "{{ catalystcenter_port }}" catalystcenter_version: "{{ catalystcenter_version }}" catalystcenter_debug: "{{ catalystcenter_debug }}" catalystcenter_log: true catalystcenter_log_level: DEBUG state: gathered file_path: "device_credential_config.yml" file_mode: "append" config: component_specific_filters: components_list: ["assign_credentials_to_site"] assign_credentials_to_site: - "Global/India/Assam" - "Global/India/Haryana" - name: Generate YAML with aggregated duplicate type filters cisco.catalystcenter.device_credential_playbook_config_generator: catalystcenter_host: "{{ catalystcenter_host }}" catalystcenter_username: "{{ catalystcenter_username }}" catalystcenter_password: "{{ catalystcenter_password }}" catalystcenter_verify: "{{ catalystcenter_verify }}" catalystcenter_port: "{{ catalystcenter_port }}" catalystcenter_version: "{{ catalystcenter_version }}" catalystcenter_debug: "{{ catalystcenter_debug }}" catalystcenter_log: true catalystcenter_log_level: DEBUG state: gathered file_path: "device_credential_config.yml" config: component_specific_filters: components_list: - global_credential_details global_credential_details: # Two entries for same type — descriptions are merged - type: cli_credential description: - WLC - type: cli_credential description: - Router_CLI # Omitting description extracts all of this type - type: snmp_v3 - name: Generate YAML Configuration with both global credential and assign credentials to site filters cisco.catalystcenter.device_credential_playbook_config_generator: catalystcenter_host: "{{ catalystcenter_host }}" catalystcenter_username: "{{ catalystcenter_username }}" catalystcenter_password: "{{ catalystcenter_password }}" catalystcenter_verify: "{{ catalystcenter_verify }}" catalystcenter_port: "{{ catalystcenter_port }}" catalystcenter_version: "{{ catalystcenter_version }}" catalystcenter_debug: "{{ catalystcenter_debug }}" catalystcenter_log: true catalystcenter_log_level: DEBUG state: gathered file_path: "device_credential_config.yml" file_mode: "append" config: component_specific_filters: components_list: ["global_credential_details", "assign_credentials_to_site"] global_credential_details: - type: cli_credential description: - WLC - type: https_read description: - http_read - type: https_write # No description filter — extracts all assign_credentials_to_site: - "Global/India/Assam" - "Global/India/TamilNadu" .. Facts .. Return values Return Values ------------- Common return values are documented :ref:`here `, the following are the fields unique to this module: .. rst-class:: ansible-option-table .. list-table:: :width: 100% :widths: auto :header-rows: 1 * - Key - Description * - .. raw:: html
.. _ansible_collections.cisco.catalystcenter.device_credential_playbook_config_generator_module__return-msg: .. rst-class:: ansible-option-title **msg** .. raw:: html .. rst-class:: ansible-option-type-line :ansible-option-type:`string` .. raw:: html
- .. raw:: html
Human-readable message describing the operation result. Indicates success, failure, or informational status of YAML generation. Provides high-level summary with file path and configuration counts for success scenarios. Provides error details for validation or generation failures. .. rst-class:: ansible-option-line :ansible-option-returned-bold:`Returned:` always .. rst-class:: ansible-option-line .. rst-class:: ansible-option-sample :ansible-option-sample-bold:`Sample:` :ansible-rv-sample-value:`"YAML configuration file generated successfully for module 'device\_credential\_workflow\_manager'"` .. raw:: html
* - .. raw:: html
.. _ansible_collections.cisco.catalystcenter.device_credential_playbook_config_generator_module__return-response_1: .. rst-class:: ansible-option-title **response_1** .. raw:: html .. rst-class:: ansible-option-type-line :ansible-option-type:`dictionary` .. raw:: html
- .. raw:: html
Response returned when YAML configuration generation completes successfully with all requested credentials and site assignments extracted and written to file. Includes operation summary with component counts, configuration counts, and file path details. Generated YAML file contains formatted playbook compatible with \ :literal:`device\_credential\_workflow\_manager`\ module. .. rst-class:: ansible-option-line :ansible-option-returned-bold:`Returned:` always .. rst-class:: ansible-option-line .. rst-class:: ansible-option-sample :ansible-option-sample-bold:`Sample:` :ansible-rv-sample-value:`{"msg": {"components\_processed": 2, "components\_skipped": 0, "configurations\_count": 2, "file\_path": "device\_credential\_config.yml", "message": "YAML configuration file generated successfully for module 'device\_credential\_workflow\_manager'", "status": "success"}, "response": {"components\_processed": 2, "components\_skipped": 0, "configurations\_count": 2, "file\_path": "device\_credential\_config.yml", "message": "YAML configuration file generated successfully for module 'device\_credential\_workflow\_manager'", "status": "success"}, "status": "success"}` .. raw:: html
* - .. raw:: html
.. _ansible_collections.cisco.catalystcenter.device_credential_playbook_config_generator_module__return-response_2: .. rst-class:: ansible-option-title **response_2** .. raw:: html .. rst-class:: ansible-option-type-line :ansible-option-type:`dictionary` .. raw:: html
- .. raw:: html
Response returned when no device credentials or site assignments are found matching the specified filters or in the Catalyst Center system. Operation status is \ :literal:`ok`\ indicating successful execution but no data available to generate. No YAML file is created when no configurations are found. \ :literal:`components\_attempted`\ shows which components were requested for extraction. .. rst-class:: ansible-option-line :ansible-option-returned-bold:`Returned:` always .. rst-class:: ansible-option-line .. rst-class:: ansible-option-sample :ansible-option-sample-bold:`Sample:` :ansible-rv-sample-value:`{"msg": {"components\_attempted": 2, "components\_processed": 0, "components\_skipped": 2, "message": "No configurations found for module 'device\_credential\_workflow\_manager'. Verify filters and component availability. Components attempted: ['global\_credential\_details', 'assign\_credentials\_to\_site']", "status": "ok"}, "response": {"components\_attempted": 2, "components\_processed": 0, "components\_skipped": 2, "message": "No configurations found for module 'device\_credential\_workflow\_manager'. Verify filters and component availability. Components attempted: ['global\_credential\_details', 'assign\_credentials\_to\_site']", "status": "ok"}, "status": "ok"}` .. raw:: html
* - .. raw:: html
.. _ansible_collections.cisco.catalystcenter.device_credential_playbook_config_generator_module__return-response_3: .. rst-class:: ansible-option-title **response_3** .. raw:: html .. rst-class:: ansible-option-type-line :ansible-option-type:`dictionary` .. raw:: html
- .. raw:: html
Response returned when playbook configuration parameters fail validation before YAML generation begins. Occurs when invalid filter parameters, incorrect data types, or unsupported component names are provided. No API calls executed and no file generation attempted. Error message provides specific validation failure details and allowed parameter values. .. rst-class:: ansible-option-line :ansible-option-returned-bold:`Returned:` always .. rst-class:: ansible-option-line .. rst-class:: ansible-option-sample :ansible-option-sample-bold:`Sample:` :ansible-rv-sample-value:`{"msg": "Validation Error: 'component\_specific\_filters' must be provided with 'components\_list' key when 'generate\_all\_configurations' is set to False.", "response": "Validation Error: 'component\_specific\_filters' must be provided with 'components\_list' key when 'generate\_all\_configurations' is set to False.", "status": "failed"}` .. raw:: html
.. Status (Presently only deprecated) .. Authors Authors ~~~~~~~ - Vivek Raj (@vivekraj2000) - Madhan Sankaranarayanan (@madhansansel) .. Extra links Collection links ~~~~~~~~~~~~~~~~ .. raw:: html .. Parsing errors