Difference between revisions of "Category:API"
From Observer GigaFlow Support | VIAVI Solutions Inc.
(Created page with "API notes.") |
|||
Line 1: | Line 1: | ||
− | + | Browser rest access | |
+ | http://172.21.40.128:7902/rest/?jsonRequest={"reportName":"Applications","type":"Table"}&portalUser=admin@myipsla.com | ||
+ | |||
+ | Sending data to scripts | ||
+ | curl -H "Content-Type: application/json" -X POST -d '{"type":"processscript","scriptid":-5,"data":{"test":false}}' "http://172.21.40.119:7902/rest/api/?userName=admin&userPass=admin" | ||
+ | curl -H "Content-Type: application/json" -X POST -d '{"type":"processscript","scriptname":"data script 1","data":{"test":false}}' "http://172.21.40.119:7902/rest/api/?userName=admin&userPass=admin" | ||
+ | |||
+ | Event Script to process incoming data | ||
+ | var thisdata = JSON.parse(data); | ||
+ | log.warn(data); | ||
+ | log.warn(thisdata); | ||
+ | log.warn(thisdata.data.test); |
Revision as of 13:56, 24 April 2019
Browser rest access http://172.21.40.128:7902/rest/?jsonRequest={"reportName":"Applications","type":"Table"}&portalUser=admin@myipsla.com
Sending data to scripts
curl -H "Content-Type: application/json" -X POST -d '{"type":"processscript","scriptid":-5,"data":{"test":false}}' "http://172.21.40.119:7902/rest/api/?userName=admin&userPass=admin" curl -H "Content-Type: application/json" -X POST -d '{"type":"processscript","scriptname":"data script 1","data":{"test":false}}' "http://172.21.40.119:7902/rest/api/?userName=admin&userPass=admin"
Event Script to process incoming data
var thisdata = JSON.parse(data); log.warn(data); log.warn(thisdata); log.warn(thisdata.data.test);
Pages in category "API"
The following 8 pages are in this category, out of 8 total.