The supplier sends this message about the minimum stays which are applied by the structures. The query type (type) is set to getminimumstay.

Below you can see the fields you can find in the message body and their meanings.

Request
  • startdate

    first day

  • days

    number of days

Let’s see an example of message the client could send.

<?xml version="1.0" encoding="UTF-8"?>
<envelope>
    <header>
        <actor>...</actor>
        <user>...</user>
        <password>...</password>
        <version>1.0.0</version>
        <timestamp>20210808162849</timestamp>
        <transaction>52791</transaction>
    </header>
    <query type="getminimumstay" product="hotel" agrement="1299">
        <startdate>2020-06-10</startdate>
        <days>300</days>
    </query>
</envelope>
Response

The reply message contains within tag response the various fields that show the minimum stay applied.

dates

  • start date

    first day

  • days

    number of days of minimum stay validity

  • roomtype

    data about the minimum stay.

    Parameter that identifies the room type:

    • SGL single room
    • TSU twin for sole use room The TSU doesn't inherit the minimum stay of the TWN.
    • TWN twin room
    • DBL double room
    • TRP triple room
    • QUD quadruple room
    • STR big accommodations
  • night

    nights of minimum stay

  • period

    validity period of the minimum stay in a single string expressed in numbers where 0 = Monday, 1 = Tuesday, 3 = Wednesday, 4 = Thursday, 5 = Saturday, 6 = Sunday)

  • checkindays

    list of checkin days for which the minimum stay applies. Each element checkinday contains one day expressed in numbers where 0 = Monday, 1 = Tuesday, 3 = Wednesday, 4 = Thursday, 5 = Saturday, 6 = Sunday

Let’s see an example of message the client could receive if the minimum stay has been set specifically for a room type.

<?xml version="1.0" encoding="UTF-8"?>
<envelope>
    <header>
        <actor>...</actor>
        <user>...</user>
        <version>0.1b</version>
        <timestamp>20210219165009</timestamp>
        <transaction>52791</transaction>
    </header>
    <response type="getminimumstay"/>
    <date>
        <startdate>2020-06-28</startdate>
        <days>2</days>
        <roomtype>
            <DBL>9</DBL>
            <TRP>9</TRP>
        </roomtype>
        <period>01234</period>
        <checkindays>
            <checkinday>0</checkinday>
            <checkinday>1</checkinday>
        </checkindays>
    </date>
</envelope>

Let’s see an example of message the client could receive if the minimum stay has been generically set.

<?xml version="1.0" encoding="UTF-8"?>
<envelope>
    <header>
        <actor>...</actor>
        <user>...</user>
        <version>0.1b</version>
        <timestamp>20210219165009</timestamp>
        <transaction>52791</transaction>
    </header>
    <response type="getminimumstay"/>
    <date>
        <startdate>2020-06-28</startdate>
        <days>2</days>
<nights>2</nights>
        <period>2345</period>
        <checkindays>
            <checkinday>0</checkinday>
            <checkinday>1</checkinday>
        </checkindays>
    </date>
</envelope>

You can get the error No value in database found: it means that, for the required period, there isn't any minimum stay set and that the parameter nights = 1 has been set in a generic way, not specifying the room type. If you set the minimum stay to night = 1 without indicating it for each room type, the system delete the value which has been previous inserted. Otherwise, if you have set the minimum stay for every room type, the response will always show the number of nights and never the error described above.

Examples

Minimum stay: generic, 2 nights

<night>2</night>

Minimum stay: generic, 1 night

"No value in database found"

Minimum stay: specific for room type, 2 nights for the double room

<DBL>2</DBL>

Minimum stay: specific for room type, 1 night for the double room

<DBL>1</DBL>