How to add workflow variables in a Delivery in Adobe Campaign Classic?

adobe-campaign-workflow-variable-delivery

There are many implementations in which we have to set the delivery variables based on the vale that we compute in the previous activities in a workflow.

Adobe Campaign has a solution for this type of implementation too.Let me explain this to you with a use case.

Implementation:

Our use case is that we have to develop a workflow that will send a reminder to our customer. This reminder mail will have their voucher details and also the expiry date of the voucher. The workflow will compute the voucher details and its expiry date. The delivery will use these workflow variables and personalize the email accordingly.

Lets start with the implementation.

Step 1: Create the variables in the delivery template.

adobe-campaign-workflow-variable-delivery-1

The Order in which you declare your variables matters. Here, coucherExpiry is defined in the second position. It will be later used in the workflow as variables[1], and storecode as variables[2] (0-index based).

Now, you can access these variables while personalizing the delivery.

adobe-campaign-workflow-variable-delivery-2

Step 2: Set the variable value in the workflow

Go to your workflow and open the delivery activity. Click on the script tab and set the variables using the below script.

delivery.variables._var[0].stringValue = vars.voucherType
delivery.variables._var[1].stringValue = vars.voucherExpiry
adobe-campaign-workflow-variable-delivery-4

Here, you can use delivery.variables._var[0] to set the value of the variables you defined before.

So, this is how you implement the solution for our use case..

Hope this helps.

error: Content is protected !!