/*
is the wildcard character you use when defining a Trigger. When you use an asterisk in the URL Link of your Trigger definition, that character will match any sequence of one or more characters.
To set a wildcard for your entire domain, enter a URL Link value for your domain name, followed by /*
(e.g., example.com/*
). This will enable the display of the ASAPP Chat UI on all pages of your site.
To enable the ASAPP Chat UI to appear on a more limited set of pages, enter a URL Link value that includes the appropriate sub-route path, followed by the /*
wildcard (e.g., example.com/settings/*
).
This will cause the Chat UI to display on any pages that start with the URL and sub-route example.com/settings/
, such as example.com/settings/profile
and example.com/settings/payment
.
example.com/customer-support/shipping.html
in the URL Link field of your Trigger definition will enable the ASAPP Chat UI to display on that single page.
window.location.origin
API to determine whether the link should open in the same window or a new window.
In order for a link to open in the same window as the user’s current SDK window, the window.location.origin
must return a matching protocol and hostname.
https://www.example.com
and clicks a link to https://www.example.com/page-two
, the SDK changes the current page to the destination page in the same window.https://www.example.com
to https://subdomain.example.com
, the SDK opens the destination page in a new window due to hostname variation.
A link from https://example.com
to http://example.com
also opens a new window due to a mismatched protocol. When a link opens a new window, the user’s SDK window remains open.