SlideShare a Scribd company logo
Email as a datasource for apps 
Tony Blank 
tony@context.io 
@thetonyblank
“The reports of my death 
were greatly exaggerated” 
- Email
4.93 .b9 ibllililoionn ibny 2 0210317 
183B messages/day 
400M tweets/day
group collaboration 
task management 
document collaboration 
customer support 
app notification 
Email is a communications system 
! 
project management 
client relationship 
applicant tracking 
photo sharing 
bug tracking 
Nigerian extortion
Overview of protocols and standards 
or “which acronym does what”
SMTP Protocol for 
transmission of emails 
across the internet
IMAP 
Protocol to allow a 
client to access and 
manipulate emails on a 
receiving server.
• All messages and their folder 
organization are on the server 
• Clients poll to know about new 
messages that arrive or 
actions made through other 
clients 
• While it doesn’t send 
messages, clients usually 
store sent messages through it
POP Protocol to allow a 
client to retrieve emails 
from a receiving server.
RFC-822 
MIME 
Multipart 
Standards defining 
headers and the actual 
body of the message
Where does your app fit in there?
Typical 
things apps 
want to do 
with email 
1. Send emails to users 
2. Receive emails from users 
3. Access emails users send and 
receive.
group collaboration 
task management 
document collaboration 
customer support 
app notification 
Email is a communications system 
! 
project management 
client relationship 
applicant tracking 
photo sharing 
bug tracking 
Nigerian extortion
Email As A Datasource
Email As A Datasource
Email As A Datasource
Email As A Datasource
Email As A Datasource
Email As A Datasource
Introduction to IMAP
Me: “App Developer, meet IMAP. IMAP, 
meet App Developer.” 
! 
IMAP: “I don’t give a shit about you, App 
Developer. Go away!”
Pitfall #1: Identifying messages
Sequence Number
Unique Identifier 
(aka UID)
Pitfall #2: 
No data until you 
select a mailbox
Pitfall #3: 
Attachments
Pitfall #4: 
Deleting messages
Email As A Datasource
The joys of parsing email messages 
Yo! I fetched a message! Now what do I do?
A simple message 
Delivered-­‐To: 
sysadmin@context.io 
Return-­‐Path: 
<2012050639be@bounces.amazon.com> 
Received: 
by 
10.229.135.136 
with 
SMTP 
id 
n8mr410292qct.135.1336583200550; 
Wed, 
09 
May 
2012 
10:06:40 
-­‐0700 
(PDT) 
Received: 
from 
smtp-­‐out.amazon.com 
(smtp-­‐out.amazon.com. 
[72.21.212.39]) 
by 
mx.google.com 
with 
ESMTP 
id 
b2si1383913qcd.195.2012.05.06.40; 
Wed, 
09 
May 
2012 
10:06:40 
-­‐0700 
(PDT) 
Date: 
Wed, 
9 
May 
2012 
17:06:39 
+0000 
(UTC) 
From: 
Amazon 
EC2 
Notification 
<no-­‐reply-­‐aws@amazon.com> 
To: 
"Sys 
Admin" 
<sys@context.io> 
Cc: 
"Alerts" 
<alerts@context.io> 
Message-­‐ID: 
<urn.correios.msg.2012050639be@1336583199032.us-­‐1.amazon.com> 
Subject: 
Notice: 
Amazon 
EC2 
Instance 
scheduled 
for 
retirement 
MIME-­‐Version: 
1.0 
Content-­‐Type: 
text/plain; 
charset=UTF-­‐8 
Content-­‐Transfer-­‐Encoding: 
7bit 
! 
Hello, 
...
A message with an attachment 
MIME-­‐Version: 
1.0 
Content-­‐Type: 
multipart/mixed; 
boundary=_MYBOUNDARY_ 
! 
-­‐-­‐_MYBOUNDARY_ 
Content-­‐Type: 
text/plain 
! 
This 
is 
the 
body 
of 
the 
message. 
-­‐-­‐_MYBOUNDARY_ 
Content-­‐Type: 
image/jpeg; 
name="IMG_713.jpg" 
Content-­‐Disposition: 
attachment; 
filename="IMG_713.jpg"; 
size=6379099; 
Content-­‐Transfer-­‐Encoding: 
base64 
! 
/9j/4AAQSkZJRgABAgAAZABkAAD/7AARRHVja3kAAQAEAAAAZA+4AJkFkb2JlAGTAAAAAAQMA 
AwMDAwMDAwMDAwMDAwMDAwMDAwMDAwMDAwMDAwMDAwMDAwMDAwMDAwMD8IAEQgAegG1AwERAI 
RAQMRAfEASMAAQACAwEBAQEBAAAAAAAAAAAHCAUGCQQDAgEKAQEAAgIDAQAAAAAAAAAAAAAAB 
gcFCAEDBAIQAAEEAgEBBgQGAQUAAAAAAAUCAwQGAQcAEjBQERMUFRBgFhcgQHAhNAhBMSIjJD 
URAAIC== 
-­‐-­‐_MYBOUNDARY_-­‐-­‐
A message with alternative parts 
MIME-­‐Version: 
1.0 
Content-­‐Type: 
multipart/alternative; 
boundary=_MYBOUNDARY_ 
! 
-­‐-­‐_MYBOUNDARY_ 
Content-­‐Type: 
text/plain; 
charset="us-­‐ascii" 
Content-­‐Transfer-­‐Encoding: 
quoted-­‐printable 
! 
Hello! 
Here’s 
a 
message 
with 
*rich* 
text 
-­‐-­‐_MYBOUNDARY_ 
Content-­‐Type: 
text/html; 
charset="us-­‐ascii" 
Content-­‐Transfer-­‐Encoding: 
quoted-­‐printable 
! 
<html><body>Hello! 
Here’s 
a 
message 
with 
<b>rich</b> 
text</body></html> 
-­‐-­‐_MYBOUNDARY_-­‐-­‐
Pitfall #1: 
Message-ID is optional
Pitfall #2: 
In-Reply-To References
Pitfall #3: 
Attachments are what you 
decide them to be
Email As A Datasource
Email As A Datasource
contacts 
messages files 
threads 
webhooks
Email as a datasource for apps 
Tony Blank 
tony@context.io 
@thetonyblank

More Related Content

PPTX
Presentasi Bahasa Inggris " Email "
PPT
Email Headers – Expert Forensic Analysis
PPT
How e-mail, chat, ATM, Skype, VOIP, online submission (online forms), online ...
PPTX
E-mail Investigation
PPTX
Internet and Email 101 v1
PPT
Intro to email for seniors
PDF
Email Forensics
PPT
Tutorial 2 - Basic Communication on the Internet: Email
 
Presentasi Bahasa Inggris " Email "
Email Headers – Expert Forensic Analysis
How e-mail, chat, ATM, Skype, VOIP, online submission (online forms), online ...
E-mail Investigation
Internet and Email 101 v1
Intro to email for seniors
Email Forensics
Tutorial 2 - Basic Communication on the Internet: Email
 

What's hot (20)

PPTX
Electronic mail
DOCX
How email works
PPTX
Email - electronic mail
PPTX
Email: Introduction
PPT
Mail services
PPT
E Mail
PDF
E-Mail Header- A Forensic Key to Examine an E-Mail
PPTX
Computer navigation basics
PPTX
Electronic mail
PPT
E mail systems
PDF
Safe Email Practices
PPT
Basics of E-Mail
PPTX
Introduction to Email
PPTX
E mail features
PPT
Tutorial 06 - Real-Time Communication on the Internet
 
PPTX
Alternative Methods Of Communication To Consumer
PPTX
Electronic mail
PPT
PPT
E mail systems
PPT
Electronic mail
How email works
Email - electronic mail
Email: Introduction
Mail services
E Mail
E-Mail Header- A Forensic Key to Examine an E-Mail
Computer navigation basics
Electronic mail
E mail systems
Safe Email Practices
Basics of E-Mail
Introduction to Email
E mail features
Tutorial 06 - Real-Time Communication on the Internet
 
Alternative Methods Of Communication To Consumer
Electronic mail
E mail systems
Ad

Viewers also liked (6)

PDF
13.07.10 nagarjuna vidyaniketan
PDF
Diario Expooptica
PPTX
Proyecto implementacion de las tics en la Escuela Luis Conrado
PDF
Wright Express/ rapid! PayCard
DOCX
Configuring e mail notificationin nagios core
PPT
MAC_ICT_Mirea_11
13.07.10 nagarjuna vidyaniketan
Diario Expooptica
Proyecto implementacion de las tics en la Escuela Luis Conrado
Wright Express/ rapid! PayCard
Configuring e mail notificationin nagios core
MAC_ICT_Mirea_11
Ad

Similar to Email As A Datasource (20)

PDF
Email as a datasource for applications
PPTX
grade 6.pptx
PPTX
L5_Electronic communication.pptx
PDF
E-Mail Security Protocol - 1 Privacy Enhanced Mail (PEM) Protocol
PDF
How to Trace an E-mail Part 1
PDF
3150710_CN_GTU_Study_Material_Presentations_Unit-2_13082021073829PM.pdf
PPTX
CoLabora - Exchange Online Protection - June 2015
PPTX
Voice enable smtp client
PPTX
Mail server using Linux(Ubuntu)
PPTX
Forensics Analysis of Email cyber forensics
PPT
Email
PPTX
BRK3161_Gagnon copilot for m365 microsoft
DOCX
Internet 8th level imen tek bouaziz 2016
PPT
Internet Tutorial 02
 
PPT
Email ftp
PPTX
presentation on email.pptx
PPT
Mail server
PPT
Mail server
PPT
E-Mail Crimes - Gurugram Cyber Crime Cell July 2017
Email as a datasource for applications
grade 6.pptx
L5_Electronic communication.pptx
E-Mail Security Protocol - 1 Privacy Enhanced Mail (PEM) Protocol
How to Trace an E-mail Part 1
3150710_CN_GTU_Study_Material_Presentations_Unit-2_13082021073829PM.pdf
CoLabora - Exchange Online Protection - June 2015
Voice enable smtp client
Mail server using Linux(Ubuntu)
Forensics Analysis of Email cyber forensics
Email
BRK3161_Gagnon copilot for m365 microsoft
Internet 8th level imen tek bouaziz 2016
Internet Tutorial 02
 
Email ftp
presentation on email.pptx
Mail server
Mail server
E-Mail Crimes - Gurugram Cyber Crime Cell July 2017

More from Cloud Elements (20)

PDF
10 Step Guide to API Integrations
PDF
How to Build Platforms, Not Products
PDF
State of API Integration Report 2017
PDF
Cloud Elements | State of API Integration Report 2018
PPTX
All Things API Presentation - Gordon Weakleim [HomeAway]
PDF
Atlassianconnectadd onsforeveryplatform-tanguycrusson-140925195129-phpapp01
PDF
Lean Product Development 101
PPTX
Building Event Driven API Services Using Webhooks
PPTX
Lean Product Development 101
PPT
'Scalable Logging and Analytics with LogStash'
PDF
The Entrepreneurial Methodology: How engineers can harness the madness in a n...
PPTX
Cloud Elements Documents Hub
PPTX
Data normalization across API interactions
PDF
Filtering From the Firehose: Real Time Social Media Streaming
PPTX
Lean Product Development for Startups- Denver Startup Week
PPTX
Appx for Developers
PPTX
Lean product development for startups
PDF
Using a simple Ruby program to interface with quickly provisioned cloud appli...
PDF
Money & Bitcoin & the Cloud: It's all just data streams, anyway!
PPTX
API Versioning in the Cloud
10 Step Guide to API Integrations
How to Build Platforms, Not Products
State of API Integration Report 2017
Cloud Elements | State of API Integration Report 2018
All Things API Presentation - Gordon Weakleim [HomeAway]
Atlassianconnectadd onsforeveryplatform-tanguycrusson-140925195129-phpapp01
Lean Product Development 101
Building Event Driven API Services Using Webhooks
Lean Product Development 101
'Scalable Logging and Analytics with LogStash'
The Entrepreneurial Methodology: How engineers can harness the madness in a n...
Cloud Elements Documents Hub
Data normalization across API interactions
Filtering From the Firehose: Real Time Social Media Streaming
Lean Product Development for Startups- Denver Startup Week
Appx for Developers
Lean product development for startups
Using a simple Ruby program to interface with quickly provisioned cloud appli...
Money & Bitcoin & the Cloud: It's all just data streams, anyway!
API Versioning in the Cloud

Recently uploaded (20)

PDF
Enhancing emotion recognition model for a student engagement use case through...
PPTX
Group 1 Presentation -Planning and Decision Making .pptx
PDF
A comparative study of natural language inference in Swahili using monolingua...
PDF
From MVP to Full-Scale Product A Startup’s Software Journey.pdf
PDF
7 ChatGPT Prompts to Help You Define Your Ideal Customer Profile.pdf
PPTX
OMC Textile Division Presentation 2021.pptx
PDF
Building Integrated photovoltaic BIPV_UPV.pdf
PDF
ENT215_Completing-a-large-scale-migration-and-modernization-with-AWS.pdf
PDF
Web App vs Mobile App What Should You Build First.pdf
PPTX
Programs and apps: productivity, graphics, security and other tools
PDF
Hindi spoken digit analysis for native and non-native speakers
PDF
Profit Center Accounting in SAP S/4HANA, S4F28 Col11
PDF
MIND Revenue Release Quarter 2 2025 Press Release
PDF
Transform Your ITIL® 4 & ITSM Strategy with AI in 2025.pdf
PPTX
A Presentation on Touch Screen Technology
PDF
Mushroom cultivation and it's methods.pdf
PDF
gpt5_lecture_notes_comprehensive_20250812015547.pdf
PPTX
TLE Review Electricity (Electricity).pptx
PDF
NewMind AI Weekly Chronicles - August'25-Week II
PDF
DASA ADMISSION 2024_FirstRound_FirstRank_LastRank.pdf
Enhancing emotion recognition model for a student engagement use case through...
Group 1 Presentation -Planning and Decision Making .pptx
A comparative study of natural language inference in Swahili using monolingua...
From MVP to Full-Scale Product A Startup’s Software Journey.pdf
7 ChatGPT Prompts to Help You Define Your Ideal Customer Profile.pdf
OMC Textile Division Presentation 2021.pptx
Building Integrated photovoltaic BIPV_UPV.pdf
ENT215_Completing-a-large-scale-migration-and-modernization-with-AWS.pdf
Web App vs Mobile App What Should You Build First.pdf
Programs and apps: productivity, graphics, security and other tools
Hindi spoken digit analysis for native and non-native speakers
Profit Center Accounting in SAP S/4HANA, S4F28 Col11
MIND Revenue Release Quarter 2 2025 Press Release
Transform Your ITIL® 4 & ITSM Strategy with AI in 2025.pdf
A Presentation on Touch Screen Technology
Mushroom cultivation and it's methods.pdf
gpt5_lecture_notes_comprehensive_20250812015547.pdf
TLE Review Electricity (Electricity).pptx
NewMind AI Weekly Chronicles - August'25-Week II
DASA ADMISSION 2024_FirstRound_FirstRank_LastRank.pdf

Email As A Datasource

  • 1. Email as a datasource for apps Tony Blank tony@context.io @thetonyblank
  • 2. “The reports of my death were greatly exaggerated” - Email
  • 3. 4.93 .b9 ibllililoionn ibny 2 0210317 183B messages/day 400M tweets/day
  • 4. group collaboration task management document collaboration customer support app notification Email is a communications system ! project management client relationship applicant tracking photo sharing bug tracking Nigerian extortion
  • 5. Overview of protocols and standards or “which acronym does what”
  • 6. SMTP Protocol for transmission of emails across the internet
  • 7. IMAP Protocol to allow a client to access and manipulate emails on a receiving server.
  • 8. • All messages and their folder organization are on the server • Clients poll to know about new messages that arrive or actions made through other clients • While it doesn’t send messages, clients usually store sent messages through it
  • 9. POP Protocol to allow a client to retrieve emails from a receiving server.
  • 10. RFC-822 MIME Multipart Standards defining headers and the actual body of the message
  • 11. Where does your app fit in there?
  • 12. Typical things apps want to do with email 1. Send emails to users 2. Receive emails from users 3. Access emails users send and receive.
  • 13. group collaboration task management document collaboration customer support app notification Email is a communications system ! project management client relationship applicant tracking photo sharing bug tracking Nigerian extortion
  • 21. Me: “App Developer, meet IMAP. IMAP, meet App Developer.” ! IMAP: “I don’t give a shit about you, App Developer. Go away!”
  • 25. Pitfall #2: No data until you select a mailbox
  • 29. The joys of parsing email messages Yo! I fetched a message! Now what do I do?
  • 30. A simple message Delivered-­‐To: sysadmin@context.io Return-­‐Path: <2012050639be@bounces.amazon.com> Received: by 10.229.135.136 with SMTP id n8mr410292qct.135.1336583200550; Wed, 09 May 2012 10:06:40 -­‐0700 (PDT) Received: from smtp-­‐out.amazon.com (smtp-­‐out.amazon.com. [72.21.212.39]) by mx.google.com with ESMTP id b2si1383913qcd.195.2012.05.06.40; Wed, 09 May 2012 10:06:40 -­‐0700 (PDT) Date: Wed, 9 May 2012 17:06:39 +0000 (UTC) From: Amazon EC2 Notification <no-­‐reply-­‐aws@amazon.com> To: "Sys Admin" <sys@context.io> Cc: "Alerts" <alerts@context.io> Message-­‐ID: <urn.correios.msg.2012050639be@1336583199032.us-­‐1.amazon.com> Subject: Notice: Amazon EC2 Instance scheduled for retirement MIME-­‐Version: 1.0 Content-­‐Type: text/plain; charset=UTF-­‐8 Content-­‐Transfer-­‐Encoding: 7bit ! Hello, ...
  • 31. A message with an attachment MIME-­‐Version: 1.0 Content-­‐Type: multipart/mixed; boundary=_MYBOUNDARY_ ! -­‐-­‐_MYBOUNDARY_ Content-­‐Type: text/plain ! This is the body of the message. -­‐-­‐_MYBOUNDARY_ Content-­‐Type: image/jpeg; name="IMG_713.jpg" Content-­‐Disposition: attachment; filename="IMG_713.jpg"; size=6379099; Content-­‐Transfer-­‐Encoding: base64 ! /9j/4AAQSkZJRgABAgAAZABkAAD/7AARRHVja3kAAQAEAAAAZA+4AJkFkb2JlAGTAAAAAAQMA AwMDAwMDAwMDAwMDAwMDAwMDAwMDAwMDAwMDAwMDAwMDAwMDAwMDAwMD8IAEQgAegG1AwERAI RAQMRAfEASMAAQACAwEBAQEBAAAAAAAAAAAHCAUGCQQDAgEKAQEAAgIDAQAAAAAAAAAAAAAAB gcFCAEDBAIQAAEEAgEBBgQGAQUAAAAAAAUCAwQGAQcAEjBQERMUFRBgFhcgQHAhNAhBMSIjJD URAAIC== -­‐-­‐_MYBOUNDARY_-­‐-­‐
  • 32. A message with alternative parts MIME-­‐Version: 1.0 Content-­‐Type: multipart/alternative; boundary=_MYBOUNDARY_ ! -­‐-­‐_MYBOUNDARY_ Content-­‐Type: text/plain; charset="us-­‐ascii" Content-­‐Transfer-­‐Encoding: quoted-­‐printable ! Hello! Here’s a message with *rich* text -­‐-­‐_MYBOUNDARY_ Content-­‐Type: text/html; charset="us-­‐ascii" Content-­‐Transfer-­‐Encoding: quoted-­‐printable ! <html><body>Hello! Here’s a message with <b>rich</b> text</body></html> -­‐-­‐_MYBOUNDARY_-­‐-­‐
  • 33. Pitfall #1: Message-ID is optional
  • 35. Pitfall #3: Attachments are what you decide them to be
  • 38. contacts messages files threads webhooks
  • 39. Email as a datasource for apps Tony Blank tony@context.io @thetonyblank