Channel object
A channel object is a legacy object that contains information about a workspace channel. These channel objects are not the same object type as private channels, which are considered group objects. Channels and groups are now considered a type of conversation.
Channel object fields
| Field | Type | Description |
|---|---|---|
accepted_user | user_id | The user ID of the user who accepted a shared channel invite. |
connected_team_ids | Array of team_id | Team IDs of external workspaces connected via Slack Connect. |
context_team_id | team_id | The workspace or enterprise ID that provides the context for this channel object. Required field. |
created | Unix timestamp | Timestamp of when the channel was created. |
creator | String | The user ID of the member that created the channel. |
enterprise_id | enterprise_id | The Enterprise org ID this channel belongs to. |
frozen_reason | String | Reason the channel was frozen (e.g. Slack Connect disconnection). |
id | String | The channel ID. |
internal_team_ids | Array of workspace_id | Workspace IDs of internal (home-org) workspaces connected to this channel. |
is_archived | Boolean | true if the channel is archived. |
is_channel | Boolean | Indicates if it is a channel. |
is_frozen | Boolean | Whether the channel is frozen (e.g. a disconnected Slack Connect channel becomes a read-only frozen copy on the away-team side). |
is_general | Boolean | true if this channel is the "general" channel that includes all regular members. In most workspaces this is called #general, but some workspaces have renamed it. |
is_global_shared | Boolean | Whether the channel is shared across an entire Enterprise Grid org. |
is_member | Boolean | true if the calling member is part of the channel. |
is_moved | Integer | Indicates whether the channel has been moved; non-zero when a move has occurred. |
is_mpim | Boolean | Indicates if the channel is a multi-party instant message. |
is_non_threadable | Boolean | Whether threading is disabled in the channel; messages cannot have thread replies. |
is_org_default | Boolean | Whether the channel is a default org-wide channel (all new members are auto-added). |
is_org_mandatory | Boolean | Whether membership in the channel is mandatory (members cannot leave). |
is_org_shared | Boolean | Indicates if the organization which the channel belongs to is shared. |
is_pending_ext_shared | Boolean | Whether the channel is pending an external/Slack Connect share (invite sent but not yet accepted). |
is_private | Boolean | Indicates if the channel is private. |
is_read_only | Boolean | Whether the channel is read-only; members cannot post messages. |
is_shared | Boolean | true if the channel is shared. |
is_starred | Boolean | Whether the user has starred this channel. |
is_thread_only | Boolean | Whether the channel is thread-only; new messages can only be posted as thread replies. |
last_read | Unix timestamp | The timestamp for the last message the calling user has read in this channel. |
latest | Object | The latest message in the channel. |
members | Array | A list of user IDs for all users in this channel. This includes any disabled accounts that were in this channel when they were disabled. |
name | String | Indicates the name of the channel-like thing, without a leading hash sign. Don't get too attached to that name. It might change. Don't even bother storing it. When thinking about channel-like things, think about their IDs, their type, and the team/workspace they belong to. |
name_normalized | String | A normalized string of the name. |
num_members | Integer | Number of members in the channel. |
pending_shared | Array of workspace_id | Workspace IDs for workspaces that have a pending share invitation to this channel. |
previous_names | Array | A list of prior names the channel has used. |
priority | Number | Sort priority of the channel in the user's sidebar. |
properties | Object | Additional channel properties. |
purpose | Object | The purpose of the channel. |
retention_duration | Integer | Custom message retention duration for the channel, in days. |
shared_team_ids | Array of workspace_id | Workspace IDs of all workspaces that are part of this shared channel. |
topic | Object | The topic of the channel. |
unlinked | Integer | Whether channel was ever shared/disconnected. |
unread_count | Integer | A full count of visible messages that the calling user has yet to read. |
unread_count_display | Integer | A count of messages that the calling user has yet to read that matter to them (this means it excludes things like join/leave messages). |
Example
{
"channel": {
"id": "C1H9RESGL",
"name": "busting",
"is_channel": true,
"created": 1466025154,
"creator": "U0G9QF9C6",
"is_archived": false,
"is_general": false,
"name_normalized": "busting",
"is_shared": false,
"is_org_shared": false,
"is_member": true,
"is_private": false,
"is_mpim": false,
"last_read": "1503435939.000101",
"latest": {
"text": "Containment unit is 98% full",
"username": "ecto1138",
"bot_id": "B19LU7CSY",
"attachments": [
{
"text": "Don't get too attached",
"id": 1,
"fallback": "This is an attachment fallback"
}
],
"type": "message",
"subtype": "bot_message",
"ts": "1503435956.000247"
},
"unread_count": 1,
"unread_count_display": 1,
"members": [
"U0G9QF9C6",
"U1QNSQB9U"
],
"topic": {
"value": "Spiritual containment strategies",
"creator": "U0G9QF9C6",
"last_set": 1503435128
},
"purpose": {
"value": "Discuss busting ghosts",
"creator": "U0G9QF9C6",
"last_set": 1503435128
},
"previous_names": [
"dusting"
]
}
}