We're Hiring!

Mattermost, Inc.

Manage channels users CLI

Looking for commands to manage users in a private channel. I need to modify a channel member, making him a channel admin. Need to use CLI, as this is a private channel which I do not need to join (even as a system admin). Didn’t find any documentation that would be helpful. Is there such a command?

I’m on E10 license.

Hello, @phs

There is no CLI command that allow System Administrators to manually add users in a private channel, especially if the account is not a participant in the channel.

May I know if you are able to ask the channel admin to add the channel member instead and make the changes accordingly?

If not, is there any specific reason as to why it has to be done through your account?

There is no CLI command that allow System Administrators to manually add users in a private channel, especially if the account is not a participant in the channel.

However I just did this using ./mattermost channel add team:private-channel username, and it worked. Reference: https://docs.mattermost.com/administration/command-line-tools.html#mattermost-channel-add. What I need is now to make this username a Channel Admin.

May I know if you are able to ask the channel admin to add the channel member instead and make the changes accordingly?

If I could ask the current Channel Admin I wouldn’t be looking for a CLI command. I had the impression a System Admin could override anyone and anything in Mattermost.