About the Campaign API

The Campaign API creates, updates, launches, pauses, and deletes Google Ads campaigns for a Wix site. It supports Smart campaigns (auto-managed by Google) and Performance Max (PMAX) campaigns, which run across all Google channels. Performance Max campaigns come in 2 types: retail PERFORMANCE_MAX campaigns advertise the products in the account's linked Google Merchant Center feed, and PERFORMANCE_MAX_LEADS campaigns build their ads from an asset group and focus on lead generation.

Creating new Smart campaigns is deprecated. Support for it will be removed in a future release, so use Performance Max campaigns instead. Existing Smart campaigns aren't affected and can still be retrieved, updated, paused, and resumed.

With the Campaign API, you can:

  • Create Performance Max campaigns.
  • Launch a campaign for the first time or resume one after a pause.
  • Pause a running campaign, optionally scheduling it to auto-resume at a future date.
  • Update campaign settings such as budget, geo targets, and creative assets.
  • Retrieve a campaign's full event history.
  • Delete draft campaigns.

Campaign lifecycle

Create Campaign creates a campaign immediately in the status you specify. Create it as DRAFT to launch it later, or as LIVE to start it right away.

  • Call Launch Campaign to activate a DRAFT campaign for the first time. Call Resume Campaign to reactivate a campaign that was previously live and then explicitly paused.
  • Call Pause Campaign to stop a running campaign without losing its configuration. Specify a scheduledResumeDate to schedule an automatic resume. A job runs at that time and fires a CampaignAutoResumed domain event. Specify null to cancel an existing scheduled resume.
  • Update Campaign isn't a partial update. Retrieve the campaign with Get Campaign or List Campaigns, change only the fields you want to update, and specify the entire campaign. The fields to update are inferred from the specified campaign, and fields you omit may be cleared or cause the request to fail.
  • Call Get Campaign Change Log to retrieve the full event history for a campaign. Get Campaign Status History is a legacy method.

Campaign statuses

A campaign's status is read-only and synced from Google Ads. It may change without developer action, for example due to a policy violation or billing issue. The possible values are:

  • DRAFT: The campaign was created but not yet launched.
  • LIVE: The campaign is active and serving ads.
  • PAUSED: The campaign was paused by the user.
  • LEARNING: The campaign is in the learning phase (PERFORMANCE_MAX_LEADS only, approximately 28 days after launch).
  • IN_REVIEW: Google is reviewing the campaign's ads, or the campaign's payment setup isn't complete yet.
  • DISAPPROVED: The campaign or its assets violate Google Ads policy and won't serve.
  • NOT_SERVING: The campaign isn't serving due to budget limitations.
  • ENDED: The campaign has ended (PMAX campaigns with an endDate).
  • ERROR: The campaign is in an error state.

Before you begin

It's important to note the following points before starting to code:

  • The Wix Google Ads app must be installed and a Google Ads account must exist for the site before creating campaigns.
  • A maximum of 5 campaigns can be live simultaneously per site on standard accounts. This limit applies across all campaign types.
  • A campaign serves ads only while the site has an active Google Ads subscription. For custom charges (PAYG) accounts, Launch Campaign and Create Campaign with status set to LIVE fail if the subscription has expired.
  • Each campaign requires at least one geo target, a language, and a daily budget in micros (1,000,000 micros equals 1 unit of the account's currency). Google caps monthly spend at approximately 30.4 times the daily budget. Use the Suggestions API to get AI-generated budget recommendations and geo target suggestions.
  • PERFORMANCE_MAX_LEADS campaigns require a url and at least one asset group with headlines, long headlines, descriptions, a business name, images, and a logo. Asset validation is synchronous, so invalid assets cause the create call to fail immediately.
  • Retail PERFORMANCE_MAX campaigns require the account's merchantCenterAccountLinkStatus.status to be ENABLED. They don't accept asset group assets, asset group signals, excluded keywords, a phone number, or a url.

Use cases

Terminology

  • Campaign: An advertising campaign on Google targeting specific audiences, locations, and budgets.
  • Smart Campaign: A simplified campaign type where Google automatically manages bidding and ad delivery based on keyword themes and geo targets.
  • Performance Max (PMAX): A goal-based campaign that runs across all Google channels (Search, Display, YouTube, etc.). There are 2 types: PERFORMANCE_MAX and PERFORMANCE_MAX_LEADS.
  • PERFORMANCE_MAX: A retail (shopping) Performance Max campaign that advertises the products in the account's linked Google Merchant Center feed, including on Shopping.
  • PERFORMANCE_MAX_LEADS: A Performance Max campaign optimized for lead generation that builds its ads from an asset group you provide, with search theme signals and a 28-day learning phase.
  • Asset Group: A collection of creative assets (headlines, descriptions, a business name, images, and logos) that a PERFORMANCE_MAX_LEADS campaign uses to generate ads.
  • Keyword Theme: A topic or phrase that guides which search queries a Smart campaign matches.
  • Reporting Key: An auto-generated identifier derived from the campaign name, embedded as the utm_campaign parameter in the campaign's final URL suffix for analytics attribution.

Last updated: 11 November 2026

Did this help?