Send identify event to segment from inside wix code

I have succesfully setup segment.com with my Wix site, using GTM. I’m getting page events and can also setup track events for clicks trough GTM triggers.

But I also want to be able to call the segment script with an identify event from inside wix code, because that makes it easier to input user data.
How can this be done?

Basically I want to call a function in a script that has been loaded as part of the header from client side wix code.

Hi Rasmus, did you ever manage to find a solution to this? I’m struggling with the same issue—Segment is recognising the events and even the emails (when a user signs up through a form on the Wix site), but isn’t able to “identify“ the user through his/her email address.