قیمت گذاری & موجودی اتاق (معاملات) مرجع XML

این صفحه مرجعی برای پیام‌های تراکنش مبتنی بر XML ارائه می‌کند.

<Transaction>

عنصر اصلی یک پیام تراکنش <Transaction> است. این محفظه ای برای اطلاعات توصیفی در مورد اتاق ها و بسته ها و قیمت و در دسترس بودن اتاق ها و بسته ها است.

عنصر <Transaction> در مکان زیر در سلسله مراتب XML پیام تراکنش ظاهر می شود:

+ <Transaction>
    + <PropertyDataSet>  // Room and package metadata
        + <Property>
        + <RoomData>
        + <PackageData>
    + <Result>           // Pricing and availability
        + <Rates>
        + <RoomBundle>
        + ...

پیام هایی که از <Transaction> به عنوان عنصر اصلی استفاده می کنند حداقل به یک عنصر فرزند نیاز دارند. پیام‌های تراکنش می‌توانند هر تعداد عنصر فرزند داشته باشند، تا زمانی که حجم پیام از 100 مگابایت تجاوز نکند.

نحو

عنصر <Transaction> از نحو زیر استفاده می کند:

<?xml version="1.0" encoding="UTF-8"?>
<Transaction timestamp="timestamp" id="transaction_ID">

  <!-- Defines data about a room or package (Room Bundle) -->
  <PropertyDataSet>
    ...
  </PropertyDataSet>

  <!-- Updates/sets prices and availability for rooms and Room Bundles -->
  <!-- (Also removes itineraries from inventory) -->
  <Result>
    ...
  </Result>

</Transaction>

صفات

عنصر <Transaction> دارای ویژگی های زیر است:

صفت مورد نیاز؟ تایپ کنید توضیحات
id Required رشته یک شناسه منحصر به فرد برای هر پیام تراکنش.
partner Optional string حساب شریکی که پیام تراکنش برای آن است. معمولاً اگر باطن شما فیدهای قیمت را برای چندین حساب شریک ارائه دهد، از آن استفاده می کنید. این مقدار رشته، مقدار «کلید شریک» است که در صفحه تنظیمات حساب در مرکز هتل فهرست شده است.
timestamp Required DateTime

لحظه ای که پیام تراکنش ارسال شد.

هر پیامی که در 24 ساعت قبل با مهر زمانی ارسال شود، پردازش می‌شود و پیام‌هایی که با مهر زمانی ارسال نشده‌اند، کنار گذاشته می‌شوند.

پیام ها به ترتیب timestamp پردازش می شوند نه به ترتیب دریافت. به عنوان مثال، به‌روزرسانی قیمت با مهر زمانی 2019-05-03 14:09:00 که پس از پیامی با مهر زمانی 2019-05-03 14:10:00 دریافت می‌شود همچنان به ترتیب پردازش می‌شود و قیمت پیام با مهر زمانی 2019-05-03 14:10:00 استفاده می‌شود.

عناصر کودک

عنصر <Transaction> دارای عناصر فرزند زیر است:

عنصر کودک مورد نیاز؟ تایپ کنید توضیحات
<PropertyDataSet> Optional* <PropertyDataSet>

یک اتاق خاص و بسته‌های اتاق را توصیف می‌کند. شما معمولاً از این عنصر در یک پیام تراکنش جداگانه برای تعریف مقادیر به اشتراک گذاشته شده برای Room Bundles و کاهش اندازه پیام های تراکنش خود استفاده می کنید.

<Result> Optional* <Result>

داده‌های قیمت‌گذاری برای برنامه سفر اتاق یا عنصر <RoomBundle> که بسته‌های اتاق و انواع اتاق‌های اضافی را برای ملک تعریف می‌کند. عنصر <Result> همچنین می تواند برای حذف برنامه های سفر از موجودی استفاده شود.

* حداقل یکی از <PropertyDataSet> یا <Result> مورد نیاز است.

نمونه ها

داده های اتاق

مثال زیر داده های اتاق را در پیام تراکنش تعریف می کند:

<?xml version="1.0" encoding="UTF-8"?>
<Transaction timestamp="2017-07-18T16:20:00-04:00" id="42">
  <PropertyDataSet>
    <Property>1234</Property>
    <RoomData>
      <RoomID>5440OF</RoomID>
      <Name>
        <Text text="Single King Bed Room" language="en"/>
        <Text text="Simple Lit de Roi" language="fr"/>
      </Name>
      <Description>
        <Text text="One king bed with pillowtop mattresses, 300-thread-count linens,
          and down comforters (bedspreads). City view. 300 square feet. Desk with
          rolling chair. Multi-line phone with voice mail. Cable/satellite TV with
          complimentary HBO and pay movies." language="en"/>
        <Text text="Un très grand lit avec matelas à plateau-coussin, ..." language="fr"/>
      </Description>
      <PhotoURL>
        <Caption>
          <Text text="Bathroom View" language="en"/>
          <Text text="La salle de baines" language="fr"/>
        </Caption>
        <URL>http://www.foo.com/static/bar/image1234.jpg</URL>
      </PhotoURL>
      <Capacity>4</Capacity>
    </RoomData>
  </PropertyDataSet>
</Transaction>

داده های قیمت گذاری

مثال زیر داده های قیمت گذاری را در پیام تراکنش تعریف می کند:

<?xml version="1.0" encoding="UTF-8"?>
<Transaction timestamp="2017-07-23T16:20:00-04:00" id="42">
  <Result>
    <Property>060773</Property>
    <RoomID>RoomType101</RoomID>
    <PackageID>Package101</PackageID>
    <Checkin>2018-06-10</Checkin>
    <Nights>2</Nights>
    <Baserate currency="USD">278.33</Baserate>
    <Tax currency="USD">25.12</Tax>
    <OtherFees currency="USD">2.00</OtherFees>
    <AllowablePointsOfSale>
      <PointOfSale id="site1"/>
    </AllowablePointsOfSale>
  </Result>
  <Result>
    <Property>052213</Property>
    <RoomID>RoomType101</RoomID>
    <PackageID>Package101</PackageID>
    <Checkin>2018-06-10</Checkin>
    <Nights>2</Nights>
    <Baserate currency="USD">299.98</Baserate>
    <Tax currency="USD">26.42</Tax>
    <OtherFees currency="USD">2.00</OtherFees>
    <AllowablePointsOfSale>
      <PointOfSale id="otto"/>
      <PointOfSale id="simon"/>
    </AllowablePointsOfSale>
    <MilesIncluded>
      <NumberOfMiles>1200</NumberOfMiles>
      <Provider>
        <Text language="en" text="United Airlines"/>
      </Provider>
      <LoyaltyCampaignID>my_campaign</LoyaltyCampaignID>
    </MilesIncluded>
  </Result>
</Transaction>

نرخ های شبانه

مثال زیر داده‌های قیمت‌گذاری را برای 1 تا 7 شب از تاریخ 7 ژوئن 2023 تعریف می‌کند:

<?xml version="1.0" encoding="UTF-8"?>
<Transaction timestamp="2017-08-24T16:20:00-04:00" id="42">
  <Result>
    <Property>1234</Property>
    <Checkin>2018-06-07</Checkin>
    <Nights>1</Nights>
    <Baserate currency="USD">209.99</Baserate>
    <Tax currency="USD">25.12</Tax>
    <OtherFees currency="USD">2.00</OtherFees>
  </Result>
  <Result>
    <Property>1234</Property>
    <Checkin>2018-06-07</Checkin>
    <Nights>2</Nights>
    <Baserate currency="USD">419.98</Baserate>
    <Tax currency="USD">25.12</Tax>
    <OtherFees currency="USD">2.00</OtherFees>
  </Result>
  <Result>
    <Property>1234</Property>
    <Checkin>2018-06-07</Checkin>
    <Nights>3</Nights>
    <Baserate currency="USD">614.97</Baserate>
    <Tax currency="USD">21.12</Tax>
    <OtherFees currency="USD">2.00</OtherFees>
  </Result>
  <Result>
    <Property>1234</Property>
    <Checkin>2018-06-07</Checkin>
    <Nights>4</Nights>
    <Baserate currency="USD">819.96</Baserate>
    <Tax currency="USD">21.12</Tax>
    <OtherFees currency="USD">2.00</OtherFees>
  </Result>
  <Result>
    <Property>1234</Property>
    <Checkin>2018-06-07</Checkin>
    <Nights>5</Nights>
    <Baserate currency="USD">999.95</Baserate>
    <Tax currency="USD">21.12</Tax>
    <OtherFees currency="USD">2.00</OtherFees>
  </Result>
  <Result>
    <Property>1234</Property>
    <Checkin>2018-06-07</Checkin>
    <Nights>6</Nights>
    <Baserate currency="USD">1193.94</Baserate>
    <Tax currency="USD">21.12</Tax>
    <OtherFees currency="USD">2.00</OtherFees>
  </Result>
  <Result>
    <Property>1234</Property>
    <Checkin>2018-06-07</Checkin>
    <Nights>7</Nights>
    <Baserate currency="USD">1259.93</Baserate>
    <Tax currency="USD">21.12</Tax>
    <OtherFees currency="USD">2.00</OtherFees>
  </Result>
</Transaction>


نرخ های پایه و مشروط

مثال زیر یک پیام تراکنش را نشان می دهد که حاوی نرخ پایه و نرخ مشروط است:

<?xml version="1.0" encoding="UTF-8" ?>
<Transaction timestamp="2023-05-18T16:20:00-04:00" id="42">
  <Result>
    <Property>1234</Property>
    <Checkin>2023-04-10</Checkin>
    <Nights>1</Nights>

    <Baserate currency="USD">200.00</Baserate>
    <Tax currency="USD">20.00</Tax>
    <OtherFees currency="USD">1.00</OtherFees>

    <Rates>
      <!-- The rate_rule_id is required when using conditional rates -->
      <Rate rate_rule_id="mobile">
        <!-- Override base rate and taxes for conditional rates -->
        <Baserate currency="USD">180.00</Baserate>
        <Tax currency="USD">18.00</Tax>
      </Rate>
    </Rates>

  </Result>
</Transaction>

موجودی را حذف کنید

مثال زیر چندین موجودی (یک شب اقامت برای چندین تاریخ مختلف) را برای یک هتل از موجودی حذف می‌کند:

<?xml version="1.0" encoding="UTF-8"?>
<Transaction timestamp="2023-05-23T16:20:00-04:00" id="42">
  <Result>
    <Property>1123581321</Property>
    <Checkin>2023-05-23</Checkin>
    <Nights>1</Nights>
    <Unavailable>
      <NoVacancy/>
    </Unavailable>
    <Tax currency="USD">0</Tax>
    <OtherFees currency="USD">0</OtherFees>
  </Result>
  <Result>
    <Property>1123581321</Property>
    <Checkin>2023-05-24</Checkin>
    <Nights>1</Nights>
    <Unavailable>
      <NoVacancy/>
    </Unavailable>
    <Tax currency="USD">0</Tax>
    <OtherFees currency="USD">0</OtherFees>
  </Result>
  <!---Sending <Baserate> is optional with <Unavailable> -->
  <Result>
    <Property>1123581321</Property>
    <Checkin>2023-05-25</Checkin>
    <Nights>1</Nights>
    <Baserate currency="USD">-1</Baserate>
    <Unavailable>
      <NoVacancy/>
    </Unavailable>
    <Tax currency="USD">0</Tax>
    <OtherFees currency="USD">0</OtherFees>
  </Result>
</Transaction>

<PropertyDataSet>

ظرفی برای اطلاعات اتاق و بسته (یا Room Bundle ) در پیام <Transaction> . ارزش‌های تعیین‌شده در هتل، ارزش‌های تعیین‌شده برای یک شریک را لغو می‌کند. Google این اطلاعات را ذخیره می کند تا هر بار که به روز رسانی قیمت را ارسال می کنید نیازی به تعریف آن نداشته باشید.

عنصر <PropertyDataSet> در مکان زیر در سلسله مراتب XML پیام تراکنش ظاهر می شود:

+ <Transaction>
    + <PropertyDataSet>  // Room and package metadata
        + <Property>
        + <RoomData>
        + <PackageData>
    + <Result>  // Pricing and availability
        + <Rates>
        + <RoomBundle>
        + ...

برای اطلاعات بیشتر، به فراداده اتاق بسته مراجعه کنید.

نحو

عنصر <PropertyDataSet> از نحو زیر استفاده می کند:

<?xml version="1.0" encoding="UTF-8"?>
<Transaction ... >
  <PropertyDataSet>
    <!-- (Required) ID that matches the Hotel List Feed -->
    <Property>hotel_ID</Property>

    <!-- (Optional) Defines metadata about a room -->
    <RoomData>
      ...
    </RoomData>

    <!-- (Optional) Defines package metadata to be paired with rooms (Room Bundles) -->
    <PackageData>
      ...
    </PackageData>
  </PropertyDataSet>
  ...
</Transaction>

صفات

عنصر <PropertyDataSet> هیچ ویژگی ندارد.

عناصر کودک

عنصر <PropertyDataSet> دارای عناصر فرزند زیر است:

عنصر کودک مورد نیاز؟ تایپ کنید توضیحات
<PackageData> Optional* <PackageData> یک اتاق بسته را توصیف می کند. این داده ها با یک شریک و هتل مرتبط است، اما نه با یک برنامه سفر. این عنصر شبیه <RoomData> است، اما امکانات و اصطلاحاتی را توصیف می کند که بخشی از توضیحات اتاق فیزیکی نیستند.

شما به شناسه بسته در به‌روزرسانی‌های قیمت‌گذاری خود اشاره می‌کنید.

برای اطلاعات بیشتر، به فراداده اتاق بسته مراجعه کنید.

<Property> Required string شناسه هتلی که داده‌های مرتبط با آن اعمال می‌شود. مقدار این عنصر باید رشته ای باشد که با فهرست <id> در فید فهرست هتل شما مطابقت داشته باشد.
<RoomData> Optional* <RoomData> یک اتاق را توصیف می کند. این داده ها با یک شریک و هتل مرتبط است، اما نه با یک برنامه سفر.

در به‌روزرسانی‌های قیمت‌گذاری، به شناسه اتاق اشاره می‌کنید.

* حداقل یکی از <PackageData> یا <RoomData> مورد نیاز است.

نمونه ها

داده های اتاق و بسته

مثال زیر داده های اتاق و بسته را در <PropertyDataSet> نشان می دهد:

<?xml version="1.0" encoding="UTF-8"?>
<Transaction timestamp="2017-07-18T16:20:00-04:00" id="42">
  <PropertyDataSet>
    <Property>180054</Property>
    <RoomData>
      <RoomID>060773</RoomID>
      <Name>
        <Text text="Single Bed Room" language="en"/>
        <Text text="Chambre single" language="fr"/>
      </Name>
      <Description>
        <Text text="Non-smoking" language="en"/>
        <Text text="Pas de fumiers" language="fr"/>
      </Description>
      <PhotoURL>
        <Caption>
          <Text text="Living area" language="en"/>
          <Text text="Le chambre" language="fr"/>
        </Caption>
        <URL>http://www.foo.com/static/bar/image1234.jpg</URL>
      </PhotoURL>
    </RoomData>
    <PackageData>
      <PackageID>P54321</PackageID>
      <Name>
        <Text text="Breakfast Included" language="en"/>
        <Text text="Avec le petit déjeuner" language="fr"/>
      </Name>
      <Description>
        <Text text="Includes a delightful array of jams and jellies." language="en"/>
        <Text text="Comprend une délicieuse gamme de confitures et gelées." language="fr"/>
      </Description>
      <BreakfastIncluded>1</BreakfastIncluded>
    </PackageData>
  </PropertyDataSet>
</Transaction>

وقتی قیمت‌ها و در دسترس بودن این اتاق و اتاق بسته را ارسال می‌کنید، به شناسه اتاق و بسته در پیام‌های قیمت‌گذاری خود اشاره می‌کنید. نتیجه این است که اندازه پیام های خود را تا حد زیادی کاهش می دهید و همچنین میزان خطاهایی که ممکن است به دلیل داده های تکراری با آنها مواجه شوید را کاهش می دهید. برای اطلاعات بیشتر، به فراداده اتاق بسته مراجعه کنید.

<RoomData>

فراداده‌های مستقل از برنامه سفر را درباره اتاق‌ها، و در نتیجه، Room Bundles را تعریف می‌کند (زیرا Room Bundles اتاق‌هایی به اضافه امکانات اضافی هستند). از <RoomData> برای کاهش تکرار داده های توصیفی در فید قیمت خود استفاده کنید.

عنصر <RoomData> در مکان زیر در سلسله مراتب XML پیام تراکنش ظاهر می شود:

+ <Transaction>
    + <PropertyDataSet>  // Room and package metadata
        + <Property>
        + <RoomData>
        + <PackageData>
    + <Result>           // Pricing and availability
        + <Rates>
        + <RoomBundle>
        + ...

عناصر <RoomData> حاوی اطلاعاتی هستند که با یک شریک و هتل مرتبط است، اما نه با یک برنامه سفر. هدف مورد نظر برای همه داده های غیر سفرنامه است.

عنصر <RoomData> شبیه <PackageData> است، اما به جای امکانات و شرایط یک بسته، اتاق فیزیکی را توصیف می کند. شما از <RoomData> و <PackageData> به صورت ترکیبی برای ارائه جزئیات در مورد Room Bundles استفاده می کنید. برای اتاق های فردی که بخشی از یک بسته نیستند، فقط از <RoomData> استفاده کنید.

شما می توانید هر دو عنصر <RoomData> و <PackageData> را برای یک اتاق یا Room Bundle تعریف کنید. هنگامی که Google آن اتاق یا بسته را در نتایج جستجو نشان می‌دهد، توضیحات هر دو را که با خط فاصله از هم جدا شده‌اند، شامل می‌شود.

برای اطلاعات بیشتر، به فراداده اتاق بسته مراجعه کنید.

نحو

عنصر <RoomData> از نحو زیر استفاده می کند:

<?xml version="1.0" encoding="UTF-8"?>
<Transaction ... >
  <PropertyDataSet>
    ...
    <RoomData>
      <RoomID>room_ID</RoomID>

      <Name>
        <Text text="room_name" language="language_code"/>
        ...
      </Name>

      <Description>
        <Text text="room_description" language="language_code"/>
        ...
      </Description>

      <Capacity>max_number_of_occupants</Capacity>
      <Occupancy>max_number_of_intended_occupants</Occupancy>
      <OccupancyDetails> <!-- optional info about the types of guests,
      whether adults, children, or seniors --></OccupancyDetails>
      <OccupancySettings>
        <MinOccupancy>min_number_of_occupants</MinOccupancy>
        <MinAge>min_age_of_occupants</MinAge>
      </OccupancySettings>

      <PhotoURL>
        <Caption>
          <Text text="photo_description" language="language_code"/>
          ...
        </Caption>
        <URL>photo_location</URL>
      </PhotoURL>
      <RoomFeatures>
        ...
      </RoomFeatures>
    </RoomData>
    ...
  </PropertyDataSet>
</Transaction>

صفات

عنصر <RoomData> هیچ ویژگی ندارد.

عناصر کودک

عنصر <RoomData> دارای عناصر فرزند زیر است:

عنصر کودک مورد نیاز؟ تایپ کنید توضیحات
<Capacity> Optional integer حداکثر تعداد مهمانانی که یک اتاق می تواند از نظر فیزیکی در خود جای دهد . برای یک اتاق، ظرفیت بیشتر یا برابر با اشغال است.

در صورت مشخص شدن، این مقدار باید برابر یا بیشتر از مقدار عنصر <Occupancy> باشد که تعداد مهمانان در نظر گرفته شده برای یک اتاق خاص است. برای مثال، <Capacity> یک سوئیت بزرگ ممکن است 6 باشد، اما <Occupancy> برای آن 4 باشد.

مقدار <Capacity> باید یک عدد صحیح مثبت بین 1 و 20 باشد.

<Description> Optional Object شرح مفصلی از اتاق این عنصر باید حاوی اطلاعاتی باشد که توسط عناصر دیگر یا عنصر <Name> توصیف نشده است. هنگام تعیین توضیحات اتاق نباید از تمام حروف بزرگ استفاده کنید.

عنصر <Description> یک عنصر فرزند به <Text> را می گیرد که دارای دو ویژگی ضروری زیر است:

  • text : شرح مفصلی از اتاق.
  • language : یک کد زبان دو حرفی. به عنوان مثال، fr .

از یک عنصر <Text> جداگانه برای هر زبانی که ممکن است آگهی شما یا پیوند رزرو رایگان در آن ظاهر شود (با مقادیر متفاوت برای ویژگی‌های language ) استفاده کنید.

مثال زیر نسخه های فرانسوی و انگلیسی توضیحات اتاق را نشان می دهد:

<Description>
  <Text text="Two queen-sized beds" language="en"/>
  <Text text="Deux lits de la reine" language="fr"/>
</Description>
<Name> Required string نام دسته اتاق. این مقدار باید با آنچه در صفحه فرود هتل (نقطه فروش سابق) ظاهر می شود مطابقت داشته باشد. مقدار این عنصر را روی همه حروف بزرگ تنظیم نکنید.

این عنصر یک عنصر فرزند منفرد، <Text> را می گیرد که دارای دو ویژگی ضروری زیر است:

  • text : نام اتاق.
  • language : یک کد زبان دو حرفی. به عنوان مثال، fr .

از یک عنصر <Text> جداگانه برای هر زبانی که ممکن است آگهی شما یا پیوند رزرو رایگان در آن ظاهر شود (با مقادیر متفاوت برای ویژگی‌های language ) استفاده کنید.

مثال زیر نسخه های فرانسوی و انگلیسی نام اتاق را نشان می دهد:

<Name>
  <Text text="Standard Double Room" language="en"/>
  <Text text="Le chambre double" language="fr"/>
</Name>
<Occupancy> Optional integer حداکثر تعداد مهمانانی که یک اتاق برای آنها در نظر گرفته شده است . به عنوان مثال، یک سوئیت بزرگ ممکن است بتواند از لحاظ فیزیکی 6 مهمان را در خود جای دهد (ظرفیت = 6)، اما فقط برای حداکثر 4 مهمان در نظر گرفته شده است.

این مقدار باید کمتر یا مساوی عنصر <Capacity> باشد، که تعداد افرادی است که اتاق می تواند از نظر فیزیکی در خود جای دهد.

مقدار <Occupancy> باید یک عدد صحیح مثبت بین 1 و 99 باشد.

<Occupancy> ممکن است با <OccupancyDetails> همراه باشد که نوع مهمانان (بزرگسالان یا کودکان) را مشخص می کند. برای نحو و شرح عناصر فرزند به <OccupancyDetails> مراجعه کنید.

<OccupancySettings> Optional Object تنظیماتی که می تواند شرایط اشغال یک اتاق را محدود یا تغییر دهد.

عنصر <OccupancySettings> عناصر فرزند زیر را می گیرد:

  • <MinOccupancy> : حداقل تعداد مهمانانی که می توانند در یک اتاق بمانند. برای مثال، اگر روی 2 تنظیم شده باشد، این اتاق را نمی توان برای یک مهمان رزرو کرد.

    مقدار <MinOccupancy> باید یک عدد صحیح مثبت بین 1 و 99 باشد.

  • <MinAge> : حداقل سن برای تمام مهمانانی که در یک اتاق می مانند. برای مثال، اگر روی 18 تنظیم شده باشد، این اتاق را فقط می‌توان برای گروه‌هایی رزرو کرد که همه مهمان‌های آن 18 سال یا بیشتر دارند.

    مقدار <MinAge> باید یک عدد صحیح مثبت بین 0 تا 99 باشد.

<OccupancySettings>
  <MinOccupancy>2</MinOccupancy>
  <MinAge>16</MinAge>
</OccupancySettings>

لازم نیست همه عناصر کودک گنجانده شوند.

<PhotoURL> Optional Object یک URL و شرح اختیاری برای عکسی از اتاق یا بسته اتاق داده شده. شما می توانید بیش از یک <PhotoURL> را برای یک اتاق یا اتاق بسته مشخص کنید. هر URL عکس باید در <PhotoURL> خودش باشد.

این عنصر عناصر فرزند زیر را می گیرد:

  • <URL> : مکان عکس را مشخص می کند. مکان باید عمومی باشد (نه پشت فایروال) و باید شامل پروتکل باشد (مثلاً https:// ). در هر <PhotoURL> فقط از یک <URL> استفاده کنید.
  • <Caption> : شرح عکس را مشخص می کند. این عنصر یک عنصر فرزند به <Text> را می گیرد که دارای دو ویژگی ضروری است: text و language . ویژگی text عبارت است و ویژگی language یک کد زبان دو حرفی مانند en را مشخص می کند.

مثال:

<PhotoURL>
  <URL>https://www.example.com/static/bar/image1234.jpg</URL>
  <Caption>
    <Text text="A bright and breezy way to enjoy your mornin'
      cuppa tea." language="en"/>
    <Text text="Une façon lumineuse et aérée pour profiter
      de votre journée tasse de thé." language="fr"/>
  </Caption>
</PhotoURL>
<PhotoURL>
  <URL>https://www.foo.com/static/bar/image5678.jpg</URL>
  <Caption>
    <Text text="Or, perhaps you prefer coffee." language="en"/>
    <Text text="Ou peut-être préférez-vous le café." language="fr"/>
  </Caption>
</PhotoURL>
<RoomFeatures> Optional <RoomFeatures> حاوی اطلاعاتی در مورد ویژگی های اتاق است.
<RoomID> Required string شناسه منحصر به فرد اتاق از این شناسه برای تطبیق داده‌های اتاق با بلوک‌های <Result> در به‌روزرسانی‌های قیمت‌گذاری خود استفاده کنید. برای اطلاعات بیشتر، به فراداده اتاق بسته مراجعه کنید. (همچنین می توانید از این شناسه برای ارجاع به تعریف اتاق مشترک در یک پیام تراکنش زمانی که داده های اتاق را به صورت خطی تعریف می کنید استفاده کنید.)

نمونه ها

داده های اتاق

مثال زیر داده های اتاق را تعریف می کند:

<?xml version="1.0" encoding="UTF-8"?>
<Transaction timestamp="2017-07-18T16:20:00-04:00" id="42">
  <PropertyDataSet>
    <Property>1234</Property>
    <RoomData>
      <RoomID>5440OF</RoomID>
      <Name>
        <Text text="Single King Bed Room" language="en"/>
        <Text text="Simple Lit de Roi" language="fr"/>
      </Name>
      <Description>
        <Text text="One king bed with pillowtop mattresses, 300-thread-count linens,
          and down comforters (bedspreads). City view. 300 square feet. Desk with
          rolling chair. Multi-line phone with voice mail. Cable/satellite TV with
          complimentary HBO and pay movies." language="en"/>
        <Text text="Un très grand lit avec matelas à plateau-coussin, ..." language="fr"/>
      </Description>
      <PhotoURL>
        <Caption>
          <Text text="Bathroom View" language="en"/>
          <Text text="La salle de baines" language="fr"/>
        </Caption>
        <URL>http://www.foo.com/static/bar/image1234.jpg</URL>
      </PhotoURL>
      <Capacity>4</Capacity>
    </RoomData>
  </PropertyDataSet>
</Transaction>

فراداده اتاق و بسته

مثال زیر فراداده اتاق و بسته را تعریف می کند:

<?xml version="1.0" encoding="UTF-8"?>
<Transaction timestamp="2017-07-18T16:20:00-04:00" id="42">
  <PropertyDataSet>
    <Property>180054</Property>
    <RoomData>
      <RoomID>060773</RoomID>
      <Name>
        <Text text="Single Bed Room" language="en"/>
        <Text text="Chambre single" language="fr"/>
      </Name>
      <Description>
        <Text text="Non-smoking" language="en"/>
        <Text text="Pas de fumiers" language="fr"/>
      </Description>
      <PhotoURL>
        <Caption>
          <Text text="Living area" language="en"/>
          <Text text="Le chambre" language="fr"/>
        </Caption>
        <URL>http://www.foo.com/static/bar/image1234.jpg</URL>
      </PhotoURL>
    </RoomData>
    <PackageData>
      <PackageID>P54321</PackageID>
      <Name>
        <Text text="Breakfast Included" language="en"/>
        <Text text="Avec le petit déjeuner" language="fr"/>
      </Name>
      <Description>
        <Text text="Includes a delightful array of jams and jellies." language="en"/>
        <Text text="Comprend une délicieuse gamme de confitures et gelées." language="fr"/>
      </Description>
      <BreakfastIncluded>1</BreakfastIncluded>
    </PackageData>
  </PropertyDataSet>
</Transaction>

بسته های چند اتاق

مثال زیر فراداده اتاق و بسته را برای چندین اتاق بسته تعریف می کند:

<?xml version="1.0" encoding="UTF-8"?>
<Transaction timestamp="2017-07-18T16:20:00-04:00" id="42">
  <!-- A transaction message with room types result. -->
  <PropertyDataSet>
    <Property>12345</Property>
    <RoomData>
      <RoomID>single</RoomID>
      <Name>
        <Text text="Single room" language="en"/>
        <Text text="Chambre simple" language="fr"/>
      </Name>
      <Description>
        <Text text="A single room" language="en"/>
        <Text text="Le chambre simple" language="fr"/>
      </Description>
      <PhotoURL>
        <Caption>
          <Text text="Living area" language="en"/>
          <Text text="Le chambre" language="fr"/>
        </Caption>
        <URL>http://www.foo.com/static/bar/image1234.jpg</URL>
      </PhotoURL>
      <PhotoURL>
        <URL>http://www.foo.com/static/bar/image1235.jpg</URL>
      </PhotoURL>
      <Capacity>2</Capacity>
    </RoomData>
    <RoomData>
      <RoomID>double</RoomID>
      <Name>
        <Text text="Double room" language="en"/>
        <Text text="Chambre double" language="fr"/>
      </Name>
      <Occupancy>1</Occupancy>
    </RoomData>
    <PackageData>
      <PackageID>refundbreakfast</PackageID>
      <Name>
        <Text text="Refundable Room with Breakfast" language="en"/>
        <Text text="Chambre remboursable avec le petit déjeuner" language="fr"/>
      </Name>
      <Description>
        <Text text="Continental Breakfast" language="en"/>
        <Text text="Petit déjeuner continental" language="fr"/>
      </Description>
      <ChargeCurrency>hotel</ChargeCurrency>
      <Refundable available="1" refundable_until_days="3"/>
      <BreakfastIncluded>1</BreakfastIncluded>
    </PackageData>
    <PackageData>
      <PackageID>prepaid</PackageID>
      <Name>
        <Text text="Nonrefundable" language="en"/>
        <Text text="Non remboursable" language="fr"/>
      </Name>
      <Description>
        <Text text="Blah blah blad" language="en"/>
        <Text text="Le blah blah blad" language="fr"/>
      </Description>
      <Occupancy>2</Occupancy>
      <ChargeCurrency>web</ChargeCurrency>
      <Refundable available="0"/>
    </PackageData>
  </PropertyDataSet>
</Transaction>

<RoomFeatures>

ویژگی های موجود در اتاق را تعریف می کند.

عنصر <RoomFeatures> در مکان زیر در سلسله مراتب XML پیام تراکنش ظاهر می شود:

+ <Transaction>
    + <PropertyDataSet>  // Room and package metadata
        + <Property>
        + <RoomData>
            + <RoomFeatures>

نحو

عنصر <RoomFeatures> از نحو زیر استفاده می کند:

<?xml version="1.0" encoding="UTF-8"?>
<Transaction ... >
  <PropertyDataSet ... >
    ...
    <RoomData>
      <RoomFeatures>
        <JapaneseHotelRoomStyle>[western|japanese|japanese_western]</JapaneseHotelRoomStyle>
        <Beds>
           <Bed size="[single|semi_double|double|queen|king]">
             <Width unit="cm" number="width"/>
             <Length unit="cm" number="length"/>
           </Bed>
           <!-- Include with any additional beds. -->
        </Beds>
        <Suite/>
        <Capsule/>
        <Roomsharing>[shared|private]</Roomsharing>
        <Outdoor/>
        <MobilityAccessible/>
        <Smoking>[smoking|non_smoking]</Smoking>
        <BathAndToilet relation="[together|separate]">
          <Bath bathtub="[false|true]" shower="[false|true]"/>
          <Toilet electronic_bidet="[false|true]" mobility_accessible="[false|true]"/>
        </BathAndToilet>
        <OpenAirBath/>
        <AirConditioning/>
        <Balcony/>
        <Views>
          <!-- (Optional) Defines the type of views from the room. -->
          <!-- Example: <OceanView/> -->
        </Views>

      </RoomFeatures>
      ...
    </RoomData>
    ...
  </PropertyDataSet>
</Transactions>

صفات

عنصر <RoomFeatures> هیچ ویژگی ندارد.

عناصر کودک

عنصر <RoomFeatures> دارای عناصر فرزند زیر است:

عنصر کودک مورد نیاز؟ تایپ کنید توضیحات
<JapaneseHotelRoomStyle> Optional enum

نشان دهنده سبک یک اتاق هتل ژاپنی است.

مقادیر معتبر عبارتند از:

  • western : اتاقی به سبک غربی با تخت.
  • japanese : اتاقی به سبک ژاپنی با تختخواب های فوتون.
  • japanese_western : اتاقی به سبک وسترن ژاپنی که هم تخت های به سبک غربی و هم فوتون های سبک ژاپنی دارد.
<Beds> Optional Object به اندازه اتاق دارای <Bed> است. توجه داشته باشید که فوتون های ژاپنی را نباید در اینجا حساب کرد.

هر <Bed> دارای ویژگی های زیر است:

  • size (اختیاری): مقادیر معتبر single ، semi_double ، double ، queen و king هستند.
هر <Bed> دارای عناصر فرزند زیر است:
  • <Width> (اختیاری): عرض بستر را مشخص می کند. باید unit مشخصه با مقدار cm و number مشخصه با عرض بستر بر حسب سانتی متر باشد.
  • <Length> (اختیاری): طول تخت را مشخص می کند. باید unit مشخصه با مقدار cm و number مشخصه با طول بستر بر حسب سانتی متر باشد.
مثال:
<Beds>
  <Bed size="double">
    <Width unit="cm" number="140"/>
    <Length unit="cm" number="195"/>
  </Bed>
  <Bed/> <!-- Size unknown -->
</Beds>
<Suite> Optional empty وقتی این اتاق یک سوئیت است، این عنصر را ارائه دهید.
<Capsule> Optional empty وقتی این اتاق یک اتاق کپسولی است، این عنصر را فراهم کنید.
<Roomsharing> Optional enum این که آیا این اتاق با ساکنان دیگر مانند مالکان یا سایر مهمانان مشترک است. مقادیر معتبر shared و private هستند.
<Outdoor> Optional empty هنگامی که این اتاق اقامتگاهی در فضای باز است که دیوارهای ثابت، لوله کشی و کنترل آب و هوا ندارد، این عنصر را ارائه دهید. به عنوان مثال، اتاق‌های هتل محل اقامت در فضای باز نیستند، در حالی که کمپینگ‌هایی که مهمانان در چادرها اقامت می‌کنند و پارک‌های RV که مهمانان RV خود را می‌آورند، اقامتگاه در فضای باز هستند.
<MobilityAccessible> Optional empty زمانی که این اتاق قابل جابجایی است، این عنصر را ارائه دهید.
<Smoking> Optional enum چه این اتاق یک اتاق غیرسیگاری باشد یا یک اتاق سیگار. مقادیر معتبر non_smoking و smoking هستند.
<BathAndToilet> Optional Object حاوی اطلاعاتی درباره حمام و توالت در اتاق است.

صفت این است:

  • relation (اختیاری): نشان می دهد که چگونه حمام و توالت در مقابل یکدیگر قرار گرفته اند. مقادیر معتبر together هستند (هر دو حمام و توالت با هم در یک اتاق قرار دارند (مثلاً حمام) درست در کنار یکدیگر) و separate (حمام و توالت هر کدام دارای فضاهای اختصاصی هستند). وقتی اتاق حمام و توالت ندارد، این ویژگی نباید تنظیم شود.

عنصر به صورت اختیاری عناصر فرزند زیر را می گیرد:

  • <Bath> (اختیاری): وجود این عنصر نشان دهنده حمام بودن اتاق است.

    صفات عبارتند از:

    • bathtub (اختیاری): نشان می دهد که حمام دارای وان در حمام است. مقادیر معتبر 0 (یا false ) و 1 (یا true ) هستند.
    • shower (اختیاری): نشان می دهد که حمام دوش دارد. مقادیر معتبر 0 (یا false ) و 1 (یا true ) هستند.
  • <Toilet> (اختیاری): وجود این عنصر نشان می دهد که این اتاق دارای سرویس بهداشتی است.

    صفات عبارتند از:

    • electronic_bidet (اختیاری): نشان می دهد که توالت دارای یک قیمت الکترونیکی است. مقادیر معتبر 0 (یا false ) و 1 (یا true ) هستند.
    • mobility_accessible (اختیاری): نشان می دهد که توالت قابل تحرک است. مقادیر معتبر 0 (یا false ) و 1 (یا true ) هستند.

مثال:

<BathAndToilet relation="separate">
  <Bath bathtub="1" shower="1"/>
  <Toilet
    electronic_bidet="1"
    mobility_accessible="1"/>
</BathAndToilet>
<OpenAirBath> Optional empty زمانی که این اتاق دارای حمام خصوصی در فضای باز است، این عنصر را تامین کنید.
<AirConditioning> Optional empty زمانی که این اتاق دارای تهویه مطبوع است، این عنصر را فراهم کنید.
<Balcony> Optional empty زمانی که این اتاق دارای بالکن یا لانه است، این عنصر را فراهم کنید.
<Views> Optional Object گزینه های معتبر عبارتند از:

<AirportView/>
<BayView/>
<BeachView>/>
<CastleView/>
<CityView/>
<CountrysideView/>
<CourtyardView/>
<DuneView/>
<ForestView/>
<GardenView/>
<GolfCourseView/>
<HarborView/>
<LagoonView/>
<LakeView/>
<MarinaView/>
<MountainView/>
<NatureView/>
<OceanView/>
<ParkView/>
<PartialOceanView/>
<PisteView/>
<PoolView/>
<PyramidView/>
<RiverView/>
<StreetView/>

نمونه ها

JapaneseHotelRoomStyle مقدار پیش فرض ندارد. حذف یک مقدار منجر به خطای XML نمی شود، اما زمانی که کاربر بر اساس سبک اتاق یا تخت فیلتر می کند، فهرست شما در نتایج جستجو نشان داده نمی شود.

دو تخت یک نفره

مثال زیر نحوه استفاده از <RoomFeatures> را نشان می دهد:

<?xml version="1.0" encoding="UTF-8"?>
<Transaction timestamp="2017-07-18T16:20:00-04:00" id="42">
  <PropertyDataSet>
    <Property>1234</Property>
    <RoomData>
      <RoomID>RoomID_1</RoomID>
      <RoomFeatures>
        <JapaneseHotelRoomStyle>western</JapaneseHotelRoomStyle>
        <Beds> <!-- Two single beds -->
          <Bed size="single">
            <Width unit="cm" number="97"/>
            <Length unit="cm" number="195"/>
          </Bed>
          <Bed size="single">
            <Width unit="cm" number="97"/>
            <Length unit="cm" number="195"/>
          </Bed>
        </Beds>
        <Suite/>
        <Capsule/>
        <Roomsharing>private</Roomsharing>
        <Outdoor/>
        <MobilityAccessible/>
        <Smoking>non_smoking</Smoking>
        <BathAndToilet relation="separate">
          <Bath bathtub="1" shower="1"/>
          <Toilet electronic_bidet="1" mobility_accessible="1"/>
        </BathAndToilet>
        <OpenAirBath/>
        <AirConditioning/>
        <Balcony/>
        <Views>
          <LakeView/>
          <MarinaView/>
          <BeachView/>
          <ForestView/>
          <MountainView/>
          <NatureView/>
        </Views>
      </RoomFeatures>
    </RoomData>
  </PropertyDataSet>
</Transaction>

دو تخت دونفره

در زیر نمونه ای از اتاق ژاپنی سبک western با دو تخت double را مشاهده می کنید.

<?xml version="1.0" encoding="UTF-8"?>
<Transaction timestamp="2023-07-23T16:20:00-04:00" id="42">
  <PropertyDataSet>
    <Property>1234</Property>
    <RoomData>
      <RoomID>RoomID_1</RoomID>
      <RoomFeatures>
        <JapaneseHotelRoomStyle>western</JapaneseHotelRoomStyle>
        <Beds> <!-- Two double beds-->
          <Bed size="double"></Bed>
          <Bed size="double"></Bed>
        </Beds>
      </RoomFeatures>
    </RoomData>
  </PropertyDataSet>
</Transaction>


سبک ژاپنی بدون تخت

نمونه زیر یک اتاق بدون تخت به سبک ژاپنی است. اطلاعات تخت برای اتاق به سبک japanese مورد نیاز نیست.

<?xml version="1.0" encoding="UTF-8"?>
<Transaction timestamp="2023-07-23T16:20:00-04:00" id="42">
  <PropertyDataSet>
    <Property>1234</Property>
    <RoomData>
      <RoomID>RoomID_1</RoomID>
      <RoomFeatures>
        <JapaneseHotelRoomStyle>japanese</JapaneseHotelRoomStyle>
      </RoomFeatures>
    </RoomData>
  </PropertyDataSet>
</Transaction>

وسترن ژاپنی با تخت

در زیر نمونه ای از یک اتاق به سبک japanese_western با تخت king است.

<?xml version="1.0" encoding="UTF-8"?>
<Transaction timestamp="2023-07-23T16:20:00-04:00" id="42">
  <PropertyDataSet>
    <Property>1234</Property>
    <RoomData>
      <RoomID>RoomID_1</RoomID>
      <RoomFeatures>
        <JapaneseHotelRoomStyle>japanese_western</JapaneseHotelRoomStyle>
        <Beds>
          <Bed size="king"></Bed>
        </Beds>
      </RoomFeatures>
    </RoomData>
  </PropertyDataSet>
</Transaction>

اگر شریک اطلاعات تعداد تخت‌ها را در اتاق‌های japanese_western ندارد، از این مثال پیروی کنید:

<?xml version="1.0" encoding="UTF-8"?>
<Transaction timestamp="2023-07-23T16:20:00-04:00" id="42">
  <PropertyDataSet>
    <Property>1234</Property>
    <RoomData>
      <RoomID>RoomID_1</RoomID>
      <RoomFeatures>
        <JapaneseHotelRoomStyle>japanese_western</JapaneseHotelRoomStyle>
      </RoomFeatures>
    </RoomData>
  </PropertyDataSet>
</Transaction>

<PackageData>

فراداده مستقل از برنامه سفر را در مورد Room Bundles برای یک ملک تعریف می کند. این عنصر حاوی اطلاعاتی است که با شریک و هتل مرتبط است، اما نه با یک برنامه سفر. هدف در نظر گرفته شده این است که همه داده های غیر سفرنامه را یک بار تعریف کنیم و از داده های سفر به آنها ارجاع دهیم.

عنصر <PackageData> در مکان زیر در سلسله مراتب XML پیام تراکنش ظاهر می شود:

+ <Transaction>
    + <PropertyDataSet>  // Room and package metadata
        + <Property>
        + <RoomData>
        + <PackageData>
    + <Result>           // Pricing and availability
        + <Rates>
        + <RoomBundle>
        + ...

عنصر <PackageData> شبیه <RoomData> است، اما ویژگی‌های نرخ و اصطلاحاتی را توصیف می‌کند که بخشی از توضیحات اتاق فیزیکی نیستند. شما <RoomData> و <PackageData> به صورت ترکیبی برای ارائه جزئیات درباره بسته‌های اتاق و ویژگی‌های امتیازدهی استفاده می‌کنید. برای اتاق های فردی که بخشی از یک بسته نیستند، فقط از <RoomData> استفاده کنید.

شما می توانید هر دو عنصر <RoomData> و <PackageData> را برای یک اتاق یا Room Bundle تعریف کنید. هنگامی که Google آن اتاق یا بسته را در نتایج جستجو نشان می‌دهد، توضیحات هر دو را که با خط فاصله از هم جدا شده‌اند، شامل می‌شود.

اگر یک عنصر <PackageData> را برای یک ویژگی به روز کنید، باید همه عناصر <PackageData> و <RoomData> را برای ویژگی به روز کنید. هر <PropertyDataSet> همه داده‌های مربوط به ویژگی در نظر گرفته می‌شود و هر داده موجود را بازنویسی می‌کند.

برای اطلاعات بیشتر، به فراداده اتاق بسته مراجعه کنید.

نحو

عنصر <PackageData> از نحو زیر استفاده می کند:

<?xml version="1.0" encoding="UTF-8"?>
<Transaction ... >
  <PropertyDataSet ... >
    <PackageData>
      <PackageID>package_ID</PackageID>
      <Name>
        <Text text="package_name" language="language_code"/>
        ...
      </Name>
      <Description>
        <Text text="package_description" language="language_code"/>
        ...
      </Description>
      <Refundable available="[false|true]" refundable_until_days="number_of_days"
        refundable_until_time="time"/>
      <ChargeCurrency>[deposit|hotel|installments|web]</ChargeCurrency>
      <Occupancy>max_number_of_intended_occupants</Occupancy>
      <OccupancyDetails><!-- optional info about the types of guests,
      whether adults or children --></OccupancyDetails>
      <!-- For these next 3 elements, boolean_value can be 0/1 or true/false -->
      <BreakfastIncluded>boolean_value</BreakfastIncluded>
      <InternetIncluded>boolean_value</InternetIncluded>
      <ParkingIncluded>boolean_value</ParkingIncluded>
      <PhotoURL>
        <Caption>
          <Text text="photo_description" language="language_code"/>
          ...
        </Caption>
        <URL>photo_location</URL>
      </PhotoURL>
      ...
      <Meals>
        <Breakfast
          included="[true|false]" buffet="[true|false]"
          in_room="[true|false]" in_private_space="[true|false]"/>
        <Dinner
          included="[true|false]" buffet="[true|false]"
          in_room="[true|false]" in_private_space="[true|false]"/>
      </Meals>
      <CheckinTime>checkin_time</CheckinTime>
      <CheckoutTime>checkout_time</CheckoutTime>
      <MembershipBenefitsIncluded>
        <ProgramName>
          <Text language="en" text="Special Rewards">
        </ProgramName>
        <ProgramLevel>
          <Text language="en" text="Platinum">
        </ProgramLevel>
      </MembershipBenefitsIncluded>
      <OnPropertyCredit>
        <Amount currency="USD">123.45</Amount>
      </OnPropertyCredit>
    </PackageData>
    <!-- a PackageID with a MilesIncluded rate feature -->
    <PackageData>
      <PackageID>room_with_miles</PackageID>
      <Name>
       <Text text="Room with Bundled Miles" language="en">
      </Name>
      <ChargeCurrency>hotel </ChargeCurrency>
      <MilesIncluded>
        <NumberOfMiles>integer</NumberOfMiles>
        <Provider>
          <Text language="en" text="provider-name">
        </Provider>
        <!-- Add Loyalty point information -->
        <LoyaltyCampaignID>campaign_ID</LoyaltyCampaignID>
      </MilesIncluded>
    </PackageData>
    ...
    ...
  </PropertyDataSet>
  ...
</Transaction>

صفات

عنصر <PackageData> هیچ ویژگی ندارد.

عناصر کودک

عنصر <PackageData> دارای عناصر فرزند زیر است:

عنصر کودک مورد نیاز؟ تایپ کنید توضیحات
<BreakfastIncluded> Optional boolean مشخص می کند که آیا این بسته شامل صبحانه با نرخ است یا خیر. مقادیر معتبر 0 (یا false ) و 1 (یا true ) هستند.

ترجیحاً از <Meals> به جای <BreakfastIncluded> استفاده کنید.

<ChargeCurrency> Optional enum زمان و مکان کاربر برای رزرو هزینه پرداخت می کند. این عنصر از نحوی مشابه <ChargeCurrency> در <Result> استفاده می کند.

مقدار پیش فرض web است.

<CheckinTime> Optional Time زودترین زمان ممکن برای ورود زمان باید کمتر از 24:00 به وقت محلی هتل باشد.
<CheckoutTime> Optional Time آخرین زمان ممکن برای خروج به وقت محلی هتل.
<Description> Optional Object توضیحات مفصل در مورد بسته. این عنصر باید حاوی اطلاعاتی باشد که توسط عناصر دیگر یا عنصر <Name> توصیف نشده است. هنگام تعیین توضیحات اتاق نباید از تمام حروف بزرگ استفاده کنید.

عنصر <Description> یک عنصر فرزند به <Text> را می گیرد که دارای دو ویژگی ضروری text و language است. ویژگی text توضیحات است و ویژگی language یک کد زبان دو حرفی را مشخص می کند، همانطور که مثال زیر نشان می دهد:

<Description>
  <Text text="Two breakfast buffet certificates for
    each night of stay." language="en"/>
  <Text text="Deux certificats petit-déjeuner buffet
    pour chaque nuit de séjour." language="fr"/>
</Description>
<InternetIncluded> Optional boolean اگر یک بسته شامل دسترسی به اینترنت بدون هزینه باشد، در حالی که بسته های دیگر شامل این امکانات نمی شوند. این عنصر را برای Room Bundles در هتلی که اینترنت رایگان برای همه اتاق‌ها فراهم می‌کند، تنظیم نکنید. این عنصر برای اینترنت سیمی داخل اتاق یا اینترنت بی‌سیمی که در اتاق‌های مهمان در دسترس نیست اعمال نمی‌شود. مقادیر معتبر 0 (یا false ) و 1 (یا true ) هستند.
<Meals> Optional Object حاوی اطلاعاتی در مورد وعده های غذایی در این بسته است.

عنصر <Meals> دو عنصر اختیاری فرزند را انتخاب می کند، <Breakfast> و <Dinner> که دارای ویژگی های زیر هستند:

  • included (الزامی): اگر نرخ شامل صبحانه/شام باشد، روی 1 (یا true ) تنظیم کنید. در غیر این صورت روی 0 یا false تنظیم کنید.
  • in_room (اختیاری): اگر مهمانان می‌توانند صبحانه/شام را در اتاقی که در آن اقامت می‌کنند می‌خورند، روی 1 (یا true ) تنظیم کنید. در غیر این صورت روی 0 (یا false ) تنظیم کنید.
  • in_private_space (اختیاری): اگر مهمانان می‌توانند صبحانه/شام را در فضایی (به استثنای اتاقی که در آن اقامت می‌کنند) می‌خورند، روی 1 (یا true ) تنظیم کنید، جایی که می‌توانند از تماس با مهمانان دیگر اجتناب کنند. در غیر این صورت روی 0 (یا false ) تنظیم کنید.
  • buffet (اختیاری): اگر صبحانه/شام به صورت بوفه سرو می شود، روی 1 (یا true ) تنظیم کنید. در غیر این صورت روی 0 (یا false ) تنظیم کنید.

ویژگی‌های اختیاری تنها زمانی استفاده می‌شوند که included درست باشد.

برای اینکه فیلترهای وعده غذایی ( no meals ، breakfast only ، dinner only ، و breakfast and dinner ) کار کنند، هر دو <Breakfast> و <Dinner> باید دارای ویژگی included باشند.

<Name> Required string نام بسته. این مقدار باید با آنچه در صفحه فرود هتل ظاهر می شود مطابقت داشته باشد. مقدار این عنصر را روی همه حروف بزرگ تنظیم نکنید.

این عنصر یک عنصر فرزند به <Text> را می گیرد که دارای دو ویژگی text و language است. ویژگی text توضیحات است و ویژگی language یک کد زبان دو حرفی را مشخص می کند، همانطور که مثال زیر نشان می دهد:

<Name>
  <Text text="Bed and Breakfast" language="en"/>
  <Text text="Lit et petit déjeuné" language="fr"/>
</Name>
<Occupancy> Optional integer حداکثر تعداد مهمانانی که یک Room Bundle برای آنها در نظر گرفته شده است . به عنوان مثال، یک سوئیت بزرگ ممکن است بتواند از لحاظ فیزیکی 6 مهمان را در خود جای دهد، اما فقط برای حداکثر 4 مهمان در نظر گرفته شده است.

این مقدار باید کمتر یا مساوی عنصر <Capacity> باشد، که تعداد افرادی است که اتاق می تواند از نظر فیزیکی در خود جای دهد.

مقدار <Occupancy> باید یک عدد صحیح مثبت بین 1 و 99 باشد.

اگر این عنصر را در <RoomBundle> و <PackageData> مشخص کنید، مقدار در <RoomBundle> اولویت دارد.

توجه :

<Occupancy> ممکن است با <OccupancyDetails> همراه باشد، که نوع مهمانان (بزرگسالان یا کودکان) را مشخص می کند. برای نحو و شرح عناصر فرزند به <OccupancyDetails> مراجعه کنید.
<PackageID> Required string

شناسه منحصر به فرد بسته. از این شناسه برای تطبیق داده‌های Room Bundle با بلوک‌های <Result> در به‌روزرسانی‌های قیمت‌گذاری خود استفاده کنید. برای اطلاعات بیشتر، به فراداده اتاق بسته مراجعه کنید.

(همچنین می توانید از این شناسه برای ارجاع به تعریف رایج Room Bundle استفاده شده در یک پیام تراکنش واحد هنگام تعریف داده های Room Bundle به صورت درون خطی استفاده کنید.)

<ParkingIncluded> Optional boolean این که آیا یک بسته اتاق شامل پارکینگ بدون پرداخت هزینه می‌شود، در غیر این صورت پارکینگ در این هتل یک سرویس پولی خواهد بود. برای هتلی که پارکینگ رایگان ارائه می دهد، مقداری برای این عنصر مشخص نکنید.

مقادیر معتبر 0 (یا false ) و 1 (یا true ) هستند. مقدار پیش فرض false است.

<PhotoURL> Optional Object (همانند <PhotoURL> در <RoomData> ، اما برای بسته (مثلاً عکس های غذا).)
<Refundable> Optional Object فهرست کردن نرخ به عنوان کاملاً قابل بازپرداخت یا ارائه یک لغو رایگان را فعال می‌کند. در صورت عدم ارائه، هیچ اطلاعاتی در مورد بازپرداخت نمایش داده نمی شود. خط مشی بازپرداخت در سطح <PackageData> خط مشی بازپرداخت را در سطح <Result> لغو می کند. خط مشی بازپرداخت در سطح <Rates> خط مشی بازپرداخت در سطح <PackageData> را لغو می کند. قیمت قابل استرداد نیز می تواند از طریق گزینه های جایگزین بدون تغییر مستقیم طرح پیام تراکنش شما برای کاربران برجسته شود. درباره این گزینه ها سیاست نرخ های قابل استرداد بیشتر بیاموزید.

مثال زیر عنصر <Refundable> را با مجموعه تمام ویژگی های آن نشان می دهد:

<Refundable available="1" refundable_until_days="7"
refundable_until_time="18:00:00"/>

توجه: توصیه می کنیم همه ویژگی ها را تنظیم کنید. هنگامی که یک یا چند ویژگی تنظیم نشده باشد، یک پیام هشدار وضعیت فید ایجاد می شود.

اگر هیچ مشخصه ای تنظیم نکنید، نرخ به عنوان قابل استرداد نمایش داده نمی شود. صفات عبارتند از:

  • available : (الزامی) روی 1 یا true تنظیم کنید تا مشخص شود آیا نرخ امکان بازپرداخت کامل را دارد یا خیر. در غیر این صورت روی 0 یا false تنظیم کنید.
  • refundable_until_days : (الزامی در صورت available true است) تعداد روزهای قبل از ورود را مشخص می کند که می توان بازپرداخت کامل را درخواست کرد. مقدار refundable_until_days باید یک عدد صحیح بین 0 تا 330 باشد.
  • refundable_until_time : (به شدت توصیه می شود در صورت available true باشد) آخرین زمانی از روز را در زمان محلی هتل مشخص می کند که درخواست بازپرداخت کامل انجام می شود. این را می توان با refundable_until_days ترکیب کرد تا مشخص شود، به عنوان مثال، "بازپرداخت تا ساعت 16:00 دو روز قبل از اعلام حضور در دسترس است". اگر refundable_until_time تنظیم نشده باشد، مقدار پیش‌فرض نیمه‌شب است.

    مقدار این ویژگی از قالب Time استفاده می کند.

هنگام تنظیم ویژگی ها، به موارد زیر توجه کنید:

  • اگر available یا refundable_until_days تنظیم نشده باشد، نرخ به عنوان قابل استرداد نمایش داده نمی شود.
  • اگر available 0 یا false باشد، سایر ویژگی ها نادیده گرفته می شوند. حتی اگر یک یا هر دو ویژگی دیگر تنظیم شده باشد، نرخ به عنوان قابل استرداد نمایش داده نمی شود.
<MembershipBenefits Included> Optional boolean نرخ شامل مزایای وضعیت نخبگان برای مدت اقامت است. شامل پارامترهای زیر است:
  • ProgramName : نام برنامه وضعیت نخبگان
  • ProgramLevel : سطح برنامه. به عنوان مثال: "طلا".
  • NightlyValue (optional) : ارزش شبانه مزایا.
<CarRentalIncluded> Optional boolean نرخ شامل اجاره ماشین رایگان برای مدت اقامت است.
<MilesIncluded> Optional boolean نرخ شامل مایل پرواز مکرر است. پارامترها عبارتند از:
  • NumberOfMiles : تعداد مایل در هر مسیر سفر.
  • Provider : ارائه دهنده مایل پروازهای مکرر.
  • LoyaltyCampaignID : شناسه منحصربه‌فردی که کمپین وفاداری خاصی را که با Google پیکربندی و به‌روزرسانی شده است، مشخص می‌کند. امتیاز وفاداری را به قیمت هتل اضافه می کند.

    برای گنجاندن عنصر <MilesIncluded> ، شناسه کمپین باید در پیکربندی کمپین وفاداری پیکربندی شود. جزئیات خاص در مورد نحوه استفاده Google از امتیازات وفاداری در نتایج توسط پیکربندی کمپین وفاداری تعیین می شود.

    عنصر <MilesIncluded> دارای یک عنصر فرزند است، <NumberOfMiles> که تعداد امتیازهای کسب شده را محاسبه می کند. اگر <NumberOfMiles> تنظیم نشده باشد، امتیازهای کسب شده توسط پیکربندی کمپین وفاداری تعیین می شود.

    <MilesIncluded>
      <LoyaltyCampaignID>my_campaign</LoyaltyCampaignID>
      <NumberOfMiles>1200</NumberOfMiles>
      <Provider>
        <Text language="en" text="United Airlines">
      </Provider>
    </MilesIncluded>
  • توجه: <NumberOfMiles> و <Provider> اختیاری هستند.

<OnPropertyCredit> Optional boolean نرخ شامل اعتبار ملک (F&B، استراحتگاه، اسپا، و غیره) است. پارامتر:
  • Amount : ارزش اعتبار در هر مسیر سفر، به ارز محلی.
<AirportTransportationIncluded> Optional Object نرخ شامل حمل و نقل رایگان به / از فرودگاه نزدیک است. ویژگی direction اختیاری جهت دار بودن حمل و نقل را مشخص می کند. مقادیر معتبر عبارتند از:
    from : حمل و نقل از فرودگاه به ملک ارائه می شود. اگر جهتی مشخص نشده باشد، این مقدار پیش فرض است. to : حمل و نقل از ملک به فرودگاه ارائه می شود. round_trip : حمل و نقل هم به فرودگاه و هم از فرودگاه ارائه می شود.

نمونه ها

بسته اتاق یک نفره

مثال زیر یک اتاق یک نفره را با ظرفیت 2 نفر (یک بزرگسال و یک کودک) تعریف می کند و شامل صبحانه می شود:

<?xml version="1.0" encoding="UTF-8"?>
<Transaction timestamp="2017-07-18T16:20:00-04:00" id="42">
  <PropertyDataSet>
    <Property>1234</Property>
    <PackageData>
      <Occupancy>2</Occupancy>
      <OccupancyDetails>
        <NumAdults>1</NumAdults>
        <Children>
          <Child age="17"/>
        </Children>
      </OccupancyDetails>
      <PackageID>P54321</PackageID>
      <Name>
         <Text text="Breakfast Included" language="en"/>
         <Text text="Avec le petit déjeuner" language="fr"/>
      </Name>
      <Description>
        <Text text="Two certificates for continental
          breakfast will be provided." language="en"/>
        <Text text="Deux certificats pour le petit déjeuner
          continental seront fournis." language="fr"/>
      </Description>
      <BreakfastIncluded>1</BreakfastIncluded>
    </PackageData>
  </PropertyDataSet>
</Transaction>

فراداده اتاق و بسته

مثال زیر فراداده اتاق و بسته را تعریف می کند:

<?xml version="1.0" encoding="UTF-8"?>
<Transaction timestamp="2017-07-18T16:20:00-04:00" id="42">
  <PropertyDataSet>
    <Property>180054</Property>
    <RoomData>
      <RoomID>060773</RoomID>
      <Name>
        <Text text="Single Bed Room" language="en"/>
        <Text text="Chambre single" language="fr"/>
      </Name>
      <Description>
        <Text text="Non-smoking" language="en"/>
        <Text text="Pas de fumiers" language="fr"/>
      </Description>
      <PhotoURL>
        <Caption>
          <Text text="Living area" language="en"/>
          <Text text="Le chambre" language="fr"/>
        </Caption>
        <URL>http://www.foo.com/static/bar/image1234.jpg</URL>
      </PhotoURL>
    </RoomData>
    <PackageData>
      <PackageID>P54321</PackageID>
      <Name>
        <Text text="Breakfast Included" language="en"/>
        <Text text="Avec le petit déjeuner" language="fr"/>
      </Name>
      <Description>
        <Text text="Includes a delightful array of jams and jellies." language="en"/>
        <Text text="Comprend une délicieuse gamme de confitures et gelées." language="fr"/>
      </Description>
      <BreakfastIncluded>1</BreakfastIncluded>
    </PackageData>
  </PropertyDataSet>
</Transaction>

بسته های چند اتاق

مثال زیر فراداده اتاق و بسته را برای چندین اتاق بسته تعریف می کند:

<?xml version="1.0" encoding="UTF-8"?>
<Transaction timestamp="2017-07-18T16:20:00-04:00" id="42">
  <!-- A transaction message with room types result. -->
  <PropertyDataSet>
    <Property>12345</Property>
    <RoomData>
      <RoomID>single</RoomID>
      <Name>
        <Text text="Single room" language="en"/>
        <Text text="Chambre simple" language="fr"/>
      </Name>
      <Description>
        <Text text="A single room" language="en"/>
        <Text text="Le chambre simple" language="fr"/>
      </Description>
      <PhotoURL>
        <Caption>
          <Text text="Living area" language="en"/>
          <Text text="Le chambre" language="fr"/>
        </Caption>
        <URL>http://www.foo.com/static/bar/image1234.jpg</URL>
      </PhotoURL>
      <PhotoURL>
        <URL>http://www.foo.com/static/bar/image1235.jpg</URL>
      </PhotoURL>
      <Capacity>2</Capacity>
    </RoomData>
    <RoomData>
      <RoomID>double</RoomID>
      <Name>
        <Text text="Double room" language="en"/>
        <Text text="Chambre double" language="fr"/>
      </Name>
      <Occupancy>1</Occupancy>
    </RoomData>
    <PackageData>
      <PackageID>refundbreakfast</PackageID>
      <Name>
        <Text text="Refundable Room with Breakfast" language="en"/>
        <Text text="Chambre remboursable avec le petit déjeuner" language="fr"/>
      </Name>
      <Description>
        <Text text="Continental Breakfast" language="en"/>
        <Text text="Petit déjeuner continental" language="fr"/>
      </Description>
      <ChargeCurrency>hotel</ChargeCurrency>
      <Refundable available="1" refundable_until_days="3"/>
      <BreakfastIncluded>1</BreakfastIncluded>
    </PackageData>
    <PackageData>
      <PackageID>prepaid</PackageID>
      <Name>
        <Text text="Nonrefundable" language="en"/>
        <Text text="Non remboursable" language="fr"/>
      </Name>
      <Description>
        <Text text="Blah blah blad" language="en"/>
        <Text text="Le blah blah blad" language="fr"/>
      </Description>
      <Occupancy>2</Occupancy>
      <ChargeCurrency>web</ChargeCurrency>
      <Refundable available="0"/>
    </PackageData>
  </PropertyDataSet>
</Transaction>


بسته اتاق با نرخ

مثال زیر فراداده اتاق و بسته را برای یک بسته اتاق با ویژگی‌های نرخ تعریف می‌کند:

<Transaction timestamp="2010-04-24T20:44:56-04:00" id="TXNID">
  <PropertyDataSet>
    <Property>12345</Property>
    <RoomData>
     ...
    </RoomData>
<!-- definitions of PackageData types including rate features -->
    <PackageData>
      <PackageID>room_with_addl_benefits</PackageID>
      <Name>
        <Text text="Acme Hotels 2017 Promotion Package" language="en"/>
      </Name>
      <ChargeCurrency>hotel</ChargeCurrency>
      <BreakfastIncluded>1</BreakfastIncluded>
      <MembershipBenefitsIncluded>
        <ProgramName>
          <Text language="en" text="Marriott Rewards"/>
        </ProgramName>
        <ProgramLevel>
          <Text language="en" text="Platinum"/>
        </ProgramLevel>
      </MembershipBenefitsIncluded>
      <OnPropertyCredit>
        <Amount currency="USD">123.45</Amount>
      </OnPropertyCredit>
    </PackageData>
    <PackageData>
      <PackageID>room_with_miles</PackageID>
      <Name>
        <Text text="Room with Bundled Miles" language="en"/>
      </Name>
      <ChargeCurrency>hotel</ChargeCurrency>
      <MilesIncluded>
        <NumberOfMiles>1000</NumberOfMiles>
        <LoyaltyCampaignID>my_campaign</LoyaltyCampaignID>
      </MilesIncluded>
      <AirportTransportationIncluded direction="from"/>
    </PackageData>
  </PropertyDataSet>

<!-- The actual list of prices -->
  <Result>
…
  </Result>
</Transaction>

غذا و عکس

مثال زیر فراداده اتاق و بسته را برای وعده‌های غذایی، عکس‌ها و زمان‌های ورود و خروج تعریف می‌کند:

<?xml version="1.0" encoding="UTF-8"?>
<Transaction timestamp="2017-07-18T16:20:00-04:00" id="42">
  <PropertyDataSet>
    <Property>1234</Property>
    <PackageData>
      <PackageID>PackageID_1</PackageID>
      <Name>
        <Text text="Meals Included" language="en"/>
      </Name>
      <PhotoURL>
        <Caption>
          <Text text="Breakfast" language="en"/>
          <Text text="朝食" language="ja"/>
        </Caption>
        <URL>http://example.com/static/bar/image1234.jpg</URL>
      </PhotoURL>
      <Meals>
        <!-- Guests can choose to have breakfast in their room or in another
        space to avoid contact with other guests. -->
        <Breakfast included="1" in_room="1" in_private_space="1"/>
        <Dinner included="1" buffet="1"/>
      </Meals>
      <CheckinTime>15:00</CheckinTime>
      <CheckoutTime>11:00</CheckoutTime>
    </PackageData>
  </PropertyDataSet>
</Transaction>

صبحانه

<?xml version="1.0" encoding="UTF-8"?>
<Transaction timestamp="2017-07-18T16:20:00-04:00" id="42">
  <PropertyDataSet>
    <Property>1234</Property>
    <PackageData>
      <PackageID>PackageID_1</PackageID>
      <Name>
        <Text text="Breakfast Included" language="en"/>
      </Name>
      <PhotoURL>
        <Caption>
          <Text text="Breakfast" language="en"/>
          <Text text="朝食" language="ja"/>
        </Caption>
        <URL>http://example.com/static/bar/image1234.jpg</URL>
      </PhotoURL>
      <Meals>
        <Breakfast included="true"/>
        <!-- Dinner not included needs to be explicitly specified -->
        <Dinner included="false"/>
      </Meals>
      <CheckinTime>15:00</CheckinTime>
      <CheckoutTime>11:00</CheckoutTime>
    </PackageData>
  </PropertyDataSet>
</Transaction>

<Result>

ظرفی برای قیمت‌گذاری و به‌روزرسانی‌های موجود در پیام <Transaction> .

عنصر <Result> در مکان زیر در سلسله مراتب XML پیام تراکنش ظاهر می شود:

+ <Transaction>
    + <PropertyDataSet>  // Room and package metadata
        + <Property>
        + <RoomData>
        + <PackageData>
    + <Result>           // Pricing and availability
        + <Rates>
        + <RoomBundle>
        + ...

برای تنظیم یا به‌روزرسانی قیمت‌های اتاق و تعریف موجودی موجود از <Result> استفاده کنید. موارد تعریف شده در این عنصر معمولاً به ابرداده مستقل از برنامه سفر درباره یک اتاق یا بسته (مانند توضیحات یا مجموعه ای از امکانات) که در <PackageData> و <RoomData> تعریف شده است، ارجاع می دهند.

شما معمولاً پیام‌های تراکنش را با به‌روزرسانی‌های قیمت‌گذاری بسیار مکرر ارسال می‌کنید. اینکه دقیقاً چگونه و چند وقت یکبار این کار را انجام می دهید به حالت تحویل شما بستگی دارد.

همانطور که در Removing Inventory توضیح داده شده است، می توانید از <Result> در پیام تراکنش برای حذف برنامه های سفر استفاده کنید. برای اطلاعات بیشتر درباره استفاده از پیام‌های تراکنش برای به‌روزرسانی قیمت‌ها و در دسترس بودن، افزودن و به‌روزرسانی موجودی .

یک پیام تراکنش می‌تواند هر تعداد عنصر <Result> را در خود داشته باشد، تا زمانی که اندازه پیام از 100 مگابایت تجاوز نکند.

نحو

عنصر <Result> از نحو زیر استفاده می کند:

<?xml version="1.0" encoding="UTF-8"?>
<Transaction ... >
  <Result>
    <!-- Required -->
    <Property>hotel_ID</Property>
    <!-- Required -->
    <Checkin>YYYY-MM-DD</Checkin>
    <!-- Required -->
    <Nights>number_of_nights</Nights>

    <Baserate currency="currency_code">price</Baserate>
    <!-- Only required when <Baserate> contains a real price -->
    <Tax currency="currency_code">tax_amount</Tax>
    <!-- Only required when <Baserate> contains a real price  -->
    <OtherFees currency="currency_code">fee_amount</OtherFees>
    <Refundable available="[false|true]" refundable_until_days="number_of_days"
      refundable_until_time="time"/>

    <RoomID>room_ID</RoomID>
    <PackageID>package_ID</PackageID>
    <ExpirationTime>expiration_time</ExpirationTime>
    <ChargeCurrency>[deposit|hotel|installments|web]</ChargeCurrency>

    <Occupancy>max_number_of_intended_occupants</Occupancy>
    <!-- For Baserate, occupancy value must be greater than or equal to 2.
         If a value is not provided for occupancy, it defaults to 2. -->
    <!-- Child occupancy rates should only be sent through Live pricing
         with context and not through Pull or Changed pricing -->
    <OccupancyDetails>occupancy_info</OccupancyDetails>

    <Rates>...</Rates>

    <RoomBundle>...</RoomBundle>

    <AllowablePointsOfSale>
      <PointOfSale id="landing_page_identifier"/>
      ...
    </AllowablePointsOfSale>

    <MilesIncluded>
      <NumberOfMiles>integer</NumberOfMiles>
      <Provider>
        <Text language="en" text="provider-name">
      </Provider>
      <!-- Add Loyalty point information -->
      <LoyaltyCampaignID>campaign_ID</LoyaltyCampaignID>
    </MilesIncluded>
  </Result>
  ...
  </Transaction>

صفات

عنصر <Result> دارای ویژگی های زیر است:

صفت مورد نیاز؟ تایپ کنید توضیحات
mergeable Optional boolean به‌طور پیش‌فرض، قیمت‌های جدید برای یک هتل خاص و جفت برنامه سفر، قیمت‌های قبلی (منقضی نشده) موجود در حافظه پنهان Google را بازنویسی می‌کند. ویژگی ادغام شدن به شما امکان می دهد بدون حذف اطلاعات قیمت قبلی، قیمت های اضافی را در حافظه پنهان Google ذخیره کنید. جستار قیمت‌گذاری زنده با پاسخ‌های زمینه همیشه این ویژگی را روی true تنظیم می‌کند (صرف نظر از پاسخ پیام تراکنش شما).

عناصر کودک

عنصر <Result> دارای عناصر فرزند زیر است:

عنصر کودک مورد نیاز؟ تایپ کنید توضیحات
<AllowablePointsOfSale> Optional Object یک یا چند صفحه فرود که برای هتل واجد شرایط هستند. صفحه فرود وب سایتی است که می تواند فرآیند رزرو را برای کاربر نهایی انجام دهد. برای گنجاندن صریح صفحه فرود خاص (و حذف سایرین)، یک یا چند عنصر <AllowablePointsOfSale> را که با ویژگی id عنصر <PointOfSale> مطابقت دارند در فایل صفحات فرود اضافه کنید.

اگر این عنصر را وارد نکنید، تمام صفحات فرود تعریف شده در فایل صفحات فرود واجد شرایط استفاده برای رزرو اتاق در نظر گرفته می شوند. برای اطلاعات بیشتر، به نحو فایل صفحات فرود مراجعه کنید.

<Baserate> Optional float

قیمت اتاق برای اقامت. مقدار این عنصر باید منعکس کننده موارد زیر باشد:

  • برای یک اتاق خصوصی، ارزان‌ترین نرخ دو نفره را که ارائه می‌دهید تعیین کنید. اگر ضریب اشغال دو برابر ندارید و در حساب شما نرخ اشغال غیر دو برابر فعال است، اشغال‌های بالاتر در اینجا مجاز است. لطفا برای فعال کردن نرخ های غیر دو نفره با ما تماس بگیرید . نرخ‌های اشغال تک نفره در اینجا مجاز نیستند - آنها باید در <Rates> تنظیم شوند.
  • برای یک اتاق مشترک، خالی بگذارید و از <RoomBundle> استفاده کنید.
  • این مقدار باید کل قیمت پایه برای همه شب ها باشد، نه میانگین نرخ شبانه.

هنگامی که اتاق برای برنامه سفر در دسترس نیست، <Baserate> یا باید حذف شود یا روی -1 تنظیم شود، و <Unavailable> باید به همراه دلایل شناخته شده برای در دسترس نبودن مشخص شود.

برای حذف یک اتاق بسته، از دستورالعمل‌های حذف بسته اتاق استفاده کنید.

<Baserate> نباید دارای علامت های گروه بندی رقمی، مانند کاما (،) یا نقطه (.) باشد. همیشه کسرها را با استفاده از نقطه (.) به عنوان علامت اعشار جدا کنید. برای مثال، 1200.40 دلار را به صورت زیر نشان دهید:

<Baserate currency="USD">1200.40</Baserate>

عنصر <Baserate> ویژگی های اختیاری زیر را می گیرد:

  • all_inclusive : یک Boolean که نشان می دهد آیا این نرخ شامل مالیات و هزینه است یا خیر. به طور کلی، این مقدار را برای کاربران نهایی ایالات متحده و کانادا روی false تنظیم کنید و مقادیر عرضه را برای عناصر <Tax> و <OtherFees> تنظیم کنید. اگر از قیمت‌های فراگیر استفاده می‌کنید، اگر قیمت‌های شما مالیات و هزینه‌های کاربران کانادایی را جدا نکرده باشد، ممکن است واجد شرایط ظاهر شدن در فهرست نباشید.

    قیمت های فراگیر اکنون به کاربران ایالات متحده نشان داده شده است.

    برای همه کاربران نهایی دیگر، معمولاً مالیات و هزینه‌ها را در نرخ پایه لحاظ می‌کنید و مقدار مشخصه all_inclusive را روی true تنظیم می‌کنید. برای اطلاعات بیشتر، به سیاست مالیات ها و هزینه ها مراجعه کنید.

    مقدار پیش فرض false است.

  • currency : کد ارز سه حرفی. به عنوان مثال، USD برای دلار آمریکا.
<ChargeCurrency> Optional enum زمان و مکان کاربر برای رزرو هزینه پرداخت می کند. این عنصر را می توان در یک پیام تراکنش در عنصر <Result> برای قیمت هتل یا بلوک <PackageData> برای یک بسته اتاق استفاده کرد.

مقادیر معتبر عبارتند از:

  • web : در زمان رزرو هزینه از کاربر به صورت آنلاین محاسبه می شود. این مقدار پیش فرض است. صفحه فرود واقعی توسط فایل صفحه فرود تعریف می شود و می تواند تحت تأثیر واحد پول، مکان، زبان یا عوامل دیگر کاربر قرار گیرد.
  • hotel : هنگام ورود به هتل هزینه ای از کاربر دریافت می شود. اگر پرداخت باید همیشه به واحد پول هتل انجام شود، مقدار <ChargeCurrency> را روی hotel تنظیم کنید. صفحه فرود واقعی تحت تأثیر واحد پولی کاربر قرار نمی گیرد.
  • deposit : مقداری از کاربر بلافاصله دریافت می شود و مابقی در زمان بعدی، معمولاً زمانی که کاربر از هتل خارج می شود، هزینه می شود.
  • installments : کسری اولیه از کل مبلغ سررسید از کاربر دریافت می شود و انتظار می رود که به طور معمول موجودی تعیین شده را در یک دوره زمانی ثابت پرداخت کند.

مقدار پیش فرض web است.

<Checkin> Required Date تاریخ ورود برای یک برنامه سفر با استفاده از قالب تاریخ . ترکیب عنصر <Nights> و عنصر <Checkin> یک برنامه سفر را تشکیل می دهند.
Optional string منسوخ شده: یک فیلد سفارشی را تعریف می کند که می توانید از آن برای ارسال داده های اضافی مرتبط با یک هتل استفاده کنید. می توانید حداکثر پنج مقدار سفارشی را با نام عناصر زیر ارسال کنید:
  • <Custom1>
  • <Custom2>
  • <Custom3>
  • <Custom4>
  • <Custom5>

عناصر <Custom> به شما امکان می دهند داده های دلخواه را منتقل کنید. به عنوان مثال، می توانید مقداری را در این فیلد مشخص کنید که سپس توسط فایل صفحات فرود برای ساخت یک URL سفارشی برای یک صفحه فرود استفاده می شود. محدودیت 200 کاراکتر در هر فیلد سفارشی وجود دارد. برای اطلاعات بیشتر، به فایل های صفحه فرود مراجعه کنید. عناصر <Custom> ارائه شده در عنصر <Rate> به عنصر <RoomBundle> به ارث برده نمی شوند. شما باید ویژگی <Custom> را به طور جداگانه در هر <RoomBundle> تعریف کنید.

مهم: اگر می‌خواهید از متغیرهای CUSTOM استفاده کنید، با مدیر حساب فنی (TAM) خود تماس بگیرید.

<ExpirationTime> Optional DateTime تاریخ و زمانی که قیمت در نظر گرفته شده است منقضی شده است (حداقل 3 ساعت).

توصیه می‌کنیم اگر برای ساختار قیمت‌گذاری شما مهم نیست، مهر زمانی انقضا ارائه نکنید.

Google هیچ قیمتی را ارائه نمی دهد که منقضی شده باشد، و هر برنامه سفری که دارای قیمت منقضی شده باشد واجد شرایط درخواست قیمت زنده می شود.

<MilesIncluded> Optional boolean نرخ شامل مایل پرواز مکرر است. پارامترها عبارتند از:
  • NumberOfMiles : تعداد مایل در هر مسیر سفر.
  • Provider : ارائه دهنده مایل پروازهای مکرر.
  • LoyaltyCampaignID : شناسه منحصربه‌فردی که کمپین وفاداری خاصی را که با Google پیکربندی و به‌روزرسانی شده است، مشخص می‌کند. امتیاز وفاداری را به قیمت هتل اضافه می کند.

    برای گنجاندن عنصر <MilesIncluded> ، شناسه کمپین باید در پیکربندی کمپین وفاداری پیکربندی شود. جزئیات خاص در مورد نحوه استفاده Google از امتیازات وفاداری در نتایج توسط پیکربندی کمپین وفاداری تعیین می شود.

    عنصر <MilesIncluded> دارای یک عنصر فرزند است، <NumberOfMiles> که تعداد امتیازهای کسب شده را محاسبه می کند. اگر <NumberOfMiles> تنظیم نشده باشد، امتیازهای کسب شده توسط پیکربندی کمپین وفاداری تعیین می شود.

    <MilesIncluded>
      <LoyaltyCampaignID>my_campaign</LoyaltyCampaignID>
      <NumberOfMiles>1200</NumberOfMiles>
      <Provider>
        <Text language="en" text="United Airlines">
      </Provider>
    </MilesIncluded>
  • توجه: <NumberOfMiles> و <Provider> اختیاری هستند.

<Nights> Required integer The number of nights for an itinerary. The value of the <Nights> element must be a positive integer. The combination of <Nights> and <Checkin> make up an itinerary.
<OtherFees> Optional float Fees other than the base rate and taxes that influence the final price of a room. The <OtherFees> element takes a single required attribute, currency , that defines the three-letter currency code for the fees. For example, USD .

The <OtherFees> element is required if <Baserate> is greater than zero.

<Occupancy> Optional integer Specifies the maximum allowed occupants for this rate. When <Occupancy> appears directly under <Result> , it must specify 2 or more. <Occupancy> may be accompanied by <OccupancyDetails> , which specifies the type of guests (adults or children). If guest types are not specified, they are assumed to be adults. Consult <OccupancyDetails> for syntax and description of child elements. If the <Occupancy> element is not provided, occupancy is defaulted as 2 .

Key Point : Child occupancy rates should only be sent through Live pricing with context and not through Pull or Changed pricing.

Note: Contact your support team to enable the feature to send non-double occupancy prices.

<PackageID> Optional string The unique ID of the package to map it to predefined package data. Also used to populate the PACKAGE-ID landing page variable. For more information, refer to Room Bundle metadata .

It is mandatory to include <RoomBundle> to define <PackageID> and <RoomID> in the <Result> element. However, it is preferred that you specify package and room IDs only within the <RoomBundle> element instead of the <Result> element.

<Property> Required string The ID of a hotel affected by the associated data (price, itinerary, Room Bundle, or metadata). The value of this element must be a string. The value of this element must match the listing <id> that you defined in your Hotel List Feed.
<Rates> Optional <Rates> A container for one or more <Rate> blocks. Each <Rate> in <Rates> defines a different price for the room/itinerary combination.

Use the <Rates> element when there are multiple rates for the same room/itinerary combination or when a rate is not allowed to be specified at the <Result> level. For example, you define multiple rates for conditional rates , private rates , conditional rates in Room Bundles , or different occupancies.

Note: Within <Result> , single-occupancy rates can only be specified in <Rates> . Please contact us to allow non-double occupancy prices.

<Refundable> Optional Object Enables listing a rate as being fully refundable or providing a free cancellation. If not provided, no information about a refund is displayed. A refund policy at the <PackageData> level overrides the refund policy at the <Result> level. A refund policy at the <Rates> level overrides the refund policy at the <PackageData> level. Refundable pricing can also be highlighted to users through alternative options without directly modifying your transaction message schema. Learn more about Refundable rates policy .

The following example shows the <Refundable> element with all of its attributes set:

<Refundable available="1" refundable_until_days="7"
refundable_until_time="18:00:00"/>

Note: We recommend setting all of the attributes. A feed status warning message is generated when one or more attributes are not set.

If you don't set any attributes, the rate does not display as refundable. The attributes are:

  • available : (Required) Set to 1 (or true ) to indicate if the rate allows a full refund; otherwise set to 0 (or false ).
  • refundable_until_days : (Required if available is true ) Specifies the number of days in advance of check-in that a full refund can be requested. The value of refundable_until_days must be an integer between 0 and 330, inclusive.
  • refundable_until_time : (Highly recommended if available is true ) Specifies the latest time of day, in the local time of the hotel, that a full refund request will be honored. This can be combined with refundable_until_days to specify, for example, that "refunds are available until 4:00PM two days before check-in". If refundable_until_time isn't set, the value defaults to midnight.

    The value of this attribute uses the Time format.

When setting the attributes, note the following:

  • If available or refundable_until_days isn't set, the rate does not display as refundable.
  • If available is 0 (or false ), the other attributes are ignored. The rate does not display as refundable even if one or both of the other attributes is set.
<RoomBundle> Optional <RoomBundle> A container for information on priced physical descriptions of a room, any packaging of amenities, and some purchase policy details for the given hotel and itinerary.

In general, use this element to define pricing for the base room and different types of rooms within the same property. While it is possible to define Room Bundle descriptions inline, you should use a separate Transaction message to define that information. Google will store metadata so that you can reference it, rather than repeat it, in all future pricing updates.

<RoomID> Optional string The unique ID of the room to map it to predefined room data. Also used to populate the PARTNER-ROOM-ID landing page variable. For more information, refer to Room Bundle metadata .

It is mandatory to include <RoomBundle> to define <PackageID> and <RoomID> in the <Result> element. However, it is preferred that you specify package and room IDs only within the <RoomBundle> element instead of the <Result> element.

<Tax> Optional float The taxes that are calculated for the final price of a room. The <Tax> element takes a single required attribute, currency , that defines the three-letter currency code for the taxes. For example, USD . The <Tax> element is required if <Baserate> is greater than zero.

If <Baserate> element's "all_inclusive" attribute is explicitly set to true, then setting this value is optional.

<Unavailable> Optional Object Indicates that the itinerary is unavailable for booking. Serves as a container for more detailed reasons why the itinerary was unavailable. One or more of the following unavailability reasons may be nested underneath the <Unavailable> tag:
  • <NoVacancy/> : No more rooms are available for sale for one or more nights of the stay.
  • <MinNightStay value=N/> : The itinerary was below the minimum night stay of N for the stay dates.
  • <MaxNightStay value=N/> : The itinerary was above the maximum night stay of N for the stay dates.
  • <MinAdvancePurchase value=N/> : The itinerary was below the minimum advance booking window of N for the stay dates.
  • <MaxAdvancePurchase value=N/> : The itinerary was above the maximum advance booking window of N for the stay dates.
  • <ClosedToArrival/> : The property does not allow check-in on the itinerary's arrival date.
  • <ClosedToDeparture/> : The property does not allow check-out on the itinerary's departure date.
  • <PropertyClosed first_open="YYYY-MM-DD" first_closed="YYYY-MM-DD"/> : The property is closed for some or all of the stay. Recommended attributes first_open and first_closed specify the first dates greater than or equal to the arrival date for which the property is open or closed, respectively. For a property that closes after the arrival date, first_open should be equal to the arrival date, and first_closed should be the date on which the property closes. For a property that is closed on the arrival date, first_closed should be equal to the arrival date, and first_opened should be the next date on which the property is open.
  • <NotFetched/> : A price for the itinerary was not provided by downstream data sources.
  • <InvalidProperty/> : The requested property identifier was not recognized.
  • <InvalidOccupancy/> : The requested occupancy is not supported by the property.
  • <PriceIssue/> : An issue with the price caused it to not be sent.
  • <InternalError reason=""/> : Some unenumerated error occurred. Optional reason attribute can report the error as text.
  • <OtherRestriction restriction=""/> : The itinerary was not available due to some unenumerated booking restriction. Optional restriction attribute allows reporting the restriction as text.

نمونه ها

Multi-property example

The following example defines one itinerary and its pricing for two properties:

<?xml version="1.0" encoding="UTF-8"?>
<Transaction timestamp="2017-07-23T16:20:00-04:00" id="42">
  <Result>
    <Property>060773</Property>
    <RoomID>RoomType101</RoomID>
    <PackageID>Package101</PackageID>
    <Checkin>2018-06-10</Checkin>
    <Nights>2</Nights>
    <Baserate currency="USD">278.33</Baserate>
    <Tax currency="USD">25.12</Tax>
    <OtherFees currency="USD">2.00</OtherFees>
    <AllowablePointsOfSale>
      <PointOfSale id="site1"/>
    </AllowablePointsOfSale>
  </Result>
  <Result>
    <Property>052213</Property>
    <RoomID>RoomType101</RoomID>
    <PackageID>Package101</PackageID>
    <Checkin>2018-06-10</Checkin>
    <Nights>2</Nights>
    <Baserate currency="USD">299.98</Baserate>
    <Tax currency="USD">26.42</Tax>
    <OtherFees currency="USD">2.00</OtherFees>
    <AllowablePointsOfSale>
      <PointOfSale id="otto"/>
      <PointOfSale id="simon"/>
    </AllowablePointsOfSale>
    <MilesIncluded>
      <NumberOfMiles>1200</NumberOfMiles>
      <Provider>
        <Text language="en" text="United Airlines"/>
      </Provider>
      <LoyaltyCampaignID>my_campaign</LoyaltyCampaignID>
    </MilesIncluded>
  </Result>
</Transaction>

Not shown in this example are details about the room, such as a description, a picture and caption, the room's name, and its capacity.

You can define that information once in a separate Transaction message that Google stores. You can then reference it in all subsequent pricing and inventory updates. For more information, refer to Room Bundle metadata .

Multi-rate example

The following example defines a single itinerary and property with multiple rates for various occupancies. The <Rates> element can be utilized to provide multi-rate pricing for a specific property. The following example is also useful for Vacation Rental (VR) properties:

<?xml version="1.0" encoding="UTF-8"?>
<Transaction timestamp="2020-07-23T16:20:00-04:00" id="42">
  <Result>
    <Property>1234</Property>
    <Checkin>2021-01-13</Checkin>
    <Nights>9</Nights>
    <Baserate currency="USD">3196.1</Baserate>
    <Tax currency="USD">559.49</Tax>
    <OtherFees currency="USD">543.34</OtherFees>
    <Occupancy>2</Occupancy>
    <Rates>
      <Rate>
        <Baserate currency="USD">3196.1</Baserate>
        <Tax currency="USD">559.49</Tax>
        <OtherFees currency="USD">543.34</OtherFees>
        <Occupancy>1</Occupancy>
      </Rate>
      <Rate>
        <Baserate currency="USD">3196.1</Baserate>
        <Tax currency="USD">559.49</Tax>
        <OtherFees currency="USD">543.34</OtherFees>
        <Occupancy>3</Occupancy>
      </Rate>
      <Rate>
        <Baserate currency="USD">3196.1</Baserate>
        <Tax currency="USD">559.49</Tax>
        <OtherFees currency="USD">543.34</OtherFees>
        <Occupancy>4</Occupancy>
      </Rate>
      <Rate>
        <Baserate currency="USD">3196.1</Baserate>
        <Tax currency="USD">559.49</Tax>
        <OtherFees currency="USD">543.34</OtherFees>
        <Occupancy>5</Occupancy>
      </Rate>
      <Rate>
        <Baserate currency="USD">3196.1</Baserate>
        <Tax currency="USD">559.49</Tax>
        <OtherFees currency="USD">543.34</OtherFees>
        <Occupancy>6</Occupancy>
      </Rate>
    </Rates>
  </Result>
</Transaction>

Unavailable example

The following example defines one itinerary whose availability couldn't be retrieved from downstream channels, a second that is both below the minimum night stay and already booked for the specified dates, and a third whose property is closed on the arrival date, but that opens during the course of the stay:

<?xml version="1.0" encoding="UTF-8"?>
<Transaction timestamp="2017-07-23T16:20:00-04:00" id="42">
  <Result>
    <Property>060773</Property>
    <Checkin>2018-06-10</Checkin>
    <Nights>2</Nights>
    <Unavailable>
      <NotFetched/>
    </Unavailable>
  </Result>
  <Result>
    <Property>073313</Property>
    <Checkin>2018-06-10</Checkin>
    <Nights>2</Nights>
    <Unavailable>
      <NoVacancy/>
      <MinNightStay value=3/>
    </Unavailable>
  </Result>
  <Result>
    <Property>052213</Property>
    <Checkin>2018-06-10</Checkin>
    <Nights>10</Nights>
    <Unavailable>
      <PropertyClosed first_open="2018-06-15" first_closed="2018-06-10"/>
    </Unavailable>
  </Result>
</Transaction>

<Rates>

A container for one or more <Rate> blocks. Each <Rate> in <Rates> defines a different price for the room or itinerary combination.

Use the <Rates> element only when there are multiple rates for the same room or itinerary combination. For example, you define multiple rates for conditional rates , private rates , or conditional rates in Room Bundles .

The <Rates> element appears in the following place in the Transaction message XML hierarchy:

+ <Transaction>
    + <PropertyDataSet>  // Room and package metadata
        + <Property>
        + <RoomData>
        + <PackageData>
    + <Result>         // Pricing and availability
        + <Rates>
        + <RoomBundle> (Can also contain <Rates>)
        + ...

Values set in a <Rate> override pricing-related values on the parent <Result> or <RoomBundle> element. If they are not set in <Rate> , they inherit their value from the parent element. Only <AllowablePointsofSale> is inherited to the <RoomBundle> element.

نحو

The <Rates> element uses the following syntax:

<?xml version="1.0" encoding="UTF-8"?>
<Transaction ... >
  <Result>
    <Rates>
      <Rate rate_rule_id="rate_rule_id">
        <Baserate currency="currency_code">price</Baserate>
        <Tax currency="currency_code">tax_amount</Tax>
        <OtherFees currency="currency_code">fee_amount</OtherFees>
        <ExpirationTime>expiration_time</ExpirationTime>
        <Refundable available="[false|true]" refundable_until_days="number_of_days"
        refundable_until_time="time"/>
        <ChargeCurrency>[deposit|hotel|installments|web]</ChargeCurrency>
        <AllowablePointsOfSale>
          <PointOfSale id="landing_page_identifier"/>
        </AllowablePointsOfSale>
        <Occupancy>max_number_of_intended_occupants</Occupancy>
        <OccupancyDetails> <!-- optional info about the types of guests,
      whether adults or children --></OccupancyDetails>
          ...
        <MilesIncluded>
          <NumberOfMiles>integer</NumberOfMiles>
          <Provider>
            <Text language="en" text="provider-name">
          </Provider>
          <LoyaltyCampaignID>campaign_ID</LoyaltyCampaignID>
        </MilesIncluded>
          ...
      </Rate>
      ...
    </Rates>
  </Result>
  ...
</Transaction>

صفات

The <Rates> element has the following attributes:

صفت مورد نیاز؟ توضیحات
rate_rule_id Optional For conditional rates , this ID matches a rate to a definition in your Rate Rule Definition file. The character limit for this field is 40 characters.

Child elements

The <Rates> element has the following child elements:

Child Element مورد نیاز؟ تایپ کنید توضیحات
<AllowablePointsOfSale> Optional Object One or more landing pages that are eligible for the hotel. This element uses the same syntax as the <AllowablePointsOfSale> on <Result> .
<Baserate> Required float The price of the room for the stay. This element uses the same syntax as the <Baserate> on <Result> .

Note: The <Baserate> child element under <Rate> cannot be defined as being unavailable.

<ChargeCurrency> Optional enum When and where the user pays for a booking. This element uses the same syntax as a <ChargeCurrency> in a <Result> .
Optional string Deprecated: Custom fields that you can use to pass additional data associated with a hotel to a landing page. This element uses the same syntax as a <Custom[1‑5]> in a <Result> . There is a limit of 200 characters per custom field. For more information, refer to landing page files . If <Custom> elements are provided in the <Result> element, then they are not inherited in the <RoomBundle> element and should be defined separately for each <RoomBundle> or it can be included in <PackageData> if needed.

Important: Contact your Technical Account Manager (TAM) if you want to use CUSTOM variables.

<ExpirationTime> Optional DateTime The date and time at which the rate is considered expired. This element uses the same syntax as an <ExpirationTime> in a <Result> .
<MilesIncluded> Optional boolean Rate includes frequent flyer miles. Parameters include:
  • NumberOfMiles : Number of miles per itinerary.
  • Provider : Frequent flyer miles provider.
  • LoyaltyCampaignID : A unique ID that identifies the specific Loyalty Campaign that was configured and updated with Google. It adds loyalty points to the hotel price.

    To include <MilesIncluded> element, the campaign ID should be configured in the Loyalty Campaign configuration. The specific details on how Google uses loyalty points in the results are determined by the Loyalty Campaign configuration.

    The <MilesIncluded> element has a child element, <NumberOfMiles> which calculates the number of points earned. If the <NumberOfMiles> is not set, the points earned are determined by the Loyalty Campaign configuration.

    <MilesIncluded>
      <LoyaltyCampaignID>my_campaign</LoyaltyCampaignID>
      <NumberOfMiles>1200</NumberOfMiles>
      <Provider>
        <Text language="en" text="United Airlines">
      </Provider>
    </MilesIncluded>
  • Note: <NumberOfMiles> and <Provider> are optional.

<Occupancy> Optional integer

Specifies the maximum allowed occupants for this rate. If not specified, it is assumed to be the same as parent rate. <Occupancy> may be accompanied by <OccupancyDetails> , which specifies the type of guests (adults or children). Consult <OccupancyDetails> for syntax and description of child elements.

<OtherFees> Required float Fees other than the base rate and taxes that influence the final price of a room. This element uses the same syntax as <OtherFees> in a <Result> .

If <Baserate> element's "all_inclusive" attribute is explicitly set to true, then setting this value is optional.

<Refundable> Optional Object Enables listing a rate as being fully refundable or providing a free cancellation. If not provided, no information about a refund is displayed. A refund policy at the <PackageData> level overrides the refund policy at the <Result> level. A refund policy at the <Rates> level overrides the refund policy at the <PackageData> level. Refundable pricing can also be highlighted to users through alternative options without directly modifying your transaction message schema. Learn more about these options Refundable rates policy .

The following example shows the <Refundable> element with all of its attributes set:

<Refundable available="1" refundable_until_days="7"
refundable_until_time="18:00:00"/>

Note: We recommend setting all of the attributes. A feed status warning message is generated when one or more attributes are not set.

If you don't set any attributes, the rate does not display as refundable. The attributes are:

  • available : (Required) Set to 1 (or true ) to indicate if the rate allows a full refund; otherwise set to 0 (or false ).
  • refundable_until_days : (Required if available is true ) Specifies the number of days in advance of check-in that a full refund can be requested. The value of refundable_until_days must be an integer between 0 and 330, inclusive.
  • refundable_until_time : (Highly recommended if available is true ) Specifies the latest time of day, in the local time of the hotel, that a full refund request will be honored. This can be combined with refundable_until_days to specify, for example, that "refunds are available until 4:00PM two days before check-in". If refundable_until_time isn't set, the value defaults to midnight.

    The value of this attribute uses the Time format.

When setting the attributes, note the following:

  • If available or refundable_until_days isn't set, the rate does not display as refundable.
  • If available is 0 (or false ), the other attributes are ignored. The rate does not display as refundable even if one or both of the other attributes is set.
<Tax> Required float The taxes that are calculated for the final price of a room. This element uses the same syntax as the a <Tax> in a <Result> .

نمونه ها

Base rate and conditional rate

The following example shows a Transaction message that contains a base rate and a conditional rate :

<?xml version="1.0" encoding="UTF-8" ?>
<Transaction timestamp="2023-05-18T16:20:00-04:00" id="42">
  <Result>
    <Property>1234</Property>
    <Checkin>2023-04-10</Checkin>
    <Nights>1</Nights>

    <Baserate currency="USD">200.00</Baserate>
    <Tax currency="USD">20.00</Tax>
    <OtherFees currency="USD">1.00</OtherFees>

    <Rates>
      <!-- The rate_rule_id is required when using conditional rates -->
      <Rate rate_rule_id="mobile">
        <!-- Override base rate and taxes for conditional rates -->
        <Baserate currency="USD">180.00</Baserate>
        <Tax currency="USD">18.00</Tax>
      </Rate>
    </Rates>

  </Result>
</Transaction>

Multiple conditional rates

The following example defines a base rate and multiple conditional rates within a <RoomBundle> :

<?xml version="1.0" encoding="UTF-8" ?>
<Transaction timestamp="2023-05-18T16:20:00-04:00" id="42">
  <Result>
    <Property>1234</Property>
    <Checkin>2023-04-10</Checkin>
    <Nights>2</Nights>
    <!-- When Google receives new room bundle information for an itinerary, all
    previous room bundle pricing is dropped from Google's cache. Thus, if you
    want to delete a specific room bundle from Google's cache, you may do so
    by simply not providing that specific room bundle in subsequent transaction
    messages. -->
    <RoomBundle>
     ...
      <!-- RoomID is required, PackageID is recommended. -->
      <RoomID>5</RoomID>
      <PackageID>ABC</PackageID>
      <!-- Baserate is required. -->
      <Baserate currency="USD">275.00</Baserate>
      <Tax currency="USD">27.50</Tax>
      <OtherFees currency="USD">2.00</OtherFees>

      <!-- RatePlanID is optional and represents the unique identifier for a
      room and package data combination. We strongly recommend using RatePlanID
      as a variable to build your dynamic landing page (formerly Point of Sale)
      URL and it should be within 50 characters in length for optimal
      performance. For details, see Using Variables and Conditions. -->
      <RatePlanID>5-ABC</RatePlanID>

      <!-- Occupancy is mandatory for RoomBundle elements. -->
      <!-- Elements below will get inherited to nested rate elements. -->
      <Occupancy>2</Occupancy>
      <OccupancyDetails>
        <NumAdults>2</NumAdults>
      </OccupancyDetails>
      <InternetIncluded>1</InternetIncluded>

      <!-- Rate rule "mobile" overrides chargeCurrency, "us_or_gb" doesn't. -->
      <ChargeCurrency>web</ChargeCurrency>

      <Rates>
        <Rate rate_rule_id="mobile">
          <Baserate currency="USD">258.33</Baserate>
          <Tax currency="USD">25.83</Tax>
          <OtherFees currency="USD">1.00</OtherFees>
          <!-- The value below overrides ChargeCurrency from roombundle. -->
          <ChargeCurrency>hotel</ChargeCurrency>
        </Rate>
        <Rate rate_rule_id="us_or_gb">
          <Baserate currency="USD">268.33</Baserate>
          <Tax currency="USD">26.83</Tax>
          <OtherFees currency="USD">1.00</OtherFees>
        </Rate>
      </Rates>
    </RoomBundle>
  </Result>
</Transaction>

<RoomBundle>

Defines pricing and availability for Room Bundles as a child of <Result> in a <Transaction> message. Define a separate element for each package or itinerary combination. To define the package and terms of the Room Bundles, use <RoomData> .

The <RoomBundle> element appears in the following place in the Transaction message XML hierarchy:

+ <Transaction>
    + <PropertyDataSet>  // Room and package metadata
        + <Property>
        + <RoomData>
        + <PackageData>
    + <Result>           // Pricing and availability
        + <Rates>
        + <RoomBundle>
        + ...

For more information, refer to Using Room Bundles .

نحو

The <RoomBundle> element uses the following syntax:

<?xml version="1.0" encoding="UTF-8"?>
<Transaction ... >
  <Result>
    ...
    <RoomBundle>
      <!-- Required unless specified inline under <RoomData> -->
      <RoomID>room_ID</RoomID>
      <!-- Required  <PackageData> -->
      <PackageID>package_ID</PackageID>

      <!-- Add Loyalty point information -->
      <MilesIncluded>
        <NumberOfMiles>integer</NumberOfMiles>
        <Provider>
          <Text language="en" text="provider-name">
        </Provider>
        <LoyaltyCampaignID>campaign_ID</LoyaltyCampaignID>>
      </MilesIncluded>

      <!-- Required -->
      <Baserate currency="currency_code">price</Baserate>
      <!-- Required -->
      <Tax currency="currency_code">taxes</Tax>
      <!-- Required -->
      <OtherFees currency="currency_code">other_fees</OtherFees>

      <Refundable available="[false|true]" refundable_until_days="number_of_days"
        refundable_until_time="time"/>
      <!-- Required -->
      <ChargeCurrency>[deposit|hotel|installments|web]</ChargeCurrency>
      <Occupancy>max_number_of_intended_occupants</Occupancy>
      <OccupancyDetails> <!-- optional info about the types of guests,
      whether adults or children --></OccupancyDetails>

      <BreakfastIncluded>boolean_value</BreakfastIncluded>
      <InternetIncluded>boolean_value</InternetIncluded>
      <ParkingIncluded>boolean_value</ParkingIncluded>

      <RatePlanID>rate_plan_ID</RatePlanID>

      <Rates>...</Rates>

    </RoomBundle>
    ...
  </Result>
</Transaction>

صفات

The <RoomBundle> element has no attributes.

Child elements

The <RoomBundle> element has the following child elements:

Child Element مورد نیاز؟ تایپ کنید توضیحات
<Baserate> Required float Defines the price of the Room Bundle for the stay. This element uses the same syntax as <Baserate> in <Result> , with the following exception:
  • When the room is unavailable for the itinerary, remove the <RoomBundle> element to indicate that a room is no longer in inventory. For more information, refer to Removing a Room Bundle .
<BreakfastIncluded> Optional boolean Specifies whether this Room Bundle includes breakfast with the rate.
<ChargeCurrency> Optional enum When and where the user pays for a booking. This element uses the same syntax as <ChargeCurrency> in a <Result> .

The default value is web .

Optional string Deprecated: Custom fields for passing additional data to the landing pages for the Room Bundle. These elements use the same syntax as <Custom[1-5]> in <Result> . There is a limit of 200 characters per custom field. For more information, refer to landing page files . Custom variables are listed only when you send the prices in the Transaction message. If <Custom> elements are provided in the <Result> element, then they are not inherited in the <RoomBundle> element and should be defined separately for each <RoomBundle> or it can be included in <PackageData> if needed.

Important: Contact your Technical Account Manager (TAM) if you want to use CUSTOM variables.

<InternetIncluded> Optional boolean If a Room Bundle includes internet access at no charge, while other bundles wouldn't include that amenity. Don't set this element for Room Bundles in a hotel that provides free internet to all rooms. This element does not apply to in-room wired internet or wireless internet that is not available in guest rooms.
<MilesIncluded> Optional boolean Rate includes frequent flyer miles. Parameters include:
  • NumberOfMiles : Number of miles per itinerary.
  • Provider : Frequent flyer miles provider.
  • LoyaltyCampaignID : A unique ID that identifies the specific Loyalty Campaign that was configured and updated with Google. It adds loyalty points to the hotel price.

    To include <MilesIncluded> campaign ID should be configured in the Loyalty Campaign configuration. The specific details on how Google uses loyalty points in the results are determined by the Loyalty Campaign configuration.

    The <MilesIncluded> element has a child element, <NumberOfMiles> which calculates the number of points earned. If the <NumberOfMiles> is not set, the points earned are determined by the Loyalty Campaign configuration.

    <MilesIncluded>
      <LoyaltyCampaignID>my_campaign</LoyaltyCampaignID>
      <NumberOfMiles>1200</NumberOfMiles>
      <Provider>
        <Text language="en" text="United Airlines">
      </Provider>
    </MilesIncluded>
  • Note: <NumberOfMiles> and <Provider> are optional.

<Occupancy> Required integer Specifies the maximum allowed occupants for this rate. For example, a large suite might be able to physically accommodate 6 guests, but the "Honeymoon Package" allows 2 guests only.

This value must be less than or equal to the <Capacity> , which is the number of people that the room can physically accommodate.

When defining occupancy in your landing page URL, use the NUM-ADULTS and NUM-CHILDREN variables, as described in Using Variables and Conditions . The default value is 2 adults and 0 children.

The value of <Occupancy> must be a positive integer between 1 and 99, inclusive.

یادداشت ها :

  • <Occupancy> for <RoomBundle> is strongly recommended so flagged as required and if omitted will throw a 1097 error.
  • <Occupancy> comes from the data object in this order: <RoomBundle> , <PackageData> , and then = <RoomData> . If there is no value present in any of these, the value defaults to 2.
  • <Occupancy> may be accompanied by <OccupancyDetails> , which specifies the type of guests (adults or children). If guest types are not specified, they are assumed to be adults. Consult <OccupancyDetails> for syntax and description of child elements.
  • When you set <Occupancy> in both <RoomBundle> and <PackageData> , the value in <RoomBundle> takes precedence.
<OtherFees> Required float Fees other than the base rate and taxes that influence the final price of a room. The <OtherFees> element takes a single required attribute, currency , that defines the three-letter currency code for the fees. For example, use USD for US dollars.
<PackageID> Optional (recommended) string The unique ID for the package data. Use this ID to match the Room Bundle data with what was sent in <PackageData> . For more information, refer to Room Bundle metadata . (You can also use this ID to reference a common Room Bundle definition used in a single Transaction message when defining Room Bundle data inline.)
<ParkingIncluded> Optional boolean Whether a Room Bundle includes parking at no charge, where parking would otherwise be a paid service at this hotel. Don't specify a value for this element for a hotel that offers free parking.

Valid values are 0 (or false ) and 1 (or true ). مقدار پیش فرض false است.

<RatePlanID> Optional string The Rate Plan ID represents the unique identifier for a room and package combination. For example, given a <RoomID> value of 5 and a <PackageID> value of ABC, you could use a value of 5-ABC for <RatePlanID> . We strongly recommend using RatePlanID as a variable to build your dynamic landing page (formerly Point of Sale) URL.

Note: RatePlanID should be within 50 characters in length for optimal performance.

For more information, refer to Using Variables and Conditions .

<Rates> Optional <Rates> Rates that override the defaults for this Room Bundle. This element uses the same syntax as <Rates> in <Result> .
<Refundable> Optional Object Enables listing a rate as being fully refundable or providing a free cancellation. If not provided, no information about a refund is displayed. A refund policy at the <PackageData> level overrides the refund policy at the <Result> level. A refund policy at the <Rates> level overrides the refund policy at the <PackageData> level. Refundable pricing can also be highlighted to users through alternative options without directly modifying your transaction message schema. Learn more about these options Refundable rates policy .

The following example shows the <Refundable> element with all of its attributes set:

<Refundable available="1" refundable_until_days="7"
refundable_until_time="18:00:00"/>

Note: We recommend setting all of the attributes. A feed status warning message is generated when one or more attributes are not set.

If you don't set any attributes, the rate does not display as refundable. The attributes are:

  • available : (Required) Set to 1 (or true ) to indicate if the rate allows a full refund; otherwise set to 0 (or false ).
  • refundable_until_days : (Required if available is true ) Specifies the number of days in advance of check-in that a full refund can be requested. The value of refundable_until_days must be an integer between 0 and 330, inclusive.
  • refundable_until_time : (Highly recommended if available is true ) Specifies the latest time of day, in the local time of the hotel, that a full refund request will be honored. This can be combined with refundable_until_days to specify, for example, that "refunds are available until 4:00PM two days before check-in". If refundable_until_time isn't set, the value defaults to midnight.

    The value of this attribute uses the Time format.

When setting the attributes, note the following:

  • If available or refundable_until_days isn't set, the rate does not display as refundable.
  • If available is 0 (or false ), the other attributes are ignored. The rate does not display as refundable even if one or both of the other attributes is set.
<RoomID> Required string The unique ID for the room data. Use this ID to match the Room Bundle data with what you sent in <RoomData> . For more information, refer to Room Bundle metadata . (You can also use this ID to reference a common room definition in a single Transaction message when defining room data inline.)
<Tax> Required float The taxes that are calculated for the final price of a room. The <Tax> element takes a single required attribute, currency , that defines the three-letter currency code for the taxes. For example, use USD for US dollars.

نمونه ها

Single occupancy bundle

The following example defines a response with a single occupancy bundle. When a user selects 1 in the Occupancy picker, Google displays the lowest eligible price regardless of occupancy.

If a single occupancy price is not available, then Google will show the lowest double-occupancy price. Note that single occupancy prices are not live queried if double-occupancy or more prices are cached for an itinerary.

This example references predefined room and package metadata with the <RoomID> and <PackageID> elements. Use the <RoomData> and <PackageData> elements to define that information.

<!-- Efficient method of defining Room Bundles-->
<!----- Occupancy of 1 example ----->

<Transaction timestamp="2017-07-18T16:20:00-04:00" id="12345678">
  <!-- Part1: Define RoomData and PackageData in PropertyDataSet -->
  <!-- Note:  Once defined it does not have to be repeated for future
              Transaction Messages.
              PropertyDataSets can also be defined and sent in their own
              Transaction Message separately from pricing. Google can be
              configured to pull just PropertyDataSets once per day
              (or on a predefined frequency). -->
  <PropertyDataSet>
    <Property>180054</Property>
    <!-- Can be reused by multiple Room Bundles -->
    <RoomData>
      <RoomID>060773</RoomID>
      <Name>
        <Text text="Single Queen Room - Non-Smoking" language="en"/>
        <Text text="Chambre de la Roi Premium - Pas de Fumeurs" language="fr"/>
      </Name>
      <!-- Room can accommodate up to 4, but package data specifies occupancy
           between 1 to 4 -->
      <Capacity>4</Capacity>
    </RoomData>
    <RoomData>
      <RoomID>436233</RoomID>
      <Name>
        <Text text="Premium King Room - Non-Smoking" language="en"/>
        <Text text="Chambre de le Roi Premium - Pas de Fumeurs" language="fr"/>
      </Name>
      <Capacity>4</Capacity>
    </RoomData>
    <!-- Can be reused by multiple Room Bundles -->
    <PackageData>
      <PackageID>P11111</PackageID>
      <Occupancy>1</Occupancy>
      <ChargeCurrency>web</ChargeCurrency>
      <Refundable available="1" refundable_until_days="7"
           refundable_until_time="18:00:00"/>
      <ParkingIncluded>1</ParkingIncluded>
      <InternetIncluded>1</InternetIncluded>
    </PackageData>
    <PackageData>
      <PackageID>P54321</PackageID>
      <Occupancy>2</Occupancy>
      <ChargeCurrency>web</ChargeCurrency>
      <Refundable available="1" refundable_until_days="7"
           refundable_until_time="18:00:00"/>
      <ParkingIncluded>1</ParkingIncluded>
      <InternetIncluded>1</InternetIncluded>
    </PackageData>
    <PackageData>
      <PackageID>P12345</PackageID>
      <Occupancy>4</Occupancy>
      <ChargeCurrency>web</ChargeCurrency>
      <Refundable available="1" refundable_until_days="1"
           refundable_until_time="18:00:00"/>
      <ParkingIncluded>1</ParkingIncluded>
      <InternetIncluded>1</InternetIncluded>
    </PackageData>
  </PropertyDataSet>

    <!-- Efficient method of defining Room Bundles -->
    <!-- Part 2: Reference RoomData and PackageData through ID -->
  <Result>
    <!-- Single occupancy pricing will be specified in a room bundle below -->
    <Property>180054</Property>
    <Checkin>2017-10-07</Checkin>
    <Nights>2</Nights>
    <!-- Base Room Bundle -->
    <RoomBundle>
      <RoomID>060773</RoomID>
      <PackageID>P54321</PackageID>
      <Baserate currency="USD">199.99</Baserate>
      <Tax currency="USD">25.12</Tax>
      <OtherFees currency="USD">2.00</OtherFees>
      <RatePlanID>060773-P54321</RatePlanID>
    </RoomBundle>
    <RoomBundle>
      <RoomID>060773</RoomID>
      <PackageID>P11111</PackageID>
      <!-- Price for 1 ("occupancy") is the lowest price and will be
           displayed -->
      <Baserate currency="USD">174.99</Baserate>
      <Tax currency="USD">22.08</Tax>
      <OtherFees currency="USD">2.00</OtherFees>
      <RatePlanID>060773-P11111</RatePlanID>
    </RoomBundle>
    <!-- Premium Room Bundle -->
    <RoomBundle>
      <RoomID>436233</RoomID>
      <PackageID>P12345</PackageID>
      <!-- Price for 4 ("occupancy"), any eligible room bundle with 1 or more
           occupancy will be displayed-->
      <Baserate currency="USD">298.88</Baserate>
      <Tax currency="USD">42.12</Tax>
      <OtherFees currency="USD">10.00</OtherFees>
      <RatePlanID>436233-P12345</RatePlanID>
    </RoomBundle>
    <!-- ..Continue providing all available RoomBundle rates under matched
         property for 1 or more occupancies..-->
  </Result>
</Transaction>


Two or more occupancies

The following example defines a response containing two or more occupancies.

This example references predefined room and package metadata with the <RoomID> and <PackageID> elements. Use the <RoomData> and <PackageData> elements to define that information.

<!-- Efficient method of defining Room Bundles-->
<!----- Occupancy of 3 example ----->

<Transaction timestamp="2017-07-18T16:20:00-04:00" id="12345678">
  <!-- Efficient method of defining Room Bundles-->
  <!-- Part1: Define RoomData and PackageData in PropertyDataSet -->
  <PropertyDataSet>
    <Property>180054</Property>
    <!-- Can be reused by multiple Room Bundles -->
    <RoomData>
      <RoomID>060773</RoomID>
      <Name>
        <Text text="Single Queen Room - Non-Smoking" language="en"/>
        <Text text="Chambre de la Roi Premium - Pas de Fumeurs" language="fr"/>
      </Name>
      <!-- Room can accommodate up to 4, but package data specifies occupancy
           between 1 to 4 -->
      <Capacity>4</Capacity>
    </RoomData>
    <RoomData>
      <RoomID>436233</RoomID>
      <Name>
        <Text text="Premium King Room - Non-Smoking" language="en"/>
        <Text text="Chambre de le Roi Premium - Pas de Fumeurs" language="fr"/>
      </Name>
      <Capacity>4</Capacity>
    </RoomData>
    <!-- Can be reused by multiple Room Bundles -->
    <PackageData>
      <PackageID>P33333</PackageID>
      <Occupancy>3</Occupancy>
      <ChargeCurrency>web</ChargeCurrency>
      <Refundable available="1" refundable_until_days="7"
           refundable_until_time="18:00:00"/>
      <ParkingIncluded>1</ParkingIncluded>
      <InternetIncluded>1</InternetIncluded>
    </PackageData>
    <PackageData>
      <PackageID>P12345</PackageID>
      <Occupancy>4</Occupancy>
      <ChargeCurrency>web</ChargeCurrency>
      <Refundable available="1" refundable_until_days="1"
           refundable_until_time="18:00:00"/>
      <ParkingIncluded>1</ParkingIncluded>
      <InternetIncluded>1</InternetIncluded>
    </PackageData>
  </PropertyDataSet>

  <Result>
    <Property>180054</Property>
    <Checkin>2017-10-07</Checkin>
    <Nights>2</Nights>
    <!-- Efficient method of defining Room Bundles -->
    <!-- Part 2: Reference RoomData and PackageData through ID -->
    <!-- Base Room Bundle -->
    <RoomBundle>
      <!-- Baserate above and attributes must match atleast one room bundle
           below -->
      <RoomID>060773</RoomID>
      <PackageID>P33333</PackageID>
      <Baserate currency="USD">499.99</Baserate>
      <Tax currency="USD">55.12</Tax>
      <OtherFees currency="USD">22.00</OtherFees>
    </RoomBundle>
    <!-- Premium Room Bundle -->
    <RoomBundle>
      <RoomID>436233</RoomID>
      <PackageID>P12345</PackageID>
      <!-- Lowest price for 3 ("occupancy"), shown below, will be displayed -->
      <Baserate currency="USD">598.88</Baserate>
      <Tax currency="USD">62.12</Tax>
      <OtherFees currency="USD">30.00</OtherFees>
    </RoomBundle>
    <!-- ..Continue providing all available RoomBundle rates under matched
         property for 2 or more occupancies..-->
  </Result>
</Transaction>


Multiple room bundles

The following example sets Occupancy in multiple Room bundles to demonstrate possible hostel room pricing.

<?xml version="1.0" encoding="UTF-8"?>
<Transaction ... >
  <Result>
    ...
    <!-- Suite Room Bundle -->
    <RoomBundle>
      <RoomID>suite1</RoomID>
      <PackageID>standard</PackageID>
      <Occupancy>2</Occupancy>
      <!-- Price for room -->
      <Baserate currency="USD">80.00</Baserate>
      <Tax currency="USD">5.12</Tax>
      <OtherFees currency="USD">2.00</OtherFees>
      <RoomData>
        <Name>
          <Text text="Suite for 2" language="en"/>
        </Name>
      </RoomData>
    </RoomBundle>

    <!-- Small Dorm Room Bundle -->
    <RoomBundle>
      <RoomID>small_dorm</RoomID>
      <PackageID>economy</PackageID>
      <Occupancy>1</Occupancy>
      <!-- Price per bed -->
      <Baserate currency="USD">35.00</Baserate>
      <Tax currency="USD">3.50</Tax>
      <OtherFees currency="USD">2.00</OtherFees>
      <RoomData>
        <Name>
          <Text text="1 bed in small dorm" language="en"/>
        </Name>
      </RoomData>
    </RoomBundle>

    <!-- Large Dorm Room Bundle -->
    <RoomBundle>
      <RoomID>large_dorm</RoomID>
      <PackageID>economy</PackageID>
      <Occupancy>1</Occupancy>
      <!-- Price per bed -->
      <Baserate currency="USD">20.00</Baserate>
      <Tax currency="USD">2.50</Tax>
      <OtherFees currency="USD">2.00</OtherFees>
      <RoomData>
        <Name>
          <Text text="1 bed in large dorm" language="en"/>
        </Name>
      </RoomData>
    </RoomBundle>
    ...
  </Result>
</Transaction>

Multiple Conditional rates

The following example defines a base rate and multiple conditional rates within a <RoomBundle> :

<?xml version="1.0" encoding="UTF-8" ?>
<Transaction timestamp="2023-05-18T16:20:00-04:00" id="42">
  <Result>
    <Property>1234</Property>
    <Checkin>2023-04-10</Checkin>
    <Nights>2</Nights>
    <!-- When Google receives new room bundle information for an itinerary, all
    previous room bundle pricing is dropped from Google's cache. Thus, if you
    want to delete a specific room bundle from Google's cache, you may do so
    by simply not providing that specific room bundle in subsequent transaction
    messages. -->
    <RoomBundle>
     ...
      <!-- RoomID is required, PackageID is recommended. -->
      <RoomID>5</RoomID>
      <PackageID>ABC</PackageID>
      <!-- Baserate is required. -->
      <Baserate currency="USD">275.00</Baserate>
      <Tax currency="USD">27.50</Tax>
      <OtherFees currency="USD">2.00</OtherFees>

      <!-- RatePlanID is optional and represents the unique identifier for a
      room and package data combination. We strongly recommend using RatePlanID
      as a variable to build your dynamic landing page (formerly Point of Sale)
      URL and it should be within 50 characters in length for optimal
      performance. For details, see Using Variables and Conditions. -->
      <RatePlanID>5-ABC</RatePlanID>

      <!-- Occupancy is mandatory for RoomBundle elements. -->
      <!-- Elements below will get inherited to nested rate elements. -->
      <Occupancy>2</Occupancy>
      <OccupancyDetails>
        <NumAdults>2</NumAdults>
      </OccupancyDetails>
      <InternetIncluded>1</InternetIncluded>

      <!-- Rate rule "mobile" overrides chargeCurrency, "us_or_gb" doesn't. -->
      <ChargeCurrency>web</ChargeCurrency>

      <Rates>
        <Rate rate_rule_id="mobile">
          <Baserate currency="USD">258.33</Baserate>
          <Tax currency="USD">25.83</Tax>
          <OtherFees currency="USD">1.00</OtherFees>
          <!-- The value below overrides ChargeCurrency from roombundle. -->
          <ChargeCurrency>hotel</ChargeCurrency>
        </Rate>
        <Rate rate_rule_id="us_or_gb">
          <Baserate currency="USD">268.33</Baserate>
          <Tax currency="USD">26.83</Tax>
          <OtherFees currency="USD">1.00</OtherFees>
        </Rate>
      </Rates>
    </RoomBundle>
  </Result>
</Transaction>

<OccupancyDetails>

<Occupancy> in a transaction message specifies the maximum number of guests for a room or package. <OccupancyDetails> can contain additional information such as the number and type of guests (adults or children).

When <Occupancy> and <OccupancyDetails> appear within the <Rates> element of <Result> or <RoomBundle> , it means that the rate is constrained by the occupancy details.

If you include <OccupancyDetails> in a <RoomBundle> , along with a nested <Rate> element you can't send a basic <Occupancy> within the <Rate> ; instead one of the following options is recommended:

  • Omit occupancy from <Rate> : In this case, the <Rate> inherits the <OccupancyDetails> directly from the <RoomBundle>

یا،

  • Duplicate <OccupancyDetails> : In this case, send additional identical <OccupancyDetails> in both the <RoomBundle> and the nested <Rate> element

نحو

When <OccupancyDetails> appears, it is always preceded by <Occupancy> . Note the following syntax:

<?xml version="1.0" encoding="UTF-8"?>
<Transaction ... >
  <Result>
  ...
    <Occupancy>max_number_of_intended_occupants</Occupancy>
    <OccupancyDetails>
      <NumAdults>number_of_adults</NumAdults>
      <Children>
        <Child age=age_of_one_child_guest/>
        <Child age=age_of_one_child_guest/>
      </Children>
    </OccupancyDetails>
  </Result>
</Transaction>

Child elements

The <OccupancyDetails> element has the following child elements:

Child Element مورد نیاز؟ تایپ کنید توضیحات
<NumAdults> Required integer The number of adult guests. Min:1, Max:20.
<Children> Optional Object A container for one or more <Child> elements.
<Child age> Optional integer The maximum age for this Child—for example, <Child age="17"> .

نمونه ها

The following examples show how <OccupancyDetails> may appear within <Results> , <RoomBundle> , or the <Rates> child element.

Result response

The following example defines one itinerary and its pricing for one property in response to a Live Pricing Query where the user specified the number and types of guests. Here, the <OccupancyDetails> -- 2 adults and one child -- are returned in <Result> .

<?xml version="1.0" encoding="UTF-8"?>
<Transaction timestamp="2017-07-23T16:20:00-04:00" id="42">
  <Result>
    <Property>060773</Property>
    <RoomID>RoomType101</RoomID>
    <PackageID>Package101</PackageID>
    <Checkin>2018-06-10</Checkin>
    <Nights>2</Nights>
    <Baserate currency="USD">278.33</Baserate>
    <Tax currency="USD">25.12</Tax>
    <OtherFees currency="USD">2.00</OtherFees>
    <AllowablePointsOfSale>
      <PointOfSale id="site1"/>
    </AllowablePointsOfSale>
    <Occupancy>3</Occupancy>
    <OccupancyDetails>
      <NumAdults>2</NumAdults>
      <Children>
        <Child age="17"/>
      </Children>
    </OccupancyDetails>
  </Result>
</Transaction>

Rates response

The following example defines one itinerary and its pricing for 1 adult and 1 child. Here, the <OccupancyDetails> are returned in the <Rates> element of <Result> .

<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<Transaction id="Wtdj8QoQIWcAAbaTGlIAAAC4" timestamp="2018-04-18T11:27:45-04:00">
  <Result>
    <Property>8251</Property>
    <Checkin>2018-06-20</Checkin>
    <Nights>1</Nights>
    <Baserate currency="USD">62.18</Baserate>
    <Tax currency="USD">2.45</Tax>
    <OtherFees currency="USD">0.00</OtherFees>
    <Rates>
      <Rate rate_rule_id="rule-951">
        <Occupancy>2</Occupancy>
        <OccupancyDetails>
          <NumAdults>1</NumAdults>
          <Children>
            <Child age="17"/>
          </Children>
        </OccupancyDetails>
        <Baserate currency="USD">42.61</Baserate>
        <Tax currency="USD">5.70</Tax>
        <OtherFees currency="USD">0.00</OtherFees>
        <AllowablePointsOfSale>
          <PointOfSale id="yourhotelpartnersite.com"/>
        </AllowablePointsOfSale>
      </Rate>
    </Rates>
  </Result>
</Transaction>

Room bundle

The following example defines an occupancy of 2 adults and 1 child for two nights, with a refundable rate. Here, the <OccupancyDetails> appear inside <RoomBundle>

<?xml version="1.0" encoding="UTF-8"?>
<Transaction timestamp="2017-07-23T16:20:00-04:00" id="42">
  <Result>
    <Property>6781291</Property>
    <Checkin>2017-08-05</Checkin>
    <Nights>2</Nights>
    ...
    <RoomBundle>
      <RoomID>10291</RoomID>
      <RatePlanID>564739</RatePlanID>
      <PackageID>564739</PackageID>
      <Occupancy>3</Occupancy>
      <OccupancyDetails>
        <NumAdults>2</NumAdults>
        <Children>
          <Child age="17"/>
        </Children>
      </OccupancyDetails>
      <ChargeCurrency>web</ChargeCurrency>
      <Refundable available="true" refundable_until_days="1" refundable_until_time="23:59:00" />
      <Baserate currency="USD">185.34</Baserate>
      <Tax currency="USD">37.06</Tax>
      <OtherFees currency="USD">2.22</OtherFees>
    </RoomBundle>
  </Result>
</Transaction>

Multiple room bundles

The following example defines multiple <RoomBundle> rates that are restricted to an occupancy of 2 adults and 2 children. Here, the <OccupancyDetails> appear in the <Rates> element of <RoomBundle> .

<?xml version="1.0" encoding="UTF-8"?>
<Transaction timestamp="2017-07-18T16:20:00-04:00" id="42">
  <Result>
    <Property>1234</Property>
    <Checkin>2018-06-10</Checkin>
    <Nights>2</Nights>
    <Baserate currency="USD">275.00</Baserate>
    <Tax currency="USD">27.50</Tax>
    <OtherFees currency="USD">0</OtherFees>
    <RoomBundle>
      <RoomID>5</RoomID>
      <PackageID>STD</PackageID>
      <Baserate currency="USD">275.00</Baserate>
      <Tax currency="USD">27.50</Tax>
      <OtherFees currency="USD">0</OtherFees>
      <InternetIncluded>1</InternetIncluded>
      <ChargeCurrency>web</ChargeCurrency>
      <Occupancy>4</Occupancy>
      <OccupancyDetails>
          <NumAdults>2</NumAdults>
          <Children>
              <Child age="17"/>
              <Child age="17"/>
          </Children>
      </OccupancyDetails>
      <Rates>
        <Rate rate_rule_id="mobile">
          <Baserate currency="USD">258.33</Baserate>
          <Tax currency="USD">25.83</Tax>
          <OtherFees currency="USD">1.00</OtherFees>
          <ChargeCurrency>hotel</ChargeCurrency>
        </Rate>
        <Rate rate_rule_id="us_or_gb">
          <Baserate currency="USD">268.33</Baserate>
          <Tax currency="USD">26.83</Tax>
          <OtherFees currency="USD">1.00</OtherFees>
        </Rate>
      </Rates>
    </RoomBundle>
  </Result>
</Transaction>