Poll Request <request version="4.0"> <auth> <username>example</username> <password>example</password> <agent>example</agent> </auth> <trains-book session="dv.UpX7Bz0osA" clientRef="12345" customerCountryCode="IL"> <customer> <title>Mr.</title> <firstName>Test Firstname</firstName> <lastName>Test Lastname</lastName> <phone type="home">044-772344066</phone> <phone type="mobile">044-545966911</phone> <email>user@example.com</email> <address>123 main st.</address> <postCode>70906</postCode> <city>Someville</city> <countryCode>GB</countryCode> </customer>
<connections> <outbound id="0"/> <inbound id="0"/> </connections> <pax-group> <pax> <title>M</title> <firstName>John</firstName> <lastName>Smith</lastName> <dateOfBirth>1977-08-17</dateOfBirth> </pax> <pax> <title>F</title> <firstName>Jane</firstName> <lastName>Smith</lastName> <dateOfBirth>1975-01-30</dateOfBirth> </pax> <pax> <title>C</title> <firstName>Bob</firstName> <lastName>Smooth</lastName> <dateOfBirth>2009-10-25</dateOfBirth> </pax> </pax-group> </result> </trains-book> </request>
Booking Response <?xml version="1.0" encoding="UTF-8"?> <response success="1" time="2017-07-18 09:30:29" session="dv.2057234148117629"> <reservation id="dv.32011342111" status="partially confirmed" clientReference="12345"> <item id="1" status="partially confirmed" token=""> <source provider="Trains"> <reference>43212052</reference> </source> <booking billable="0"> <price amount="820" currency="EUR"/> </booking> <train> <paxgroup> <pax id="0"> <title>F</title> <firstName>Firstname</firstName> <lastName>Lastname</lastName> <age>32</age> <dateOfBirth>1985-01-01</dateOfBirth> </pax> <pax id="1"> <title>M</title> <firstName>FirstnameOne</firstName> <lastName>LastnameParent</lastName> <age>32</age> <dateOfBirth>1985-01-01</dateOfBirth> </pax> <pax id="2"> <title>C</title> <firstName>FirstnameTwo</firstName> <lastName>LastnameParent</lastName> <age>3</age> <dateOfBirth>20140101</dateOfBirth> </pax> </paxgroup> <outbound> <segments> <segment> <tripNumber/> <carrierCode>TH(TH)</carrierCode> <class/> <bookingClass/> <operatingCarrierCode/> <departure terminal="AMSTERDAM CS(AMSTERDAM)" dateTime="2017-07-30 06:17"/> <arrival terminal="PARIS NORD(PARIS)" dateTime="2017-07-30 09:44"/> </segment> </segments> </outbound> <inbound> <segments> <segment> <tripNumber>9337</tripNumber> <carrierCode>TH(TH)</carrierCode> <class/> <bookingClass/> <operatingCarrierCode/> <departure terminal="PARIS NORD(PARIS)" dateTime="2017-08-07 11:55"/> <arrival terminal="BRUXELLES MIDI(BRUSSELS)" dateTime="2017-08-07 13:17"/> </segment> <segment> <tripNumber>9126</tripNumber> <carrierCode>ES(ES)</carrierCode> <class/> <bookingClass/> <operatingCarrierCode/> <departure terminal="BRUXELLES MIDI(BRUSSELS)" dateTime="2017-08-07 14:02"/> <arrival terminal="AMSTERDAM CS(AMSTERDAM)" dateTime="2017-08-07 15:54"/> </segment> </segments> </inbound> </train> </item> </reservation> </response>
Note: It is mandatory to validate each item status in case some items are not confirmed |