Deep link and URL templates

For each product Option in the product feed, you can provide up to two deep links (one for product view and another for list view). Each deep link has built-in URL template support which enables Google to provide you information about the source of the deep link click.

By adding additional parameters via URL templates to your deep links, you can identify the source of the deep link click, the currency and language of the user and additional detail about the product clicked. With this information, you can then route the user to the most appropriate landing page (e.g. with the matching language and currency).

How URL templates work

To make use of URL templates, deep links provided to Google must include url template parameters such as {lang}. When your deep link is clicked, the URL which the user is directed to will replace these parameter with the resolved values.

If you want to add more than one parameter to a single URL, simply append them together in your URL using an ampersand (&), like this: ?source={src}&language={lang}

For language codes, please refer to BCP47.

The currently supported url templates are:

Parameter What it returns
{src} Source of the deeplink click. e.g. The value cu will be returned when url is triggered from Things to do Ads.
{lang} The language the user is browsing in, e.g. "en-US"
{currency} The currency the user is browsing in, e.g. "USD".
{product_id} The id of the product which the user clicked the deep link for.
{option_id} The id of the product option id which the user clicked the deep link for.

list of possible src values

Below is the list of possible src values. As Things to do is launched on more surfaces, additional values may be added.

Value Surface
bm The Things to do search tickets booking module.
cu The Things to do ads commercial unit.
e The Things to do search experience module.
o The Things to do operator booking module.

Examples

If a user is currently browsing in English UK, shopping in Pounds and clicked on Things to do Ad then the URL template:

www.test.com/deeplink?source={src}&language={lang}&currency={currency}

will resolve to:

www.test.com/deeplink?source=cu&language=en-GB&currency=GBP