Skip to content

diamondio/parse-gmail-email

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

34 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

parse-gmail-email

Build Status NPM version

Parse gmail API emails

var parse = require('parse-gmail-email');

var email = 'Your full gmail API email';

parse(email, function(err, data) {
  // =>
  /*
  {
    subject: 'Subject here',
    from: { name: 'Steve Lacy', address: 'me@slacy.me' },
    to: [ { address: 'me@slacy.me', name: 'Steve Lacy' } ],
    cc: [
      { address: 'test@test.com', name: '' },
      { address: 'funkytek@wearefractal.com', name: 'Aaron Murray' }
    ],
    id: '14b9d36df0e',
    threadId: '14b9d3694f7',
    labelIds: [ 'INBOX', 'CATEGORY_UPDATES' ],
    snippet: 'this is a snippet',
    attachments: {
      '2': {
        filename: 'great-websites.md', attachmentId: 'SUCHIDHERE'
      }
    },
    message: 'This is the message'
  }

  */
});

About

Parse gmail API emails

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • JavaScript 100.0%