ホテルリストは、料金情報を提供する対象であるすべてのホテルをリストした 1 つ以上の XML ファイルです。ホテルリスト ファイル自体に料金情報は含まれません。
ホテルリストのルート要素は <listings> 要素です。この要素には、宿泊施設を説明する <listing> 要素が含まれます。
初期実装の一環としてホテルリストを作成してから、定期的なメンテナンスの一環としてホテルリストでホテルの追加や削除を行います。
ファイルが構文ガイドラインに準拠していることを確認します。たとえば、UTF-8 エンコードを使用し、XML タグに encoding 属性を含めることで、このエンコード スキーマを指定します。
ホテルリストを作成したら、https://support.google.com/hotelprices/を使用して手動で Google にアップロードするか、自社のサーバーでホストします。
データの問題を検出して修正する
ホテルリスト内のデータの問題を検出して修正するには、次の記事をご覧ください。
リスティングの要件
ホテルリスト内の宿泊施設が Google ホテル広告に表示されるには、宿泊施設が次の条件を満たしている必要があります。
- 宿泊客が滞在できる有料の客室がある
- 一般開放されており、物理的な設備と固定の住所がある
- 壁と水道設備が頑丈に固定されている
- 最短滞在期間が 7 日以下である
対象外となる宿泊施設の一般的な例としては、クルージング、アパートなどがあります(通常は Listing requirements の条件を満たさないため)。
壁、水道設備、空調設備(薪ストーブやプロパンガスの暖房を含む)が頑丈に固定されているキャンピング キャビンなどのキャンプ場が対象となります。以下の屋外宿泊施設は対象外です。
- 宿泊客がテントに滞在するキャンプ場
- 宿泊客が自分の RV 車を利用する RV パーク
<listings>
<listings> はホテルリストのルート要素であり、<language> 要素と少なくとも 1 つの <listing> が含まれます。
<listings> 要素は、ホテルリストの XML 階層内の次の場所にあります。
+ <listings>
    + <language>
    + <datum>
    + <listing>
構文
<listings> 要素の構文は次のとおりです。
<?xml version="1.0" encoding="UTF-8"?>
<listings xmlns:xsi="xsi"
    xsi:noNamespaceSchemaLocation="schema_xsd">
  <language> language_code</language>
  <datum> datum_code </datum>
  <listing> listing</listing>
  ...
</listings>
属性
<listings> 要素には次の属性があります。
| 属性 | 必須 | 説明 | 
|---|---|---|
| xmlns:xsi | 必須 | http://www.w3.org/2001/XMLSchema-instanceに設定します。 | 
| xsi:noNamespaceSchemaLocation | 必須 | http://www.gstatic.com/localfeed/local_feed.xsdに設定します。 | 
子要素
<listings> 要素には次の子要素があります。
| 子要素 | 必須 | 型 | 説明 | 
|---|---|---|---|
| <language> | Required | string | フィードが記述されている言語。この要素の値は、
  2 文字の言語コードに設定します。たとえば、英語の場合は enです。 | 
| <datum> | Optional | enum | この要素は、フィードで指定された緯度と経度の座標の測地系または参照モデルを指定します。データ値が指定されていない場合、この要素のデフォルト値は WGS84です。これは、ほとんどの最新の GPS デバイスで使用されています。東京測地系は、日本の住所にのみ適用されます。この要素の有効な値は次のとおりです。 
 WGS84のデフォルト値を使用するには、ホテルリストに<datum>要素を含めないでください。 | 
| <listing> | Required | <listing> | フィード内の各ホテルを説明する 1 つ以上のエントリ。リスト内の各ホテルには、サイトに固有の ID が必要です。また、この ID は絶対に再利用しないでください。 | 
例
構造化された住所
次の例に、構造化された住所が含まれるホテルリストの一部を示します。
<?xml version="1.0" encoding="UTF-8"?>
<listings xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
    xsi:noNamespaceSchemaLocation="http://www.gstatic.com/localfeed/local_feed.xsd">
  <language>en</language>
  <listing>
    <!-- The value of <id> must be unique to your site for all time. Do NOT reuse IDs. -->
    <id>123abc</id>
    <name>Belgrave House</name>
    <address format="simple">
      <component name="addr1">6 Acacia Ave</component>
      <component name="addr2">Floor 5</component>
      <component name="city">London</component>
      <component name="province">Greater London</component>
      <component name="postal_code">SW1W 9TQ</component>
    </address>
    <country>GB</country>
    <latitude>35.070374</latitude>
    <longitude>-106.213648</longitude>
    <phone type="main">123-456-7890</phone>
    <category>hotel</category> <!-- You can use whatever property type categories you wish -->
  </listing>
  ...
</listings>
自由形式の住所
次の例に、自由形式の住所が含まれるホテルリストの一部を示します。
<?xml version="1.0" encoding="UTF-8"?>
<listings xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
    xsi:noNamespaceSchemaLocation="http://www.gstatic.com/localfeed/local_feed.xsd">
  <language>en</language>
  <listing>
    <!-- The value of <id> must be unique to your site for all time. Do NOT reuse IDs. -->
    <id>123abc</id>
    <name>Belgrave House</name>
    <address>6 Elm Ave Unit 3, Boston, MA, 02472</address>
    <country>US</country>
    <latitude>35.070374</latitude>
    <longitude>-106.213648</longitude>
    <phone type="main">123-456-7890</phone>
    <category>hotel</category> <!-- You can use whatever property type categories you wish -->
  </listing>
  ...
</listings>
オプションのコンテンツ
次の例に、<content>(省略可)を含むリスティングが含まれるホテルリストの一部を示します。
<?xml version="1.0" encoding="UTF-8"?>
<listings xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
    xsi:noNamespaceSchemaLocation="http://www.gstatic.com/localfeed/local_feed.xsd">
  <language>en</language>
  <listing>
    <id>123456</id>
    <name>My Apartment</name>
    <address format="simple">
      <component name="addr1">1 Sandstone Building</component>
      <component name="city">Los Angeles</component>
      <component name="postal_code">90210</component>
      <component name="province">CA</component>
    </address>
    <country>US</country>
    <latitude>40.730610</latitude>
    <longitude>-73.935242</longitude>
    <phone type="main">12345678</phone>
    <category>hotel</category> <!-- You can use whatever property type categories you wish -->
    <content>
      <text type="description">
        <link>https://examplelisting.com/listings/12345</link>
        <title>3 bedrooms with ocean views</title>
        <body>Stay in this newly renovated 3BR house with ocean views.</body>
        <date month="7" day="23" year="2023"/>
      </text>
      <attributes>
        <website>https://hotel.example.com</website>
        <client_attr name="rating">8.2</client_attr>
      </attributes>
      <image type="photo" url="https://image_url">
        <link>https://image_url</link>
        <title>Main hotel picture</title>
      </image>
    </content>
  </listing>
  ...
</listings>
<listing>
ホテルリスト <listings> 要素内のホテル定義。
<listing> 要素は、ホテルリスト フィードの XML 階層の次の場所にあります。
+ <listings>
    + <language>
    + <listing>
構文
<listing> 要素の構文は次のとおりです。
<?xml version="1.0" encoding="UTF-8"?>
<listings ... >
  <listing>
    <!-- Specify <listing>'s child elements in the order shown below. -->
    <id>hotel_ID</id>
    <name>hotel_name</name>
    <address>
      <component name="addr1">street_address_1</component>
      <component name="addr2">street_address_2</component>
      <component name="city">city_name</component>
      <component name="province">province_name</component>
      <component name="postal_code">postal_code</component>
    </address>
    <!-- You can also define an address freeform, although this is not recommended: -->
    <!-- <address>freeform_address</address> -->
    <country>country_code</country>
    <latitude>hotel_latitude</latitude>
    <longitude>hotel_longitude</longitude>
    <phone type="[fax|main|mobile|tdd|tollfree]">phone_number</phone>
    <category>hotel</category> <!-- You can use whatever property type categories you wish -->
    <content>content</content>
  </listing>
</listings>
属性
<listing> 要素には属性はありません。
子要素
<listing> 要素には次の子要素があります。
| 子要素 | 必須 | 型 | 説明 | 
|---|---|---|---|
| <id> | Required | string | ホテルの一意の ID。 注: この値は、サイトで常に一意である必要があります。ID を再利用すると、宿泊施設の一致の問題を解決しようとしたときに問題が発生する可能性があるため、ID の再利用は禁止されています。 | 
| <name> | Required | string | ホテルの名前。次に例を示します。 <name>Belgrave House</name> | 
| <address> | Required | Object or string | ホテルの正式な物理的所在地。 この要素は、 少なくとも、ホテルの番地、市区町村、都道府県 / 州、郵便番号を指定する必要があります。 
 次に例を示します。 <address format="simple"> <component name="addr1">6 Acacia Ave</component> <component name="addr2">Floor 5</component> <component name="city">London</component> <component name="province">Greater London</component> <component name="postal_code">SW1W 9TQ</component> </address> または、「自由形式」の住所を指定することもできますが、おすすめしません。次に例を示します。 <address>6 Elm Ave Unit 3, Boston, MA, 02472</address> 私書箱や郵便物受け取り専用住所は、正式な物理的住所とは見なされません。 | 
| <country> | Required | string | このリスティングが存在する国。値は2 文字の国コードにする必要があります。例: 日本であれば「JP」、米国であれば「US」。次に例を示します。 <country>US</country> | 
| <latitude> | Required* | float | ホテル所在地の緯度。次に例を示します。 <latitude>37.423738</latitude> この値は、Google Maps API などの GeoCoding ツールを使用して生成できます。 | 
| <longitude> | Required* | float | ホテル所在地の経度。次に例を示します。 <longitude>-122.090101</longitude> この値は、Google Maps API などの GeoCoding ツールを使用して生成できます。 | 
| <location_precision> | Optional | integer | 宿泊施設の緯度と経度が難読化されている場合に、送信される宿泊施設の位置情報の精度(メートル単位)。ゼロ(0)は難読化が行われておらず、正確な位置情報であることを意味します。注: この要素は民泊にのみ適用されます。 | 
| <phone> | Required* | string | ホテルの 1 つ以上の連絡先電話番号。リスティングが企業の支店の場合は、(本社の電話番号ではない)支店の所在地に固有の電話番号を指定してください。 
 
 次に例を示します。 <!-- Singapore (country code +65) --> <phone type="main">+65 6722-2323</phone> <!-- U.S. (country code +1) --> <phone type="fax">+1 408-555-1111</phone> 少なくとも、 | 
| <category> | Optional | string | ホテルなどの宿泊施設のタイプ。パートナーは、「ビジネス ホテル」、「リゾート」、「モーテル」など、宿泊施設を説明するための任意の内部カテゴリを使用できます。 | 
| <content> | Optional | <content> | 宿泊施設の説明、評価、特長など、リスティングに使用されるオプションの詳細情報。 | 
* 電話番号または経緯度のいずれかを必ず指定してください。両方を定義することをおすすめします。
例
構造化された住所
次の例に、構造化された住所が含まれるホテルリストの一部を示します。
<?xml version="1.0" encoding="UTF-8"?>
<listings xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
    xsi:noNamespaceSchemaLocation="http://www.gstatic.com/localfeed/local_feed.xsd">
  <language>en</language>
  <listing>
    <!-- The value of <id> must be unique to your site for all time. Do NOT reuse IDs. -->
    <id>123abc</id>
    <name>Belgrave House</name>
    <address format="simple">
      <component name="addr1">6 Acacia Ave</component>
      <component name="addr2">Floor 5</component>
      <component name="city">London</component>
      <component name="province">Greater London</component>
      <component name="postal_code">SW1W 9TQ</component>
    </address>
    <country>GB</country>
    <latitude>35.070374</latitude>
    <longitude>-106.213648</longitude>
    <phone type="main">123-456-7890</phone>
    <category>hotel</category> <!-- You can use whatever property type categories you wish -->
  </listing>
  ...
</listings>
自由形式の住所
次の例に、自由形式の住所が含まれるホテルリストの一部を示します。
<?xml version="1.0" encoding="UTF-8"?>
<listings xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
    xsi:noNamespaceSchemaLocation="http://www.gstatic.com/localfeed/local_feed.xsd">
  <language>en</language>
  <listing>
    <!-- The value of <id> must be unique to your site for all time. Do NOT reuse IDs. -->
    <id>123abc</id>
    <name>Belgrave House</name>
    <address>6 Elm Ave Unit 3, Boston, MA, 02472</address>
    <country>US</country>
    <latitude>35.070374</latitude>
    <longitude>-106.213648</longitude>
    <phone type="main">123-456-7890</phone>
    <category>hotel</category> <!-- You can use whatever property type categories you wish -->
  </listing>
  ...
</listings>
オプションのコンテンツ
次の例に、<content>(省略可)を含むリスティングが含まれるホテルリストの一部を示します。
<?xml version="1.0" encoding="UTF-8"?>
<listings xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
    xsi:noNamespaceSchemaLocation="http://www.gstatic.com/localfeed/local_feed.xsd">
  <language>en</language>
  <listing>
    <id>123456</id>
    <name>My Apartment</name>
    <address format="simple">
      <component name="addr1">1 Sandstone Building</component>
      <component name="city">Los Angeles</component>
      <component name="postal_code">90210</component>
      <component name="province">CA</component>
    </address>
    <country>US</country>
    <latitude>40.730610</latitude>
    <longitude>-73.935242</longitude>
    <phone type="main">12345678</phone>
    <category>hotel</category> <!-- You can use whatever property type categories you wish -->
    <content>
      <text type="description">
        <link>https://examplelisting.com/listings/12345</link>
        <title>3 bedrooms with ocean views</title>
        <body>Stay in this newly renovated 3BR house with ocean views.</body>
        <date month="7" day="23" year="2023"/>
      </text>
      <attributes>
        <website>https://hotel.example.com</website>
        <client_attr name="rating">8.2</client_attr>
      </attributes>
      <image type="photo" url="https://image_url">
        <link>https://image_url</link>
        <title>Main hotel picture</title>
      </image>
    </content>
  </listing>
  ...
</listings>
<content>
リスティングに関する情報(評価、設備などの詳細情報)を追加します。<content> 要素は省略可能です。<content> 内では、すべての子要素は省略可です。
<content> 要素は、ホテルリスト フィードの XML 階層の次の場所にあります。
+ <listings>
    + <language>
    + <listing>
        + <content>
構文
<content> 要素の構文は次のとおりです。
<?xml version="1.0" encoding="UTF-8"?>
<listings ... >
  <listing>
    <content>
      <!-- Specify <text>'s child elements in the order shown below. -->
      <text type="description">
        <link>listing_link</link>
        <title>listing_title</title>
        <author>listing_author</author>
        <body>listing_description</body>
        <date month="MM" day="DD" year="YYYY"/>
      </text>
      <!-- 0 or more attributes: -->
      <attributes>
        <website>https://hotel.example.com</website>
        <client_attr name="alternate_hotel_id">alternate_hotel_id</client_attr>
        <client_attr name="hotel_brand">hotel_brand</client_attr>
        <client_attr name="rating">aggregate_rating</client_attr>
      </attributes>
      <!-- a picture of the hotel or property-->
      <image type="photo" url="https://image_url">
        <link>https://image_url</link>
        <title>Main Hotel Picture</title>
      </image>
    </content>
  </listing>
  ...
</listings>
属性
<content> 要素には属性はありません。
子要素
<content> 要素には次の子要素があります。
| 子要素 | 必須 | 型 | 説明 | 
|---|---|---|---|
| <text | Optional | Object | プロバイダのリスティングに関連付けられているウェブページ。 次の子要素があります: 
 注: これらの要素は上記の順序にする必要があります。 | 
| <review | Optional | <review> | リスティングのユーザー レビューまたはエディタ レビューが含まれます。リスティングには、どちらのレビューでも、任意の数だけ含めることができます。 
 キーポイント: <review> は民泊アカウントにのみ送信する必要があります。詳しくは、テクニカル アカウント マネージャー(TAM)にお問い合わせください。 | 
| <attributes> | Optional | Object | 宿泊施設に関する詳細情報を提供する 0 個以上の  <client_attr name="attribute_name">attribute_value<client_attr> 子要素のリストと説明については、 すべての  
 | 
| <image> | Optional | Object | 繰り返しタグ。詳細な画像情報が含まれます。 | 
例
次の例に、<content> 要素が含まれるホテルリストの一部を示します。
<?xml version="1.0" encoding="UTF-8"?>
<listings xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
    xsi:noNamespaceSchemaLocation="http://www.gstatic.com/localfeed/local_feed.xsd">
  <language>en</language>
  <listing>
    <id>123456</id>
    <name>My Apartment</name>
    <address format="simple">
      <component name="addr1">1 Sandstone Building</component>
      <component name="city">Los Angeles</component>
      <component name="postal_code">90210</component>
      <component name="province">CA</component>
    </address>
    <country>US</country>
    <latitude>40.730610</latitude>
    <longitude>-73.935242</longitude>
    <phone type="main">12345678</phone>
    <category>hotel</category> <!-- You can use whatever property type categories you wish -->
    <content>
      <text type="description">
        <link>https://examplelisting.com/listings/12345</link>
        <title>3 bedrooms with ocean views</title>
        <body>Stay in this newly renovated 3BR house with ocean views.</body>
        <date month="7" day="23" year="2023"/>
      </text>
      <attributes>
        <website>https://hotel.example.com</website>
        <client_attr name="rating">8.2</client_attr>
      </attributes>
      <image type="photo" url="https://image_url">
        <link>https://image_url</link>
        <title>Main hotel picture</title>
      </image>
    </content>
  </listing>
  ...
</listings>
<attributes>
<attributes> タグを使用すると、宿泊施設の設備を説明し、宿泊施設の評価を分類することができます。
+ <listings>
    + <language>
    + <listing>
        + <content>
            + <attributes>
子要素
| 子要素 | 必須 | 説明 | |
|---|---|---|---|
| <website> | Optional | ホテルのメインのウェブサイト。存在する場合は、最初の <client_attr>要素の前に配置する必要があります。例:<website>https://hotel.example.com</website> | |
| <client_attr name="attribute_name"> | Optional | 宿泊施設の追加の特性または「属性」。サポートされている attribute_nameまたは
    民泊のattribute_nameを使用して指定できます。 | |
attribute_name プレースホルダの値
次の表に、<client_attr name="attribute_name"> 要素の attribute_name に有効な値の一覧を示します。
| attribute_nameの値 | 説明 | 有効なコンテンツの値 | 
|---|---|---|
| alternate_hotel_id | 宿泊施設の代替 ID。フィード情報用と予約エンジン用にそれぞれの宿泊施設 ID が必要な場合は、個別の ID があると便利です。 | 任意の文字列値 | 
| 非推奨: 任意の文字列型のカスタム属性。これらはユーザーには表示されません。 重要:  | 任意の文字列値 | |
| hotel_brand | このホテルが所属するブランド。「Marriott」や「Hilton」などです。これはユーザーには表示されませんが、ホテルをグループ化するために使用できます。 | 任意の文字列値 | 
| lodging | Lodgingプロトで使用可能なすべてのフィールドのエンコードされた表現。 | エンコードされた Lodgingプロトの Base64 エンコード文字列 | 
| num_reviews | リスティングのレビューの数。 キーポイント: 「num_reviews」は、民泊フィードでのみ送信する必要があります。 | 負ではない任意の整数。 | 
| rating | 宿泊施設の評価の集計を表す浮動小数点数。 | この数値は、通常は 0 ~ 5、0 ~ 10、0 ~ 100 の範囲ですが、評価システムを表す任意の範囲を使用できます。たとえば、rating_scale が 5 の場合、宿泊施設の評価は 3 または 4 にする必要があります。 注: 指定しない場合、デフォルトの rating_scale は 0 ~ 10 です。 | 
民泊の attribute_name プレースホルダの値
民泊固有の属性と XML の例を参照してください。
<image>
+ <listings>
    + <language>
    + <listing>
        + <content>
            <!-- <review> is allowed in Vacation Rentals only -->
            + <review>
            + <attributes>
            + <image>
画像は、リスティング ID で宿泊施設を表示するために使用されます。使用するすべての画像は、次のガイドラインに従う必要があります。
- 画像の推奨アスペクト比は 4:3 です。
- Googlebot 画像クローラが画像の URL にアクセスできる必要があります。
- サイトのルートレベルに robots.txt が含まれている場合は、下記に示す 2 つのオプションのいずれかが含まれることを確認します。 - Googlebot クローラーがサイトのコンテンツ(画像を含む)をクロールできるようにします。 - User-agent: Googlebot
- Allow: /
 
- Googlebot 画像クローラがサイトの画像をクロールできるようにします。 - User-agent: Googlebot-Image
- Allow: /
 
 
- 画像またはウェブサイトのスクリーンショットは許可しません。画像は、オリジナルかつ実物の画像や写真にする必要があります。 
属性
- 画像が広告である場合は "ad"
- 画像がレストランのメニューである場合は "menu"
- 画像が店舗の写真である場合は "photo"
| 属性名 | 必須 | 形式 | 説明 | 
|---|---|---|---|
| type | Required | Text | 画像には、以下のいずれかを指定する必要があります。 | 
| url | Required | Text | フルサイズの画像の URL。 url属性を使用して、そのページで使用する画像を指定します。 | 
| width | Required | A non-negative integer | 画像の幅(ピクセル単位、720 ピクセル以上を推奨) | 
| height | Required | A non-negative integer | 画像の高さ(ピクセル単位、720 ピクセル以上を推奨) | 
子要素
| 子要素 | 必須 | 説明 | 
|---|---|---|
| <link> | リクエスト済み、ただしローカルの写真のリスティングに必須。 | このタグには、関連する画像が存在するサイト上のページの、有効かつ最新の URL が含まれます。画像自体の URL は含まれません。
    例: <link><http://www.example.com/magic_pizza/></link> | 
| <title> | リクエスト済み | このタグには画像のタイトルが含まれます。例: <title>"Luxury Apartment"</title> | 
| <author> | 不要 | コンテンツの作成者の名前。値は、ユーザー名か、「名 姓」の形式の氏名で指定します。 | 
| <date> | 必須 | このタグは、コンテンツ項目が作成された日付を示します。次の例に示すように、年、月、日を入力する必要があります。 <date month="6" day="7" year="2023"/> | 
例
次の例に、画像のタグが含まれるホテルリストの一部を示します。
<?xml version="1.0" encoding="UTF-8"?>
<listings xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
    xsi:noNamespaceSchemaLocation="http://www.gstatic.com/localfeed/local_feed.xsd">
  <language>en</language>
  <listing>
    <content>
      <image type="photo" url="https://image_url" width="400" height="300">
        <link>https://image_url</link>
        <title>Apartment at Sandstone</title>
        <author>Jessica Landlord</author>
        <date month="6" day="7" year="2023"/>
      </image>
    </content>
  </listing>
  ...
</listings>
構文のガイドライン
XML ベースのホテルリストを作成する場合は、以下のガイドラインを使用します。
- ホテルリストの XML ファイルを検証するには、Google の XSD スキーマを使用します。 
- UTF-8 エンコードを使用します。このエンコード スキーマを指定するには、次の例に示すように、XML タグに - encoding属性を含めます。
- CDATAセクションを使用して、フィード内にデータ値を指定できます。- CDATAセクションを使用する場合は、特殊文字をエスケープ処理しないでください。
- CDATAセクションにないデータ値(URL など)には、エスケープ コードを使用します。エンティティ コードまたは文字コードのいずれかを使用して、これらの特殊文字を表すことができます。次の表に、使用できる共通のエンティティ コードと文字コードを示します。- 文字 - エンティティ - 文字コード - アンパサンド(&) - & - & - 単一引用符(') - ' - ' - 二重引用符(") - " - " - より大きい(>) - > - > - より小さい(<) - < - < 
- データを含まない XML 要素を削除します。たとえば、ホテルに緯度と経度を使用しない場合は、空の - <latitude/>要素と- <longitude/>要素は含めないでください。
- どのような状況でも(エスケープ処理されている場合であっても)XML 要素で HTML は使用しないでください。 
- アップロードの前にフィードを検証するには、ローカル フィード XSD(http://www.gstatic.com/localfeed/local_feed.xsd)を使用します。 
- フィードでコメントを使用するには、次の例に示すように、 - <!--タグや- -->タグ内でコメントをラップします。- <!-- This is a comment -->