redirect to page with some custom data

Hi there!

I want to redirect from my UI to website with some authentication data when I click a button
.
My authentication data is in some object(and possible in session but I didn’t check it).

How to do it? I wanted to use

MyUi.getCurrent().getPage().setLocation("url"); but I don’t know how to pass data.

If it’s plain text parameters what you want to pass, I guess you can just append them on the URL.

MyUi.getCurrent().getPage().setLocation(“url” + “?” + “param1=” + paramValue);

If it’s more about authentication, usually you need to set it in the request headers.

I see.
But I don’t know how to send request and navigate from UI to another web page.
And yes it’s authentication data.
Oh basic HttpRequest will work just fine?

This navigation is implicit in the “setLocation” method. This should navigate to the external site with the params already in the request.

Oh! I see. Thanks.