urbanairship / android-library

Urban Airship Android SDK
Other
109 stars 123 forks source link

Opening "Web Page" URLs from "Landingpage" buttons doesn't work #199

Closed iwt-tobiasboehm closed 2 years ago

iwt-tobiasboehm commented 2 years ago

Preliminary Info

What Airship dependencies are you using?

urbanairship-fcm and -automation - v14.6.0

Report

What unexpected behavior are you seeing?

Our marketing wants to send (!)landing page messages with buttons that link to various web pages that are not necessarily owned by us/referenced via assetLinks (fir example www.google.com should work ;)). The landing page itself is displayed but if the user clicks one of the buttons the link won't open in a browser. I can see via logcat that that OpenExternalUrlAction doesn't #perform() since it runs into that "action is unable to accept arguments" case in Action#L103ff.

What is the expected behavior?

An OpenExternalUrlAction#perform is executed properly and a browser app with that link is opened.

What are the steps to reproduce the unexpected behavior?

Send a notification with landing page content that contains a button with a (!) web page link.

rlepinski commented 2 years ago

You need to add the urls to the allow list. To accept anything add urlAllowListScopeOpenUrl = * to your config. https://docs.airship.com/platform/android/getting-started/#url-allow-list

iwt-tobiasboehm commented 2 years ago

Thx for your quick response - we will try that out :)