Create a standalone ad group
Google Ads compliance row C.190: creates an ad group WITHOUT an ad,
under an existing campaign. Ads join it later via existingAdGroupId
on POST /v1/ads/create. Google only; every other platform returns 501.
Created PAUSED unless status: ACTIVE. The new ad group has no ad
yet, so it will not appear in GET /v1/ads/tree (built purely from ads
rows) until one is added; use GET /v1/ads/ad-sets to see it in the
meantime.
Idempotency: send an Idempotency-Key header to make retries safe.
API key authentication - use your Zernio API key as a Bearer token
In: header
Header Parameters
Optional client-generated unique key (e.g. a UUID) that makes retries safe. Same key + same body replays the original response; same key + different body → 422; key still processing → 409. Only 2xx responses are stored, so a request that failed with a 4xx can be retried with a corrected body under the SAME key.
length <= 255Zernio SocialAccount id owning the Google Ads connection.
Only "google" is implemented today; every other value returns 501.
"facebook" | "instagram" | "tiktok" | "linkedin" | "pinterest" | "google" | "twitter" | "openai"Google platform campaign ID (numeric) the ad group is created under.
1 <= length <= 255"PAUSED""ACTIVE" | "PAUSED"Numeric Google Ads customer id. Only required when the connection has more than one.
Response Body
application/json
application/json
application/json
import Zernio from '@zernio/node';const zernio = new Zernio({ apiKey: process.env.ZERNIO_API_KEY });const { data } = await zernio.adcampaigns.createAdSet({ body: { accountId: 'account_abc123', platform: 'facebook', campaignId: 'campaign_abc123', name: 'Example', },});console.log(data);{
"adSetId": "string",
"campaignId": "string"
}{
"error": "string",
"type": "invalid_request_error",
"code": "string",
"param": "string",
"platform": "string",
"platformError": {},
"details": {}
}{
"error": "Unauthorized"
}Add Search keywords to an ad group POST
Adds one or more keyword criteria to an existing Google Search ad group, without touching the keywords already there (unlike the whole-set diff on `PUT /v1/ads/{adId}`, `keywords`/`negativeKeywords` in `platformSpecificData`, which replaces the set). Set `negative: true` to add ad-group-level negatives instead of positive keywords.
Create a Google Ads portfolio bid strategy POST
Creates a standalone bid strategy shared across campaigns. Attach it to a campaign with `portfolioBidStrategyId` on POST /v1/ads/create, PUT /v1/ads/campaigns/{campaignId}, or PUT /v1/ads/ad-sets/{adSetId}. Attaching a strategy aligned to a shared budget fails there with a 400 (Google's `BIDDING_STRATEGY_AND_BUDGET_MUST_BE_ALIGNED`); this is not retryable.