cisco / cisco.dnac / 6.13.3 / module / pnp_workflow_manager Resource module for Site and PnP related functions | "added in version" 6.6.0 of cisco.dnac" Authors: Abinash Mishra (@abimishr) Madhan Sankaranarayanan (@madhansansel) Rishita Chowdhary (@rishitachowdhary)cisco.dnac.pnp_workflow_manager (6.13.3) — module
Install with ansible-galaxy collection install cisco.dnac:==6.13.3
collections: - name: cisco.dnac version: 6.13.3
Manage operations add device, claim device and unclaim device of Onboarding Configuration(PnP) resource
API to add device to pnp inventory and claim it to a site.
API to delete device from the pnp inventory.
API to reset the device from errored state.
- name: Import multiple switches in bulk only cisco.dnac.pnp_workflow_manager: dnac_host: "{{dnac_host}}" dnac_username: "{{dnac_username}}" dnac_password: "{{dnac_password}}" dnac_verify: "{{dnac_verify}}" dnac_port: "{{dnac_port}}" dnac_version: "{{dnac_version}}" dnac_debug: "{{dnac_debug}}" dnac_log_level: "{{dnac_log_level}}" dnac_log: True state: merged config_verify: True config: - device_info: - serial_number: QD2425L8M7 state: Unclaimed pid: c9300-24P is_sudi_required: False - serial_number: QTC2320E0H9 state: Unclaimed pid: c9300-24P hostname: Test-123 - serial_number: ETC2320E0HB state: Unclaimed pid: c9300-24P
- name: Add a new EWLC and claim it cisco.dnac.pnp_workflow_manager: dnac_host: "{{dnac_host}}" dnac_username: "{{dnac_username}}" dnac_password: "{{dnac_password}}" dnac_verify: "{{dnac_verify}}" dnac_port: "{{dnac_port}}" dnac_version: "{{dnac_version}}" dnac_debug: "{{dnac_debug}}" dnac_log_level: "{{dnac_log_level}}" dnac_log: True state: merged config_verify: True config: - device_info: - serial_number: FOX2639PAY7 hostname: New_WLC state: Unclaimed pid: C9800-CL-K9 site_name: Global/USA/San Francisco/BGL_18 template_name: Ansible_PNP_WLC template_params: hostname: IAC-EWLC-Claimed project_name: Onboarding Configuration image_name: C9800-40-universalk9_wlc.17.12.01.SPA.bin golden_image: true pnp_type: CatalystWLC static_ip: 204.192.101.10 subnet_mask: 255.255.255.0 gateway: 204.192.101.1 vlan_id: 1101 ip_interface_name: TenGigabitEthernet0/0/0
- name: Claim a pre-added switch, apply a template, and perform an image upgrade for a specific site cisco.dnac.pnp_workflow_manager: dnac_host: "{{dnac_host}}" dnac_username: "{{dnac_username}}" dnac_password: "{{dnac_password}}" dnac_verify: "{{dnac_verify}}" dnac_port: "{{dnac_port}}" dnac_version: "{{dnac_version}}" dnac_debug: "{{dnac_debug}}" dnac_log_level: "{{dnac_log_level}}" dnac_log: True state: merged config_verify: True config: - device_info: - serial_number: FJC271924EQ hostname: Switch state: Unclaimed pid: C9300-48UXM site_name: Global/USA/San Francisco/BGL_18 template_name: "Ansible_PNP_Switch" image_name: cat9k_iosxe_npe.17.03.07.SPA.bin project_name: Onboarding Configuration template_params: hostname: SJC-Switch-1 interface: TwoGigabitEthernet1/0/2
- name: Remove multiple devices from the PnP dashboard safely (ignores non-existent devices) cisco.dnac.pnp_workflow_manager: dnac_host: "{{dnac_host}}" dnac_username: "{{dnac_username}}" dnac_password: "{{dnac_password}}" dnac_verify: "{{dnac_verify}}" dnac_port: "{{dnac_port}}" dnac_version: "{{dnac_version}}" dnac_debug: "{{dnac_debug}}" dnac_log_level: "{{dnac_log_level}}" dnac_log: True state: deleted config_verify: True config: - device_info: - serial_number: QD2425L8M7 - serial_number: FTC2320E0HA - serial_number: FKC2310E0HB
state: choices: - merged - deleted default: merged description: The state of Cisco Catalyst Center after module completion. type: str config: description: - List of details of device being managed. elements: dict required: true suboptions: device_info: description: - Provides the device-specific information required for adding devices to the PnP database that are not already present. - For adding a single device, the list should contain exactly one set of device information. If a site name is also provided, the device can be claimed immediately after being added. - For bulk import, the list must contain information for more than one device. Bulk import is intended solely for adding devices; claiming must be performed with separate tasks or configurations. elements: dict required: true suboptions: hostname: description: - Defines the desired hostname for the PnP device after it has been claimed. - The hostname can only be assigned or changed during the claim process, not during bulk or single device additions. type: str is_sudi_required: description: Sudi Authentication requiremnet's flag. type: bool pid: description: Pnp Device's pid. type: str serial_number: description: Pnp Device's serial_number. type: str state: description: - Represents the onboarding state of the PnP device. - Possible values are 'Unclaimed', 'Claimed', or 'Provisioned'. type: str type: list gateway: description: Gateway IP address of the Wireless Controller for getting pinged type: str golden_image: description: Is the image to be condifgured tagged as golden image type: bool image_name: description: Name of image to be configured on the device type: str ip_interface_name: description: Specifies the interface name utilized for Plug and Play (PnP) by the Wireless Controller. Ensure this interface is pre-configured on the Controller prior to device claiming. type: str pnp_type: choices: - Default - CatalystWLC - AccessPoint - StackSwitch default: Default description: Specifies the device type for the Plug and Play (PnP) device. - Options include 'Default', 'CatalystWLC', 'AccessPoint', or 'StackSwitch'. - 'Default' is applicable to switches and routers. - 'CatalystWLC' should be selected for 9800 series wireless controllers. - 'AccessPoint' is used when claiming an access point. - 'StackSwitch' should be chosen for a group of switches that operate as a single switch, typically used in the access layer. type: str project_name: default: Onboarding Configuration description: Name of the project under which the template is present type: str rf_profile: choices: - HIGH - LOW - TYPICAL description: - Radio Frequecy (RF) profile of the AP being claimed. - RF Profiles allow you to tune groups of APs that share a common coverage zone together. - They selectively change how Radio Resource Management will operate the APs within that coverage zone. - HIGH RF profile allows you to use more power and allows to join AP with the client in an easier fashion. - TYPICAL RF profile is a blend of moderate power and moderate visibility to the client. - LOW RF profile allows you to consume lesser power and has least visibility to the client. type: str site_name: description: Name of the site for which device will be claimed. type: str static_ip: description: Management IP address of the Wireless Controller type: str subnet_mask: description: Subnet Mask of the Management IP address of the Wireless Controller type: str template_name: description: - Name of template to be configured on the device. - Supported for EWLC from Cisco Catalyst Center release version 2.3.7.x onwards. type: str template_params: description: - Parameter values for the parameterised templates. - Each varibale has a value that needs to be passed as key-value pair in the dictionary. We can pass values as variable_name:variable_value. - Supported for EWLC from Cisco Catalyst Center release version 2.3.7.x onwards. type: dict vlan_id: description: Vlan Id allocated for claimimg of Wireless Controller type: str type: list dnac_log: default: false description: - Flag to enable/disable playbook execution logging. - When true and dnac_log_file_path is provided, - Create the log file at the execution location with the specified name. - When true and dnac_log_file_path is not provided, - Create the log file at the execution location with the name 'dnac.log'. - When false, - Logging is disabled. - If the log file doesn't exist, - It is created in append or write mode based on the "dnac_log_append" flag. - If the log file exists, - It is overwritten or appended based on the "dnac_log_append" flag. type: bool dnac_host: description: - The hostname of the Cisco Catalyst Center. required: true type: str dnac_port: default: '443' description: - Specifies the port number associated with the Cisco Catalyst Center. type: str dnac_debug: default: false description: - Indicates whether debugging is enabled in the Cisco Catalyst Center SDK. type: bool dnac_verify: default: true description: - Flag to enable or disable SSL certificate verification. type: bool dnac_version: default: 2.2.3.3 description: - Specifies the version of the Cisco Catalyst Center that the SDK should use. type: str config_verify: default: false description: Set to True to verify the Cisco Catalyst Center config after applying the playbook config. type: bool dnac_password: description: - The password for authentication at the Cisco Catalyst Center. type: str dnac_username: aliases: - user default: admin description: - The username for authentication at the Cisco Catalyst Center. type: str dnac_log_level: default: WARNING description: - 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. type: str dnac_log_append: default: true description: Determines the mode of the file. Set to True for 'append' mode. Set to False for 'write' mode. type: bool dnac_log_file_path: default: dnac.log description: - Governs logging. Logs are recorded if dnac_log is True. - If path is not specified, - When 'dnac_log_append' is True, 'dnac.log' is generated in the current Ansible directory; logs are appended. - When 'dnac_log_append' is False, 'dnac.log' is generated; logs are overwritten. - If path is specified, - When 'dnac_log_append' is True, the file opens in append mode. - When 'dnac_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. type: str dnac_api_task_timeout: default: 1200 description: 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. type: int dnac_task_poll_interval: default: 2 description: Specifies the interval in seconds between successive calls to the API to retrieve task details. type: int validate_response_schema: default: true description: - Flag for Cisco Catalyst Center SDK to enable the validation of request bodies against a JSON schema. type: bool
response_1: description: A dictionary with the response returned by the Cisco Catalyst Center Python SDK returned: always sample: "{\n \"response\":\n {\n \"response\": String,\n \"version\"\ : String\n },\n \"msg\": String\n}\n" type: dict response_2: description: A list with the response returned by the Cisco Catalyst Center Python SDK returned: always sample: "{\n \"response\": [],\n \"msg\": String\n}\n" type: list response_3: description: A string with the response returned by the Cisco Catalyst Center Python SDK returned: always sample: "{\n \"response\": String,\n \"msg\": String\n}\n" type: dict