Ascio Web Service v2

Login and sessions

Before you can access the AWS functionality, you must log into the service using your Ascio account username and password. You only need to log in once per session, as the login function returns a unique sessionID that can be used in next calls. Each sessionId remains valid until you call the logout function or after twenty minutes of inactivity. It is possible to have multiple sessions at the same time.

Please look at the examples.

LogIn input parameters

Property
session

Example

var soap = require("soap");

var logInExample = function(callback) {

	//Session
	session =  {};
	session.Account="AccountTest";
	session.Password="PasswordTest";	
	soap.createClient("../AscioServiceTest.wsdl", function(err, client) {
		if(err) {
			callback(err);
		} 
		else {
			client.LogIn({session: session}, function(err,result) {
				if(err) {
					callback({error: err, request : result.request.body});
				} else {
					if(result.LogInResult.ResultCode < 400) {
						callback(null,result);	
					} else {
						callback({error: result.LogInResult,request : request});
					}
				}
			});
		};
	});
};
logInExample(function(err,result) {
	if(err) {
		console.log("\n\n Request \n\n",err.request, "\n\n Response \n\n" ,err.error,"\n");
	}
	else {
		console.log(result);
	}
});

LogOut input parameters

PropertyDescription
sessionIdExample: o58t9fjgw9bjarp6q7byv13e

Example

var soap = require("soap");

var logOutExample = function(callback) {	
	soap.createClient("../AscioServiceTest.wsdl", function(err, client) {
		if(err) {
			callback(err);
		} 
		else {
			client.LogOut({sessionId: "sessionId"}, function(err,result) {
				if(err) {
					callback({error: err, request : result.request.body});
				} else {
					if(result.LogOutResult.ResultCode < 400) {
						callback(null,result);	
					} else {
						callback({error: result.LogOutResult,request : request});
					}
				}
			});
		};
	});
};
logOutExample(function(err,result) {
	if(err) {
		console.log("\n\n Request \n\n",err.request, "\n\n Response \n\n" ,err.error,"\n");
	}
	else {
		console.log(result);
	}
});
WSDL for AWS v2
https://aws.demo.ascio.com/2012/01/01/AscioService.wsdl (OTE)
https://aws.ascio.com/2012/01/01/AscioService.wsdl (Live)
Please configure the IP-Whitelisting in the portal/demo-portal.