Cisco Prime Infrastructure API
Prime Infrastructure API Documentation

GET_Sites

# GET Sites

- Jump To

### Resource Information

Rate Limiting? | Yes
Sorting? | Yes
Paging? | Yes
Filtering? | Yes
Response Formats | xml json
HTTP Methods | GET

Deprecated

Do not use this resource. Replaced by /op/groups/sites.

This provides information about the site groups and its hierarchy of campus and buildings. Note that internally to NCS, Sites are type of "Group", and thus all children will be of the generic type "subGroup".

## Resource URL

/webacs/api/v1/data/Sites

Since : 1.2

## Response Parameters

Type | Attribute Name | Description
--- | --- | ---
int | apCount | The number of Access Points within the site.
int | clearedAlarms | Number of cleared alarms registered against devices within this site.
int | clientCount | Number of clients connected to the site.
int | criticalAlarms | Number of critical alarms registered against devices within this site.
int | deviceCount | Total number of devices (non-APs).
long | groupId | The internal id of the site group.
String | groupName | The name of the site group.
int | informationAlarms | Number of information alarms registered against devices within this site.
Float | latitude | Latitude of site.
String | locationAddress | Address of site.
Float | longitude | Longitude of site.
int | majorAlarms | Number of major alarms registered against devices within this site.
int | minorAlarms | Number of minor alarms registered against devices within this site.
String | name | The hierarchical name of the site.
String | siteType | The type of site: 1 Campus, 2 Building, 4 Floor Area, 5 Outdoor Area.
int | warningAlarms | Number of warning alarms registered against devices within this site.

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://192.168.116.207/webacs/api/v1/data/Sites/42

    <?xml version="1.0" encoding="UTF-8" standalone="yes"?>
    <queryResponse rootUrl="/webacs/data" requestUrl="https://192.168.116.207/webacs/api/v1/data/Sites/42" responseType="getEntity">
        <entity url="/webacs/data/className/15" type="className" dtoType="sitesDTO_$$_javassist_5198">
            <sitesDTO id="15" displayName="String value">
                <apCount>1</apCount>
                <clearedAlarms>1</clearedAlarms>
                <clientCount>1</clientCount>
                <criticalAlarms>1</criticalAlarms>
                <deviceCount>1</deviceCount>
                <groupId>2</groupId>
                <groupName>String value</groupName>
                <informationAlarms>1</informationAlarms>
                <latitude>15.0</latitude>
                <locationAddress>String value</locationAddress>
                <longitude>15.0</longitude>
                <majorAlarms>1</majorAlarms>
                <minorAlarms>1</minorAlarms>
                <name>String value</name>
                <siteType>String value</siteType>
                <warningAlarms>1</warningAlarms>
            </sitesDTO>
        </entity>
    </queryResponse>

## Sample JSON Payload

https://192.168.116.207/webacs/api/v1/data/Sites/42.json

    {
      "queryResponse" : {
        "@rootUrl" : "\/webacs\/data",
        "@requestUrl" : "https : \/\/192.168.116.207\/webacs\/api\/v1\/data\/Sites\/42",
        "@responseType" : "getEntity",
        "entity" : {
          "@url" : "\/webacs\/data\/className\/15",
          "@type" : "className",
          "@dtoType" : "sitesDTO_$$_javassist_5198",
          "sitesDTO" : {
            "@id" : "15",
            "@displayName" : "String value",
            "apCount" : 1,
            "clearedAlarms" : 1,
            "clientCount" : 1,
            "criticalAlarms" : 1,
            "deviceCount" : 1,
            "groupId" : 2,
            "groupName" : "String value",
            "informationAlarms" : 1,
            "latitude" : 15,
            "locationAddress" : "String value",
            "longitude" : 15,
            "majorAlarms" : 1,
            "minorAlarms" : 1,
            "name" : "String value",
            "siteType" : "String value",
            "warningAlarms" : 1
          }
        }
      }
    }