I would like to write a vro script that continuously checks if a website is up and running all the time. Tried with vRO 8 but I got certificate error. Anyone has already did this? If so, could you share the idea/code? I have tried with http get object in vRO, it did not work.
You need to import the certificate first. You have a workflow for that. But, why an action instead of a workflow scheduled to run every 10 minutes or so?
You could use a "TransientHost" from the RESTHostManger:
var http_host = "https://yourhost.fq.dn" var http_uri = "index.html" var restHost = RESTHostManager.createHost("dynamicRequest") restHost.setAutoUrlRedirect(true) var http_resthost = RESTHostManager.createTransientHostFrom(restHost) http_resthost.url = http_host http_resthost.connectionTimeout = 900 http_resthost.operationTimeout = 900 //ignore cert http_resthost.hostVerification = false var method = "GET" var body = "" var request = http_resthost.createRequest(method, http_uri, body) //example - add header //request.setHeader("Content-Type", "application/json") var response = request.execute() var result = response.contentAsString return result