This module lets you join groups using an ad-hoc command. When a user
joins a group, everyone in the group is added to their roster, and they
are added to the rosters of existing members.
With the plugin
installer in Prosody 0.12 you can use:
sudo prosodyctl install --server=https://modules.prosody.im/rocks/ mod_adhoc_groups
For earlier versions see the documentation for installing 3rd party modules