Best Channel - Captain icon

Best Channel - Captain

Best Channel

Best Channel - Captain

AI-generated

Overview

This node filters input data items based on the specified best communication channel position (first, second, or third best channel) and routes them to corresponding outputs. It is useful in scenarios where you want to direct messages or notifications through the most preferred communication channel for each data item, such as SMS, email, WhatsApp, web push, app push, or Telegram.

Use Case Examples

  1. A marketing automation workflow that sends promotional messages through the best available channel for each customer.
  2. A notification system that routes alerts to the preferred communication channel of each user.

Properties

Name Meaning
Channel Position Specifies which best channel position to use for filtering (first, second, or third best channel).

Output

JSON

  • not-defined - Items without a valid best channel at the specified position or with an unrecognized channel.
  • sms - Items where the best channel at the specified position is SMS.
  • email - Items where the best channel at the specified position is Email.
  • whatsapp - Items where the best channel at the specified position is WhatsApp.
  • webPush - Items where the best channel at the specified position is Web Push.
  • appPush - Items where the best channel at the specified position is App Push.
  • telegram - Items where the best channel at the specified position is Telegram.

Troubleshooting

  • Ensure that the input data items contain a 'bestChannels' array with at least as many elements as the selected channel position; otherwise, items will be routed to the 'not-defined' output.
  • If the channel name in 'bestChannels' is not one of the recognized channels (sms, email, whatsapp, webPush, appPush, telegram), the item will be routed to the 'not-defined' output.

Discussion