Setting participant's display name from server side

How can I set the display name of a participant before joining room ? I want to set it on server side using lua language, and I don’t want to use the javascript function api.executecommand.

Hello,
Can you tell me where I can exactly set the display name of the participant ?

The above link is not exactly the same thing what you want but I think it’s possible to customize it according to your needs

I have created a custom authentication module that sends an HTTP request to a web server to check if a username and password are valid. In that web server I have a table of users that contains the username and the password, and also the nickname for each user.
I want to set the display name for the logged-in user as soon as he logged in. (display name = user nick name)
So please help me to know how I can do that ?

Use JWT authentication

The display name is called a ‘nick’ in Jitsi-meet and it’s majorly confusing because it clashes with the nick in xmpp. You should read the specification, In Jitsi-meet the display name is called a nick in the session field of the participant, while the participant has also a nick field, not displayed in the UI (it’s a random value).

Participant
   jid
  nick (the xmpp one)
  (...other fields)
  session(s) 
      (...other data;...)
       nick  (the display name)

If I understand correctly the Prosody module you were referred to, it is putting the stanza presence fields as tags in the participant.sessions table BUT skips the nick field, and then forces the nick to be equal to the name.

Edit: Right, both ‘nickname’(s) come from 2 different Xmpp specs. (standards, it’s so nice that there are so many). They can differ and are used in different ways in Jitsi-meet.

https://xmpp.org/extensions/xep-0172.html

Hello,
Can you Help me to know how I can send the message <nick xmlns='http://jabber.org/protocol/nick'>Custom Nick Name</nick> to all the participants of the room in the event muc-occupant-pre-join

I have used the following function from force-nick module to set the nick name:

event.stanza:tag("nick", {xmlns = "http://jabber.org/protocol/nick"} ):text(name):up();