You need to sign in to do that
Don't have an account?
nilan
Trigger notification email when creating leads via API - Please help
Hi,
I am using the API to create leads in SF. To assign leads to a queue, I use the Ownerid field and set it to a relevant queue id. It’ is working well and leads are generated inside SF in that queue. But the problem is that the notification email is not sent any of the members of that specific queue. “Send Email to Members” check box is checked for this queue so it seems nothing wrong with the queue. Doesn’t the API trigger this email by default? Is there any thing should we set it to work? Please help
Thanks
Nilan
I am using the API to create leads in SF. To assign leads to a queue, I use the Ownerid field and set it to a relevant queue id. It’ is working well and leads are generated inside SF in that queue. But the problem is that the notification email is not sent any of the members of that specific queue. “Send Email to Members” check box is checked for this queue so it seems nothing wrong with the queue. Doesn’t the API trigger this email by default? Is there any thing should we set it to work? Please help
Thanks
Nilan
Hi Nilan,
I think that the "Send Email to Members" only works if you use the Lead Assignment Rules in the Salesforce point & click configuration area to assign the incoming Leads to queues. Assigning it directly to the queue using the API is a good idea, but unfortunately bypasses the notification functionality.
Also, I think there is a "Use Assignment Rules" flag that you'll need to set in your API calls for the Lead Assignment Rules to fire properly and notify the queue members (sorry I don't have the exact info).
Hope this helps,
Alex S.
Thanks Alex,
I have setup an assignment rule and pass the rule id using the AssignmentRuleHeader object and setAssignmentRuleHeader method. It triggers the rule and leads are assigned to the particular queue. But email is still not triggered.
Nilan
You can use the API to send the email yourself. You'll need to retrieve the queue (group) email address once the lead is assigned. You can then create the email in your code and send it using the API.
Park
$client->setEmailHeader($header);
Thanks
Nilan
I used a lead Assignment rule with email template associated. So in that case we have to define the assignment rule header and the email header in the SOAP call something like below.
$header = new AssignmentRuleHeader($rule_id, false);
$client->setAssignmentRuleHeader($header);
$header = new EmailHeader(false, false, true); $client->setEmailHeader($header);
Thanks for your all help
Nilan