API enhancement to support install preview in the response for multiple devices
FortiManager 7.6.0 includes API enhancements to support install preview in the response for multiple devices. For more information on FortiManager API, see the Fortinet Developer Network.
Example:
Request:
{
"method":"exec",
"params":[
{
"data":{
"adom":3,
"scope":[
{
"oid":185,
"vdom_oid":3
},
{
"oid":197,
"vdom_oid":3
}
]
},
"url":"/securityconsole/install/preview"
}
],
"session":"XKzDfn4Pmk2oRjIrsAae8ZhWPrm/CSHp1PDlSZSh5Yupuab745s8kv7dx4IaV6Rp6sHo0BxyxD3+BH2BVgLrIA=="
}
Response:
{
"result": [
{
"data": {
"message": "session id(14178) task(0) username(admin)",
"task": 51
},
"status": {
"code": 0,
"message": "OK"
},
"url": "/securityconsole/install/preview"
}
]
}
Request:
{
"method":"exec",
"params":[
{
"data":{
"adom":3,
"scope":[
{
"oid":185,
"vdom_oid":3
},
{
"oid":197,
"vdom_oid":3
}
]
},
"url":"/securityconsole/preview/result"
}
],
"session":"XKzDfn4Pmk2oRjIrsAae8ZhWPrm/CSHp1PDlSZSh5Yupuab745s8kv7dx4IaV6Rp6sHo0BxyxD3+BH2BVgLrIA=="
}
Response:
{
"result": [
{
"data": {
"message": "[{ \"name\": \"FGVM02Q105060027\", \"oid\": 185, \"result\": \"=== No preview result ===\\n\"}, { \"name\": \"FGVMSLTM20000118\", \"oid\": 197, \"result\": \"=== No preview result ===\\n\"}]"
},
"status": {
"code": 0,
"message": "OK"
},
"url": "/securityconsole/preview/result"
}
]
}
Request:
{
"method":"exec",
"params":[
{
"data":{
"adom":3,
"scope":[
{
"oid":185,
"vdom_oid":3
},
{
"oid":197,
"vdom_oid":3
}
]
},
"url":"/securityconsole/install/preview"
}
],
"session":"XKzDfn4Pmk2oRjIrsAae8ZhWPrm/CSHp1PDlSZSh5Yupuab745s8kv7dx4IaV6Rp6sHo0BxyxD3+BH2BVgLrIA=="
}
Response:
{
"result": [
{
"data": {
"message": "session id(14178) task(0) username(admin)",
"task": 52
},
"status": {
"code": 0,
"message": "OK"
},
"url": "/securityconsole/install/preview"
}
]
}
Request:
{
"method":"exec",
"params":[
{
"data":{
"adom":3,
"scope":[
{
"oid":185,
"vdom_oid":3
},
{
"oid":197,
"vdom_oid":3
}
]
},
"url":"/securityconsole/preview/result"
}
],
"session":"XKzDfn4Pmk2oRjIrsAae8ZhWPrm/CSHp1PDlSZSh5Yupuab745s8kv7dx4IaV6Rp6sHo0BxyxD3+BH2BVgLrIA=="
}
Response:
{
"result": [
{
"data": {
"message": "[{ \"name\": \"FGVM02Q105060027\", \"oid\": 185, \"result\": \"=== No preview result ===\\n\"}, { \"name\": \"FGVMSLTM20000118\", \"oid\": 197, \"result\": \"=== No preview result ===\\n\"}]"
},
"status": {
"code": 0,
"message": "OK"
},
"url": "/securityconsole/preview/result"
}
]
}