We highly recommend you complete the Authoring Cards tutorial first. This is not strictly required, as we’ll show you where to find preloaded card templates you can use to send directly from the workbench.
There are three ways to send cards to your customers using Atomic:
- Directly from the
Customerssection in the Workbench.
- Using segment triggers.
- Using the Atomic
Action FlowAPI endpoint.
Each of these methods is outlined below.
Read the Advanced guide to sending cards if you want to learn more about adding card delivery options to the request payload when using one of the API endpoints.
Sending cards from the workbench
This option uses the Customers feature, which is currently in beta.
- To explore sending cards, we suggest working in your
Switch between environments by selecting the environment switcher in the top left:
- Navigate to the Customers section of the workbench:
In this screen you can select which customers you’d like to send a card to:
One, multiple or all customers
a. Select the checkboxes next to the customers.
b. Select ‘Send card to [n] customers’ button.
c. In the dropdown, select the card you wish to send and the stream(s) you wish to send it to.
d. Optional: add delivery detail: flow invocation ID, expiry or embargo values (expiry and embargo are based on your current time zone).
e. Select the ‘Send’ button.
A segment of customers
a. Select the Segment from the pre-configured segments.
b. Select the ‘select all’ checkbox.
c. Select ‘Send card to [n] customers’ button.
d. In the dropdown, select the card you wish to send and the stream(s) you wish to send it to.
e. Optional: add delivery detail: flow invocation ID, expiry or embargo values (expiry and embargo are based on your current time zone).
f. Select the ‘Send’ button.
Read more more about creating segments in the Customer segment section in our Help Docs.
You can send cards when customers enter or exit a segment, by adding a segment trigger to a card.
When you create a segment that has some customers in it and then later add an on-segment-entry trigger, a card will not be triggered to those customers (since they're not entering the segment, they're already in the segment).
When a customer exits a segment and then re-enters, they will be sent the same card again as long as the on-segment-entry trigger is associated with the card.
Setting up a typical on-segment-entry trigger
A common use case is setting up a segment trigger to send a card to customers that belong to a segment now, as well as customers who enter the segment later. The following steps describe how to do this, based on a customer's current home address:
- Have a look at the Customer segment section and set up a segment with a meaningful name, but with a filter or a tag that makes the segment completely empty (no customers should be part of this segment). One of the easiest ways to do this is, is adding a filter where
xyz. Save the segment.
- Navigate to the card you want to send to customers entering the segment.
- Select the
Triggerstab and then select the
Add segment triggeroption.
- Select the name of the segment from the dropdown menu and select
on segment entry.
- Now go back to the segment you created earlier, which currently holds no customers. You can now apply the right filters and see how the segment updates as you're applying the filters. Note this is only a preview of what the segment would look like, giving you the chance to check all the right customers have been added to the segment. Once you're satisfied with the (combination of) filters and/or tags applied, you can now
savethe segment. Once you hit the
savebutton, customers will be added to the segment and receive their card.
To send a test card to test users, they must be set up with test accounts in the workbench.
Add a new test user in the Workbench
- In the Workbench, go: Configuration > Testing > Test Accounts, and select 'New test account', and add the necessary details to create a test account:
- Name = Your name
- User ID = User Identifier (can be anything you choose)
- Send the provided magic link to the test user.
Sending test cards from the workbench
Send one-off test cards from the workbench
Test cards can be targeted to one or more Workbench members who are pre-configured in the Workbench as test Accounts.
You can send a test card easily from the Content area of the card by selecting the 'Send test card' icon in the bottom right corner. The test card will work almost identically to a real API event. The main difference is that test cards use the latest content of the card template, including unpublished draft edits, so you can test your un-published work-in-progress card.
Send a batch of test cards
Learn more about the Test Action Flow sender in the Tools guide.
Atomic Action Flows
As a first step to unlock the full Action Flow feature set, all cards can now be sent using its API start trigger. This is a URL which can be found in the
Triggers tab of the card you want to send.
Sending cards via its API start trigger using curl
A sample curl request looks like this:
# set Action Flow start API
"discount": "10 %"
"discount": "15 %"
"targetUserIds": ["user-1", "user-2"]
"discount": "12 %"
# send request to Atomic
curl -X POST "$START_API" \
--header "Content-Type:application/json" \
--header "Authorization: Bearer $TOKEN" \
Sending cards via its API start trigger using Insomnia
Setting up and using Insomnia to send API requests to the Action Flow endpoint is described in the Using Insomania guide. It also includes a link to import the Atomic Swagger Collection, which gives you access to all public API endpoints.
A similar request to the
Action Flow endpoint and its response when using Insomnia looks like this: