Sample - Slack Web API
POST/admin.usergroups.addChannels

Add default channels to an IDP group

Adds one or more default channels to an IDP group. Provide the group identifier and a comma-separated list of channel identifiers, and optionally scope the change to a workspace with team_id. Authenticate with a token that has the admin.usergroups:write scope.

  • RetriesRetries up to 2×, 500ms backoff, 30s timeout.

1 parameter · 3 body fields
tokenstringrequired
Authentication token with the `admin.usergroups:write` scope.

IDP group channel associations submitted as form data.

usergroup_idstringrequired
ID of the IDP group to add default channels for.
team_idstringoptional
The workspace to add default channels in.
channel_idsstringrequired
Comma separated string of channel IDs.

2 status codes
200Returns an object with `ok` set to true when the channels are added to the IDP group.
okbooleanrequired
Allowed:true
defaultReturns an object with `ok` set to false when the request cannot be completed.
okbooleanrequired
Allowed:false

Error handling

The request must include usergroup_id and channel_ids. token must have the admin.usergroups:write scope, and channel_ids must be a comma-separated string of channel identifiers.