Skip to main content

Slack

This connector lets you materialize data from Estuary directly into Slack channels.

Prerequisites​

To use this connector, ensure you have the following:

  1. An active Slack workspace with appropriate permissions.
  2. Slack credentials and access token for authentication.
  3. At least one Estuary collection.

Configuration​

The Slack connector is available for use in the Estuary web application. To learn more about connectors and how to set them up, read our guide on using connectors.

Endpoint​

PropertyTitleDescriptionTypeRequired/Default
/access_tokenAccess TokenThe Slack API access token for authentication.stringRequired
/client_idClient IDClient ID for authentication.stringRequired
/client_secretClient SecretThe Slack API client secret.stringRequired
/advanced/raw_messagesRaw MessagesSend the text and blocks of each document to Slack as written instead of escaping them. See Message format.booleanfalse

Bindings​

PropertyTitleDescriptionTypeRequired/Default
/sourceSourceSource data in Estuary to be sent to Slack.stringRequired
/channelChannelThe ID of the Slack channel to send messages to.stringRequired
/display_nameDisplay NameThe display name for the sender in Slack.string
/logo_emojiLogo EmojiThe emoji to be used.string

Message format​

Each document is sent as one Slack message, built from these fields of the source collection:

FieldDescriptionRequired
tsMessage timestamp in RFC 3339 format. Documents with a timestamp more than 10 minutes in the past are skipped.Required
textThe message text.Required
blocksAn array of Block Kit blocks for a rich message.Optional

By default, the connector escapes &, <, and > in text and in every string inside blocks, so Slack displays them as written. Formatting such as *bold*, _italic_, and emoji codes still applies, but <...> sequences such as <!channel>, <@U123>, and <url|label> are not turned into mentions or links.

To send mentions and labeled links, enable Raw Messages under Advanced configuration. The connector then sends text and blocks unchanged, and Slack interprets every <...> sequence in them. The setting applies to all bindings of the materialization, so only enable it when everything written to the source collections is trusted. Escape &, <, and > yourself in any text that should appear literally, as described in Slack's formatting guide.

Sample​

materializations:
${PREFIX}/${MATERIALIZATION_NAME}:
endpoint:
connector:
image: ghcr.io/estuary/materialize-slack:v1
config:
credentials:
auth_type: OAuth
access_token: {secret}
client_id: {your_client_id}
client_secret: {secret}
bindings:
- source: ${PREFIX}/source_name
resource:
channel: "id: C05A95LJHSL"
sender_config:
display_name: Task Monitor
logo_emoji: ":eyes:"