php - Mailgun: How to keep track of the Message-ID (and References and In-Reply-To) to build threads -


i using mailgun api. want keep thread when reply mail using mailgun api.

let me explain. fetch mail using imap. have message_id,subject,text,sender mail etc. reply mail using mailgun api. here face problem. replied same subject email-id person mail new mail. thread not generated. in php mailer find following way thread generated. how create thread using mailgun api.

$mail->addcustomheader('in-reply-to', $message_id); $mail->addcustomheader('references', $message_id); 

thanks in advance.

finally got solution. hope someone.

$mail->addheader('your-header', 'value'); 

example:

$mail->addheader('reply-to', $message_id);


Comments

Popular posts from this blog

javascript - Thinglink image not visible until browser resize -

firebird - Error "invalid transaction handle (expecting explicit transaction start)" executing script from Delphi -

mongodb - How to keep track of users making Stripe Payments -