Skip to main content
POST
Create a Google Ads Search campaign in one request. Ayrshare builds the budget, the campaign, one ad group, your keywords, one responsive search ad, and the location targeting together. If Google refuses any part, nothing is created. The request uses the shared Ad Campaigns shape. This page covers what is specific to Google.
  • Google ads are turned on per account. Contact us to enable them.
  • Link Google Ads from the Social Accounts page first. accountId is the 10-digit Google Ads customer id, with or without hyphens (123-456-7890).
  • The Google user you link must have direct access to the ad account. Accounts you reach only through a manager account are not listed and cannot be used yet: add that user to the ad account itself. Manager accounts are not listed either: they cannot hold campaigns.
  • New campaigns start paused unless you send status: "active".
  • The budget is per day, in the ad account’s currency. Do not send budget.currency: it answers code: 101.
  • Spend in another currency is converted to USD for billing at that day’s exchange rate from Open Exchange Rates. An account in a currency that cannot be converted answers code: 101 before anything is created.
  • Ads show on Google Search only, not on search partners or the Display Network.
Conversion tracking. maximizeConversions only works when conversion tracking is set up in your Google Ads account. Ayrshare does not set it up for you. Without it, use maximizeClicks or manualCpc.

Header Parameters

string
required
A new unique value, such as a UUID, for each new campaign. Repeating a request with the same key returns the first response and creates nothing new. When a create fails before Ayrshare sends the campaign to Google, the key is freed, so you can fix the request and retry with the same key. That covers a value Ayrshare refuses (such as an unsupported bidding strategy), an account in a currency that cannot be converted to USD, and any failure of the account check Ayrshare makes first, including Google refusing it. A create that fails once the campaign was sent to Google keeps its answer: retry it with a new key.

Body Parameters

The shared fields work as described on Ad Campaigns. On Google:
string
required
search.
string
required
maximizeClicks, manualCpc, or maximizeConversions. Any other answers code: 101.
boolean
required
Google requires this declaration on every campaign. While any campaign in an account is undeclared, Google rejects every change to that account’s campaigns.
object
Google schedules whole days in the ad account’s time zone. start begins at 00:00:00 on its day and end stops at 23:59:59 on its day; a time you send only picks the day. start can be today but not an earlier day. For a one-day campaign, send the same date for start and end. An end on an earlier day than start answers code: 101.
object
Google matches Search ads to people by the language of your ad text, so there is no language setting. Sending targeting.languages answers code: 101.
object
required

Errors