HowTo: Quality Center / REST API / VBScript – Discard the token / Logout
Question ID: 105771
0
0

How Do I log out of the session using REST API / VBScript?

Marked as spam
Posted by (Questions: 122, Answers: 3)
Asked on January 2, 2015 5:08 pm
35 views
Answers (1)
0
Private answer

**Example:**

Sub Disconnect()
Dim XMLHttpRequestObj, ALMServer

Set XMLHttpRequestObj = CreateObject(''Msxml2.ServerXMLHTTP.6.0'')

ALMServer = ''http://localhost:8080/qcbin'' ''<--No trailing slash XMLHttpRequestObj.open ''GET'', ALMServer & ''/authentication-point/logout'', False XMLHttpRequestObj.setRequestHeader ''Accept'',''application/xml'' XMLHttpRequestObj.send MsgBox ''--- Disconnect ---'' & vbCrLf & _ ''Status Code : '' & XMLHttpRequestObj.status & vbCrLf & _ ''Status Text : '' & XMLHttpRequestObj.statusText & vbCrLf & _ ''-------------------'' & vbCrLf & vbCrLf & _ ''Response Text : '' & vbCrLf & XMLHttpRequestObj.responseText, , ''Disconnect'' Set XMLHttpRequestObj = Nothing End Sub

Marked as spam
Posted by (Questions: 3, Answers: 168)
Answered on January 2, 2015 5:27 pm
EyeOnTesting

Welcome back to "EyeOnTesting" brought to you by Orasi Software, Inc.

X
Scroll to Top