Avatar

Level 4

Hi @DavidKangni,

 

I am new to this. Can you give me an example ?

 

Currently i am able to send the deliveries through API but there are some variables of recipient table which i need to pass to delivery template like ( recipient.firstname) how can i do so ?

 

along with email i need to pass two more variables of recipient table.

 

Currently this is my code : 

 

// vars.tableName = table which is generated by query activity and it has email column

var cnx = application.getConnection();

var details = cnx.query("select * from "+vars.tableName);
for each(var row in details)
{
var emailCondition = "@email = '"+row[1]+"'";
var deliveryId = nms.delivery.SubmitNotification ("prdDM30608",
<delivery>
<targets >
<deliveryTarget >
<targetPart type='query' exclusion='false' ignoreDeleteStatus='false'>
<where>
<condition expr={emailCondition} />
</where>
</targetPart>
</deliveryTarget>
</targets>
</delivery>);
logInfo("deliveryid : "+deliveryId)
}
cnx.dispose();