Skip to content

Instantly share code, notes, and snippets.

# Example encoding of an email message in JSON
{
headers: [ # in an array since order matters
{ name: 'Subject', value: 'An email' },
{ name: 'Date', value: 'Thu, 4 Mar 2010 15:35:32 -0800' },
{ name: 'From', value: '[email protected]' },
{ name: 'To', value: '[email protected]' }
{ name: 'Sender', value: '[email protected]' }
{ name: 'Reply-to', value: '[email protected]' }