BeginSession

The BeginSession method takes a Host Access Profile (HAP) then signs on the user and initializes a session token to be used with sessioned transactions. BeginSession also emulates the pseudo city code specified in the HAP, if the user's HAP allows emulation.

Session tokens represent GTIDs (global terminal identifiers). As there is a limited number of GTIDs, call EndSession when you are finished calling sessioned transactions to release the session token and return it to the pool. BeginSession times out after a period of inactivity. You do not have to begin and end a session every time you need to call a sessioned transaction. You can call BeginSession, then call as many sessioned transactions as you need before calling EndSession.

Refer to the sample of BeginSession for an example of a request and response. The following sample illustrates how to use the BeginSession method using SOAP.

SOAP

The following is a sample SOAP request and response. The placeholders shown need to be replaced with actual values.

Request

POST /XMLSelect/XMLSelect.asmx HTTP/1.1

Host: testws.galileo.com

Content-Type: text/xml; charset=utf-8

Content-Length: length

SOAPAction: "http://webservices.galileo.com/BeginSession"

<?xml version="1.0" encoding="utf-8"?>

<soap:Envelope xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/">

  <soap:Body>

    <BeginSession xmlns="http://webservices.galileo.com">

      <Profile>string</Profile>

    </BeginSession>

  </soap:Body>

</soap:Envelope>

Response

HTTP/1.1 200 OK

Content-Type: text/xml; charset=utf-8

Content-Length: length

<?xml version="1.0" encoding="utf-8"?>

<soap:Envelope xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/">

  <soap:Body>

    <BeginSessionResponse xmlns="http://webservices.galileo.com">

      <BeginSessionResult>string</BeginSessionResult>

    </BeginSessionResponse>

  </soap:Body>

</soap:Envelope>