.. 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.inventory_playbook_config_generator_module: .. Anchors: short name for ansible.builtin .. Anchors: aliases .. Title cisco.catalystcenter.inventory_playbook_config_generator module -- Generate YAML playbook for \ :literal:`inventory\_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.inventory_playbook_config_generator`. .. version_added .. rst-class:: ansible-version-added New in cisco.catalystcenter 6.44.0 .. contents:: :local: :depth: 1 .. Deprecated Synopsis -------- .. Description - Generates YAML configurations compatible with the \ :literal:`inventory\_workflow\_manager`\ module, reducing the effort required to manually create Ansible playbooks and enabling programmatic modifications. - The YAML configurations generated represent the inventory configurations configured on the Cisco Catalyst Center. .. Aliases .. Requirements .. _ansible_collections.cisco.catalystcenter.inventory_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 .. Options Parameters ---------- .. rst-class:: ansible-option-table .. list-table:: :width: 100% :widths: auto :header-rows: 1 * - Parameter - Comments * - .. raw:: html
.. _ansible_collections.cisco.catalystcenter.inventory_playbook_config_generator_module__parameter-catalystcenter_api_task_timeout: .. _ansible_collections.cisco.catalystcenter.inventory_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.inventory_playbook_config_generator_module__parameter-catalystcenter_debug: .. _ansible_collections.cisco.catalystcenter.inventory_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.inventory_playbook_config_generator_module__parameter-catalystcenter_host: .. _ansible_collections.cisco.catalystcenter.inventory_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.inventory_playbook_config_generator_module__parameter-catalystcenter_log: .. _ansible_collections.cisco.catalystcenter.inventory_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.inventory_playbook_config_generator_module__parameter-catalystcenter_log_append: .. _ansible_collections.cisco.catalystcenter.inventory_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.inventory_playbook_config_generator_module__parameter-catalystcenter_log_file_path: .. _ansible_collections.cisco.catalystcenter.inventory_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.inventory_playbook_config_generator_module__parameter-catalystcenter_log_level: .. _ansible_collections.cisco.catalystcenter.inventory_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.inventory_playbook_config_generator_module__parameter-catalystcenter_password: .. _ansible_collections.cisco.catalystcenter.inventory_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.inventory_playbook_config_generator_module__parameter-catalystcenter_api_port: .. _ansible_collections.cisco.catalystcenter.inventory_playbook_config_generator_module__parameter-catalystcenter_port: .. _ansible_collections.cisco.catalystcenter.inventory_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.inventory_playbook_config_generator_module__parameter-catalystcenter_task_poll_interval: .. _ansible_collections.cisco.catalystcenter.inventory_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.inventory_playbook_config_generator_module__parameter-catalystcenter_username: .. _ansible_collections.cisco.catalystcenter.inventory_playbook_config_generator_module__parameter-dnac_username: .. _ansible_collections.cisco.catalystcenter.inventory_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.inventory_playbook_config_generator_module__parameter-catalystcenter_verify: .. _ansible_collections.cisco.catalystcenter.inventory_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.inventory_playbook_config_generator_module__parameter-catalystcenter_version: .. _ansible_collections.cisco.catalystcenter.inventory_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.inventory_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
A dictionary of filters for generating YAML playbook compatible with the \ :literal:`inventory\_workflow\_manager`\ module. If config is not provided (omitted entirely), all configurations for all inventory devices will be generated. This is useful for complete brownfield infrastructure discovery and documentation. Important - An empty dictionary {} is not valid. Either omit 'config' entirely to generate all configurations, or provide specific filters within 'config'. .. raw:: html
* - .. raw:: html
.. _ansible_collections.cisco.catalystcenter.inventory_playbook_config_generator_module__parameter-config/global_filters: .. rst-class:: ansible-option-title **global_filters** .. raw:: html .. rst-class:: ansible-option-type-line :ansible-option-type:`dictionary` .. raw:: html
- .. raw:: html
Global filters used to filter inventory data. Multiple filters under \ :literal:`global\_filters`\ are combined using logical AND. At least one supported global filter must be provided when using \ :literal:`global\_filters`\ . Unknown keys fail validation with an error. .. raw:: html
* - .. raw:: html
.. _ansible_collections.cisco.catalystcenter.inventory_playbook_config_generator_module__parameter-config/global_filters/device_identifier: .. rst-class:: ansible-option-title **device_identifier** .. raw:: html .. rst-class:: ansible-option-type-line :ansible-option-type:`string` .. raw:: html
- .. raw:: html
Identifier used to build the generated list key in output config. The output key is written as \ :literal:`\\_list`\ . .. rst-class:: ansible-option-line :ansible-option-choices:`Choices:` - :ansible-option-choices-entry-default:`"ip\_address"` :ansible-option-choices-default-mark:`← (default)` - :ansible-option-choices-entry:`"hostname"` - :ansible-option-choices-entry:`"serial\_number"` - :ansible-option-choices-entry:`"mac\_address"` .. raw:: html
* - .. raw:: html
.. _ansible_collections.cisco.catalystcenter.inventory_playbook_config_generator_module__parameter-config/global_filters/device_roles: .. rst-class:: ansible-option-title **device_roles** .. raw:: html .. rst-class:: ansible-option-type-line :ansible-option-type:`list` / :ansible-option-elements:`elements=string` .. raw:: html
- .. raw:: html
List of inventory device roles to include. Supported values are \ :literal:`ACCESS`\ , \ :literal:`DISTRIBUTION`\ , \ :literal:`CORE`\ , \ :literal:`BORDER ROUTER`\ , and \ :literal:`UNKNOWN`\ . .. rst-class:: ansible-option-line :ansible-option-choices:`Choices:` - :ansible-option-choices-entry:`"ACCESS"` - :ansible-option-choices-entry:`"DISTRIBUTION"` - :ansible-option-choices-entry:`"CORE"` - :ansible-option-choices-entry:`"BORDER ROUTER"` - :ansible-option-choices-entry:`"UNKNOWN"` .. raw:: html
* - .. raw:: html
.. _ansible_collections.cisco.catalystcenter.inventory_playbook_config_generator_module__parameter-config/global_filters/devices: .. rst-class:: ansible-option-title **devices** .. raw:: html .. rst-class:: ansible-option-type-line :ansible-option-type:`list` / :ansible-option-elements:`elements=string` .. raw:: html
- .. raw:: html
List of device identifier values to filter inventory records. You can provide one or more values from \ :literal:`ip\_address`\ , \ :literal:`hostname`\ , \ :literal:`serial\_number`\ , or \ :literal:`mac\_address`\ , and the module matches each value against these identifier fields. .. raw:: html
* - .. raw:: html
.. _ansible_collections.cisco.catalystcenter.inventory_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. This parameter is only relevant when \ :literal:`file\_path`\ is specified. Defaults to \ :literal:`overwrite`\ . .. 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.inventory_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
Path where the YAML configuration file will be saved. If not provided, the file will be saved in the current working directory with a default file name \ :literal:`inventory\_playbook\_config\_\.yml`\ . For example, \ :literal:`inventory\_playbook\_config\_2026-02-20\_13-34-58.yml`\ . .. raw:: html
* - .. raw:: html
.. _ansible_collections.cisco.catalystcenter.inventory_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
The desired state of Cisco Catalyst Center after module execution. .. 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.inventory_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:: - Cisco Catalyst Center \>= 2.3.7.9 - SDK Methods used are devices.Devices.get\_device\_list - SDK/REST Paths used are GET /dna/intent/api/v1/network-device - Auto-discovery mode: When \ :literal:`config`\ is omitted entirely, the module runs in auto-discovery mode and generates inventory configuration for all discovered devices without applying filters. - Filter behavior: When \ :literal:`config.global\_filters`\ is provided, \ :literal:`devices`\ and \ :literal:`device\_roles`\ are applied with AND semantics. Unknown global filter keys fail validation with an error. - Module result behavior (changed/ok/failed): The module result reflects local file state only, not Catalyst Center state. In overwrite mode, generated YAML is compared against existing file content after excluding generated comment lines. In append mode, only the last YAML document is considered for idempotency check. - changed=true (status: success): Generated configuration differs (or file does not exist), and file is written. - changed=false (status: ok): Generated configuration matches existing content, so write is skipped. - failed=true (status: failed): Validation/API/file-write failure occurred. - Stack device handling: Stack switches (e.g. Cisco Catalyst 9500 StackWise) are returned by Catalyst Center as a single device record whose identifier fields (serial\_number, mac\_address) contain comma-separated values, one per stack member. When generating the YAML configuration, such records are expanded into one entry per stack member so that each member appears as a distinct '\\_list' entry in the output. Filtering by an individual member identifier (e.g. a single member serial number) matches the parent stack record. - 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.inventory\_workflow\_manager `\ Module for managing inventory settings and workflows. .. Examples Examples -------- .. code-block:: yaml+jinja - name: Auto-generate YAML Configuration for all inventory devices cisco.catalystcenter.inventory_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_level: "{{ catalystcenter_log_level }}" catalystcenter_log: true state: gathered # No config provided - generates all inventory configurations - name: Generate YAML Configuration with file path and overwrite mode cisco.catalystcenter.inventory_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_level: "{{ catalystcenter_log_level }}" catalystcenter_log: true state: gathered file_path: "tmp/catc_inventory_config.yml" file_mode: "overwrite" - name: Generate YAML Configuration filtered by device roles cisco.catalystcenter.inventory_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_level: "{{ catalystcenter_log_level }}" catalystcenter_log: true state: gathered file_path: "tmp/catc_filtered_inventory_config.yml" file_mode: "overwrite" config: global_filters: device_roles: ["ACCESS", "CORE"] device_identifier: "hostname" - name: Generate YAML Configuration for selected devices using serial number and IP cisco.catalystcenter.inventory_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_level: "{{ catalystcenter_log_level }}" catalystcenter_log: true state: gathered file_path: "tmp/catc_inventory_config.yml" file_mode: "append" config: global_filters: devices: - "10.10.20.11" - "FDO1234A1BC" - name: Generate YAML Configuration for a stack switch by member serial number cisco.catalystcenter.inventory_playbook_config_generator: catalystcenter_host: "{{ catalystcenter_host }}" catalystcenter_username: "{{ catalystcenter_username }}" catalystcenter_password: "{{ catalystcenter_password }}" catalystcenter_version: "{{ catalystcenter_version }}" catalystcenter_log: true state: gathered file_path: "tmp/catc_stack_inventory.yml" config: global_filters: # Either member serial matches the parent stack record; # the stack is expanded into one entry per member in the output. devices: - "FJC27102F2K" device_identifier: "serial_number" .. 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.inventory_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
A dictionary with the response returned by the Cisco Catalyst Center Python SDK .. 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": {"configurations\_count": 31, "file\_mode": "overwrite", "file\_path": "tmp/inventory\_testing.yml", "message": "YAML configuration file generated successfully for module 'inventory\_workflow\_manager'", "status": "success"}, "response": {"configurations\_count": 31, "file\_mode": "overwrite", "file\_path": "tmp/inventory\_testing.yml", "message": "YAML configuration file generated successfully for module 'inventory\_workflow\_manager'", "status": "success"}, "status": "success"}` .. raw:: html
* - .. raw:: html
.. _ansible_collections.cisco.catalystcenter.inventory_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
A string with the response returned by the Cisco Catalyst Center Python SDK .. 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:`"{\\n \\"msg\\":\\n \\"Configuration cannot be an empty dictionary. Either omit 'config' entirely to generate all configurations,\\n or provide specific filters within 'config'.\\",\\n \\"response\\":\\n \\"Configuration cannot be an empty dictionary. Either omit 'config' entirely to generate all configurations,\\n or provide specific filters within 'config'.\\"\\n}\\n"` .. raw:: html
.. Status (Presently only deprecated) .. Authors Authors ~~~~~~~ - Mridul Saurabh (@msaurabh12) - Sunil Shatagopa (@shatagopasunil) - Madhan Sankaranarayanan (@madhansansel) .. Extra links Collection links ~~~~~~~~~~~~~~~~ .. raw:: html .. Parsing errors