function readOnly(count){ }
Starting November 20, the site will be set to read-only. On December 4, 2023,
forum discussions will move to the Trailblazer Community.
+ Start a Discussion
hemmhemm 

Apex Email Service Email Addresses cannot be saved in Salesforce email fields

I created a Salesforce Email Services email address that triggers some Apex Code.  I wanted to enter that email address as a Contact's email address in Salesforce so that I could send stuff to it.  Salesforce email fields do not accept those email addresses in them (ironic).

 Apex Email Error When Saving a Contact

For now, I am keeping it as an Outlook contact, but I'd like to sync that Outlook Contact with Salesforce so I always have a safe copy.

Message Edited by hemm on 04-11-2008 12:35 PM
Rasmus MenckeRasmus Mencke
We currently do not allow you to store the email address, I am looking at changing this policy.
hemmhemm
Why not be able to store it?  What's the harm? 
Rasmus MenckeRasmus Mencke
the reason we out the check in place was to prevent run-away processes where your apex code would send emails to an inbound email address. We are adding more controls around how emails can be delivered and I am looking at removing this contraint. I am aiming at removing it in the summer '08 release.
hemmhemm
Got it.  It'd be nice to be able to store it.  As a workaround, I tried creating an email alias on my mail server that has a rule to forward it onto the Apex address.  However, once I do this, the Email Services domain rules stop being enforced.  Salesforce sees the email as coming from my server no matter what email address I originally send from.

So it'd be nice to be able to put that email address into a Salesforce email field.  For my use case, it is for the purposes of syncing with Outlook.
paul-lmipaul-lmi
you don't want to forward, you want to deliver to, which preserves teh original email's headers.

if you are using exchange, you can do this by adding the salesforce email service address as a contact then delivering email to that contact, not forwarding to the address.
hemmhemm
I use Google Apps and I tried it by setting up a filter in my account that forwards the mail.  That didn't work.

What did work, however, was creating an email list on the domain that had my Apex address as a recipient.

It's kind of silly that I have to go this route just to get an email address into Salesforce.  Can't you all make it so it can be saved and do something on the automation end that disallows it from being a workflow recipient or something?

From a user perspective, Salesforce is a database for Contacts and a potential technical issue shouldn't stop a piece of data from being stored.
Rasmus MenckeRasmus Mencke
We are looking at removing this check for the Email Services - I hope to have it included into our Summer '08 Release.

Google does a header re-direct when you enable forwarding, so the email will look like it was send from the original sender.
moniferlomoniferlo
Summer'08 is now in my org, but I still can't add my email service as a valid email in Salesforce objects, for example, in a contact's email or in the email to send an alert. I would like to know when this feature will be implemented.
Rasmus MenckeRasmus Mencke
This is not being fixed with the Summer '08 release. We are still looking into when we can allow for inbound emails to be saved in the app.
StianSStianS
How do you make it delivering to this contact in Exchange, and not forwarding by using a rule e.g.?
Is it in the setup in Exchange?

I have a public address, like support@ourcompany.com which I will make go to the Email Service email address which I have setup.

-Stian