Alexander Meise
Alexander Meise

Reputation: 1438

How can I deactivate an slack user via slash-commands?

I want to create a bot that deactivates users under some criteria. I can not find any slash command that deactivates user accounts for free slack groups. I only see the option to kick from channel.

For paid versions the following can be used:

https://github.com/ErikKalkoken/slackApiDoc/blob/master/users.admin.setInactive.md

Upvotes: 1

Views: 1421

Answers (2)

Erik Kalkoken
Erik Kalkoken

Reputation: 32852

To my knowledge there is no API methods to "kick" users automatically that works for free slack teams, so you will have to manually deactivate users you want to kick.

As a workaround I have a small bot running on my slack teams that report daily in a special admin channel which users need to be manually deactivated. That works of course only if you have a hard criteria that you can use to can test if a user is still eligible to be member of your Slack team.

Upvotes: 1

Joel
Joel

Reputation: 754

You can't do that. Slack exposes a SCIM API for user management, but it is not available for free teams.

Upvotes: 2

Related Questions