How to create a welcome command

I want the bot to say hi to every new viewer/ chatter. Do you whats the commande?

Hello,
Automatically or via a command?