REST Resources
-
/ -
/exec-deploy -
/exec-scripts -
/job-instances /{job-id} /script-mgmt-job-results -
/match-scripts-by-context -
/scripts -
/scripts /exec-deploy -
/scripts /exec-disable -
/scripts /exec-enable -
/scripts /exec-remove -
/scripts /exec-scripts -
/scripts /exec-verify -
/scripts /{script-id} -
/scripts /{script-id} /contents -
/scripts /{script-id} /parameters -
/scripts /{script-id} /results -
/scripts /{script-id} /view-associated-devices
/api/space/script-management/scripts/exec-disable
The following operations are supported on this resource:
- POST - Disable scripts on devices
POST /scripts/exec-disable | Version 2 |
This API disables scripts on devices. Here a script and a device are passed as reference URLs (href).
Sample Usage
This API makes an asynchronous method call; so, you can optionally specify queue and schedule parameters:
POST /scripts/exec-disable?queue=<queue>&schedule=<schedule>
Note: The queue URL denoted by <queue> must have been created already.
-
Parameters:
Name Type URI Type Description Required queue Queue URL Query A fully qualified queue URL, where job progress notifications will be sent (See Asynchronous API Usage) N schedule cron-like-expression Query Schedule this API in the future, by specifying a cron-like-expression (See Job Scheduling) N
-
Content-Type Headers:
application/vnd.net.juniper.space.script-management.exec-disable+xml;version=2;charset=UTF-8
application/vnd.net.juniper.space.script-management.exec-disable+json;version=2;charset=UTF-8 -
Accept Headers:
application/vnd.net.juniper.space.job-management.task+xml;version=1
application/vnd.net.juniper.space.job-management.task+json;version=1
<exec-disable>
<scriptMgmt>
<script
href="/api/space/script-management/scripts/294912" />
<device
href="/api/space/device-management/devices/458753" />
<scriptVersionSelected>1.1</scriptVersionSelected>
<scriptParams>
<scriptParam>
<paramName>paramName1</paramName>
<paramValue>paramValue1</paramValue>
</scriptParam>
<scriptParam>
<paramName>paramName2</paramName>
<paramValue>paramValue2</paramValue>
</scriptParam>
</scriptParams>
</scriptMgmt>
</exec-disable>
<task href="/api/space/job-management/jobs/688128">
<id>688128</id>
</task>
{
"exec-disable": {
"scriptMgmt": {
"script":{
"@href":"/api/space/script-management/scripts/294912"
},
"scriptVersionSelected":"1.1",
"device":{
"@href":"/api/space/device-management/devices/458753"
},
"scriptParams": {
"scriptParam": [
{
"paramName":"test1",
"paramValue":"test1"
},
{
"paramName":"test2",
"paramValue":"test2"
}
]
}
}
}
}
{
"task":{
"@href":"/api/space/job-management/jobs/688128",
"id":688128
}
}
Access Control
The following capabilities are required to access this API: DisableScriptCap