Repeating Emails based on an Array

Hi,

I have a CDT with claim information. This cdt has the claim start date and the claimant information such as name and email and the claim expiry date along with other details. We have to retrieve all the claims that exceeded 30 days in the system with claim status still as open and alert the claimant that it is pending.

I have written a rule to get such claims from the database and am able to access them in the Process Design and for the send Email activity after the Script Task, I have enabled multi node from the other tab.

Now, I am not able to customize with each iteration which user the notification should go to and customize the information in the body of the email.

I am trying to see if pv!ClaimInfo_cdt.customerEmailID will work in the To field of the Email smart service, but not sure how to access the index while the multi node is iterating on each record in the CDT array.

Hope my question is clear. I am new to Appian and I am facing this difficulty.

 

Thanks,

Adi

  Discussion posts and replies are publicly visible

Parents
  • Hi AdirajuB,

    For repeating nodes in loop, you can use the MNI configuration. If pv!ClaimInfo_cdt has 3 set values, the Email node smart service hits 3 times to send an Email notification. For sending to 3 different emails for every iteration, you have to pass the tp!instanceindex to the cdt.
    EX: pv!ClaimInfo_cdt[tp!instanceindex].customerEmailID.
    So in this case, it will work, as you expected.
    I'm not sure about how to customize the body of an email node, I suggest you to write a rule, that maintains the separate body for that particular user. but it is little bit more complex to write the body for all users. If possible go through this link.
    docs.appian.com/.../Configuring_Custom_Email_Senders.html
Reply
  • Hi AdirajuB,

    For repeating nodes in loop, you can use the MNI configuration. If pv!ClaimInfo_cdt has 3 set values, the Email node smart service hits 3 times to send an Email notification. For sending to 3 different emails for every iteration, you have to pass the tp!instanceindex to the cdt.
    EX: pv!ClaimInfo_cdt[tp!instanceindex].customerEmailID.
    So in this case, it will work, as you expected.
    I'm not sure about how to customize the body of an email node, I suggest you to write a rule, that maintains the separate body for that particular user. but it is little bit more complex to write the body for all users. If possible go through this link.
    docs.appian.com/.../Configuring_Custom_Email_Senders.html
Children
  • Hi Ravalik,
    I have tried using the way you have suggested, but I am getting the below error in the activity:

    Details:
    ERROR: An error occurred while evaluation expression: pv_CustomerName:pv!ClaimInfo_cdt[tp!instanceindex].customerEmailID (invalid index: cannot index property 'customerEmailID' of type Text into type Data Store Entity) (Data Outputs)

    I am not really sure what is happening here as I am simply using the email id and in the body using the customer name to test.

    Thanks,
    Adi