Custom data in action URLs


When composing a notification, it can be set to “Open URL” upon click/tap. In that field, the URL is parsed before being sent to the server. This prevents the interpolations for custom data from being sent in the URL outside the query string.

Take this URL for example:


Where “12” and “22” are dynamic numbers.

Inputting: https://example.domain/products/{{product_id}}/?track_id={{track_id}}
And passing the appropriate data will evaluate into this URL:
Which breaks the “product_id” segment of the interpolation.

This is caused by the “blur” handler, because it is parsing the URL for validation before sending it to the server forward, and it causes URI encoding on characters which should be preserved.

Before blur:
https:// aws1.discourse-cdn. com/standard11/uploads/wonderpush/original/1X/5773b684954355df57c83bd80c694dbd51b7de5c.png

After blur:

When passing “alert.targetUrl” from the API call and overriding this value properly (no need to parse your own data, but using the built-in interpolation) works as expected and the URL is parsed with the data expanded inside it properly.


We’ve fixed the validation of the URL to no longer escape the curvy brackets.
You can now add parameters in the path as well as in the query string.


Seems to work great, thank you :slight_smile: