How To Send A Product Notification
This guide will walk you through triggering a product notification using the Courier Send API or a Segment integration through an automation.
Send a Notification
There are two primary ways in which you can send a notification. You can trigger a send via the Courier Send API, or via a Segment event.
You can access the code snippet to send your notification via the Courier Send API by selecting the Send
tab from within the notification designer, and select the runtime that you want to use to make the send call from.
Your Product Notification Template
Generating a Code Snippet
Once you have completed the required steps, you’ll be able to generate a code snippet and send a test Notification.
Code Snippet
To generate the right code snippet for your stack and start sending your notification to live users, confirm you have the right selection for these three settings:
Select Your Programming Stack
- Choose between a list of programming languages that best fits your server stack to send your notification
Set the Notification Test Event
- Choose the test event you wish to use with your notification to include the correct data and recipient profile sent in the request.
Recipient Profile Set
- Make sure your test event includes a recipient profile so the request can successfully send.
Sending a Test Notification
After you configure the code snippet, setting these values will allow you to send a test Notification from the Send Tab:
Select a Test event
- Selecting a test event modifies the send request with the selected
data
andprofile
payloads you wish to test your request with.
Select a Brand
- Brand selection is used to give your notification content a consistent look depending on your company brand colors and styling. Available for Email and Courier Inbox.
Send a Test Notification
- Alternatively, instead of copying a code snippet and sending it, you can send directly from the send tab page by clicking
Send Test
.
Copy the Code Snippet
- The code snippet can be copied and pasted in your implementation to fire off a notification.
Read more: How to Send a Notification
Sending With Segment
In order to trigger a notification from a Segment event, you will first need to install the Courier destination in your Segment account, and then create a Courier automation.
Automations Overview
Linking Segment to an Automation
Once you have created an Automation, you need to configure the Segment event as the automation trigger.
Setting Up Your Automations Triggers