Your login for our support center is different than your Control Panel login.

Click here to create a login for the support center

Code Example - Creating an MTA Account via the Web Service (VBScript)

A simple example for creating an MTA Account via the Web Service using VBScript.

'URL to open....
sUrl = "http://localhost:8086/AccountSettings.asmx/Create"
'POST Request to send.
sRequest = "friendlyName=name123&userName=user123&password=pass123&basePath="

account = ParseXML(HTTPPost(sUrl, sRequest),"int")
WScript.Echo account

Function ParseXML(XMLResponse,XMLNode)
dim xmlObj
Set xmlObj = CreateObject("Microsoft.XMLDOM")
xmlObj.async = False
dim value
set value = xmlObj.getElementsByTagName(XMLNode)(0)
ParseXML = value.text
End Function

Function HTTPPost(sUrl, sRequest)
set oHTTP = CreateObject("Microsoft.XMLHTTP") "POST", sUrl,false
oHTTP.setRequestHeader "Content-Type", "application/x-www-form-urlencoded"
oHTTP.setRequestHeader "Content-Length", Len(sRequest)
oHTTP.send sRequest
HTTPPost = oHTTP.responseText
End Function

Comments (0)
Help Desk Software by Kayako  Copyright © 2018 SocketLabs, Inc.  Terms of Service | Privacy Policy | Acceptable Use Policy