Table of Contents

How to send a message in a channel in Slack when voiding a sales order?

The following is required to send a message in Slack when а sales order is voiding:

Webhook template

Below is an example of what the webhook template should contain.

Attribute name Attribute value
Code slack_void_01
Name Slack - voiding a sales order
Repository name Crm.Sales.SalesOrders
URL https://slack.com/api/chat.postMessage?channel=<channel>&text=<{DisplayText}>
Headers Authorization: Bearer <accessToken>
Notes Sends a message in a Slack channel when a sales order is voiding.

Where,

  • <channel> - the Slack channel where the message will be sent.
  • {DisplayText} - the message contents. It is also an interpolated string. It will be evaluated by ERP.net and will contain the display text of the sales order (e.g., Sales Order 00108).
  • <accessToken> - the access token provided from Slack.
Note

Body attribute is missing intentionally. It's not required.

User business rule

А business rule that triggers when a sales order is voiding.

Repository
Crm.Sales.SalesOrders
Events
Event type Event parameter Execution priority
VOIDING Normal
Actions
Action No Action type Parameter1 type Parameter1 value
1 WEBHOOK Constant slack_void_01

See more