Add or update an dndpoint - JSON/XML
Add or update a host with a JSON object {Endpoint}.
https://<servername>:8443/api/host
Return value |
Type |
Description |
||
---|---|---|---|---|
id |
Integer |
ID that uniquely identifies the endpoint. |
||
createTime |
Time |
Date and time that this endpoint was created. |
||
atRisk |
Boolean |
If true, endpoint has been marked at risk. |
||
connected |
Boolean |
True = Endpoint is connected. |
||
enabled |
Boolean |
If true, endpoint is enabled |
||
deviceType |
String |
Type of the endpoint, such as, an IP Phone. |
||
ipAddress |
String |
List of IP Addresses assigned to the interfaces on the endpoint separated by commas. |
||
macAddress |
String |
List of MAC addresses on the endpoint separated by commas.
|
||
location |
String |
Name of the connection location, such as a port name. |
||
hardwareType |
String |
Type of hardware, such as, a PC . |
||
hostName |
String |
Host name of the endpoint. |
||
loggedOnUser |
String |
User ID of the logged on user. |
||
owner |
String |
User ID of the user to whom this endpoint is registered. |
||
notes |
String |
Notes entered on the host record. |
||
os |
String |
Operating System on the endpoint. |
||
serialNumber |
String |
Serial Number of the endpoint. |
Example request
curl -k -u '<username>:<password>' -H "accept: application/json" -H "content-type: application/json" -X POST -d '{"id":3691,"role":"MyNewRole","deviceType":"Registered Host"}' https://<servername>:8443/api/host
curl -k -u '<username>:<password>' -H "accept: application/xml" -H "content-type: application/xml" -X POST -d '<endpoint><id>3691</id><role>MyNewRole</role></endpoint>' https://<servername>:8443/api/host
Example XML format
<endpointResult>
<status>success</status>
<errorMessage></errorMessage>
<endpoints>
<endpoint>
<atRisk>false</atRisk>
<connected>false</connected>
<createTime>2017-01-25T10:22:57.121-05:00</createTime>
<deviceType>Registered Host</deviceType>
<enabled>true</enabled>
<id>3691</id>
<macAddress>00:30:48:92:86:32</macAddress>
<role>MyNewRole</role>
</endpoint>
</endpoints>
</endpointResult>