How to check if an user has just registered

Hi, I need to send an event with google tag manager when an user has just registered, the login/register process is the same, the client writes his email, a code is sent to that email, the client provides this code and is logged in/registered

Is there any way I can be sure that the client has just registered, or if it’s his first time login?

Hi Rober! How are you doing?

Every time a user registers, a CL document is created on the MasterData, and hence, you can create a trigger to identify any creations of new clients: https://help.vtex.com/pt/tutorial/criando-trigger-no-master-data--tutorials_1270

Please let me know if you have any questions!

Regards :slight_smile:

Hello)

I have tried it and created trigger for customer created event and send https request, it works, but userId field value does not work, it is set as null, other fileds like email and first name works. Do you know how can I fix this?

Hi Vasyl (@v.topalo),

I found a video that shows a similar problem where the user was created with a userId, but for some unknown reason, after that the userId field is set to null.

VTex - Client’s “userId” field updates itself to null value - YouTube

In this case, I would probably create a ticket for VTEX to understand the reasons that could generate this scenario.

This topic was automatically closed 24 hours after the last reply. New replies are no longer allowed.