cisco.dnac.network_devices_create module -- Resource module for Network Devices Create
Note
This module is part of the cisco.dnac collection (version 6.46.0).
To install it, use: ansible-galaxy collection install cisco.dnac.
You need further requirements to be able to use this module,
see Requirements for details.
To use it in a playbook, specify: cisco.dnac.network_devices_create.
New in cisco.dnac 6.46.0
Synopsis
Manage operation create of the resource Network Devices Create. - > Adds the network device to inventory. The API supports Network Device, Meraki Dashboard, Compute Device, Firewall Management Center FMC and Third-Party Device. Access points associated with added WLC will be automatically added to inventory. For Meraki Dashboard, use the dashboard URL as the management address.
Note
This module has a corresponding action plugin.
Requirements
The below requirements are needed on the host that executes this module.
dnacentersdk >= 2.11.0
python >= 3.12
Parameters
Parameter |
Comments |
|---|---|
Category of the device. Used to determine the type of the device being added. |
|
Network Devices Create's credentials. |
|
Network Devices Create's cli. |
|
Password that is used to move to a higher privilege level in the CLI. Configure this password only if your network devices require it. Passwords cannot contain spaces or angle brackets(<>). |
|
CLI Password. Passwords cannot contain spaces or angle brackets(<>). |
|
Protocol used for CLI access. Default is SSH. |
|
CLI username to login to the device. |
|
Network Devices Create's http. |
|
HTTP password. The password cannot contain spaces or angle brackets (< >). Note that some Cisco IOS XE devices do not allow a question mark (?). |
|
HTTP port. The default port is 443 for protocol= HTTPS and 80 for protocol=HTTP. |
|
HTTP protocol. Compute device require HTTPS. |
|
HTTP username. Username cannot contain spaces or angle brackets (< >). |
|
Network Devices Create's meraki. |
|
Meraki API key. |
|
Meraki organizations for which the devices needs to be imported. Imports devices from all organizations if not provided. |
|
Network Devices Create's netconf. |
|
Netconf port of the device. Default port is 830. |
|
Network Devices Create's snmp. |
|
SNMPv3 authentication password. |
|
SNMPv3 authentication type. Required for AUTHPRIV (Authentication and Privacy) and AUTHNOPRIV (Authentication) modes. SHA256 The device will be authenticated using SHA256. SHA The device will be authenticated using SHA. MD5 The device will be authenticated using MD5. |
|
Security level that an SNMP message requires. AUTHPRIV provides both authentication and encryption. AUTHNOPRIV provides authentication, but does not provide encryption. NOAUTHNOPRIV does not provide authentication or encryption. |
|
SNMPv3 privacy password. |
|
SNMP privacy type. Required if the SNMP mode is AUTHPRIV. AES128 algorithm used for encryption. AES192 algorithm used for encryption. AES256 algorithm used for encryption. CISCOAES192 algorithm used for encryption. CISCOAES256 algorithm used for encryption. |
|
Read-only community string password used only to view SNMP information on the device. |
|
Name associated with the SNMPv3 settings. |
|
SNMP version to be used for the device. |
|
Write community string used to make changes to the SNMP information on the device. |
|
Flag for Cisco DNA Center SDK to enable debugging. Choices: |
|
The Cisco DNA Center hostname. |
|
The Cisco DNA Center password to authenticate. |
|
The Cisco DNA Center port. Default: :ansible-option-default:`443` |
|
The Cisco DNA Center username to authenticate. Default: :ansible-option-default:`"admin"` |
|
Flag to enable or disable SSL certificate verification. Choices: |
|
Informs the SDK which version of Cisco DNA Center to use. Default: :ansible-option-default:`"3.1.6.0"` |
|
Management address of the network device. For meraki dashboard, this is the dashboard URL. |
|
Flag for Cisco DNA Center SDK to enable the validation of request bodies against a JSON schema. Choices: |
Notes
Note
SDK Method used are devices.Devices.adds_a_new_network_device,
Paths used are post /dna/intent/api/v1/networkDevices,
Does not support
check_modeThe plugin runs on the control node and does not use any ansible connection plugins, but instead the embedded connection manager from Cisco DNAC SDK
The parameters starting with dnac_ are used by the Cisco DNAC Python SDK to establish the connection
See Also
See also
- Cisco DNA Center documentation for Devices AddsANewNetworkDevice
Complete reference of the AddsANewNetworkDevice API.
Examples
---
- name: Create
cisco.dnac.network_devices_create:
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}}"
category: string
credentials:
cli:
enablePassword: string
password: string
protocol: string
username: string
http:
password: string
port: 0
protocol: string
username: string
meraki:
apiKey: string
orgIds:
- string
netconf:
port: 0
snmp:
authPassword: string
authType: string
mode: string
privacyPassword: string
privacyType: string
readCommunity: string
username: string
version: string
writeCommunity: string
managementAddress: string
Return Values
Common return values are documented here, the following are the fields unique to this module:
Key |
Description |
|---|---|
A dictionary or list with the response returned by the Cisco DNAC Python SDK Returned: always Sample: :ansible-rv-sample-value:`{"response": {"taskId": "string", "url": "string"}, "version": "string"}` |