Add team members to a team channel

Is it possible to automatically add team members to a team channel in Mattermost?

Hi Roger,

with the enterprise edition, this works by binding an LDAP group to the channel, so as soon as a new user with a matching group membership is being created in your mattermost instance, this user will automatically be added to the channel which is linked to this specific group(s).

Without this feature you would have to automate that using the API or mmctl f.ex. Base on what criteria would you want to add people to channels? Are these private channels you want to add them to or public channels? For the latter I think you could also use the welcomebot-plugin.

Best,
Alex

Thank you very much Alex, I think most of the channels are public. The question was: The creator of a channel wants his team members to become channel members directly. The way with “mmctl” is fine and the other way with welcomebot sounds good, but first I should read more about this “bot”. Your answers helped me a lot and I will find a solution here.

Cheers
Roger

Alright, let me know if I can help with the scripting or the like; Welcome Bot basically allows people to join channels based on questions they answer, so you could ask new members if they are developers and if they answer with yes, you can automatically join them to the developers channel, etc.

Not sure what your authentication backend will be, but if you need to manually create the user accounts on Mattermost, mmctl will be able to create the user, assign it to a team, join channels based on parameters given to the script, etc., so this could turn out to be an experience like:

# ./create-mattermost-account.sh username teamname functionassignment
./create-mattermost-account.sh alice companyXYZ developer
1 Like