Campaign Reference ID while importing from Json

68 views
Skip to first unread message

Subash NG

unread,
Jun 4, 2015, 4:42:20 AM6/4/15
to adwor...@googlegroups.com
Hello,

We have been importing campaigns from json and we are using mutatejobservice to do this, our issue right now is we can't parse our product id into campaign settings. We don't have any issues while importing campaigns but when thought about "Update" we need to parse our ID into campaign settings, same for adgroup settings to Update based upon our json.

"campaign_array_field": [
        {
            "product_id: "1234",
            "product_name: "value",
            "product_budget": "$10",
            "product_status": "TRUE:FALSE",
             ...etc
}
]

We can't use product_id into labels coz labels can be added only after the campaign is created. We need some reference while importing campaigns.

Thanks!

Subash NG

unread,
Jun 5, 2015, 6:11:53 AM6/5/15
to adwor...@googlegroups.com
Hello, Anyone from Google? please help me here.

Anash P. Oommen (AdWords API Team)

unread,
Jun 9, 2015, 2:25:19 PM6/9/15
to adwor...@googlegroups.com, adwor...@emphasizebpo.com
Hi Subash,

I'm not sure I follow the issue completely, but my understanding is that when doing the import, you don't have a way to identify the campaign you are creating in MJS to the corresponding entry in your local feed.

If that's the case, you might want to switch back to CampaignService, so you could create one campaign at a time, and associate its ID to your local ID immediately when the call returns. Another option is to continue using MJS, but create the campaign initially while encoding your ID into the campaign name (e.g. [12345] Campaign Name). Once the campaign is created, you can rename it after doing the necessary local association.

AdWords API doesn't provide a way to add custom metadata to an AdWords object.

Cheers,
Anash P. Oommen,
AdWords API Advisor.

Subash NG

unread,
Jun 9, 2015, 3:55:30 PM6/9/15
to adwor...@googlegroups.com, adwor...@emphasizebpo.com
Hi Anash,

Thanks for your reply, much helpful. What would you suggest here? MJS or CampaignService? We choose MJS coz we will get xx number of products daily to our feed and need to create each products as each campaigns so only we choose MJS as we can see the jobs results and once job is completed we can retrieve the Completed, Failure results so based on it we can update as per our needs, so these can be done using MJS only, right?

and also when product status is inactive we need to pause the campaign so I think all these can be done in MJS?

Any ideas would be helpful? as we like to get everything perfect, so for example: we had 1000 products in our feed and new products will come/exists..etc as per the product status so based on it we need to insert and pause the campaigns, just some hint is enough as we already completed 75% of code and everything in testing stage. We successfully inserted the campaigns from feed and right now we are on "Update" stage.

Thanks,
Subash

Anash P. Oommen (AdWords API Team)

unread,
Jun 10, 2015, 11:29:48 AM6/10/15
to adwor...@googlegroups.com, adwor...@emphasizebpo.com
Hi Subash,

Yes, your choice of MJS for its async capabilities is right in this context. The only thing to keep in mind is that MJS is originally designed for bulk operations. It gives you good performance when updating lots (say, order of millions) of entries, but the regular sync version of services (e.g. CampaignService) would give you better performance if you are updating a few (say, a thousand) entities.

And, if you are using Shopping campaigns, then keep in mind that product partitions won't work with MJS, you'd have to use AdGroupCriterionService. If by product you mean a generic product and not a product in Google Merchant Center, feel free to ignore this suggestion.

Cheers,
Anash
Reply all
Reply to author
Forward
0 new messages