Sample GET/POST/PUT/DELETE Request and Responses

Below is a sample of GET/POST/PUT/DELETE request and responses:

REQUEST

POST /api/v1/configuration/uac/infranet-enforcer/connections/infranet-enforcer/

HTTP/1.1

Host xx.xx.xx.xx

Authorization : Basic

VU9qSTlGTzNrYVk5d0t2aXpBN1dPZ0FyZlN1S3FmTkNnQUh0R0ZuR0xSbz06

Content-Type: application/json

{

"idp-for-local-sessions-only": "true",

"junos": {

"location-group": "- No 802.1X -",

"password-encrypted":

"3u+UR6n8AgABAAAAofSnIBrU19vdwUslG5LG4cg1QH6CbXDSmY4ZW0x85HY="

},

"name": "SRX",

"serial-number": [

"SJFIOQJI4KNM"

],

"severity-filter": "medium",

"use-idp": "false"

} RESPONSE

HTTP/1.1 201 OK

Content-Length: 122

Content-Type: application/json

{

"result": {

"info": [

{

"message": "Operation succeed without warning or error!"

}

]

}

}

 

PUT API call: It will update the existing configuration. Configured Location Group as "Guest" and updated to "Default" Location group.

Before Updating the Location Group

REQUEST

GET api/v1/configuration/uac/network-access/radius-clients/radius-client/

Radius%20Client HTTP/1.1

Host xx.xx.xx.xx

Authorization : Basic

VU9qSTlGTzNrYVk5d0t2aXpBN1dPZ0FyZlN1S3FmTkNnQUh0R0ZuR0xSbz06

Content-Type: application/json

{

"coa-support": "true",

"description": "",

"disconnect-support": "true",

"dynamic-auth-port": "3799",

"enable": "true",

"gatewayid": "",

"ip-address": "10.204.88.12",

"ip-address-range": "1",

"kek-encrypted": "",

"key-wrap-format": "HEX",

"key-wrap-support": "false",

"location-group": "Guest",

"mack-encrypted": "",

"make-model": "Ruckus Wireless",

"name": "Radius Client",

"ruckus-certificate-verification": "false",

"ruckus-password-encrypted": "",

"shared-secret-encrypted":

"3u+UR6n8AgABAAAAofSnIBrU19vdwUslG5LG4cg1QH6CbXDSmY4ZW0x85HY="

} RESPONSE

HTTP/1.1 200 OK

Content-Length: 122

Content-Type: application/json

After Updating the Location Group

REQUEST

PUT api/v1/configuration/uac/network-access/radius-clients/radius-client/

Radius%20Client HTTP/1.1

Host xx.xx.xx.xx

Authorization : Basic

VU9qSTlGTzNrYVk5d0t2aXpBN1dPZ0FyZlN1S3FmTkNnQUh0R0ZuR0xSbz06

Content-Type: application/json

{

"coa-support": "true",

"description": "",

"disconnect-support": "true",

"dynamic-auth-port": "3799",

"enable": "true",

"gatewayid": "",

"ip-address": "xx.xxx.xx.xx",

"ip-address-range": "1",

"kek-encrypted": "",

"key-wrap-format": "HEX",

"key-wrap-support": "false",

"location-group": "Default",

"mack-encrypted": "",

"make-model": "Ruckus Wireless",

"name": "Radius Client",

"ruckus-certificate-verification": "false",

"ruckus-password-encrypted": "",

"shared-secret-encrypted":

"3u+UR6n8AgABAAAAofSnIBrU19vdwUslG5LG4cg1QH6CbXDSmY4ZW0x85HY="

} RESPONSE

HTTP/1.1 200 OK

Content-Length: 122

Content-Type: application/json

{

"result": {

"info": [

{

"message": "Operation succeed without warning or error!"

}

]

}

}

DELETE API Call: Deleting SNMP device from Ivanti Policy Secure

REQUEST

DELETE api/v1/configuration/uac/snmpEnforcement/clients/client/ruckus HTTP/1.1

Host 10.96.73.37

Authorization : Basic

VU9qSTlGTzNrYVk5d0t2aXpBN1dPZ0FyZlN1S3FmTkNnQUh0R0ZuR0xSbz06

Content-Type: application/json

{

"default-vlan": "0",

"description": "",

"enable": "true",

"ip-address": "10.204.88.12",

"location-group": "none",

"model": "Ruckus Wireless",

"name": "ruckus",

"read-auth-password-encrypted": "",

"read-auth-protocol": "md5",

"read-priv-password-encrypted": "",

"read-priv-protocol": "",

"read-security-level": "auth",

"read-username": "public",

"snmp-enforcement": "false",

"snmp-version": "V2",

"sys-contact": "https://support.ruckuswireless.com/contact_us",

"sys-description": "Ruckus Wireless ZD1200",

"sys-location": "350 West Java Dr. Sunnyvale, CA 94089 US",

"sys-name": "ruckus",

"trap-auth-password-encrypted": "",

"trap-auth-protocol": "md5",

"trap-priv-password-encrypted": "",

"trap-priv-protocol": "",

"trap-security-level": "auth",

"trap-username": "public",

"use-samecredential": "true",

"write-auth-password-encrypted": "",

"write-auth-protocol": "md5",

"write-priv-password-encrypted": "",

"write-priv-protocol": "",

"write-security-level": "auth",

"write-username": "public"

} RESPONSE

HTTP/1.1 204 NO CONTENT

Content-Length: 0

Content-Type: application/json