I have written some simple VBScript code to use a GET REST HTTP request. It is as follows:
Set objXmlHttpMain = CreateObject("Msxml2.ServerXMLHTTP.6.0")
URL = endpoint & resource & parameter
On Error Resume Next
objXmlHttpMain.open "GET",URL, False, "admin", "jhdsjkF"
objXmlHttpMain.setRequestHeader "Content-Type", "application/xml"
objXmlHttpMain.setRequestHeader "Accept", "application/xml"
objXmlHttpMain.setRequestHeader "UserID", "admin"
objXmlHttpMain.setRequestHeader "Password", "jhdsjkF"
response = objXmlHttpMain.responsetext
Ideally, I want to store this response in a UIPath string variable to use it further in the sequence. Is there a way to do that?
However, if there isn't could you assist me in putting this response in a text file? I want the text file to be the same no matter how many times the VBScript is executed, and for the response to be written after the file gets cleared.