An alternative method for implementing the price feed is to use Pull with Hints. In this method:
- Google sends a HintRequest message that contains the time it last received an update from your server.
- Your server responds to a HintRequest message with a Hint Response message that lists the hotels whose prices have changed since that time.
- Google then responds with a Query message.
- Your server responds with a Transaction message that includes the updated data.
The following image shows the request/response flow for Pull with hints:
For an overview of repricing, see Repricing process.
Google sends a HintRequest message to your servers at a specified rate (we recommend 5 minutes). The frequency of the HintRequest messages is configurable. To set or modify the frequency, contact us.
The message is sent using an HTTP
POST request with the
Content-Type header set to "application/xml" and the
header set to
Ensure that the endpoint that Google sends HintRequest messages to is OK by contacting your Technical Account Manager (TAM). You configured this setting during your Hotel Prices initial setup.
HintRequest messages have a root element of
<HintRequest> and a
single child element,
<LastFetchTime> element uses the following syntax:
YYYYis the four-digit year
MMis the two-digit month
DDis the two-digit day
Tseparates the date from the time
HHis the hours
MMis the minutes
SSis the seconds (optional)
You can optionally add a number of hours and minutes for the UTC offset (either positive ("+") or negative ("-")).
The value of the
<LastFetchTime> element is the last time
that Google succeeded in getting a Hint Response message to a HintRequest message.
If this time is older than the last time you updated prices on your server, then
you should respond with a Hint Response message specifying which hotels have
changed. For more information, see Hint Response Messages.
The following example shows a typical HintRequest message:
<?xml version="1.0" encoding="UTF-8"?> <HintRequest id="ABCDEF" timestamp="2014-03-25T00:09:09Z"> <LastFetchTime>2014-03-25T00:04:09Z</LastFetchTime> </HintRequest>
The HintRequest Message Schema defines the structure and constraints of a HintRequest message. For more information, see Schemas.