cisco.dnac.pnp_device – Manage PnpDevice objects of DeviceOnboardingPnp

Note

This plugin is part of the cisco.dnac collection (version 2.0.7).

To install it use: ansible-galaxy collection install cisco.dnac.

To use it in a playbook, specify: cisco.dnac.pnp_device.

New in version 1.0.0: of cisco.dnac

Synopsis

  • Returns list of devices based on filter crieteria. If a limit is not specified, it will default to return 50 devices. Pagination and sorting are also supported by this endpoint.

  • Adds a device to the PnP database.

  • Returns device details specified by device id.

  • Deletes specified device from PnP database.

  • Updates device details specified by device id in PnP database.

  • Returns the device count based on filter criteria. This is useful for pagination.

  • Returns history for a specific device. Serial number is a required parameter.

Note

This module has a corresponding action plugin.

Requirements

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

  • dnacentersdk

Parameters

Parameter Choices/Defaults Comments
_id
string
Device's _id.
_state
string
Device State.
cm_state
string
Device Connection Manager State.
count
boolean
    Choices:
  • no
  • yes
If true gets the number of objects.
Required for state query.
deviceInfo
dictionary / required
Device's deviceInfo.
aaaCredentials
dictionary
It is the pnp device's aaaCredentials.
password
string
It is the pnp device's password.
username
string
It is the pnp device's username.
addedOn
integer
It is the pnp device's addedOn.
addnMacAddrs
list / elements=string
It is the pnp device's addnMacAddrs.
agentType
string
It is the pnp device's agentType.
authenticatedSudiSerialNo
string
It is the pnp device's authenticatedSudiSerialNo.
authStatus
string
It is the pnp device's authStatus.
capabilitiesSupported
list / elements=string
It is the pnp device's capabilitiesSupported.
cmState
string
It is the pnp device's cmState.
description
string
It is the pnp device's description.
deviceSudiSerialNos
list / elements=string
It is the pnp device's deviceSudiSerialNos.
deviceType
string
It is the pnp device's deviceType.
featuresSupported
list / elements=string
It is the pnp device's featuresSupported.
fileSystemList
list / elements=dictionary
It is the pnp device's fileSystemList.
freespace
integer
It is the pnp device's freespace.
name
string
It is the pnp device's name.
readable
boolean
    Choices:
  • no
  • yes
It is the pnp device's readable.
size
integer
It is the pnp device's size.
type
string
It is the pnp device's type.
writeable
boolean
    Choices:
  • no
  • yes
It is the pnp device's writeable.
firstContact
integer
It is the pnp device's firstContact.
hostname
string
It is the pnp device's hostname.
httpHeaders
list / elements=dictionary
It is the pnp device's httpHeaders.
key
string
It is the pnp device's key.
value
string
It is the pnp device's value.
imageFile
string
It is the pnp device's imageFile.
imageVersion
string
It is the pnp device's imageVersion.
ipInterfaces
list / elements=dictionary
It is the pnp device's ipInterfaces.
ipv4Address
dictionary
It is the pnp device's ipv4Address.
ipv6AddressList
list / elements=string
It is the pnp device's ipv6AddressList.
macAddress
string
It is the pnp device's macAddress.
name
string
It is the pnp device's name.
status
string
It is the pnp device's status.
lastContact
integer
It is the pnp device's lastContact.
lastSyncTime
integer
It is the pnp device's lastSyncTime.
lastUpdateOn
integer
It is the pnp device's lastUpdateOn.
location
dictionary
It is the pnp device's location.
address
string
It is the pnp device's address.
altitude
string
It is the pnp device's altitude.
latitude
string
It is the pnp device's latitude.
longitude
string
It is the pnp device's longitude.
siteId
string
It is the pnp device's siteId.
macAddress
string
It is the pnp device's macAddress.
mode
string
It is the pnp device's mode.
name
string
It is the pnp device's name.
neighborLinks
list / elements=dictionary
It is the pnp device's neighborLinks.
localInterfaceName
string
It is the pnp device's localInterfaceName.
localMacAddress
string
It is the pnp device's localMacAddress.
localShortInterfaceName
string
It is the pnp device's localShortInterfaceName.
remoteDeviceName
string
It is the pnp device's remoteDeviceName.
remoteInterfaceName
string
It is the pnp device's remoteInterfaceName.
remoteMacAddress
string
It is the pnp device's remoteMacAddress.
remotePlatform
string
It is the pnp device's remotePlatform.
remoteShortInterfaceName
string
It is the pnp device's remoteShortInterfaceName.
remoteVersion
string
It is the pnp device's remoteVersion.
onbState
string
It is the pnp device's onbState.
pid
string
It is the pnp device's pid.
pnpProfileList
list / elements=dictionary
It is the pnp device's pnpProfileList.
createdBy
string
It is the pnp device's createdBy.
discoveryCreated
boolean
    Choices:
  • no
  • yes
It is the pnp device's discoveryCreated.
primaryEndpoint
dictionary
It is the pnp device's primaryEndpoint.
certificate
string
It is the pnp device's certificate.
fqdn
string
It is the pnp device's fqdn.
ipv4Address
dictionary
It is the pnp device's ipv4Address.
ipv6Address
dictionary
It is the pnp device's ipv6Address.
port
integer
It is the pnp device's port.
protocol
string
It is the pnp device's protocol.
profileName
string
It is the pnp device's profileName.
secondaryEndpoint
dictionary
It is the pnp device's secondaryEndpoint.
certificate
string
It is the pnp device's certificate.
fqdn
string
It is the pnp device's fqdn.
ipv4Address
dictionary
It is the pnp device's ipv4Address.
ipv6Address
dictionary
It is the pnp device's ipv6Address.
port
integer
It is the pnp device's port.
protocol
string
It is the pnp device's protocol.
populateInventory
boolean
    Choices:
  • no
  • yes
It is the pnp device's populateInventory.
preWorkflowCliOuputs
list / elements=dictionary
It is the pnp device's preWorkflowCliOuputs.
cli
string
It is the pnp device's cli.
cliOutput
string
It is the pnp device's cliOutput.
projectId
string
It is the pnp device's projectId.
projectName
string
It is the pnp device's projectName.
reloadRequested
boolean
    Choices:
  • no
  • yes
It is the pnp device's reloadRequested.
serialNumber
string
It is the pnp device's serialNumber.
smartAccountId
string
It is the pnp device's smartAccountId.
source
string
It is the pnp device's source.
stack
boolean
    Choices:
  • no
  • yes
It is the pnp device's stack.
stackInfo
dictionary
It is the pnp device's stackInfo.
isFullRing
boolean
    Choices:
  • no
  • yes
It is the pnp device's isFullRing.
stackMemberList
list / elements=dictionary
It is the pnp device's stackMemberList.
hardwareVersion
string
It is the pnp device's hardwareVersion.
licenseLevel
string
It is the pnp device's licenseLevel.
licenseType
string
It is the pnp device's licenseType.
macAddress
string
It is the pnp device's macAddress.
pid
string
It is the pnp device's pid.
priority
integer
It is the pnp device's priority.
role
string
It is the pnp device's role.
serialNumber
string
It is the pnp device's serialNumber.
softwareVersion
string
It is the pnp device's softwareVersion.
stackNumber
integer
It is the pnp device's stackNumber.
state
string
It is the pnp device's state.
sudiSerialNumber
string
It is the pnp device's sudiSerialNumber.
stackRingProtocol
string
It is the pnp device's stackRingProtocol.
supportsStackWorkflows
boolean
    Choices:
  • no
  • yes
It is the pnp device's supportsStackWorkflows.
totalMemberCount
integer
It is the pnp device's totalMemberCount.
validLicenseLevels
list / elements=string
It is the pnp device's validLicenseLevels.
state
string
It is the pnp device's state.
sudiRequired
boolean
    Choices:
  • no
  • yes
It is the pnp device's sudiRequired.
tags
dictionary
It is the pnp device's tags.
userSudiSerialNos
list / elements=string
It is the pnp device's userSudiSerialNos.
virtualAccountId
string
It is the pnp device's virtualAccountId.
workflowId
string
It is the pnp device's workflowId.
workflowName
string
It is the pnp device's workflowName.
id
string / required
Id path parameter.
last_contact
boolean
    Choices:
  • no
  • yes
Device Has Contacted lastContact > 0.
limit
integer
Limits number of results.
name
string
Device Name.
offset
integer
Index of first result.
onb_state
string
Device Onboarding State.
pid
string
Device ProductId.
project_id
string
Device Project Id.
project_name
string
Device Project Name.
runSummaryList
list / elements=dictionary
Device's runSummaryList (list of objects).
details
string
It is the pnp device's details.
errorFlag
boolean
    Choices:
  • no
  • yes
It is the pnp device's errorFlag.
historyTaskInfo
dictionary
It is the pnp device's historyTaskInfo.
addnDetails
list / elements=dictionary
It is the pnp device's addnDetails.
key
string
It is the pnp device's key.
value
string
It is the pnp device's value.
name
string
It is the pnp device's name.
timeTaken
integer
It is the pnp device's timeTaken.
type
string
It is the pnp device's type.
workItemList
list / elements=dictionary
It is the pnp device's workItemList.
command
string
It is the pnp device's command.
endTime
integer
It is the pnp device's endTime.
outputStr
string
It is the pnp device's outputStr.
startTime
integer
It is the pnp device's startTime.
state
string
It is the pnp device's state.
timeTaken
integer
It is the pnp device's timeTaken.
timestamp
integer
It is the pnp device's timestamp.
serial_number
string
Device Serial Number.
Required for state query.
smart_account_id
string
Device Smart Account.
sort
string
Comma seperated list of fields to sort on.
sort_order
string
Sort Order Ascending (asc) or Descending (des).
source
string
Device Source.
systemResetWorkflow
dictionary
Device's systemResetWorkflow.
_id
string
It is the pnp device's _id.
addedOn
integer
It is the pnp device's addedOn.
addToInventory
boolean
    Choices:
  • no
  • yes
It is the pnp device's addToInventory.
configId
string
It is the pnp device's configId.
currTaskIdx
integer
It is the pnp device's currTaskIdx.
description
string
It is the pnp device's description.
endTime
integer
It is the pnp device's endTime.
execTime
integer
It is the pnp device's execTime.
imageId
string
It is the pnp device's imageId.
instanceType
string
It is the pnp device's instanceType.
lastupdateOn
integer
It is the pnp device's lastupdateOn.
name
string
It is the pnp device's name.
startTime
integer
It is the pnp device's startTime.
state
string
It is the pnp device's state.
tasks
list / elements=dictionary
It is the pnp device's tasks.
currWorkItemIdx
integer
It is the pnp device's currWorkItemIdx.
endTime
integer
It is the pnp device's endTime.
name
string
It is the pnp device's name.
startTime
integer
It is the pnp device's startTime.
state
string
It is the pnp device's state.
taskSeqNo
integer
It is the pnp device's taskSeqNo.
timeTaken
integer
It is the pnp device's timeTaken.
type
string
It is the pnp device's type.
workItemList
list / elements=dictionary
It is the pnp device's workItemList.
command
string
It is the pnp device's command.
endTime
integer
It is the pnp device's endTime.
outputStr
string
It is the pnp device's outputStr.
startTime
integer
It is the pnp device's startTime.
state
string
It is the pnp device's state.
timeTaken
integer
It is the pnp device's timeTaken.
tenantId
string
It is the pnp device's tenantId.
type
string
It is the pnp device's type.
useState
string
It is the pnp device's useState.
version
integer
It is the pnp device's version.
systemWorkflow
dictionary
Device's systemWorkflow.
_id
string
It is the pnp device's _id.
addedOn
integer
It is the pnp device's addedOn.
addToInventory
boolean
    Choices:
  • no
  • yes
It is the pnp device's addToInventory.
configId
string
It is the pnp device's configId.
currTaskIdx
integer
It is the pnp device's currTaskIdx.
description
string
It is the pnp device's description.
endTime
integer
It is the pnp device's endTime.
execTime
integer
It is the pnp device's execTime.
imageId
string
It is the pnp device's imageId.
instanceType
string
It is the pnp device's instanceType.
lastupdateOn
integer
It is the pnp device's lastupdateOn.
name
string
It is the pnp device's name.
startTime
integer
It is the pnp device's startTime.
state
string
It is the pnp device's state.
tasks
list / elements=dictionary
It is the pnp device's tasks.
currWorkItemIdx
integer
It is the pnp device's currWorkItemIdx.
endTime
integer
It is the pnp device's endTime.
name
string
It is the pnp device's name.
startTime
integer
It is the pnp device's startTime.
state
string
It is the pnp device's state.
taskSeqNo
integer
It is the pnp device's taskSeqNo.
timeTaken
integer
It is the pnp device's timeTaken.
type
string
It is the pnp device's type.
workItemList
list / elements=dictionary
It is the pnp device's workItemList.
command
string
It is the pnp device's command.
endTime
integer
It is the pnp device's endTime.
outputStr
string
It is the pnp device's outputStr.
startTime
integer
It is the pnp device's startTime.
state
string
It is the pnp device's state.
timeTaken
integer
It is the pnp device's timeTaken.
tenantId
string
It is the pnp device's tenantId.
type
string
It is the pnp device's type.
useState
string
It is the pnp device's useState.
version
integer
It is the pnp device's version.
tenantId
string
Device's tenantId.
version
integer
Device's version.
virtual_account_id
string
Device Virtual Account.
workflow
dictionary
Device's workflow.
_id
string
It is the pnp device's _id.
addedOn
integer
It is the pnp device's addedOn.
addToInventory
boolean
    Choices:
  • no
  • yes
It is the pnp device's addToInventory.
configId
string
It is the pnp device's configId.
currTaskIdx
integer
It is the pnp device's currTaskIdx.
description
string
It is the pnp device's description.
endTime
integer
It is the pnp device's endTime.
execTime
integer
It is the pnp device's execTime.
imageId
string
It is the pnp device's imageId.
instanceType
string
It is the pnp device's instanceType.
lastupdateOn
integer
It is the pnp device's lastupdateOn.
name
string
It is the pnp device's name.
startTime
integer
It is the pnp device's startTime.
state
string
It is the pnp device's state.
tasks
list / elements=dictionary
It is the pnp device's tasks.
currWorkItemIdx
integer
It is the pnp device's currWorkItemIdx.
endTime
integer
It is the pnp device's endTime.
name
string
It is the pnp device's name.
startTime
integer
It is the pnp device's startTime.
state
string
It is the pnp device's state.
taskSeqNo
integer
It is the pnp device's taskSeqNo.
timeTaken
integer
It is the pnp device's timeTaken.
type
string
It is the pnp device's type.
workItemList
list / elements=dictionary
It is the pnp device's workItemList.
command
string
It is the pnp device's command.
endTime
integer
It is the pnp device's endTime.
outputStr
string
It is the pnp device's outputStr.
startTime
integer
It is the pnp device's startTime.
state
string
It is the pnp device's state.
timeTaken
integer
It is the pnp device's timeTaken.
tenantId
string
It is the pnp device's tenantId.
type
string
It is the pnp device's type.
useState
string
It is the pnp device's useState.
version
integer
It is the pnp device's version.
workflow_id
string
Device Workflow Id.
workflow_name
string
Device Workflow Name.
workflowParameters
dictionary
Device's workflowParameters.
configList
list / elements=dictionary
It is the pnp device's configList.
configId
string
It is the pnp device's configId.
configParameters
list / elements=dictionary
It is the pnp device's configParameters.
key
string
It is the pnp device's key.
value
string
It is the pnp device's value.
licenseLevel
string
It is the pnp device's licenseLevel.
licenseType
string
It is the pnp device's licenseType.
topOfStackSerialNumber
string
It is the pnp device's topOfStackSerialNumber.

See Also

See also

cisco.dnac.plugins.module_utils.definitions.pnp_device

The official documentation on the cisco.dnac.plugins.module_utils.definitions.pnp_device module.

PnpDevice reference

Complete reference of the PnpDevice object model.

PnpDevice reference

SDK reference.

Examples

- name: get_device_list
  cisco.dnac.pnp_device:
    state: query  # required
    cm_state: SomeValue  # string
    last_contact: True  # boolean
    limit: 1  #  integer
    name: SomeValue  # string
    offset: 1  #  integer
    onb_state: SomeValue  # string
    pid: SomeValue  # string
    project_id: SomeValue  # string
    project_name: SomeValue  # string
    serial_number: SomeValue  # string
    smart_account_id: SomeValue  # string
    sort: SomeValue  # string
    sort_order: SomeValue  # string
    source: SomeValue  # string
    _state: SomeValue  # string
    virtual_account_id: SomeValue  # string
    workflow_id: SomeValue  # string
    workflow_name: SomeValue  # string
  register: nm_get_device_list

- name: add_device
  cisco.dnac.pnp_device:
    state: create  # required
    deviceInfo:  # required
      aaaCredentials:
        password: SomeValue  # string
        username: SomeValue  # string
      addedOn: 1  #  integer
      addnMacAddrs:
      - SomeValue  # string
      agentType: SomeValue  # string
      authStatus: SomeValue  # string
      authenticatedSudiSerialNo: SomeValue  # string
      capabilitiesSupported:
      - SomeValue  # string
      cmState: SomeValue  # string
      description: SomeValue  # string
      deviceSudiSerialNos:
      - SomeValue  # string
      deviceType: SomeValue  # string
      featuresSupported:
      - SomeValue  # string
      fileSystemList:
      - freespace: 1  #  integer
        name: SomeValue  # string
        readable: True  # boolean
        size: 1  #  integer
        type: SomeValue  # string
        writeable: True  # boolean
      firstContact: 1  #  integer
      hostname: SomeValue  # string
      httpHeaders:
      - key: SomeValue  # string
        value: SomeValue  # string
      imageFile: SomeValue  # string
      imageVersion: SomeValue  # string
      ipInterfaces:
      - ipv4Address: None
        ipv6AddressList:
        macAddress: SomeValue  # string
        name: SomeValue  # string
        status: SomeValue  # string
      lastContact: 1  #  integer
      lastSyncTime: 1  #  integer
      lastUpdateOn: 1  #  integer
      location:
        address: SomeValue  # string
        altitude: SomeValue  # string
        latitude: SomeValue  # string
        longitude: SomeValue  # string
        siteId: SomeValue  # string
      macAddress: SomeValue  # string
      mode: SomeValue  # string
      name: SomeValue  # string
      neighborLinks:
      - localInterfaceName: SomeValue  # string
        localMacAddress: SomeValue  # string
        localShortInterfaceName: SomeValue  # string
        remoteDeviceName: SomeValue  # string
        remoteInterfaceName: SomeValue  # string
        remoteMacAddress: SomeValue  # string
        remotePlatform: SomeValue  # string
        remoteShortInterfaceName: SomeValue  # string
        remoteVersion: SomeValue  # string
      onbState: SomeValue  # string
      pid: SomeValue  # string
      pnpProfileList:
      - createdBy: SomeValue  # string
        discoveryCreated: True  # boolean
        primaryEndpoint:
          certificate: SomeValue  # string
          fqdn: SomeValue  # string
          ipv4Address: None
          ipv6Address: None
          port: 1  #  integer
          protocol: SomeValue  # string
        profileName: SomeValue  # string
        secondaryEndpoint:
          certificate: SomeValue  # string
          fqdn: SomeValue  # string
          ipv4Address: None
          ipv6Address: None
          port: 1  #  integer
          protocol: SomeValue  # string
      populateInventory: True  # boolean
      preWorkflowCliOuputs:
      - cli: SomeValue  # string
        cliOutput: SomeValue  # string
      projectId: SomeValue  # string
      projectName: SomeValue  # string
      reloadRequested: True  # boolean
      serialNumber: SomeValue  # string
      smartAccountId: SomeValue  # string
      source: SomeValue  # string
      stack: True  # boolean
      stackInfo:
        isFullRing: True  # boolean
        stackMemberList:
        - hardwareVersion: SomeValue  # string
          licenseLevel: SomeValue  # string
          licenseType: SomeValue  # string
          macAddress: SomeValue  # string
          pid: SomeValue  # string
          priority: 1  #  integer
          role: SomeValue  # string
          serialNumber: SomeValue  # string
          softwareVersion: SomeValue  # string
          stackNumber: 1  #  integer
          state: SomeValue  # string
          sudiSerialNumber: SomeValue  # string
        stackRingProtocol: SomeValue  # string
        supportsStackWorkflows: True  # boolean
        totalMemberCount: 1  #  integer
        validLicenseLevels:
        - SomeValue  # string
      state: SomeValue  # string
      sudiRequired: True  # boolean
      tags: None
      userSudiSerialNos:
      - SomeValue  # string
      virtualAccountId: SomeValue  # string
      workflowId: SomeValue  # string
      workflowName: SomeValue  # string
    _id: SomeValue  # string
    runSummaryList:
    - details: SomeValue  # string
      errorFlag: True  # boolean
      historyTaskInfo:
        addnDetails:
        - key: SomeValue  # string
          value: SomeValue  # string
        name: SomeValue  # string
        timeTaken: 1  #  integer
        type: SomeValue  # string
        workItemList:
        - command: SomeValue  # string
          endTime: 1  #  integer
          outputStr: SomeValue  # string
          startTime: 1  #  integer
          state: SomeValue  # string
          timeTaken: 1  #  integer
      timestamp: 1  #  integer
    systemResetWorkflow:
      _id: SomeValue  # string
      addToInventory: True  # boolean
      addedOn: 1  #  integer
      configId: SomeValue  # string
      currTaskIdx: 1  #  integer
      description: SomeValue  # string
      endTime: 1  #  integer
      execTime: 1  #  integer
      imageId: SomeValue  # string
      instanceType: SomeValue  # string
      lastupdateOn: 1  #  integer
      name: SomeValue  # string
      startTime: 1  #  integer
      state: SomeValue  # string
      tasks:
      - currWorkItemIdx: 1  #  integer
        endTime: 1  #  integer
        name: SomeValue  # string
        startTime: 1  #  integer
        state: SomeValue  # string
        taskSeqNo: 1  #  integer
        timeTaken: 1  #  integer
        type: SomeValue  # string
        workItemList:
        - command: SomeValue  # string
          endTime: 1  #  integer
          outputStr: SomeValue  # string
          startTime: 1  #  integer
          state: SomeValue  # string
          timeTaken: 1  #  integer
      tenantId: SomeValue  # string
      type: SomeValue  # string
      useState: SomeValue  # string
      version: 1  #  integer
    systemWorkflow:
      _id: SomeValue  # string
      addToInventory: True  # boolean
      addedOn: 1  #  integer
      configId: SomeValue  # string
      currTaskIdx: 1  #  integer
      description: SomeValue  # string
      endTime: 1  #  integer
      execTime: 1  #  integer
      imageId: SomeValue  # string
      instanceType: SomeValue  # string
      lastupdateOn: 1  #  integer
      name: SomeValue  # string
      startTime: 1  #  integer
      state: SomeValue  # string
      tasks:
      - currWorkItemIdx: 1  #  integer
        endTime: 1  #  integer
        name: SomeValue  # string
        startTime: 1  #  integer
        state: SomeValue  # string
        taskSeqNo: 1  #  integer
        timeTaken: 1  #  integer
        type: SomeValue  # string
        workItemList:
        - command: SomeValue  # string
          endTime: 1  #  integer
          outputStr: SomeValue  # string
          startTime: 1  #  integer
          state: SomeValue  # string
          timeTaken: 1  #  integer
      tenantId: SomeValue  # string
      type: SomeValue  # string
      useState: SomeValue  # string
      version: 1  #  integer
    tenantId: SomeValue  # string
    version: 1  #  integer
    workflow:
      _id: SomeValue  # string
      addToInventory: True  # boolean
      addedOn: 1  #  integer
      configId: SomeValue  # string
      currTaskIdx: 1  #  integer
      description: SomeValue  # string
      endTime: 1  #  integer
      execTime: 1  #  integer
      imageId: SomeValue  # string
      instanceType: SomeValue  # string
      lastupdateOn: 1  #  integer
      name: SomeValue  # string
      startTime: 1  #  integer
      state: SomeValue  # string
      tasks:
      - currWorkItemIdx: 1  #  integer
        endTime: 1  #  integer
        name: SomeValue  # string
        startTime: 1  #  integer
        state: SomeValue  # string
        taskSeqNo: 1  #  integer
        timeTaken: 1  #  integer
        type: SomeValue  # string
        workItemList:
        - command: SomeValue  # string
          endTime: 1  #  integer
          outputStr: SomeValue  # string
          startTime: 1  #  integer
          state: SomeValue  # string
          timeTaken: 1  #  integer
      tenantId: SomeValue  # string
      type: SomeValue  # string
      useState: SomeValue  # string
      version: 1  #  integer
    workflowParameters:
      configList:
      - configId: SomeValue  # string
        configParameters:
        - key: SomeValue  # string
          value: SomeValue  # string
      licenseLevel: SomeValue  # string
      licenseType: SomeValue  # string
      topOfStackSerialNumber: SomeValue  # string

- name: get_device_by_id
  cisco.dnac.pnp_device:
    state: query  # required
    id: SomeValue  # string, required
  register: nm_get_device_by_id

- name: delete_device_by_id_from_pnp
  cisco.dnac.pnp_device:
    state: delete  # required
    id: SomeValue  # string, required

- name: update_device
  cisco.dnac.pnp_device:
    state: update  # required
    id: SomeValue  # string, required
    deviceInfo:  # required
      aaaCredentials:
        password: SomeValue  # string
        username: SomeValue  # string
      addedOn: 1  #  integer
      addnMacAddrs:
      - SomeValue  # string
      agentType: SomeValue  # string
      authStatus: SomeValue  # string
      authenticatedSudiSerialNo: SomeValue  # string
      capabilitiesSupported:
      - SomeValue  # string
      cmState: SomeValue  # string
      description: SomeValue  # string
      deviceSudiSerialNos:
      - SomeValue  # string
      deviceType: SomeValue  # string
      featuresSupported:
      - SomeValue  # string
      fileSystemList:
      - freespace: 1  #  integer
        name: SomeValue  # string
        readable: True  # boolean
        size: 1  #  integer
        type: SomeValue  # string
        writeable: True  # boolean
      firstContact: 1  #  integer
      hostname: SomeValue  # string
      httpHeaders:
      - key: SomeValue  # string
        value: SomeValue  # string
      imageFile: SomeValue  # string
      imageVersion: SomeValue  # string
      ipInterfaces:
      - ipv4Address: None
        ipv6AddressList:
        macAddress: SomeValue  # string
        name: SomeValue  # string
        status: SomeValue  # string
      lastContact: 1  #  integer
      lastSyncTime: 1  #  integer
      lastUpdateOn: 1  #  integer
      location:
        address: SomeValue  # string
        altitude: SomeValue  # string
        latitude: SomeValue  # string
        longitude: SomeValue  # string
        siteId: SomeValue  # string
      macAddress: SomeValue  # string
      mode: SomeValue  # string
      name: SomeValue  # string
      neighborLinks:
      - localInterfaceName: SomeValue  # string
        localMacAddress: SomeValue  # string
        localShortInterfaceName: SomeValue  # string
        remoteDeviceName: SomeValue  # string
        remoteInterfaceName: SomeValue  # string
        remoteMacAddress: SomeValue  # string
        remotePlatform: SomeValue  # string
        remoteShortInterfaceName: SomeValue  # string
        remoteVersion: SomeValue  # string
      onbState: SomeValue  # string
      pid: SomeValue  # string
      pnpProfileList:
      - createdBy: SomeValue  # string
        discoveryCreated: True  # boolean
        primaryEndpoint:
          certificate: SomeValue  # string
          fqdn: SomeValue  # string
          ipv4Address: None
          ipv6Address: None
          port: 1  #  integer
          protocol: SomeValue  # string
        profileName: SomeValue  # string
        secondaryEndpoint:
          certificate: SomeValue  # string
          fqdn: SomeValue  # string
          ipv4Address: None
          ipv6Address: None
          port: 1  #  integer
          protocol: SomeValue  # string
      populateInventory: True  # boolean
      preWorkflowCliOuputs:
      - cli: SomeValue  # string
        cliOutput: SomeValue  # string
      projectId: SomeValue  # string
      projectName: SomeValue  # string
      reloadRequested: True  # boolean
      serialNumber: SomeValue  # string
      smartAccountId: SomeValue  # string
      source: SomeValue  # string
      stack: True  # boolean
      stackInfo:
        isFullRing: True  # boolean
        stackMemberList:
        - hardwareVersion: SomeValue  # string
          licenseLevel: SomeValue  # string
          licenseType: SomeValue  # string
          macAddress: SomeValue  # string
          pid: SomeValue  # string
          priority: 1  #  integer
          role: SomeValue  # string
          serialNumber: SomeValue  # string
          softwareVersion: SomeValue  # string
          stackNumber: 1  #  integer
          state: SomeValue  # string
          sudiSerialNumber: SomeValue  # string
        stackRingProtocol: SomeValue  # string
        supportsStackWorkflows: True  # boolean
        totalMemberCount: 1  #  integer
        validLicenseLevels:
        - SomeValue  # string
      state: SomeValue  # string
      sudiRequired: True  # boolean
      tags: None
      userSudiSerialNos:
      - SomeValue  # string
      virtualAccountId: SomeValue  # string
      workflowId: SomeValue  # string
      workflowName: SomeValue  # string
    _id: SomeValue  # string
    runSummaryList:
    - details: SomeValue  # string
      errorFlag: True  # boolean
      historyTaskInfo:
        addnDetails:
        - key: SomeValue  # string
          value: SomeValue  # string
        name: SomeValue  # string
        timeTaken: 1  #  integer
        type: SomeValue  # string
        workItemList:
        - command: SomeValue  # string
          endTime: 1  #  integer
          outputStr: SomeValue  # string
          startTime: 1  #  integer
          state: SomeValue  # string
          timeTaken: 1  #  integer
      timestamp: 1  #  integer
    systemResetWorkflow:
      _id: SomeValue  # string
      addToInventory: True  # boolean
      addedOn: 1  #  integer
      configId: SomeValue  # string
      currTaskIdx: 1  #  integer
      description: SomeValue  # string
      endTime: 1  #  integer
      execTime: 1  #  integer
      imageId: SomeValue  # string
      instanceType: SomeValue  # string
      lastupdateOn: 1  #  integer
      name: SomeValue  # string
      startTime: 1  #  integer
      state: SomeValue  # string
      tasks:
      - currWorkItemIdx: 1  #  integer
        endTime: 1  #  integer
        name: SomeValue  # string
        startTime: 1  #  integer
        state: SomeValue  # string
        taskSeqNo: 1  #  integer
        timeTaken: 1  #  integer
        type: SomeValue  # string
        workItemList:
        - command: SomeValue  # string
          endTime: 1  #  integer
          outputStr: SomeValue  # string
          startTime: 1  #  integer
          state: SomeValue  # string
          timeTaken: 1  #  integer
      tenantId: SomeValue  # string
      type: SomeValue  # string
      useState: SomeValue  # string
      version: 1  #  integer
    systemWorkflow:
      _id: SomeValue  # string
      addToInventory: True  # boolean
      addedOn: 1  #  integer
      configId: SomeValue  # string
      currTaskIdx: 1  #  integer
      description: SomeValue  # string
      endTime: 1  #  integer
      execTime: 1  #  integer
      imageId: SomeValue  # string
      instanceType: SomeValue  # string
      lastupdateOn: 1  #  integer
      name: SomeValue  # string
      startTime: 1  #  integer
      state: SomeValue  # string
      tasks:
      - currWorkItemIdx: 1  #  integer
        endTime: 1  #  integer
        name: SomeValue  # string
        startTime: 1  #  integer
        state: SomeValue  # string
        taskSeqNo: 1  #  integer
        timeTaken: 1  #  integer
        type: SomeValue  # string
        workItemList:
        - command: SomeValue  # string
          endTime: 1  #  integer
          outputStr: SomeValue  # string
          startTime: 1  #  integer
          state: SomeValue  # string
          timeTaken: 1  #  integer
      tenantId: SomeValue  # string
      type: SomeValue  # string
      useState: SomeValue  # string
      version: 1  #  integer
    tenantId: SomeValue  # string
    version: 1  #  integer
    workflow:
      _id: SomeValue  # string
      addToInventory: True  # boolean
      addedOn: 1  #  integer
      configId: SomeValue  # string
      currTaskIdx: 1  #  integer
      description: SomeValue  # string
      endTime: 1  #  integer
      execTime: 1  #  integer
      imageId: SomeValue  # string
      instanceType: SomeValue  # string
      lastupdateOn: 1  #  integer
      name: SomeValue  # string
      startTime: 1  #  integer
      state: SomeValue  # string
      tasks:
      - currWorkItemIdx: 1  #  integer
        endTime: 1  #  integer
        name: SomeValue  # string
        startTime: 1  #  integer
        state: SomeValue  # string
        taskSeqNo: 1  #  integer
        timeTaken: 1  #  integer
        type: SomeValue  # string
        workItemList:
        - command: SomeValue  # string
          endTime: 1  #  integer
          outputStr: SomeValue  # string
          startTime: 1  #  integer
          state: SomeValue  # string
          timeTaken: 1  #  integer
      tenantId: SomeValue  # string
      type: SomeValue  # string
      useState: SomeValue  # string
      version: 1  #  integer
    workflowParameters:
      configList:
      - configId: SomeValue  # string
        configParameters:
        - key: SomeValue  # string
          value: SomeValue  # string
      licenseLevel: SomeValue  # string
      licenseType: SomeValue  # string
      topOfStackSerialNumber: SomeValue  # string

- name: get_device_count
  cisco.dnac.pnp_device:
    state: query  # required
    count: True  # boolean, required
    cm_state: SomeValue  # string
    last_contact: True  # boolean
    name: SomeValue  # string
    onb_state: SomeValue  # string
    pid: SomeValue  # string
    project_id: SomeValue  # string
    project_name: SomeValue  # string
    serial_number: SomeValue  # string
    smart_account_id: SomeValue  # string
    source: SomeValue  # string
    _state: SomeValue  # string
    virtual_account_id: SomeValue  # string
    workflow_id: SomeValue  # string
    workflow_name: SomeValue  # string
  register: nm_get_device_count

- name: get_device_history
  cisco.dnac.pnp_device:
    state: query  # required
    serial_number: SomeValue  # string, required
    sort: SomeValue  # string
    sort_order: SomeValue  # string
  register: nm_get_device_history

Return Values

Common return values are documented here, the following are the fields unique to this module:

Key Returned Description
dnac_response
dictionary
always
A dictionary with the response returned by the DNA Center Python SDK

Sample:
{'response': 29, 'version': '1.0'}
missing_params
list / elements=string
when the function request schema is not satisfied
Provided arguments do not comply with the schema of the DNA Center Python SDK function

sdk_function
string
always
The DNA Center SDK function used to execute the task

Sample:
device_onboarding_pnp.add_device


Authors

  • Rafael Campos (@racampos)