Cisco Prime Infrastructure API
Prime Infrastructure API Documentation

GET Devices

Represents the device view with information about the managed network elements. It provides device information such as device name, device type, ip address, software type, version, and also provides the reachability and management status.

Since Product Version: 1.2

Resource Information

Rate Limiting?

Yes

Sorting?

Yes

Paging?

Yes

Filtering?

Yes

Group Filtering?

Yes

Aggregation?

Yes

Response Formats

xml

json

User Group

NBI Read

HTTP Methods

GET

Resource URL

/webacs/api/v2/data/Devices

To filter entities based on device groups, use Group Based Filtering as documented on the Filtering page on the Home page. Example: ?.group=myrouters

Unmodified

This resource has not been modified since the previous API version.

Response Parameters

Attribute Description

adminStatus String

Represents the current admin status of the device.

clearedAlarms int

The number of cleared alarms against this device.

collectionDetail String

A detailed status of inventory collection

collectionTime Date

Time of inventory collection

creationTime Date

The timestamp when the instance of the device was created.

criticalAlarms int

The number of critical alarms against this device.

deviceId Long

An internal id to recognize the device, which is the id of the associated management network element associated with this device.

deviceName String

The name of the device.

deviceType String

The type of the device.

informationAlarms int

The number of information alarms against this device.

ipAddress String

The ip address of the device. This is the preferred management access address for the device. This is typically an address at which SNMP, telnet, and ssh agents are available.

location String

The system location of the device.

majorAlarms int

The number of major alarms against this device.

managementStatus LifecycleStateEnum

Represents the current management state of the network element: managed, unmanaged, under maintenance, and so on. This state is modified by events in the network and network management system, and also by user request.

  • UNKNOWN
  • ADDED_ININITIALSTATE
  • MANAGED_BUT_NEVERSYNCHRONIZED
  • MANAGED_AND_SYNCHRONIZED
  • MANAGED_BUT_OUTOFSYNC
  • MANAGED_BUT_LOSSOFCONNECTIVITY
  • PREPROVISIONED
  • UNMANAGED
  • INSERVICE_MAINTENANCE
  • MANAGED_BUT_INCOMPLETE
  • MANAGED_BUT_AGENTSHUTTINGDOWN
  • MANAGED_PREPARINGFORMAINTENANCE
  • MANAGED_BUT_DUPLICATE
  • MANAGED_BUT_CONFLICTINGCREDENTIALS
  • MANAGED_BUT_SYNCHRONIZING
  • UNMANAGED_UNLICENSED
  • IN_SERVICE
  • OUT_OF_SERVICE
  • OUT_OF_SERVICE_FOR_MAINTENANCE
  • SYNC_DISABLED
  • QUARANTINED

manufacturerPartNr String[]

The manufacturer part numbers that make up the device chassis.

minorAlarms int

The number of minor alarms against this device.

productFamily String

The product family of this device.

reachability ReachabilityStateEnum

Indicates management availability or reachability of the managed network element. It can indicate the availability or reachability of the management agent serving as a proxy for the network element.

  • UNKNOWN
  • REACHABLE
  • UNREACHABLE
  • AGENT_UNREACHABLE
  • AGENT_UNLOADED
  • PING_REACHABLE
  • PING_UNREACHABLE

softwareType String

A string that identifies the specific type of software that is installed. For example, Cisco IOS or Linux.

softwareVersion String

The specific version of the software (see attribute softwareType) that is installed. The value is formatted as a text field.

warningAlarms int

The number of warning alarms against this device.

Sample Payloads

Sample payloads are for information only. They are automatically generated and the values included may not be representative of actual valid data values.

Sample XML Payload

https://localhost/webacs/api/v2/data/Devices/15

<?xml version="1.0" ?>
<queryResponse type="Devices" responseType="getEntity" requestUrl="https://localhost/webacs/api/v2/data/Devices/15" rootUrl="https://localhost/webacs/api/v2/data">
  <entity dtoType="devicesDTO" type="Devices" url="https://localhost/webacs/api/v2/data/Devices/15">
    <devicesDTO displayName="String value" id="15" uuid="String value">
      <collectionDetail>String value</collectionDetail>
      <collectionTime>1986-07-24T00:00:00Z</collectionTime>
      <creationTime>1986-07-24T00:00:00Z</creationTime>
      <deviceId>15</deviceId>
      <deviceName>String value</deviceName>
      <deviceType>String value</deviceType>
      <ipAddress>String value</ipAddress>
      <location>String value</location>
      <managementStatus>UNKNOWN</managementStatus>
      <productFamily>String value</productFamily>
      <reachability>UNKNOWN</reachability>
      <softwareType>String value</softwareType>
      <softwareVersion>String value</softwareVersion>
      <adminStatus>String value</adminStatus>
      <clearedAlarms>1</clearedAlarms>
      <criticalAlarms>1</criticalAlarms>
      <informationAlarms>1</informationAlarms>
      <majorAlarms>1</majorAlarms>
      <manufacturerPartNrs>
        <manufacturerPartNr>String value</manufacturerPartNr>
      </manufacturerPartNrs>
      <minorAlarms>1</minorAlarms>
      <warningAlarms>1</warningAlarms>
    </devicesDTO>
  </entity>
</queryResponse>

Sample JSON Payload

https://localhost/webacs/api/v2/data/Devices/15.json

{
  "queryResponse" : {
    "@type" : "Devices",
    "@requestUrl" : "https://localhost/webacs/api/v2/data/Devices/15",
    "@responseType" : "getEntity",
    "@rootUrl" : "https://localhost/webacs/api/v2/data",
    "entity" : [ {
      "@dtoType" : "devicesDTO",
      "@type" : "Devices",
      "@url" : "https://localhost/webacs/api/v2/data/Devices/15",
      "devicesDTO" : {
        "@displayName" : "String value",
        "@id" : 15,
        "@uuid" : "String value",
        "adminStatus" : "String value",
        "clearedAlarms" : 1,
        "collectionDetail" : "String value",
        "collectionTime" : 522547200000,
        "creationTime" : 522547200000,
        "criticalAlarms" : 1,
        "deviceId" : 15,
        "deviceName" : "String value",
        "deviceType" : "String value",
        "informationAlarms" : 1,
        "ipAddress" : "String value",
        "location" : "String value",
        "majorAlarms" : 1,
        "managementStatus" : "UNKNOWN",
        "manufacturerPartNrs" : {
          "manufacturerPartNr" : [ "String value" ]
        },
        "minorAlarms" : 1,
        "productFamily" : "String value",
        "reachability" : "UNKNOWN",
        "softwareType" : "String value",
        "softwareVersion" : "String value",
        "warningAlarms" : 1
      }
    } ]
  }
}