# Tracking received emails like basecamp or github

**URL:** <https://www.ruby-forum.com/t/tracking-received-emails-like-basecamp-or-github/151224>\
**Category:** Rails\
**Created:** [October 18, 2008, 2:15pm UTC](https://www.ruby-forum.com/t/tracking-received-emails-like-basecamp-or-github/151224 "2008-10-18T14:15:17Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![captaffy](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/c/f04885/32.png) [@captaffy](https://www.ruby-forum.com/u/captaffy)\
**Post date:** [October 18, 2008, 2:15pm UTC](https://www.ruby-forum.com/t/tracking-received-emails-like-basecamp-or-github/151224/1 "2008-10-18T14:15:17Z")

</div>

I have an application which I configured to send and receive email. Both  
processes work at the basic level. The application can send email to  
users. Users can send email back to the application where I use the  
mail\_fetcher plugin to poll the inbox.

My problem is i am trying to determine the best way to ‘track’ these  
emails so that when they are retrieved from the mail server I can  
process them correctly.

For example:

Application can send email to a user so that user can reply and update a  
message on a specific web page in the application. At this point i need  
to know the message id when the email is sent from the app so i can  
persist it and use it as cross-reference when the reply comes back (in  
the case of a threaded message situation).

Ive tried setting custom header parameters but these get stripped coming  
back from the user.

Should i simply use some form of unique identifier on the subject line?  
reply-to? (although i would assume this would require dynamic email  
inboxes), or in the message body itself?

I have searched everywhere and am even looking for other open source  
apps that do this so i can understand a clean way to proceed. Any help  
would be most appreciated.

J
