The creativessubmit Tool

Users of the API find that, after the initial setup, one of the things they lean heavily on the API for is the submission of creatives and the resubmission of disapproved creatives.

To help, we put together a tool called creativessubmit that can be used to manage Accounts, PretargetingConfig and Creatives by making calls to the Ad Exchange Buyer REST API.

Setup

  • Follow the googleads-adxbuyer-examples instructions here.
  • Edit BuyerServiceHelper.java and fill in the account details.
  • Run the creativessubmit.Selection class.
  • The code waits for you to type the menu option for the code you want to run; you can hit ? to get a list of options.
  • Try typing in AL for an Accounts List to make sure that everything is working ok.

Accounts

Managing creatives is done on a per account basis so we have included this call as a way to list the accounts you are associated with; type in AL in creativessubmit and note the AccountId of the account you want to work with.

Note: When you are prompted for accountId or see this field in a .json file, this is the id you will need to use.

Pretargeting

You can set up a PretargetingConfig to help filter the impression requests you receive; read up on it here.

Add PretargetingConfig from template

  • Copy the pretargetingConfig.json template.
  • Edit the file using the PretargetingConfig reference as a guide.
  • Select PI in creativessubmit.
  • Enter the path to the .json file.

Update existing PretargetingConfig

  • Use PG in creativessubmit to get an existing config.
  • Edit the file using the PretargetingConfig reference as a guide.
  • Select PU in creativessubmit.
  • Enter the path to the modified file.
  • This replaces the PretargetingConfig with the new values from the file.

Creatives

List creatives

CL in creativessubmit will list existing Creatives; you set the optional filter to disapproved to get a list of Creatives you need to fix and resubmit.

Add creative from template

  • Copy the creative.json template.
  • Edit the copy using the Creatives reference as a guide.
  • Select CI in the running code.
  • Enter the path to the modified file.

Resubmit creative

  • Get the existing Creative by typing CG in the running code.
  • Edit the .json file using the Creatives reference as a guide.
  • Select CI in the running code.
  • Enter the path to the modified file.

Next Steps

Extend the solution by:

  • add custom menu options.
  • automate .json file editing by spawning an editor after doing a Get.
  • move .json files to a database or other centralized location.

Remember to take a look at the performance tips when starting a new project.

Send feedback about...

Buyer REST API
Buyer REST API