The SendGrid Event Webhook lets you stream all of the events that happen within an email directly to Keen IO for real time analysis and long term raw storage. These events are things like Delivered, Opened, Clicked, Marked as Spam… and lots more!
It only takes a couple minutes to start streaming data over and once you do you can start analyzing and visualizing your data in a whole bunch of different ways.
This guide covers:
- Send your SendGrid Data to Keen IO
- Analyze and Visualize your SendGrid Data
- Doing Drilldowns & Reporting on Your Data
- Embedding SendGrid Analytics Into Your App
Step 1: Create a Keen IO account
- Create a Keen IO account (if you don’t already have one)
Step 2: Activate SendGrid’s Event Notification App
First click on Mail Settings within Settings in the left column. Next, locate and activate the Event Notification Setting.
Enter the Keen HTTP POST URL, exampled below, as the endpoint where SendGrid will send event notifications. You can find your
KEEN_API_WRITE_KEY listed in the Access tab of your Keen project.
If you’re using Version 1 or 2 of the SendGrid Event API, use this as your Post Event URL instead:
In the settings, select the events you want to post to Keen IO (why not all of them?). To do this, check “Select All” under the “Select Actions”, or select just the ones you’d like to send to Keen IO.
That’s it! Now, as your emails make their way through SendGrid, all of the event information will be posted to Keen IO. A new Event Collection, aptly named “SendGrid Email Events”, will be created within your project.
Step 3: Send a test email!
To test this out, you can click on the “Test Your Integration” button in the Event Notification settings inside of SendGrid, which should create a set of sample email events from SendGrid into your Keen IO Project.
Your SendGrid email data should now be populated in Keen IO. To check, head over to your Keen IO project page. Check out the “Streams” tab, select “SendGrid Email Events” from the drop-down list, and then you can see your Last 10 Events streamed. This should show at least one of our delivered email events, or more if you went to your inbox and opened it!
Step 1: Log into your Keen account, select your Project
Open the “Streams” tab, and select the
SendGrid Email Events to check out your data collection.
Step 2: Run some basic queries
Open the “Explorer” tab
count as the “Analysis Type”, select
SendGrid Email Events as your “Collection Name”, and press “Run Query”. You ran a query!
The type of analysis you can do is vast, here’s a link to read up on what those are. Adding an “Interval” will give you a line graph over time, you can “Group By” properties to view results categorically, and you can add “Filters” to refine the scope of your query.
Save Your Query & Make Your First Dashboard
Step 1: Let’s save your first query
Step 2: Add your graph to a dashboard. Select “Create Dashboard”, name your dashboard, and add the query we saved to the first tile. Then click “Save”.
Congratulations! You’ve created your first dashboard!
Now start digging into your data and creating more custom analyses & visualizations.
Select_Unique allows you extract many properties from a single field and filter on a specific segment of users based on any number of fields such as campaigns, clicks, and companyID.
Return a list of unique property values for a single “Target Property”, among all events matching given criteria. You can download the results as a .CSV.
Some example uses for this analysis type:
- List all of the email addresses for people who clicked a certain URL
- List all of the countries where your email was opened
- List all of the email addresses for a specific company
- List all of the bounced emails from the last six months
Extraction feature returns full-form event data with all property values. We strongly believe you should always have full access to all of your data, and we aim to make that as simple and painless as possible.
You can do all the things you can do with
Select_Unique, but we will return you with more data.
Returns the number of unique actors that successfully (or unsuccessfully) make it through a series of steps. “Actors” could mean email addresses, campaigns, or any other identifiers that are meaningful to you.
Actors will fall off at each step, to varying degrees, so a funnel analysis reveals where a given flow loses the most users.
For example, a funnel could include these steps:
- Successful email delivery
- Opened email
- Clicked URL
- Lastly, you can grab a list of all of the actors in any step of your funnel, in this case, maybe you want a list of all the email addresses for people who opened an email and clicked a URL.
You can add as many filters as you’d like to make your funnel more targeted.
Here’s an example funnel:
Just like SendGrid, Keen IO is 100% powered by APIs. This means you can embed rich analytics anywhere you can write code. Here’s a link to our Native Analytics Guide that will give you step-by-step instructions on how to embed your SendGrid analytics into your product.
That concludes our guide for the day. Hope you have some fun with data and happy hacking!