Channels
Create, update, and query the available channels in Slack.
Select
The provider uses the Slack API to process search criteria that refer to the Id, IsArchived, IsPublic, IsPrivate, IsDirectMessage, IsMultipartyDirectMessage and User columns. These columns support server-side processing for the = operator. The provider processes other filters client-side within the provider.
For example, the following queries are processed server side by the Slack APIs:
SELECT * FROM Channels WHERE IsPublic = false AND IsArchived = true SELECT * FROM Channels WHERE Id = 'D71R6CSR1' SELECT * FROM Channels WHERE User = 'U03AZBU3CMT'
Insert
The Name column is the minimum requirement for an insert. Name and IsPublic are the only columns that can be set on an insert.
INSERT INTO Channels (Name, IsPublic) VALUES ('initialname', true)
Update
The Channels table allows updates for columns Name, Purpose, and Topic when Id is specified.
UPDATE Channels SET Topic = 'A Topic Text', Purpose = 'A Purpose Text', Name = 'updatedname' WHERE Id = 'D71R6CSR1'
Delete
Slack does not allow Channels to be deleted.
Columns
| Name | Type | ReadOnly | References | Description |
| Id [KEY] | String | True |
The Id of the channel. | |
| Name | String | False |
The name of the channel. | |
| Topic | String | False |
Information about the channel topic. | |
| TopicCreator | String | True |
The creator of the channel topic. | |
| Purpose | String | False |
Information about the channel purpose. | |
| TotalMembers | Integer | True |
The number of members in the channel. | |
| Created | Datetime | True |
The datetime of the Channel creation. | |
| Creator | String | True |
Users.Id |
The user ID of the member that created this channel. |
| LastRead | Datetime | True |
The datetime for the last message the calling user has read in this channel. | |
| IsMember | Boolean | True |
Indicates whether the user, bot user, or Slack app associated with the token making the API call is itself a member of the conversation. | |
| IsArchived | Boolean | True |
Indicates whether a conversation is archived. | |
| IsPublic | Boolean | False |
Indicates whether a conversation is a public channel. Everything said in a public channel can be read by anyone else belonging to a workspace. | |
| IsGroup | Boolean | True |
Indicates whether the channel is a private channel between a group of members. | |
| IsDirectMessage | Boolean | True |
Indicates whether the conversation is a direct message between two distinguished individuals or a user and a bot. | |
| IsMultipartyDirectMessage | Boolean | True |
Represents an unnamed private conversation between multiple users. | |
| IsGeneral | Boolean | True |
Indicates whether the channel is the workspace's 'general' discussion channel. | |
| Unlinked | Integer | True |
Number of times a link to the channel has been removed. | |
| NameNormalized | String | True |
The normalized name of the channel. | |
| IsShared | Boolean | True |
Indicates whether the conversation is in some way shared between multiple workspaces. | |
| IsExtShared | Boolean | True |
Indicates whether this conversation is part of a Shared Channel with a remote organization. | |
| IsOrgShared | Boolean | True |
Indicates whether this shared channel is shared between Enterprise Grid workspaces within the same organization. | |
| IsPendingExtShared | Boolean | True |
Indicates whether the conversation is ready to become an IsExtShared channel but needs some kind of approval or sign off. | |
| PreviousNames | String | True |
A list of previous names this channel has had. | |
| Locale | String | True |
The locale of the channel. | |
| User | String | True |
The Id of the user. | |
| IsUserDeleted | Boolean | True |
Indicates whether the user is deleted. | |
| Priority | String | True |
The priority of the channel. | |
| ItemURL | String | True |
The URL of the Channel. | |
| IsPrivate | Boolean | True |
Indicates whether a conversation is a private channel. | |
| IsChannel | Boolean | True |
Indicates whether a conversation is a channel. | |
| IsFrozen | Boolean | True |
Indicates whether a conversation is frozen. | |
| PendingShared | String | True |
The pending shared. | |
| ContextTeamId | String | True |
The context team Id. | |
| Updated | Timestamp | True |
The timestamp, in milliseconds, when the channel settings were updated (for example, the 'topic' or 'description' of the channel changed). | |
| TopicLastSet | Datetime | True |
Provides information about the channel topic. | |
| ParentConversation | String | True |
The parent conversation. | |
| SharedTeamIds | String | True |
The Ids of the shared teams. | |
| PendingConnectedTeamIds | String | True |
The Ids of the pending connected teams. | |
| PurposeCreator | String | True |
The creator of the channel purpose. | |
| PurposeLastSet | Datetime | True |
Provides information about the channel purpose. | |
| Properties | String | True |
Additional channel properties. |
Pseudo-Columns
Pseudo column fields are used in the WHERE clause of SELECT statements. These offer a more granular control over the tuples that are returned from the data source.
| Name | Type | Description |
| TeamId | String |
The Id of the team. DEPRECATED. |
| ChannelType | String |
The type of channel to include or exclude in the search. To filter with channel type, UseSearch property must be enabled. Possible values are : private, private_exclude, archived, exclude_archived, private_exclude_archived, multi_workspace, org_wide, external_shared_exclude, external_shared, external_shared_private, external_shared_archived, exclude_org_shared |