
RyanR.27482 (Customer) asked a question.
I am trying to enable user reactivation for users that took too long to follow their initial activation link before it expired. I would like to provide a button allowing the user to send a out a new activation email if the link they followed is expired.
In order to reactivate a user, I need to call POST {{url}}/api/v1/users/{{userID}}/lifecycle/reactivate?sendEmail=true, yet all I have available in the application at this point is the expired "activationToken". Here is the list of available variables: https://developer.okta.com/docs/guides/custom-email/main/*use-vtl-variables
"user.id" is not available in the User Activation email template, yet "user.profile.email" is. I could use this on my server to look up the "user.id". However, I cannot add this as a query parameter to the activation link in the email as the user's email needs to be url encoded.
So, my questions are:
- How could I url-encode the email address of a user within the User Activation template?
- Is there a simpler way to reactivate the user?
- Is there a different user identifier available that would not need to be encoded?

Hi @RyanR.27482 (Customer),
Thank you for posting on the Okta Community page!
I have done some research and I have managed to find the bellow article that provides an expression for how to get the user id:
Additionally, if the above does not do the trick, I would recommend to also leverage the Okta Developer forums for this type of questions and take advantage of their expertise.