Action “checkavail” is a simple version of action “check”, in order to obtain the availability of a specific list of times/hotels, where can be check multiple offers in a row.
Example of query:
<?xml version='1.0'?> <mds> <auth> <login>LOGIN</login> <pass>PASSWORD</pass> </auth> <request> <type>checkavail</type> <conditions> <ofr_id>05e168d7b6144142125ff99c1d4faa3d6a30eaee64f0233e835d8e85fba93022</ofr_id> <par_adt>2</par_adt> <par_chd>1</par_chd> <par_inf>1</par_inf> <birthdates> <adta>19891223</adta> <adta>19791223</adta> <chda>20051223</chda> <infa>20091223</infa> </birthdates> </conditions> </request> </mds>
Fild | Required | Description |
---|---|---|
ofr_id | yes | - |
par_adt | yes | number of adults for which the availability is checked |
par_chd | no | number of children for which the availability is asked |
par_inf | no | number of infants for which the availability is asked |
birthdates | yes | list of birthdates of participants |
adta | no | birthdate assigned to an adult |
chda | no | birthdate assigned to a child |
infa | no | birthdate assigned to an infant |
expedient_code | no | Agent (expedient) code |
x_htl | yes - for type offers of 7+7 | Cod ofr second part of stay in case of 7+7 offers. Format: [extra id hotelu]_[kod hotelu] Example: 5_LCAOASI/1/KOMB |
In case of birthdates the format is: YYYYMMDD.
For the entire section birthdates each field contained herein is optional - if not stated, the dates of birth of the participants accepted will be the default values:
An example of answer in the case of the available offers:
<?xml version="1.0" encoding="UTF-8" standalone="no"?> <response> <merlin_offer_info> <info>Flight</info> <info>Accommodation</info> <info hint="A : BOJTRAN_14 / Transfer: airport-hotel-airport">Transfer</info> <info hint="A : BOJ_DP_LOT / mandatory airport charges 400.00">mandatory airport charges </info> <info hint="A : BOJ_DP_TRA / mandatory transport charges 200.00">mandatory transport charges </info> <info hint="A : KUBS / Insurance included in price -32.00">Insuraance included in price</info> <info hint="A : UBSKLNW / Insurance Itaka Simple 32.00">Insurance Itaka Simple</info> </merlin_offer_info> <merlin_offer_status>OK</merlin_offer_status> <result_message msgCode="712"/> <pricetotal price="915" curr="EUR"/> <persons> <person id="0" gender="H" date="131280" price="313"/> <person id="1" gender="H" date="131280" price="313"/> <person id="2" gender="K" date="231205" price="229"/> <person id="3" gender="I" date="231209" price="60"/> </persons> </response>
An example answer in case that offer is not available:
<?xml version="1.0" encoding="UTF-8" standalone="no"?> <response> <merlin_offer_status>XX</merlin_offer_status> <result_message msgCode="927"/> <booking_info>Expired offer</booking_info> </response>
Example of response in case of error:
<?xml version="1.0" encoding="UTF-8" standalone="no"?> <response> <merlin_offer_status></merlin_offer_status> <error>Offer not found</error> </response>
Field | Attribute | Description |
---|---|---|
merlin_offer_info | - | Information contained in the price of services |
info | - | Information about services included in offer |
info | addedcost | If the value is given or equal to “1”, this service has an additional fee |
info | hint | Information about the service from the organizer |
merlin_offer_status | - | Status of offer in Merlin (see list of statuses below) |
result_message | msgCode | Actual code. List of possible codes on our site: http://www.merlinx.pl/mdsws/msgcode.csv |
booking_info | - | Message |
pricetotal | price | Total price of excursions |
pricetotal | curr | Currency |
persons | - | The list of participants along with the prices (if available) returned from a tour operator 1) |
person | - | Participants to trip |
person | id | order number of participants to trip |
person | gender | Tour participant gender code (returned by the organizer) |
person | date | birthdate of participants to tour (Format: DDMMYY) |
person | price | Price for the tour participant (in same currency as the total price) |
error | - | Message for critical errors |
Table of possible statuses in Merlin:
Code | Description |
---|---|
OK | offer available |
XX | offer not available |
ER | error received at availability checking |
RQ | offer “on request” |
TO | Timeout, or other problem with the connection (only version 2.1) In the event of this status information, if available, will be returned in the error . |
? | Unknown error |