Create a site

Create a site. The site initially contains no devices.

Request

Security

Table 1. Roles capable of executing the Create Site API method
Any Super User System Admin Security Admin Operator
  superUser systemAdmin    

HTTP method

POST /manager/api/{apiResponseType}/1.0/createSite.adm HTTP/1.1 Host:{manager.dsnet} name={siteName}

Curl method

curl -u {admin}:{password} -k ”https://{manager.dsnet}/manager/api/{apiResponseType}/1.0/createSite.adm“ -d ”name={siteName}“

Parameters

Table 2. Request parameters for Create Site (createSite) API method
Parameter Type Usage Default Description
name String Required  

Unique name of new site.

description String Optional  

Description of new site.

abbreviation String Optional  

Abbreviation of site; must be <12 characters.

company String Optional  

Company field of site.

address String Optional  

Address of site.

phone String Optional  

Telephone number that is related to site.

latitude String Longitude  

Latitude of this site's location.

Longitude String Latitude  

Longitude of the site's location.

ldapServiceName String    

The site-specific code that maps to the site's name in Active Directory.

country String Optional   The 2-character ISO-3166 country code where this site is located

Response

Success or failure status. ID of new site that is returned on success.

JSON response example

{
  ”responseStatus“:”ok“,
  ”responseHeader“:{
    ”status“:”ok“,
    ”now“:{milliseconds from the UNIX epoch},
    ”requestId“:”U2qeIsCoDicAACV9Ad8AAACH“
  },
  ”responseData“:{
    ”id“:9
  }

}

Parameters

Table 3. Response parameters for Create Site (createSite) API method
Parameter Type Description
id Long

ID of new site.