料金ルール XML ファイルは、限定価格と非公開レートを配信するためのルールを定義します。料金ルール XML ファイルを追加または編集するには、Hotel Center の [料金ルール] ページを使用します。限定価格と非公開レートについて詳しくは、限定価格と非公開レートをご覧ください。
各料金ルールには id
が必要です。これは、トランザクション メッセージの <Rate>
で参照できます。料金ルール ID を参照する <Rate>
は、料金ルールで定義された条件の下でのみユーザーに配信されます。料金ルール ID は、ランディング ページ URL の変数を使用して参照することもできます。
<RateRuleSettings>
料金ルール XML ファイルのルート要素。<RateRuleSettings>
(旧称 <PrivateRates>
)要素には次のものが含まれます。
限定価格と非公開レートで照合する条件を定義する
<UserRateCondition>
要素。たとえば、特定の国のすべてのユーザーの条件に一致する限定価格を作成できます。トランザクション メッセージの
<Rate>
で参照する料金ルールをそれぞれ定義する<RateRule>
要素。各<RateRule>
で、限定価格または非公開レートを構成する条件と UI 処理を指定します。
<RateRuleSettings>
要素は、料金ルール XML 階層の次の場所に表示されます。
+<RateRuleSettings>
+<UserRateCondition>
+<RateRule>
+<UserRateCondition>
+<RateIneligibility>
+<RateModification>
構文
<RateRuleSettings>
要素の構文は次のとおりです。
<?xml version="1.0" encoding="UTF-8"?>
<RateRuleSettings>
<UserRateCondition id="some_id" op="[all|any|none]">
...
</UserRateCondition>
<!-- Required -->
<RateRule id="rate_rule_id">
<!-- Required -->
<UserRateCondition op="[all|any|none]">
...
</UserRateCondition>
</RateRule>
</RateRuleSettings>
属性
<RateRuleSettings>
要素に属性はありません。
子要素
<RateRuleSettings>
要素には次の子要素があります。
子要素 | 必須 / 任意 | タイプ | 説明 |
---|---|---|---|
<RateRule> |
Required | <RateRule> |
限定価格または非公開レートを提供するための一致条件、変更、適格性を定義します。 |
<UserRateCondition> |
Optional | <UserRateCondition> |
条件が一致した場合に、限定価格または非公開レートが提供される 1 つ以上の条件を定義します。 条件は、
|
限定価格の例
次の例は、限定価格を定義する基本的な方法を示しています。
モバイル ユーザーの例に示すように、事前定義された条件を参照することをおすすめします。
モバイル ユーザー
次の限定価格の例では、事前定義された <UserRateCondition>
を参照して、すべてのモバイル ユーザーに一致する料金ルールを定義しています。
<?xml version="1.0" encoding="UTF-8"?>
<RateRuleSettings>
<UserRateCondition id="mobile">
<UserDeviceType>mobile</UserDeviceType>
</UserRateCondition>
<RateRule id="mobile">
<!-- Referencing pre-defined conditions is recommended -->
<UserRateCondition reference_id="mobile"/>
</RateRule>
</RateRuleSettings>
米国のユーザー
次の限定価格の例では、事前定義済みの <UserRateCondition>
を参照して、米国で検索するすべてのユーザーに一致する料金ルールを定義しています。
<?xml version="1.0" encoding="UTF-8"?>
<RateRuleSettings>
<UserRateCondition id="us">
<UserCountry>US</UserCountry>
</UserRateCondition>
<RateRule id="us">
<UserRateCondition reference_id="us"/>
</RateRule>
</RateRuleSettings>
<RateRule>
以下を指定するためのコンテナ:
- 料金を表示する条件
- 料金と UI の取り扱いの変更(該当する場合)
- 非公開レートの非表示 UI 処理の使用
<RateRule>
要素は、料金ルールの XML 階層の次の場所にあります。
+<RateRuleSettings>
+<UserRateCondition>
+<RateRule>
+<UserRateCondition>
+<RateIneligibility>
+<RateModification>
構文
<RateRule>
要素の構文は次のとおりです。
<?xml version="1.0" encoding="UTF-8"?>
<RateRuleSettings ...>
<UserRateCondition ...>
...
</UserRateCondition>
<!-- At least one RateRule is required. The id attribute is required -->
<RateRule id="rate_rule_id">
<!-- One or more UserRateCondition elements (inline or referenced) are required. -->
<UserRateCondition op="[all|any|none]"> // Inline example
<Description>user_rate_condition_description</Description>
<!-- Uses the member rate visible UI treatment -->
<AlwaysEligibleMembershipProgram>program_name</AlwaysEligibleMembershipProgram>
<LanguageCode>language_code</LanguageCode>
<MaxUsersPercent>20</MaxUsersPercent> // 20% of users
<!-- Requires <RateIneligibility> -->
<MembershipProgram>program_name</MembershipProgram>
<UserRateCondition reference_id="user_rate_condition_id"/>
<UserCountry>country_code</UserCountry>
<UserDeviceType>[mobile|desktop|tablet]</UserDeviceType>
<UserListId>id</UserListId>
<UserSignedIn>[true|false]</UserSignedIn>
<IsDomestic>[true|false]</IsDomestic>
</UserRateCondition>
<RateIneligibility>
<IneligibilityType>[exact|price_band|existence]</IneligibilityType>
<IneligibilityReason>[program_member]</IneligibilityReason>
</RateIneligibility>
<RateModification>
<HotelAmenity>[free_wifi]</HotelAmenity>
</RateModification>
</RateRule>
</RateRuleSettings>
属性
<RateRule>
要素には次の属性があります。
属性 | 必須かどうか | タイプ | 説明 |
---|---|---|---|
id |
必須 | 文字列 |
料金ルールの一意の識別子。この ID は、限定価格または非公開レートを提供するトランザクション メッセージで 最大 40 文字まで入力できます。 |
子要素
<RateRule>
要素には次の子要素があります。
子要素 | 必須 / 任意 | タイプ | 説明 |
---|---|---|---|
<RateIneligibility> |
Optional | <RateIneligibility> |
<MembershipProgram> のレートに対する特定の UI の処理を決定する値を指定します。
|
<UserRateCondition> |
Required | <UserRateCondition> |
条件が一致した場合に、限定価格または非公開レートが提供される 1 つ以上の条件を定義します。 条件は、 ただし、 |
<RateModification> |
Optional | <RateModification> |
非公開レートの UI の取り扱いを変更します。 |
<PromoCode> |
Optional | string | この料金ルールが適用される場合に料金に関連付けられるコードを指定します。PROMO-CODE ランディング ページ変数に反映されます。 |
<UserRateCondition>
条件が一致した場合に、限定価格または非公開レートが提供される 1 つ以上の条件を定義します。
<UserRateCondition>
要素は、料金ルール XML 階層の次の場所に表示されます。
+<RateRuleSettings>
+<UserRateCondition>
+<RateRule>
+<UserRateCondition>
+<RateIneligibility>
+<RateModification>
構文
<UserRateCondition>
要素の構文は次のとおりです。
<?xml version="1.0" encoding="UTF-8"?>
<RateRuleSettings ...>
<!-- "op" is required for more than one child element -->
<UserRateCondition id="some_id" op="[all|any|none]">
<UserDeviceType>device_type</UserDeviceType>
</UserRateCondition>
<UserRateCondition id="some_other_id" op="[all|any|none]">
<UserDeviceType>device_type</UserDeviceType>
</UserRateCondition>
<!-- At least one RateRule is required -->
<RateRule id="rate_rule_id">
<UserRateCondition reference id="some_id"/>
</RateRule>
<RateRule id="rate_rule_id">
<UserRateCondition reference id="some_other_id"/>
</RateRule>
<RateRule id="rate_rule_id">
<UserRateCondition>
<UserDeviceType>device_type</UserDeviceType>
</UserRateCondition>
</RateRule>
<span class="nocode"></RateRuleSettings></span>
属性
<UserRateCondition>
要素には次の属性があります。
属性 | 必須かどうか | タイプ | 説明 |
---|---|---|---|
id |
Required (if top-level under
<RateRuleSettings> ) |
string |
この |
op |
Optional | enum |
|
reference_id |
Optional | string |
この要素を、
|
子要素
<UserRateCondition>
要素には次の子要素があります。
子要素 | 必須 / 任意 | タイプ | 説明 |
---|---|---|---|
<AlwaysEligibleMembershipProgram> |
Optional | string | メンバー料金を表示する UI 処理を料金に指定します。 この要素の値には、任意のメンバーシップ プログラム名を指定できます。 |
<Description> |
Optional | string | <UserRateCondition> を記述します。これはドキュメント化を目的としており、機能には影響しません。 |
<LanguageCode> |
Optional | string | この 2 文字の 言語コードと一致する言語のユーザーに料金を表示することを指定します。 |
<MaxUsersPercent> |
Optional | float | この割合のエンドユーザーにランダムに料金を表示することを指定します。 値には 0 ~ 100 の整数を指定してください。たとえば、20 に設定するとエンドユーザーの 20% がターゲティングされます。 |
<MembershipProgram> |
Optional | string |
|
<UserRateCondition> |
Optional | <UserRateCondition> |
条件が一致した場合に、限定価格または非公開レートが提供される 1 つ以上の条件を定義します。
|
<UserCountry> |
Optional | string | CLDR 国コード(例: ユーザーが指定した国に居住している必要があることを指定します。 Google は IP アドレスからエンドユーザーの国を判断します。 |
<UserDeviceType> |
Optional | enum | デバイスタイプの条件を定義します。指定できる値は次のとおりです。
|
<UserListId> |
Optional | string | オーディエンス リストの Google 広告ユーザーリスト ID。
この条件は、 |
<UserSignedIn> |
Optional | boolean | ユーザーが Google アカウントにログインする必要があるかどうかを指定するブール値。値 true は、ユーザーがログインする必要があることを示します。値 false は、ユーザーがログインできないことを示します。ユーザーのログイン状況とログアウト状況を気にしない場合は、<UserSignedIn> 条件を含めないでください。
|
<IsDomestic> |
Optional | boolean | ユーザーがホテルの所在地と同じ国にいる必要があるかどうかを指定するブール値。値 true は、ユーザーがホテルと同じ国に居住している必要があることを示します。値 false は、ユーザーがホテルがある国以外の国にいる可能性があることを示します。よりきめ細かい制御が必要な場合は、<UserCountry> 条件を使用します。 |
限定価格の例
ユーザーの割合
次の限定価格の例では、ユーザーの 20% にランダムに料金が提示されるように指定しています。
<?xml version="1.0" encoding="UTF-8"?>
<RateRuleSettings>
<RateRule id="20_percent_users">
<UserRateCondition>
<MaxUsersPercent>20</MaxUsersPercent>
</UserRateCondition>
</RateRule>
</RateRuleSettings>
英国とモバイル ユーザー
次の限定価格の例では、インライン <UserRateCondition>
を使用して、英国で検索するすべてのユーザーとモバイル デバイスを照合する料金ルールを定義します。
<?xml version="1.0" encoding="UTF-8"?>
<RateRuleSettings>
<RateRule id="gb_mobile">
<UserRateCondition op="all">
<UserCountry>GB</UserCountry>
<UserDeviceType>mobile</UserDeviceType>
</UserRateCondition>
</RateRule>
</RateRuleSettings>
Japan(日本以外)
次の限定価格の例は、日本のユーザーに一致する 1 つの料金ルールと、その他の国のユーザー(RoW)に一致する別の料金ルールを示しています。
<?xml version="1.0" encoding="UTF-8"?>
<RateRuleSettings>
<RateRule id="jp">
<UserRateCondition>
<UserCountry>jp</UserCountry>
</UserRateCondition>
</RateRule>
<RateRule id="row_not_jp">
<UserRateCondition op="none">
<UserCountry>jp</UserCountry>
</UserRateCondition>
</RateRule>
</RateRuleSettings>
すべて、すべて、なし
次の限定価格の例は、op
属性で値 any
、all
、none
を使用して、複数の条件をさまざまな方法で照合する方法を示しています。たとえば、au_nz
条件に示すように、any を使用して複数の国のユーザーを照合できます。au_nz_mobile_tablet
料金ルールに示すように、all
を使用すると、ユーザーが複数の条件に一致することを必須にできます。row_mobile_tablet
料金ルールは、オーストラリアとニュージーランドを除く世界以外の地域(行)に居住し、かつ mobile_tablet
条件にも一致するユーザーに一致します。
<?xml version="1.0" encoding="UTF-8"?>
<RateRuleSettings>
<UserRateCondition id="au_nz" op="any">
<UserCountry>AU</UserCountry>
<UserCountry>NZ</UserCountry>
</UserRateCondition>
<UserRateCondition id="mobile_tablet" op="any">
<UserDeviceType>mobile</UserDeviceType>
<UserDeviceType>tablet</UserDeviceType>
</UserRateCondition>
<RateRule id="au_nz_mobile_tablet">
<UserRateCondition op="all">
<UserRateCondition reference_id="au_nz"/>
<UserRateCondition reference_id="mobile_tablet"/>
</UserRateCondition>
</RateRule>
<RateRule id="row_mobile_tablet">
<UserRateCondition op="all">
<UserRateCondition op="none">
<UserRateCondition reference_id="au_nz"/>
</UserRateCondition>
<UserRateCondition reference_id="mobile_tablet"/>
</UserRateCondition>
</RateRule>
</RateRuleSettings>
非公開レートの例
メンバー料金を表示 1
<?xml version="1.0" encoding="UTF-8"?>
<RateRuleSettings>
<RateRule id="member_visible">
<UserRateCondition>
<AlwaysEligibleMembershipProgram>[enter your program here]</AlwaysEligibleMembershipProgram>
</UserRateCondition>
</RateRule>
</RateRuleSettings>
メンバー料金を表示 2
<?xml version="1.0" encoding="UTF-8"?>
<RateRuleSettings>
<RateRule id="member_visible_es_only">
<UserRateCondition op="all">
<AlwaysEligibleMembershipProgram>[enter your program here]</AlwaysEligibleMembershipProgram>
<UserCountry>es</UserCountry>
</UserRateCondition>
</RateRule>
</RateRuleSettings>
オーディエンス リスト率 1
<?xml version="1.0" encoding="UTF-8"?>
<RateRuleSettings>
<RateRule id="audience_list">
<UserRateCondition>
<UserListId>[enter an audience list id]</UserListId>
</UserRateCondition>
</RateRule>
</RateRuleSettings>
オーディエンス リスト率 2
次の非公開レートの例は、複数のオーディエンス リストに対して、メンバー料金の表示に関する UI の取り扱いを指定する方法を示しています。
<?xml version="1.0" encoding="UTF-8"?>
<RateRuleSettings>
<RateRule id="membership_program">
<UserRateCondition op="all">
<AlwaysEligibleMembershipProgram>[enter the program name here]</AlwaysEligibleMembershipProgram>
<UserRateCondition op="any">
<UserListId>[enter one audience list id here]</UserListId>
<UserListId>[enter another audience list id here]</UserListId>
</UserRateCondition>
</UserRateCondition>
</RateRule>
</RateRuleSettings>
<RateIneligibility>
メンバー料金の非表示 UI 処理を表示する方法を示します。指定しない場合、メンバー料金の非表示 UI 処理は表示されません。
<RateRule>
で <RateIneligibility>
を使用するには、<RateRule>
の <UserRateCondition>
要素でも <MembershipProgram>
を指定する必要があります。
<RateIneligibility>
要素は、料金ルール XML 階層の次の場所に表示されます。
+<RateRuleSettings>
+<UserRateCondition>
+<RateRule>
+<UserRateCondition>
+<RateIneligibility>
+<RateModification>
構文
<RateIneligibility>
要素の構文は次のとおりです。
<?xml version="1.0" encoding="UTF-8"?>
<RateRuleSettings ...>
<UserRateCondition ...>
...
</UserRateCondition>
<RateRule ...>
<UserRateCondition ...>
...
<!-- Required when using RateIneligibility -->
<MembershipProgram>program_name</MembershipProgram>
...
</UserRateCondition>
<RateIneligibility>
<IneligibilityType>[exact|price_band|existence]</IneligibilityType>
<IneligibilityReason>[program_member]</IneligibilityReason>
</RateIneligibility>
</RateRule>
</RateRuleSettings>
属性
<RateIneligibility>
要素に属性はありません。
子要素
<RateIneligibility>
要素には次の子要素があります。
子要素 | 必須 / 任意 | タイプ | 説明 |
---|---|---|---|
<IneligibilityType> |
Required | enum | テキスト(取り消し線を引いた値の横に表示)で非表示の割合がどのように説明されるかを定義します。 指定できる値は次のとおりです。
UI の処理について詳しくは、非公開レートの詳細と例をご覧ください。 |
<IneligibilityReason> |
Required | enum | 指定できる値は次のとおりです。
|
非公開レートの例
このセクションでは、メンバー料金の非表示の例(基本)とメンバー料金の非表示の例(複数の条件)について説明します。一部のユーザーにメンバー料金を表示することもできます。例については、非公開レートの例をご覧ください。
メンバー料金の非表示の例(基本)
正確な割引率
<?xml version="1.0" encoding="UTF-8"?>
<RateRuleSettings>
<RateRule id="membership_program">
<RateIneligibility>
<IneligibilityReason>program_member</IneligibilityReason>
<IneligibilityType>exact</IneligibilityType>
</RateIneligibility>
<UserRateCondition>
<MembershipProgram>[enter program name here]</MembershipProgram>
</UserRateCondition>
</RateRule>
</RateRuleSettings>
バンドの割引
<?xml version="1.0" encoding="UTF-8"?>
<RateRuleSettings>
<RateRule id="membership_program">
<RateIneligibility>
<IneligibilityReason>program_member</IneligibilityReason>
<IneligibilityType>price_band</IneligibilityType>
</RateIneligibility>
<UserRateCondition>
<MembershipProgram>[enter program name here]</MembershipProgram>
</UserRateCondition>
</RateRule>
</RateRuleSettings>
割引のヒント
<?xml version="1.0" encoding="UTF-8"?>
<RateRuleSettings>
<RateRule id="membership_program">
<RateIneligibility>
<IneligibilityReason>program_member</IneligibilityReason>
<IneligibilityType>existence</IneligibilityType>
</RateIneligibility>
<UserRateCondition>
<MembershipProgram>[enter program name here]</MembershipProgram>
</UserRateCondition>
</RateRule>
</RateRuleSettings>
メンバー料金の非表示の例(複数の条件)
op="any"
メンバーのオーディエンス リスト料金 + メンバー以外のメンバー料金非表示(存在割引)
この非公開レートの例では、existence
タイプのメンバー料金の非表示 UI 処理を指定しています。これは、オーディエンス リストではなく、ユーザーに表示されます。オーディエンス リストのユーザーには、オーディエンス率が表示されます。
<?xml version="1.0" encoding="UTF-8"?>
<RateRuleSettings>
<RateRule id="membership_program">
<RateIneligibility>
<IneligibilityReason>program_member</IneligibilityReason>
<IneligibilityType>existence</IneligibilityType>
</RateIneligibility>
<UserRateCondition op="any">
<MembershipProgram>[enter program name here]</MembershipProgram>
<UserListId>[enter you audience list id here]</UserListId>
</UserRateCondition>
</RateRule>
</RateRuleSettings>
op="all"
メンバー料金を非表示にできるのはオーディエンス リストのユーザーのみ
この非公開レートの例では、メンバー料金の非表示 UI 処理として exact
タイプのメンバー料金を指定しており、「+ 無料 Wi-Fi」というテキストを追加して変更しています。この UI 処理は、オーディエンス リストに一致するユーザーに表示されます。
<?xml version="1.0" encoding="UTF-8"?>
<RateRuleSettings>
<RateRule id="membership_program_for_audience_list">
<RateIneligibility>
<IneligibilityReason>program_member</IneligibilityReason>
<IneligibilityType>exact</IneligibilityType>
</RateIneligibility>
<RateModification>
<HotelAmenity>free_wifi</HotelAmenity>
</RateModification>
<UserRateCondition op="all">
<MembershipProgram>[enter program name here]</MembershipProgram>
<UserListId>[enter you audience list id here]</UserListId>
</UserRateCondition>
</RateRule>
</RateRuleSettings>
透明/表示 UI
この例では、オーディエンス リストのユーザーに対して 2 つの UI 処理(透明で表示されている UI)を使用してメンバー料金を指定し、それ以外のユーザーに対して非表示の料金を指定する方法を示しています。
<?xml version="1.0" encoding="UTF-8"?>
<RateRuleSettings>
<RateRule id="membership_program">
<RateIneligibility>
<IneligibilityReason>program_member</IneligibilityReason>
<IneligibilityType>existence</IneligibilityType>
</RateIneligibility>
<UserRateCondition op="any">
<MembershipProgram>[enter program name here]</MembershipProgram>
<UserRateCondition op="all">
<UserListId>[enter you audience list id here]</UserListId>
<AlwaysEligibleMembershipProgram>program_name</AlwaysEligibleMembershipProgram>
</UserRateCondition>
</UserRateCondition>
</RateRule>
</RateRuleSettings>
<RateModification>
非公開レートの UI の取り扱いを変更します。
<RateModification>
要素は、料金ルール XML 階層の次の場所に表示されます。
+<RateRuleSettings>
+<UserRateCondition>
+<RateRule>
+<UserRateCondition>
+<RateIneligibility>
+<RateModification>
属性
<RateModification>
要素に属性はありません。
子要素
<RateModification>
要素には次の子要素があります。
子要素 | 必須 / 任意 | タイプ | 説明 |
---|---|---|---|
<HotelAmenity> |
Optional | enum |
指定できる値は次のとおりです。
|
<PriceMultiplier> |
Optional | float | この値を基本料金、税金、手数料を掛けて価格を修正します。たとえば、 これにより、特定の料金ルールを持つすべての料金に割引を適用できます。 |
非公開レートの例
ホテルの設備情報
すべてのユーザーにメンバー料金を非表示(バンドの割引)+ 無料 Wi-Fi
<?xml version="1.0" encoding="UTF-8"?>
<RateRuleSettings>
<RateRule id="membership_program">
<RateIneligibility>
<IneligibilityReason>program_member</IneligibilityReason>
<IneligibilityType>price_band</IneligibilityType>
</RateIneligibility>
<RateModification>
<HotelAmenity>free_wifi</HotelAmenity>
</RateModification>
<UserRateCondition>
<MembershipProgram>[enter program name here]</MembershipProgram>
</UserRateCondition>
</RateRule>
</RateRuleSettings>
料金の乗数
料金フィードのモバイル料金に 5% の割引を適用する
<?xml version="1.0" encoding="UTF-8"?>
<RateRuleSettings>
<RateRule id="mobile">
<RateModification>
<PriceMultiplier>0.95</PriceMultiplier>
</RateModification>
<UserRateCondition>
<UserDeviceType>mobile</UserDeviceType>
</UserRateCondition>
</RateRule>
</RateRuleSettings>