I have a contact form on our website that is generating an email to support@domain.com. We are setting the from email address to no-reply@domain.com and the reply-to email address to the customer's address inputed in the form.

The is creating an issue as emails are forwarded to Salesforce using email to case and all incoming emails are bound to the contact with the email address "no-reply@domain.com" instead of the customer's actual email address which is the reply-to address.

Is it possible to have the contact be created from the reply-to address instead of the from address? This will ensure each customer receives their own contact record.

It's not possible to change the from address on the web form to the customer's email address as we do not have permission to send from that email address.

closed as off-topic by Brian Mansfield, Himanshu, Sebastian Kessel, Pranay Jaiswal, battery.cord Apr 5 at 13:24

This question appears to be off-topic. The users who voted to close gave this specific reason:

  • "Questions on problems in code you've written must describe the specific problem and include valid code to reproduce it. For help writing short, self-contained syntactically-valid examples, see: SSCCE.org" – Brian Mansfield, Himanshu, Sebastian Kessel, Pranay Jaiswal, battery.cord
If this question can be reworded to fit the rules in the help center, please edit the question.

  • Do you have any InboundEmailHandler implemented? – Jayant Das Apr 3 at 19:53
  • No, I am not familiar with that. We are new to salesforce, just migrated from desk.com – Brian Salta Apr 3 at 19:54

If you are using On-Demand Email-to-Case, you don't have a way to really do so. Using this approach will always associate a Case to a Contact by matching the from address.

You could however achieve what you want by using an Apex Email Service. Using this approach, you can process an incoming email and then accordingly utilize the InboundEmail class' replyTo address to create a Contact record or associate it with any existing Contact.

You can either use only Apex Email Service to create a Case, Contact, etc. or you can have the email sent to both your Email-to-Case email address as well as the Apex Email address for only the purpose of creating/associating a Contact.

These are some good resources which will help you get started in that direction:

Not the answer you're looking for? Browse other questions tagged or ask your own question.