How can i access address in authenticate message

I want to modify the authentication message how do i access the signer address in it. i want the message to be like “Hi {address}, welcome to my dapp”.

Also please tell me about the variables i can access in authenticate message.

Hi @jezeus,

You can attain the addresses of the user this way –

let user = await Moralis.User.current();
let userAccounts = user.get('accounts');

And later use the variable like this –
`Hi ${userAccounts[0]}, welcome to my dapp`

This will work. :slight_smile: