Skip to main content
Skip table of contents

Slack DM Notifications

Overview

You can send step-by-step notifications to the requester, approvers, and executors of a workflow via Slack Direct Messages (DM). To ensure smooth receipt of DMs, ensure that the QueryPie user’s email matches the email address used in Slack.

The DM message can contain an 'Approve / Reject' button, enabling approvers to take action directly within Slack. Alternatively, you have the option not to include such a button.

To integrate QueryPie with the Slack Bot, you will need to input the Bot User OAuth Token obtained from the Slack app. Additionally, please note that adjustments to your internal network settings may be necessary for seamless communication with Slack servers.

To utilize the settings described below, it is imperative to have a Slack app configured beforehand. If you have not created an app yet, kindly reach out to us via the QueryPie Customer Portal support thread or get in touch with one of our authorized partners for assistance with app creation.

Set Up Slack DM

General Settings > Workflow Management > Approval Rules

  1. In General Settings > Workflow Management > Approval Rules, click on the top-right gear icon. (Accessible to Owners and Approval Admins)

  2. In the Workflow Configurations modal that appears, enable the third item labeled “Workflow Notifications via Slack Direct Messages”.

  3. Once enabled, an input field will appear where you can enter the Bot User OAuth Token for the Slack App you wish to integrate with.

  4. Additionally, if you enable the option Allow Users to Approve or Reject on Slack located at the bottom of the input field, approvers will have the ability to approve or reject workflow drafts directly from Slack by clicking the Approve / Reject button included in the messages.

Example of an Action Allowed type (left) / Example of an Action Disallowed type (right)

To ensure that users receive direct messages (DMs) correctly, it is important that your QueryPie user Email matches the email address you use in Slack.

You can locate the Bot User OAuth Token for your Slack app under the 'OAuth & Permissions' section in the app management menu.

Types of Slack DM Notifications

For a standard workflow with a pre-approval status, four types of notifications are dispatched according to progress:

  1. Approval request notifications

  2. Decline notifications

  3. Notification to the requester that approval is complete

  4. Execution available notifications

In the scenario of post-approval (Urgent Mode), the following four types of notifications are sent:

  1. Approval request notifications

  2. Execution available notifications

  3. Notification to the requester that approval is complete

  4. Urgent Mode unauthorized notifications

Approval Request Notifications

QueryPie supports all four types of workflows (SQL Request, SQL Export Request, DB Access Request, Server Access Request).

approval request notifications are triggered immediately that the first-level approver receives a notification upon the creation of a draft. Upon completion of the first level approval, the second level approver is notified, followed by the third-level approver upon completion of the second-level approval.

In cases where multiple approvers exist at each level, notifications are dispatched to all of them. Additionally, if any of the approvers have approval delegation set up, proxy approvers will also receive notifications. For detailed instructions on setting up approval delegation, refer to https://chequer.atlassian.net/wiki/spaces/QS1/pages/369787776.

Depending on your QueryPie admin's configurations, approvers receiving the notification may also approve or reject directly within Slack. Please refer to the section 'Setting Up Slack DM' above for the required settings.

Even in the absence of an action button, a 'Details' button is consistently provided. Clicking on it launches a web browser, prompting the QueryPie login window to appear. Upon successful login, users are directed to the Workflow details page.

For post-approval (Urgent Mode) drafts, a corresponding message is displayed. In such instances, only the 'Approve' button is visible, even if the Action button is utilized.

Normal mode approval request example (left) / Post-approval mode approval request example (right)

Decline Notifications

Decline notifications are applicable to all four types of workflows: SQL Request, SQL Export Request, DB Access Request, and Server Access Request.

In the event of a draft being rejected by any approver, a notification is promptly dispatched to the requester. The notification includes a comment detailing the reason for the rejection.

While no separate action button is provided, a 'Details' button is available. Clicking on it launches a web browser, presenting the QueryPie login window. Upon successful login, users are directed to the Workflow details page.

For post-approval (Urgent Mode) drafts, rejection cases are not applicable, thus no rejection message is sent.

Notify Requester That Approval Is Complete

This notification feature is applicable to all four types of workflows: SQL Request, SQL Export Request, DB Access Request, and Server Access Request.

A notification is dispatched to the requester upon the finalization of approval.

While no separate action button is provided, a 'Details' button is available. Clicking on it launches a web browser, presenting the QueryPie login window. After successful login, users are directed to the Workflow details page.

Even in cases where the draft is in Urgent Mode, the requester will receive a notification once all post-approvals have been completed.

Execution Available Notification

This notification feature applies to workflows that support two types: SQL Request and SQL Export Request, both of which include an 'Execute' action.

Upon finalizing authorization, a notification is dispatched to the designated executor.

While it does not contain a separate action button, a 'Details' button is provided. Clicking on it launches a web browser, presenting the QueryPie login window. After successful login, users are directed to the Workflow details page, from which SQL Requests and SQL Export Requests can be executed.

In cases where the draft is in Urgent Mode, the executor receives a notification immediately upon submission of the draft.

Urgent Mode Unauthorized Notifications

This notification feature applies to two types of workflows: SQL Request and SQL Export Request.

It serves to alert users when a draft that has been escalated to Urgent Mode remains unapproved for more than one day. Sent out once every morning, it targets approvers at that stage for all drafts older than a day.

If there are multiple approvers at each level, the message is distributed to all of them. Additionally, if any of the approvers have set up proxy approvals, the notification extends to their proxy approvers as well. For guidance on configuring proxy approvals, refer to Approval Delegation.

A separate message is dispatched for each unapproved draft. Therefore, if there are multiple unapproved drafts, multiple notifications will be generated. These messages are sent out at 10 am every morning, without distinction between business days and holidays.

Related Topics

 

Back to Workflow

JavaScript errors detected

Please note, these errors can depend on your browser setup.

If this problem persists, please contact our support.