Get the member's username with the new Wix Member API

Hi,

So I just saw that Wix launched a new API to create member’s pages, it seems pretty decent.

Now one thing I really need which apparently wasn’t possible with the Log In API provided by wix forum, is to retrieve the username and insert it in a field on one of my pages.

To sum up, once the user has logged in, he can access a “submit” page, here he can type any info he wished to submit, and I would like to automatically get his username and put it into a “pseudo” field within the collection.

I tried this :

$w("#input1") === ("#loginSocialBar1".value);
//input1 = where the username should be in
//loginSocialBar1 = the ID of the new Log In API provided by wix 
//(you can see it at the very bottom of the menu in the editor)

but I’m terrible at coding and of course it didn’t work.

Thanks !

1 Like

Wix Team, we need the userName added to wix user API. Pretty Please!! :slight_smile:

Hi!

Please post a feature request here so we can make it happen for our users!

Doron. :slight_smile:

Isnt this just the field “Slug” from the “Members/PrivateMembersData” collection ? If so you can query the collection using the User’s ID