Expand my Community achievements bar.

The 5th edition of the Campaign Community Lens newsletter is out now!

Control groups in A/B winner delivery node


Level 1



I am trying to set up an A/B test using the standard adobe method for campaign classic using the below Javascript,
However, I need to pull through the control group from the workflow which is saved in a list for the delivery node and am unsure how to do this in the below javascript code. Is it also possible to pull through the seed addresses set in the a/b tests as well? 

I followed these instructions and have been able to send the delivery based on the winner but the control groups and seeds are not populating as stated above


// query the database to find the winner (best open rate)
var winner = xtk.queryDef.create(
<queryDef schema="nms:delivery" operation="get">
<node expr="@id"/>
<node expr="@label"/>
<node expr="[@operation-id]"/>
<node expr="[@workflow-id]"/>
<condition expr={"@FCP=0 and [@workflow-id]= " + instance.id}/>
<node expr="[indicators/@estimatedRecipientOpenRatio]" sortDesc="true"/>

// create a new delivery object and initialize it by doing a copy of
// the winner delivery
var delivery = nms.delivery.create()
delivery.Duplicate("nms:delivery|" + winner.@id)

// append 'final' to the delivery label
delivery.label = winner.@label + " final"

// link the delivery to the operation to make sure it will be displayed in
// the campaign dashboard. This attribute needs to be set manually here since
// the Duplicate() method has reset it to its default value => 0
delivery.operation_id = winner.@["operation-id"]
delivery.workflow_id = winner.@["workflow-id"]

// adjust some delivery parameters to make it compatible with the
// "Prepare and start" option selected in the Delivery tab of this activity
delivery.scheduling.validationMode = "manual"
delivery.scheduling.delayed = 0

// save the delivery in database

// store the new delivery Id in event variables
vars.deliveryId = delivery.id


9 Replies


Level 5

Hi Buster, 


I think control groups can be pulled from deliverOperation table - [operation/controlGroup] will be the link to pull from delivery schema. 




Level 1

Hey Adithya,

Thanks for your reply!

Any idea how I would pull this through in the above script?

I have been trying based on your comment but with no success so far.


Level 5

Hi Buster, I can see the link for control Group element  in here.






Level 5
Hi Buster, sorry i might be confusing you , you might be searching this element in delivery schema, but this actually belongs to nms:deliveryOperation schema, and you might have to pull this field from here.


Level 1


Hey hey,

I have tried the below but can't seem to find the table you referenced or call it in the javascript, what node were you using to bring up the window to show the enabled path?

Sorry I am not very experienced with Javascript



Hi @bustert17264389,

Were you able to resolve this query or do you still need more help here? Do let us know.



Level 1

Hi @Sukrity_Wadhwa

Unfortunately Yes I still need help. I haven't been able to find the specific schema mentioned in the last reply and don't know where to go from here to be able to implement this which is a shame as its a use case for our company.


Thanks for the update. I will escalate it further among SMEs to get you some more help.