<div dir="ltr">Yeah, what I actually did was the 1st choice, we added it to the form action via JavaScript, but somehow the value doesn't get returned, only the redirect_uri without any query params.<div><br></div><div>I think I'll have to go with your 2nd option.</div></div><div class="gmail_extra"><br><div class="gmail_quote">On Tue, Sep 16, 2014 at 10:09 AM, Stian Thorgersen <span dir="ltr"><<a href="mailto:stian@redhat.com" target="_blank">stian@redhat.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">How do you then set it as "query parameter on the redirect_uri param"? The redirect_uri is part of the form action url, not the form data.<br>
<br>
Currently, I think your options are:<br>
<br>
1. You can use JavaScript to add the checkbox value to the form action before submitting the form<br>
2. Modify TokenService and build your own KC to have TokenService.processLogin extract the checkbox value from the form data and add to redirect_uri<br>
3. Wait until we add customization user profiles and registration form<br>
4. Display a separate registration form on your app when a user first logins<br>
<span class="im HOEnZb"><br>
----- Original Message -----<br>
> From: "Rodrigo Sasaki" <<a href="mailto:rodrigopsasaki@gmail.com">rodrigopsasaki@gmail.com</a>><br>
</span><div class="HOEnZb"><div class="h5">> To: "Stian Thorgersen" <<a href="mailto:stian@redhat.com">stian@redhat.com</a>><br>
> Cc: <a href="mailto:keycloak-user@lists.jboss.org">keycloak-user@lists.jboss.org</a><br>
> Sent: Tuesday, 16 September, 2014 2:56:12 PM<br>
> Subject: Re: [keycloak-user] Send parameter back after registration<br>
><br>
> We actually added the checkbox on our login.ftl, with our own theme<br>
> customizations, and we wanted to send that value back when keycloak<br>
> redirects back to our application<br>
><br>
> On Tue, Sep 16, 2014 at 9:49 AM, Stian Thorgersen <<a href="mailto:stian@redhat.com">stian@redhat.com</a>> wrote:<br>
><br>
> > Is the checkbox on your website and you add it to the redirect_uri as a<br>
> > query param? If so it should be included in the url Keycloak redirects to<br>
> > after login.<br>
> ><br>
> > One feature that we want to add is to be able to customize the attributes<br>
> > for the users profiles, as well as configure which are shown on the<br>
> > registration screen. Not sure when we'll have time to add that though.<br>
> ><br>
> > ----- Original Message -----<br>
> > > From: "Rodrigo Sasaki" <<a href="mailto:rodrigopsasaki@gmail.com">rodrigopsasaki@gmail.com</a>><br>
> > > To: <a href="mailto:keycloak-user@lists.jboss.org">keycloak-user@lists.jboss.org</a><br>
> > > Sent: Tuesday, 16 September, 2014 2:40:40 PM<br>
> > > Subject: [keycloak-user] Send parameter back after registration<br>
> > ><br>
> > > Hello,<br>
> > ><br>
> > > I was wondering if there is a way for me to send a parameter back to my<br>
> > > server after a new user registers in Keycloak.<br>
> > ><br>
> > > For example, we have a checkbox that the user can check if he wants to<br>
> > > receive newsletter from our website, and I wanted to send that value<br>
> > back to<br>
> > > us.<br>
> > ><br>
> > > I tried setting it as a query parameter on the redirect_uri param, it<br>
> > gets<br>
> > > sent on the request, but it isn't posted back to us.<br>
> > ><br>
> > > Is there a defined way to accomplish this?<br>
> > ><br>
> > > Thank you again!<br>
> > ><br>
> > > --<br>
> > > Rodrigo Sasaki<br>
> > ><br>
> > > _______________________________________________<br>
> > > keycloak-user mailing list<br>
> > > <a href="mailto:keycloak-user@lists.jboss.org">keycloak-user@lists.jboss.org</a><br>
> > > <a href="https://lists.jboss.org/mailman/listinfo/keycloak-user" target="_blank">https://lists.jboss.org/mailman/listinfo/keycloak-user</a><br>
> ><br>
><br>
><br>
><br>
> --<br>
> Rodrigo Sasaki<br>
><br>
</div></div></blockquote></div><br><br clear="all"><div><br></div>-- <br><div dir="ltr"><font face="Times New Roman">Rodrigo Sasaki</font><div></div></div>
</div>