Help us improve your experience.

Let us know what you think.

Do you have time for a two-minute survey?

 

Associate a Device Group with Devices

 

Use this API to add devices to a device group.

URI

https://[host]/api/juniper/servicenow/device-group-management/deviceGroup /{id}/associateDevices (HTTP method = POST)

URI Parameters

Parameter

Type

Required

Description

id

Integer

Yes

ID of the device group to which the devices should be associated

Consumes

  • application/vnd.juniper.servicenow.device-group-management. ssociatedevices+xml;version=1; charset=UTF-8

  • application/vnd.juniper.servicenow.device-group-management. ssociatedevices+json;version=1 ;charset=UTF-8

Request Elements

Element

Type

Description

devices

device

Collection of devices

device

device

A device to be associated with the device group

href

String

Link to the device

key

Integer

ID of the device

Produces

  • application/vnd.juniper.servicenow.device-group-management.servicenowmsg+json;version=1

  • application/vnd.juniper.servicenow.device-group-management.servicenowmsg+json;version=1

Response Elements

Element

Type

Description

desc

String

Description of the associate device with device group job status

key

Integer

ID of the device

exceptions

exception

Exceptions that might have occurred in the job

severity

String

Severity of the exception

code

String

Exception code

desc

String

Description of the exception

Key

Integer

ID of the exception

Sample Input

Sample XML Input

Sample JSON Input

Sample Output

Sample XML Output

Sample JSON Output

Response Status Code

Message

Description

404 Not Found

Invalid device ID or invalid device group ID specified.