Skip to content

Feature Request: usergroups.users.add / usergroups.users.remove Web API methods #1898

Description

@BrettMoan

Acknowledgment

I realize this is a request about the Slack Web API itself, not this SDK specifically — so
this may be the wrong repo. But the slack-api-specs repo doesn't appear to be actively
monitored, and this is where I see Slack's developer relations team engaging with the
community. Happy to move this if there's a better place.

Problem

The only Web API method for managing usergroup membership is usergroups.users.update,
which does a full replacement of the entire member list. There is no way to add or remove
individual users.

This creates real problems for automation and Infrastructure-as-Code tooling:

  • Brittle lookups: To add one person, you must first resolve every existing member,
    then push the full list back. If any single member lookup fails (e.g., a recently
    deactivated user via users.lookupByEmail returning users_not_found), the entire
    operation fails — even for unrelated members. This makes managing usergroup membership
    as code particularly painful, since other identity providers (GitHub, Google Workspace,
    PagerDuty) gracefully handle deactivated accounts. Slack's full-replacement pattern
    means one stale account blocks all membership updates for the entire group.
  • Race conditions: Two automations that each add a user concurrently will clobber
    each other, since both read the current list, append their user, and write back.
  • No parity with other Slack APIs: Channels have per-member add/remove
    (conversations.invite / conversations.kick). Usergroups don't.

The capability may already exist

Slack Workflow Builder exposes add_user_to_usergroup and remove_user_from_usergroup
built-in functions that accept a usergroup_id and user_ids array. The naming and
interface suggest these perform incremental membership changes rather than full
replacement — though it's possible they wrap usergroups.users.update internally.

Either way, the fact that Workflow Builder surfaces this as an add/remove abstraction
signals that the use case is recognized. Exposing similar functionality as Web API
methods would be valuable for external automation tooling.

Request

Expose these as Web API methods, e.g.:

  • usergroups.users.add — add one or more users to a usergroup without affecting
    existing members
  • usergroups.users.remove — remove one or more users from a usergroup without
    affecting other members

Same scopes (usergroups:write), same inputs (usergroup_id, user_ids), just
accessible via the Web API like every other method.

Use case

We manage our Slack usergroups programmatically via the API — using third-party Terraform
providers since there isn't a first-party one. When someone leaves and their Slack account
is deactivated, the users.lookupByEmail call fails with users_not_found, which blocks
the full-replacement membership update for the entire group. Per-user add/remove endpoints
would let any automation tooling manage membership incrementally and avoid this class of
failure entirely.

This likely affects anyone managing usergroups at scale through the API — the
full-replacement pattern becomes increasingly fragile as group sizes and the number of
groups grow.

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementM-T: A feature request for new functionality

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions