> ## Documentation Index
> Fetch the complete documentation index at: https://docs.m3ter.com/llms.txt
> Use this file to discover all available pages before exploring further.

# Slack Functions

## Send Slack Error Message

**Function name:** `SendSlackErrorMessageFunction`
**Category:** Write
**Destination:** Slack

Sends a formatted workflow error message to Slack

### Parameters

| Name                       | Label       | Required | Description                   |
| -------------------------- | ----------- | :------: | ----------------------------- |
| `integrationCredentialsId` | Credentials |    Yes   | The Slack credentials to use. |
| `channelId`                | Channel ID  |    Yes   | Slack Channel ID              |

### Exits

| Exit    | Description |
| ------- | ----------- |
| `NEXT`  | -           |
| `ERROR` | -           |

## Send Slack Message

**Function name:** `SendSlackMessageFunction`
**Category:** Write
**Destination:** Slack

Sends message to a given Slack channel

### Parameters

| Name                       | Label               | Required | Description                                                                                                                                                                                 |
| -------------------------- | ------------------- | :------: | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| `integrationCredentialsId` | Credentials         |    Yes   | The Slack credentials to use.                                                                                                                                                               |
| `channelId`                | Channel ID          |    Yes   | Slack Channel ID                                                                                                                                                                            |
| `message`                  | Message             |    No    | The name of the object to pass as message text                                                                                                                                              |
| `contentBlocks`            | ContentBlocks       |    No    | The name of the object to pass as message blocks list                                                                                                                                       |
| `attachment`               | Attachment          |    No    | m3sh file to send as an attachment. N.B. Attachments cannot be sent using Slack webhook credentials. m3sh files that are sent as attachment can no longer be written to during the workflow |
| `compressAttachment`       | Compress attachment |    No    | Compress the contents of the attachment before sending to Slack                                                                                                                             |

### Exits

| Exit    | Description |
| ------- | ----------- |
| `NEXT`  | -           |
| `ERROR` | -           |

## Send Slack Webhook Error Message

**Function name:** `SendSlackWebhookErrorMessageFunction`
**Category:** Write
**Destination:** Slack

Sends a formatted workflow error message to Slack using a webhook

### Parameters

| Name                       | Label       | Required | Description                   |
| -------------------------- | ----------- | :------: | ----------------------------- |
| `integrationCredentialsId` | Credentials |    Yes   | The Slack credentials to use. |

### Exits

| Exit    | Description |
| ------- | ----------- |
| `NEXT`  | -           |
| `ERROR` | -           |

## Send Slack Webhook Message

**Function name:** `SendSlackWebhookMessageFunction`
**Category:** Write
**Destination:** Slack

Sends message to a given Slack channel using a webhook.

### Parameters

| Name                       | Label         | Required | Description                                           |
| -------------------------- | ------------- | :------: | ----------------------------------------------------- |
| `integrationCredentialsId` | Credentials   |    Yes   | The Slack credentials to use.                         |
| `message`                  | Message       |    No    | The name of the object to pass as message content     |
| `contentBlocks`            | ContentBlocks |    No    | The name of the object to pass as message blocks list |

### Exits

| Exit    | Description |
| ------- | ----------- |
| `NEXT`  | -           |
| `ERROR` | -           |
