Hello,
I'm adding different locations programmatically to a particular campaign. However this does not edit the current locations but instead simply adds new ones on top.
I'm now trying to first remove all existing locations and then add the new ones.
My code looks like this:
for criterion_id in criterions_to_remove:
operations.append({
'operator': 'REMOVE',
'operand': {'xsi_type': 'CampaignCriterion', 'campaignId': campaign_id, 'criterion': {'id': criterion_id }}
})
result = campaign_criterion_service.mutate(operations)
However, I'm now sure how can I query a list of criterions_to_remove for a specific campaign. How can I get all criterion_ids of a campaign, starting with the campaign ID?
The criterions I add to the campaign are: 'xsi_type': 'Proximity'