zernio-sdk 0.0.818 → 0.0.820
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/docs/AdCampaignsApi.md +1 -1
- data/docs/BoostPostRequest.md +2 -0
- data/docs/CreateAdCampaignRequest.md +2 -2
- data/docs/CreateAdCreativeRequest.md +1 -1
- data/docs/CreateCallAdRequest.md +2 -0
- data/docs/CreateCustomConversionRequest.md +1 -1
- data/docs/CreateMessagingAdRequest.md +2 -0
- data/docs/CreateRfPredictionRequest.md +1 -1
- data/docs/CreateStandaloneAdRequest.md +2 -0
- data/docs/CreateValueRuleSetRequest.md +2 -2
- data/docs/CtwaAdRequestBody.md +3 -1
- data/docs/GenerateAdPreviewsRequest.md +1 -1
- data/docs/UpdateAdCreativeRequest.md +1 -1
- data/docs/UpdateValueRuleSetRequest.md +1 -1
- data/docs/UploadAdImageRequest.md +2 -2
- data/docs/UploadAdVideoRequest.md +2 -2
- data/lib/zernio-sdk/api/ad_campaigns_api.rb +2 -2
- data/lib/zernio-sdk/models/boost_post_request.rb +13 -1
- data/lib/zernio-sdk/models/create_ad_campaign_request.rb +2 -2
- data/lib/zernio-sdk/models/create_ad_creative_request.rb +1 -1
- data/lib/zernio-sdk/models/create_call_ad_request.rb +13 -1
- data/lib/zernio-sdk/models/create_custom_conversion_request.rb +1 -1
- data/lib/zernio-sdk/models/create_messaging_ad_request.rb +13 -1
- data/lib/zernio-sdk/models/create_rf_prediction_request.rb +1 -1
- data/lib/zernio-sdk/models/create_standalone_ad_request.rb +13 -1
- data/lib/zernio-sdk/models/create_value_rule_set_request.rb +2 -2
- data/lib/zernio-sdk/models/ctwa_ad_request_body.rb +16 -4
- data/lib/zernio-sdk/models/generate_ad_previews_request.rb +1 -1
- data/lib/zernio-sdk/models/update_ad_creative_request.rb +1 -1
- data/lib/zernio-sdk/models/update_value_rule_set_request.rb +1 -1
- data/lib/zernio-sdk/models/upload_ad_image_request.rb +2 -2
- data/lib/zernio-sdk/models/upload_ad_video_request.rb +2 -2
- data/lib/zernio-sdk/version.rb +1 -1
- data/openapi.yaml +41 -20
- data/spec/api/ad_campaigns_api_spec.rb +1 -1
- data/spec/models/boost_post_request_spec.rb +6 -0
- data/spec/models/create_call_ad_request_spec.rb +6 -0
- data/spec/models/create_messaging_ad_request_spec.rb +6 -0
- data/spec/models/create_standalone_ad_request_spec.rb +6 -0
- data/spec/models/ctwa_ad_request_body_spec.rb +6 -0
- metadata +2 -2
checksums.yaml
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
SHA256:
|
|
3
|
-
metadata.gz:
|
|
4
|
-
data.tar.gz:
|
|
3
|
+
metadata.gz: 26df76b6eb6c9ad0862d2ca6e44e517a5c54a9d6410b3bc7f716f2fb6b30d0b0
|
|
4
|
+
data.tar.gz: 6ef0ac7a7e19b2a7694f783b4bca9bb73a105cbd51309ba52a365ec1c8ab8dbf
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: 91590d4cb9c0eff22122efcc24a38eb449c246ed9b8fdc006bfae19aa63f29d739669feaa8010ff2b65ae49c235fa6d9ef4dcd8316eed53d7cc98ebb96b92114
|
|
7
|
+
data.tar.gz: 1729f074ff854dcd036af00b8d134e7a7b726ce23d00c6c6333cedc01bedeef3696f20ada0a754f82099d4565379a911101cf6044a7b5acab889c2d2db4dfadc
|
data/docs/AdCampaignsApi.md
CHANGED
|
@@ -249,7 +249,7 @@ end
|
|
|
249
249
|
|
|
250
250
|
Create a standalone campaign
|
|
251
251
|
|
|
252
|
-
Creates a campaign WITHOUT its first ad set / ad
|
|
252
|
+
Creates a campaign WITHOUT its first ad set / ad, on the platform of the given `accountId`. Ad sets join it later via `existingCampaignId` on the create endpoints. Platform notes: on Meta a budget here is campaign-level (CBO) by definition; omit it for ABO (each ad set carries its own budget), and `specialAdCategories` / `bidStrategy` are Meta-only (400 elsewhere). Google, X and OpenAI require a budget (422 without one; OpenAI accepts only `budgetType: lifetime`). LinkedIn creates the campaign GROUP (our campaign level) and rejects a budget, which lives on the campaign (ad set) level there; it comes back `status: DRAFT`. TikTok campaigns are created without a status and report `ENABLE`. Created `PAUSED` unless `status: ACTIVE` where the platform supports it. **Idempotency:** send an `Idempotency-Key` header to make retries safe.
|
|
253
253
|
|
|
254
254
|
### Examples
|
|
255
255
|
|
data/docs/BoostPostRequest.md
CHANGED
|
@@ -25,6 +25,7 @@
|
|
|
25
25
|
| **tracking** | [**BoostPostRequestTracking**](BoostPostRequestTracking.md) | | [optional] |
|
|
26
26
|
| **special_ad_categories** | **Array<String>** | Meta only. Required for housing, employment, credit, or political ads. | [optional] |
|
|
27
27
|
| **special_ad_category_country** | **Array<String>** | Meta (metaads) only. 2-letter ISO country codes the special ad category applies to. Requires specialAdCategories to be set (400 otherwise). | [optional] |
|
|
28
|
+
| **regional_regulated_categories** | **Array<String>** | Meta only. Regional regulation categories required when the ad set targets certain countries (e.g. SINGAPORE_UNIVERSAL, TAIWAN_UNIVERSAL, THAILAND_UNIVERSAL, AUSTRALIA_FINSERV, INDIA_FINSERV). Forwarded to the ad set. | [optional] |
|
|
28
29
|
| **link_url** | **String** | Destination URL for the CTA button. Send it together with `callToAction`. **Meta**: adds a top-level `call_to_action` to the post-reference creative. This is what gives a `traffic` boost a clickable destination without replacing the creative and losing the post's social proof. Ignored when `leadGenFormId` is set, which supplies its own destination. Live-verified against a Page-post creative. **TikTok**: maps to `landing_page_url` on the Spark Ad creative (`AdcreateCreatives.landing_page_url`); Spark Ads have no clickable destination without it. Ignored on LinkedIn / Pinterest / X / Google, which infer the destination from the boosted post. | [optional] |
|
|
29
30
|
| **call_to_action** | **String** | CTA button label. Send it together with `linkUrl` — a CTA without a destination produces a button that goes nowhere, so sending one alone is a 400. **Meta**: the CTA enum of POST /v1/ads/create plus `VIEW_INSTAGRAM_PROFILE`, which is accepted on boost only. For that value `linkUrl` is typically the Instagram profile URL. **TikTok**: pass-through to `call_to_action` on the Spark Ad creative; the platform validates the value. See TikTok's \"Enumeration - Call-to-Action\". | [optional] |
|
|
30
31
|
| **spark_auth_code** | **String** | TikTok-only. Spark Code (creator's `auth_code`) authorizing cross-creator Spark Ads — the advertiser can boost a video owned by a DIFFERENT TikTok account. Without this, boosts are limited to videos owned by the same account running the ads (same-BC creators only). The creator generates the code in their TikTok app's Promote settings and shares it with the advertiser. Maps to `auth_code` on the creative entry of /v2/ad/create/. | [optional] |
|
|
@@ -61,6 +62,7 @@ instance = Zernio::BoostPostRequest.new(
|
|
|
61
62
|
tracking: null,
|
|
62
63
|
special_ad_categories: null,
|
|
63
64
|
special_ad_category_country: null,
|
|
65
|
+
regional_regulated_categories: null,
|
|
64
66
|
link_url: null,
|
|
65
67
|
call_to_action: null,
|
|
66
68
|
spark_auth_code: null,
|
|
@@ -4,8 +4,8 @@
|
|
|
4
4
|
|
|
5
5
|
| Name | Type | Description | Notes |
|
|
6
6
|
| ---- | ---- | ----------- | ----- |
|
|
7
|
-
| **account_id** | **String** | Zernio SocialAccount id (posting or ads variant)
|
|
8
|
-
| **ad_account_id** | **String** |
|
|
7
|
+
| **account_id** | **String** | Zernio SocialAccount id (posting or ads variant); its platform decides where the campaign is created. | |
|
|
8
|
+
| **ad_account_id** | **String** | Platform ad account id (Meta act_<n>, Google customer id, LinkedIn account id, ...). | |
|
|
9
9
|
| **name** | **String** | | |
|
|
10
10
|
| **goal** | **String** | Mapped to the ODAX objective (same mapping as POST /v1/ads/create). | |
|
|
11
11
|
| **special_ad_categories** | **Array<String>** | | [optional] |
|
|
@@ -5,7 +5,7 @@
|
|
|
5
5
|
| Name | Type | Description | Notes |
|
|
6
6
|
| ---- | ---- | ----------- | ----- |
|
|
7
7
|
| **account_id** | **String** | Zernio SocialAccount id (posting or ads variant) used to resolve the Meta token and Page. | |
|
|
8
|
-
| **ad_account_id** | **String** |
|
|
8
|
+
| **ad_account_id** | **String** | Platform ad account id (Meta act_<n>, Google customer id, LinkedIn account id, ...). | |
|
|
9
9
|
| **headline** | **String** | | |
|
|
10
10
|
| **body** | **String** | Primary text | |
|
|
11
11
|
| **description** | **String** | Link description below the headline; omitted = Meta scrapes the destination's OG description. | [optional] |
|
data/docs/CreateCallAdRequest.md
CHANGED
|
@@ -38,6 +38,7 @@
|
|
|
38
38
|
| **roas_average_floor** | **Float** | Decimal ROAS multiplier (e.g. `2.0` = 2.0× ROAS floor). Required when `bidStrategy` is `LOWEST_COST_WITH_MIN_ROAS`; rejected otherwise. Meta enforces its own upper bound server-side. | [optional] |
|
|
39
39
|
| **dsa_beneficiary** | **String** | Legal entity that benefits from the ad. Required when targeting EU users (EU DSA, Article 26). Optional if the ad account has a default beneficiary: set it once via `PATCH /v1/ads/accounts` or in Meta Ads Manager, and Meta fills it in whenever the field is omitted. | [optional] |
|
|
40
40
|
| **dsa_payor** | **String** | Legal entity that pays for the ad. Can differ from `dsaBeneficiary` (for example, an agency paying for a client's ads). Same rules as `dsaBeneficiary`: required for EU targeting unless the ad account has a default payor. | [optional] |
|
|
41
|
+
| **regional_regulated_categories** | **Array<String>** | Meta only. Regional regulation categories required when the ad set targets certain countries (e.g. SINGAPORE_UNIVERSAL, TAIWAN_UNIVERSAL, THAILAND_UNIVERSAL, AUSTRALIA_FINSERV, INDIA_FINSERV). Forwarded to the ad set. | [optional] |
|
|
41
42
|
| **phone_number** | **String** | E.164 number the CALL_NOW CTA dials (e.g. +34600111222). | |
|
|
42
43
|
| **link_url** | **String** | Website shown as the creative's link. Required: Meta rejects tel: as link_data.link; the phone number rides only the CTA. | |
|
|
43
44
|
|
|
@@ -81,6 +82,7 @@ instance = Zernio::CreateCallAdRequest.new(
|
|
|
81
82
|
roas_average_floor: null,
|
|
82
83
|
dsa_beneficiary: null,
|
|
83
84
|
dsa_payor: null,
|
|
85
|
+
regional_regulated_categories: null,
|
|
84
86
|
phone_number: null,
|
|
85
87
|
link_url: null
|
|
86
88
|
)
|
|
@@ -4,7 +4,7 @@
|
|
|
4
4
|
|
|
5
5
|
| Name | Type | Description | Notes |
|
|
6
6
|
| ---- | ---- | ----------- | ----- |
|
|
7
|
-
| **ad_account_id** | **String** |
|
|
7
|
+
| **ad_account_id** | **String** | Platform ad account id (Meta act_<n>, Google customer id, LinkedIn account id, ...). | |
|
|
8
8
|
| **name** | **String** | Also the reuse key, together with pixelId. | |
|
|
9
9
|
| **pixel_id** | **String** | Meta pixel id (event_source_id). From GET /v1/accounts/{accountId}/tracking-tags. | |
|
|
10
10
|
| **custom_event_type** | **String** | Meta custom_event_type, e.g. LEAD, PURCHASE, OTHER. | |
|
|
@@ -38,6 +38,7 @@
|
|
|
38
38
|
| **roas_average_floor** | **Float** | Decimal ROAS multiplier (e.g. `2.0` = 2.0× ROAS floor). Required when `bidStrategy` is `LOWEST_COST_WITH_MIN_ROAS`; rejected otherwise. Meta enforces its own upper bound server-side. | [optional] |
|
|
39
39
|
| **dsa_beneficiary** | **String** | Legal entity that benefits from the ad. Required when targeting EU users (EU DSA, Article 26). Optional if the ad account has a default beneficiary: set it once via `PATCH /v1/ads/accounts` or in Meta Ads Manager, and Meta fills it in whenever the field is omitted. | [optional] |
|
|
40
40
|
| **dsa_payor** | **String** | Legal entity that pays for the ad. Can differ from `dsaBeneficiary` (for example, an agency paying for a client's ads). Same rules as `dsaBeneficiary`: required for EU targeting unless the ad account has a default payor. | [optional] |
|
|
41
|
+
| **regional_regulated_categories** | **Array<String>** | Meta only. Regional regulation categories required when the ad set targets certain countries (e.g. SINGAPORE_UNIVERSAL, TAIWAN_UNIVERSAL, THAILAND_UNIVERSAL, AUSTRALIA_FINSERV, INDIA_FINSERV). Forwarded to the ad set. | [optional] |
|
|
41
42
|
| **destination** | **String** | Where the conversation opens when the ad is tapped. | |
|
|
42
43
|
|
|
43
44
|
## Example
|
|
@@ -80,6 +81,7 @@ instance = Zernio::CreateMessagingAdRequest.new(
|
|
|
80
81
|
roas_average_floor: null,
|
|
81
82
|
dsa_beneficiary: null,
|
|
82
83
|
dsa_payor: null,
|
|
84
|
+
regional_regulated_categories: null,
|
|
83
85
|
destination: null
|
|
84
86
|
)
|
|
85
87
|
```
|
|
@@ -5,7 +5,7 @@
|
|
|
5
5
|
| Name | Type | Description | Notes |
|
|
6
6
|
| ---- | ---- | ----------- | ----- |
|
|
7
7
|
| **account_id** | **String** | Zernio SocialAccount id (posting or ads variant). | |
|
|
8
|
-
| **ad_account_id** | **String** |
|
|
8
|
+
| **ad_account_id** | **String** | Platform ad account id (Meta act_<n>, Google customer id, LinkedIn account id, ...). | |
|
|
9
9
|
| **budget_amount** | **Float** | Whole currency units. Exactly one of budgetAmount / reach. | [optional] |
|
|
10
10
|
| **reach** | **Integer** | Target unique reach. Exactly one of budgetAmount / reach. | [optional] |
|
|
11
11
|
| **start_date** | **Time** | Campaign window start (must be in the future). | |
|
|
@@ -63,6 +63,7 @@
|
|
|
63
63
|
| **raw_targeting** | **Hash<String, Object>** | Meta only. A raw Meta-native targeting spec (snake_case: `geo_locations`, `age_min`, `excluded_custom_audiences`, `flexible_spec`, `targeting_automation`, `user_os`, `wireless_carrier`, business places, etc.) — exactly the shape `GET /v1/ads/{adId}` returns for external ads. Sent alone it reaches the ad set VERBATIM (the clone-a-campaign's-targeting-exactly path). Meta validates and surfaces any errors. Can be combined with the camelCase targeting fields (countries/regions/cities/interests/ageMin/..., `targeting`, `savedTargetingId`, `audienceId`): rawTargeting is the BASE layer and the built camelCase spec is merged on top, key by key, with the camelCase side winning on collision (the camelCase precedence chain stays `savedTargetingId` < `targeting` < flat fields). The merge goes one level deep inside `geo_locations` and `excluded_geo_locations`: built sub-keys win, raw-only sub-keys such as `location_types` survive alongside built `countries`. Array values (`flexible_spec`, ...) are replaced as a WHOLE key when the camelCase spec builds them, never element-merged. When rawTargeting is present the defaults the camelCase builder normally injects (US geo, `targeting_automation.advantage_audience: 0`) are suppressed, so raw's values are not clobbered — include `targeting_automation` in the raw spec (or send `advantageAudience`) as Meta requires it on create. If cloning an EU campaign, also pass `dsaBeneficiary` / `dsaPayor` (those are separate fields, not part of targeting). | [optional] |
|
|
64
64
|
| **special_ad_categories** | **Array<String>** | Meta only. Declares the ad's special category, required for housing, employment, credit, or political/social-issue ads (Meta enforces restricted targeting for these). Note: setting a special category disables income/zip targeting on Meta. | [optional] |
|
|
65
65
|
| **special_ad_category_country** | **Array<String>** | Meta (metaads) only. 2-letter ISO country codes the special ad category applies to. Requires specialAdCategories to be set (400 otherwise). Ignored when joining an existing campaign via existingCampaignId (the existing campaign's category/country already governs it). | [optional] |
|
|
66
|
+
| **regional_regulated_categories** | **Array<String>** | Meta only. Regional regulation categories required when the ad set targets certain countries. Known values: SINGAPORE_UNIVERSAL, TAIWAN_UNIVERSAL, THAILAND_UNIVERSAL, AUSTRALIA_FINSERV, INDIA_FINSERV, TAIWAN_FINSERV. Meta rejects the ad set without this when the targeting geo includes the corresponding country. | [optional] |
|
|
66
67
|
| **end_date** | **Time** | Required for lifetime budgets | [optional] |
|
|
67
68
|
| **start_date** | **Time** | Meta only. Ad-set start time (ISO 8601, e.g. \"2026-06-10T09:00:00Z\"), mapped to the ad set's `start_time`. When omitted the ad starts delivering immediately. For lifetime budgets Meta also requires `endDate`. (Same `schedule.startDate` semantics already available on `POST /v1/ads/boost`.) | [optional] |
|
|
68
69
|
| **instagram_account_id** | **String** | Meta only. Override the Instagram account the ad is delivered as — pass an Instagram Business Account ID (e.g. 17841...), mapped to the creative's `instagram_user_id`. When omitted we use the Instagram actor Meta already runs the Page's other ads as, falling back to the Page's page-backed Instagram account. Useful when a Page has more than one eligible IG account. | [optional] |
|
|
@@ -161,6 +162,7 @@ instance = Zernio::CreateStandaloneAdRequest.new(
|
|
|
161
162
|
raw_targeting: null,
|
|
162
163
|
special_ad_categories: null,
|
|
163
164
|
special_ad_category_country: null,
|
|
165
|
+
regional_regulated_categories: null,
|
|
164
166
|
end_date: null,
|
|
165
167
|
start_date: null,
|
|
166
168
|
instagram_account_id: null,
|
|
@@ -4,8 +4,8 @@
|
|
|
4
4
|
|
|
5
5
|
| Name | Type | Description | Notes |
|
|
6
6
|
| ---- | ---- | ----------- | ----- |
|
|
7
|
-
| **account_id** | **String** | Zernio SocialAccount id (posting or ads variant)
|
|
8
|
-
| **ad_account_id** | **String** |
|
|
7
|
+
| **account_id** | **String** | Zernio SocialAccount id (posting or ads variant); its platform decides where the campaign is created. | |
|
|
8
|
+
| **ad_account_id** | **String** | Platform ad account id (Meta act_<n>, Google customer id, LinkedIn account id, ...). | |
|
|
9
9
|
| **name** | **String** | | |
|
|
10
10
|
| **rules** | [**Array<ValueRule>**](ValueRule.md) | Evaluated in order; the first matching rule wins. | |
|
|
11
11
|
|
data/docs/CtwaAdRequestBody.md
CHANGED
|
@@ -38,6 +38,7 @@
|
|
|
38
38
|
| **roas_average_floor** | **Float** | Decimal ROAS multiplier (e.g. `2.0` = 2.0× ROAS floor). Required when `bidStrategy` is `LOWEST_COST_WITH_MIN_ROAS`; rejected otherwise. Meta enforces its own upper bound server-side. | [optional] |
|
|
39
39
|
| **dsa_beneficiary** | **String** | Legal entity that benefits from the ad. Required when targeting EU users (EU DSA, Article 26). Optional if the ad account has a default beneficiary: set it once via `PATCH /v1/ads/accounts` or in Meta Ads Manager, and Meta fills it in whenever the field is omitted. | [optional] |
|
|
40
40
|
| **dsa_payor** | **String** | Legal entity that pays for the ad. Can differ from `dsaBeneficiary` (for example, an agency paying for a client's ads). Same rules as `dsaBeneficiary`: required for EU targeting unless the ad account has a default payor. | [optional] |
|
|
41
|
+
| **regional_regulated_categories** | **Array<String>** | Meta only. Regional regulation categories required when the ad set targets certain countries (e.g. SINGAPORE_UNIVERSAL, TAIWAN_UNIVERSAL, THAILAND_UNIVERSAL, AUSTRALIA_FINSERV, INDIA_FINSERV). Forwarded to the ad set. | [optional] |
|
|
41
42
|
|
|
42
43
|
## Example
|
|
43
44
|
|
|
@@ -78,7 +79,8 @@ instance = Zernio::CtwaAdRequestBody.new(
|
|
|
78
79
|
bid_amount: null,
|
|
79
80
|
roas_average_floor: null,
|
|
80
81
|
dsa_beneficiary: null,
|
|
81
|
-
dsa_payor: null
|
|
82
|
+
dsa_payor: null,
|
|
83
|
+
regional_regulated_categories: null
|
|
82
84
|
)
|
|
83
85
|
```
|
|
84
86
|
|
|
@@ -5,7 +5,7 @@
|
|
|
5
5
|
| Name | Type | Description | Notes |
|
|
6
6
|
| ---- | ---- | ----------- | ----- |
|
|
7
7
|
| **account_id** | **String** | Zernio SocialAccount id used to resolve the Meta token. | |
|
|
8
|
-
| **ad_account_id** | **String** |
|
|
8
|
+
| **ad_account_id** | **String** | Platform ad account id (Meta act_<n>, Google customer id, LinkedIn account id, ...). | |
|
|
9
9
|
| **formats** | **Array<String>** | Meta ad_format values, one preview per format. Defaults to [DESKTOP_FEED_STANDARD]. | [optional] |
|
|
10
10
|
| **existing_creative_id** | **String** | Preview an existing ad-account creative by id. Mutually exclusive with creativeSpec. | [optional] |
|
|
11
11
|
| **creative_spec** | **Hash<String, Object>** | Raw Meta creative spec forwarded verbatim to /generatepreviews. Mutually exclusive with existingCreativeId. | [optional] |
|
|
@@ -4,7 +4,7 @@
|
|
|
4
4
|
|
|
5
5
|
| Name | Type | Description | Notes |
|
|
6
6
|
| ---- | ---- | ----------- | ----- |
|
|
7
|
-
| **account_id** | **String** | Zernio SocialAccount id (posting or ads variant)
|
|
7
|
+
| **account_id** | **String** | Zernio SocialAccount id (posting or ads variant); its platform decides where the campaign is created. | |
|
|
8
8
|
| **name** | **String** | | |
|
|
9
9
|
|
|
10
10
|
## Example
|
|
@@ -4,7 +4,7 @@
|
|
|
4
4
|
|
|
5
5
|
| Name | Type | Description | Notes |
|
|
6
6
|
| ---- | ---- | ----------- | ----- |
|
|
7
|
-
| **account_id** | **String** | Zernio SocialAccount id (posting or ads variant)
|
|
7
|
+
| **account_id** | **String** | Zernio SocialAccount id (posting or ads variant); its platform decides where the campaign is created. | |
|
|
8
8
|
| **name** | **String** | Required: the update replaces the whole set. | |
|
|
9
9
|
| **rules** | [**Array<ValueRule>**](ValueRule.md) | The COMPLETE rule list. Omitting a rule deletes it on Meta. | |
|
|
10
10
|
|
|
@@ -4,8 +4,8 @@
|
|
|
4
4
|
|
|
5
5
|
| Name | Type | Description | Notes |
|
|
6
6
|
| ---- | ---- | ----------- | ----- |
|
|
7
|
-
| **account_id** | **String** | Zernio SocialAccount id (posting or ads variant)
|
|
8
|
-
| **ad_account_id** | **String** |
|
|
7
|
+
| **account_id** | **String** | Zernio SocialAccount id (posting or ads variant); its platform decides where the campaign is created. | |
|
|
8
|
+
| **ad_account_id** | **String** | Platform ad account id (Meta act_<n>, Google customer id, LinkedIn account id, ...). | |
|
|
9
9
|
| **image_base64** | **String** | Raw base64 image bytes, or a full data URL (the data:image/...;base64, prefix is stripped). | |
|
|
10
10
|
| **filename** | **String** | Optional filename shown in Meta's image library. Defaults to ad_image.jpg. | [optional] |
|
|
11
11
|
|
|
@@ -4,8 +4,8 @@
|
|
|
4
4
|
|
|
5
5
|
| Name | Type | Description | Notes |
|
|
6
6
|
| ---- | ---- | ----------- | ----- |
|
|
7
|
-
| **account_id** | **String** | Zernio SocialAccount id (posting or ads variant)
|
|
8
|
-
| **ad_account_id** | **String** |
|
|
7
|
+
| **account_id** | **String** | Zernio SocialAccount id (posting or ads variant); its platform decides where the campaign is created. | |
|
|
8
|
+
| **ad_account_id** | **String** | Platform ad account id (Meta act_<n>, Google customer id, LinkedIn account id, ...). | |
|
|
9
9
|
| **video_url** | **String** | Public https URL of the video; downloaded server-side (SSRF-guarded) before chunked upload. Provide exactly one of videoUrl or videoBase64. | [optional] |
|
|
10
10
|
| **video_base64** | **String** | Raw base64 video bytes, or a full data URL (the data:video/...;base64, prefix is stripped). Capped by Vercel's body limit (~4.5 MB payload). Provide exactly one of videoUrl or videoBase64. | [optional] |
|
|
11
11
|
| **filename** | **String** | Optional filename shown alongside the upload session. Applied only when uploading via videoBase64. | [optional] |
|
|
@@ -237,7 +237,7 @@ module Zernio
|
|
|
237
237
|
end
|
|
238
238
|
|
|
239
239
|
# Create a standalone campaign
|
|
240
|
-
# Creates a campaign WITHOUT its first ad set / ad
|
|
240
|
+
# Creates a campaign WITHOUT its first ad set / ad, on the platform of the given `accountId`. Ad sets join it later via `existingCampaignId` on the create endpoints. Platform notes: on Meta a budget here is campaign-level (CBO) by definition; omit it for ABO (each ad set carries its own budget), and `specialAdCategories` / `bidStrategy` are Meta-only (400 elsewhere). Google, X and OpenAI require a budget (422 without one; OpenAI accepts only `budgetType: lifetime`). LinkedIn creates the campaign GROUP (our campaign level) and rejects a budget, which lives on the campaign (ad set) level there; it comes back `status: DRAFT`. TikTok campaigns are created without a status and report `ENABLE`. Created `PAUSED` unless `status: ACTIVE` where the platform supports it. **Idempotency:** send an `Idempotency-Key` header to make retries safe.
|
|
241
241
|
# @param create_ad_campaign_request [CreateAdCampaignRequest]
|
|
242
242
|
# @param [Hash] opts the optional parameters
|
|
243
243
|
# @option opts [String] :idempotency_key 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.
|
|
@@ -248,7 +248,7 @@ module Zernio
|
|
|
248
248
|
end
|
|
249
249
|
|
|
250
250
|
# Create a standalone campaign
|
|
251
|
-
# Creates a campaign WITHOUT its first ad set / ad
|
|
251
|
+
# Creates a campaign WITHOUT its first ad set / ad, on the platform of the given `accountId`. Ad sets join it later via `existingCampaignId` on the create endpoints. Platform notes: on Meta a budget here is campaign-level (CBO) by definition; omit it for ABO (each ad set carries its own budget), and `specialAdCategories` / `bidStrategy` are Meta-only (400 elsewhere). Google, X and OpenAI require a budget (422 without one; OpenAI accepts only `budgetType: lifetime`). LinkedIn creates the campaign GROUP (our campaign level) and rejects a budget, which lives on the campaign (ad set) level there; it comes back `status: DRAFT`. TikTok campaigns are created without a status and report `ENABLE`. Created `PAUSED` unless `status: ACTIVE` where the platform supports it. **Idempotency:** send an `Idempotency-Key` header to make retries safe.
|
|
252
252
|
# @param create_ad_campaign_request [CreateAdCampaignRequest]
|
|
253
253
|
# @param [Hash] opts the optional parameters
|
|
254
254
|
# @option opts [String] :idempotency_key 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.
|
|
@@ -72,6 +72,9 @@ module Zernio
|
|
|
72
72
|
# Meta (metaads) only. 2-letter ISO country codes the special ad category applies to. Requires specialAdCategories to be set (400 otherwise).
|
|
73
73
|
attr_accessor :special_ad_category_country
|
|
74
74
|
|
|
75
|
+
# Meta only. Regional regulation categories required when the ad set targets certain countries (e.g. SINGAPORE_UNIVERSAL, TAIWAN_UNIVERSAL, THAILAND_UNIVERSAL, AUSTRALIA_FINSERV, INDIA_FINSERV). Forwarded to the ad set.
|
|
76
|
+
attr_accessor :regional_regulated_categories
|
|
77
|
+
|
|
75
78
|
# Destination URL for the CTA button. Send it together with `callToAction`. **Meta**: adds a top-level `call_to_action` to the post-reference creative. This is what gives a `traffic` boost a clickable destination without replacing the creative and losing the post's social proof. Ignored when `leadGenFormId` is set, which supplies its own destination. Live-verified against a Page-post creative. **TikTok**: maps to `landing_page_url` on the Spark Ad creative (`AdcreateCreatives.landing_page_url`); Spark Ads have no clickable destination without it. Ignored on LinkedIn / Pinterest / X / Google, which infer the destination from the boosted post.
|
|
76
79
|
attr_accessor :link_url
|
|
77
80
|
|
|
@@ -142,6 +145,7 @@ module Zernio
|
|
|
142
145
|
:'tracking' => :'tracking',
|
|
143
146
|
:'special_ad_categories' => :'specialAdCategories',
|
|
144
147
|
:'special_ad_category_country' => :'specialAdCategoryCountry',
|
|
148
|
+
:'regional_regulated_categories' => :'regionalRegulatedCategories',
|
|
145
149
|
:'link_url' => :'linkUrl',
|
|
146
150
|
:'call_to_action' => :'callToAction',
|
|
147
151
|
:'spark_auth_code' => :'sparkAuthCode',
|
|
@@ -187,6 +191,7 @@ module Zernio
|
|
|
187
191
|
:'tracking' => :'BoostPostRequestTracking',
|
|
188
192
|
:'special_ad_categories' => :'Array<String>',
|
|
189
193
|
:'special_ad_category_country' => :'Array<String>',
|
|
194
|
+
:'regional_regulated_categories' => :'Array<String>',
|
|
190
195
|
:'link_url' => :'String',
|
|
191
196
|
:'call_to_action' => :'String',
|
|
192
197
|
:'spark_auth_code' => :'String',
|
|
@@ -318,6 +323,12 @@ module Zernio
|
|
|
318
323
|
end
|
|
319
324
|
end
|
|
320
325
|
|
|
326
|
+
if attributes.key?(:'regional_regulated_categories')
|
|
327
|
+
if (value = attributes[:'regional_regulated_categories']).is_a?(Array)
|
|
328
|
+
self.regional_regulated_categories = value
|
|
329
|
+
end
|
|
330
|
+
end
|
|
331
|
+
|
|
321
332
|
if attributes.key?(:'link_url')
|
|
322
333
|
self.link_url = attributes[:'link_url']
|
|
323
334
|
end
|
|
@@ -553,6 +564,7 @@ module Zernio
|
|
|
553
564
|
tracking == o.tracking &&
|
|
554
565
|
special_ad_categories == o.special_ad_categories &&
|
|
555
566
|
special_ad_category_country == o.special_ad_category_country &&
|
|
567
|
+
regional_regulated_categories == o.regional_regulated_categories &&
|
|
556
568
|
link_url == o.link_url &&
|
|
557
569
|
call_to_action == o.call_to_action &&
|
|
558
570
|
spark_auth_code == o.spark_auth_code &&
|
|
@@ -572,7 +584,7 @@ module Zernio
|
|
|
572
584
|
# Calculates hash code according to all attributes.
|
|
573
585
|
# @return [Integer] Hash code
|
|
574
586
|
def hash
|
|
575
|
-
[post_id, platform_post_id, account_id, ad_account_id, name, goal, ad_set_id, budget, instagram_account_id, destination_type, currency, schedule, targeting, raw_targeting, bid_strategy, bid_amount, roas_average_floor, platform_specific_data, tracking, special_ad_categories, special_ad_category_country, link_url, call_to_action, spark_auth_code, dsa_beneficiary, dsa_payor, lead_gen_form_id, status, optimization_goal].hash
|
|
587
|
+
[post_id, platform_post_id, account_id, ad_account_id, name, goal, ad_set_id, budget, instagram_account_id, destination_type, currency, schedule, targeting, raw_targeting, bid_strategy, bid_amount, roas_average_floor, platform_specific_data, tracking, special_ad_categories, special_ad_category_country, regional_regulated_categories, link_url, call_to_action, spark_auth_code, dsa_beneficiary, dsa_payor, lead_gen_form_id, status, optimization_goal].hash
|
|
576
588
|
end
|
|
577
589
|
|
|
578
590
|
# Builds the object from hash
|
|
@@ -15,10 +15,10 @@ require 'time'
|
|
|
15
15
|
|
|
16
16
|
module Zernio
|
|
17
17
|
class CreateAdCampaignRequest < ApiModelBase
|
|
18
|
-
# Zernio SocialAccount id (posting or ads variant)
|
|
18
|
+
# Zernio SocialAccount id (posting or ads variant); its platform decides where the campaign is created.
|
|
19
19
|
attr_accessor :account_id
|
|
20
20
|
|
|
21
|
-
#
|
|
21
|
+
# Platform ad account id (Meta act_<n>, Google customer id, LinkedIn account id, ...).
|
|
22
22
|
attr_accessor :ad_account_id
|
|
23
23
|
|
|
24
24
|
attr_accessor :name
|
|
@@ -18,7 +18,7 @@ module Zernio
|
|
|
18
18
|
# Zernio SocialAccount id (posting or ads variant) used to resolve the Meta token and Page.
|
|
19
19
|
attr_accessor :account_id
|
|
20
20
|
|
|
21
|
-
#
|
|
21
|
+
# Platform ad account id (Meta act_<n>, Google customer id, LinkedIn account id, ...).
|
|
22
22
|
attr_accessor :ad_account_id
|
|
23
23
|
|
|
24
24
|
attr_accessor :headline
|
|
@@ -111,6 +111,9 @@ module Zernio
|
|
|
111
111
|
# Legal entity that pays for the ad. Can differ from `dsaBeneficiary` (for example, an agency paying for a client's ads). Same rules as `dsaBeneficiary`: required for EU targeting unless the ad account has a default payor.
|
|
112
112
|
attr_accessor :dsa_payor
|
|
113
113
|
|
|
114
|
+
# Meta only. Regional regulation categories required when the ad set targets certain countries (e.g. SINGAPORE_UNIVERSAL, TAIWAN_UNIVERSAL, THAILAND_UNIVERSAL, AUSTRALIA_FINSERV, INDIA_FINSERV). Forwarded to the ad set.
|
|
115
|
+
attr_accessor :regional_regulated_categories
|
|
116
|
+
|
|
114
117
|
# E.164 number the CALL_NOW CTA dials (e.g. +34600111222).
|
|
115
118
|
attr_accessor :phone_number
|
|
116
119
|
|
|
@@ -176,6 +179,7 @@ module Zernio
|
|
|
176
179
|
:'roas_average_floor' => :'roasAverageFloor',
|
|
177
180
|
:'dsa_beneficiary' => :'dsaBeneficiary',
|
|
178
181
|
:'dsa_payor' => :'dsaPayor',
|
|
182
|
+
:'regional_regulated_categories' => :'regionalRegulatedCategories',
|
|
179
183
|
:'phone_number' => :'phoneNumber',
|
|
180
184
|
:'link_url' => :'linkUrl'
|
|
181
185
|
}
|
|
@@ -228,6 +232,7 @@ module Zernio
|
|
|
228
232
|
:'roas_average_floor' => :'Float',
|
|
229
233
|
:'dsa_beneficiary' => :'String',
|
|
230
234
|
:'dsa_payor' => :'String',
|
|
235
|
+
:'regional_regulated_categories' => :'Array<String>',
|
|
231
236
|
:'phone_number' => :'String',
|
|
232
237
|
:'link_url' => :'String'
|
|
233
238
|
}
|
|
@@ -420,6 +425,12 @@ module Zernio
|
|
|
420
425
|
self.dsa_payor = attributes[:'dsa_payor']
|
|
421
426
|
end
|
|
422
427
|
|
|
428
|
+
if attributes.key?(:'regional_regulated_categories')
|
|
429
|
+
if (value = attributes[:'regional_regulated_categories']).is_a?(Array)
|
|
430
|
+
self.regional_regulated_categories = value
|
|
431
|
+
end
|
|
432
|
+
end
|
|
433
|
+
|
|
423
434
|
if attributes.key?(:'phone_number')
|
|
424
435
|
self.phone_number = attributes[:'phone_number']
|
|
425
436
|
else
|
|
@@ -849,6 +860,7 @@ module Zernio
|
|
|
849
860
|
roas_average_floor == o.roas_average_floor &&
|
|
850
861
|
dsa_beneficiary == o.dsa_beneficiary &&
|
|
851
862
|
dsa_payor == o.dsa_payor &&
|
|
863
|
+
regional_regulated_categories == o.regional_regulated_categories &&
|
|
852
864
|
phone_number == o.phone_number &&
|
|
853
865
|
link_url == o.link_url
|
|
854
866
|
end
|
|
@@ -862,7 +874,7 @@ module Zernio
|
|
|
862
874
|
# Calculates hash code according to all attributes.
|
|
863
875
|
# @return [Integer] Hash code
|
|
864
876
|
def hash
|
|
865
|
-
[account_id, ad_account_id, name, headline, body, image_url, video, welcome_message, creatives, ad_set_id, budget_amount, budget_type, currency, end_date, countries, cities, regions, zips, metros, custom_locations, age_min, age_max, interests, audience_id, placements, advantage_audience, objective, status, campaign_status, bid_strategy, bid_amount, roas_average_floor, dsa_beneficiary, dsa_payor, phone_number, link_url].hash
|
|
877
|
+
[account_id, ad_account_id, name, headline, body, image_url, video, welcome_message, creatives, ad_set_id, budget_amount, budget_type, currency, end_date, countries, cities, regions, zips, metros, custom_locations, age_min, age_max, interests, audience_id, placements, advantage_audience, objective, status, campaign_status, bid_strategy, bid_amount, roas_average_floor, dsa_beneficiary, dsa_payor, regional_regulated_categories, phone_number, link_url].hash
|
|
866
878
|
end
|
|
867
879
|
|
|
868
880
|
# Builds the object from hash
|
|
@@ -15,7 +15,7 @@ require 'time'
|
|
|
15
15
|
|
|
16
16
|
module Zernio
|
|
17
17
|
class CreateCustomConversionRequest < ApiModelBase
|
|
18
|
-
#
|
|
18
|
+
# Platform ad account id (Meta act_<n>, Google customer id, LinkedIn account id, ...).
|
|
19
19
|
attr_accessor :ad_account_id
|
|
20
20
|
|
|
21
21
|
# Also the reuse key, together with pixelId.
|
|
@@ -111,6 +111,9 @@ module Zernio
|
|
|
111
111
|
# Legal entity that pays for the ad. Can differ from `dsaBeneficiary` (for example, an agency paying for a client's ads). Same rules as `dsaBeneficiary`: required for EU targeting unless the ad account has a default payor.
|
|
112
112
|
attr_accessor :dsa_payor
|
|
113
113
|
|
|
114
|
+
# Meta only. Regional regulation categories required when the ad set targets certain countries (e.g. SINGAPORE_UNIVERSAL, TAIWAN_UNIVERSAL, THAILAND_UNIVERSAL, AUSTRALIA_FINSERV, INDIA_FINSERV). Forwarded to the ad set.
|
|
115
|
+
attr_accessor :regional_regulated_categories
|
|
116
|
+
|
|
114
117
|
# Where the conversation opens when the ad is tapped.
|
|
115
118
|
attr_accessor :destination
|
|
116
119
|
|
|
@@ -173,6 +176,7 @@ module Zernio
|
|
|
173
176
|
:'roas_average_floor' => :'roasAverageFloor',
|
|
174
177
|
:'dsa_beneficiary' => :'dsaBeneficiary',
|
|
175
178
|
:'dsa_payor' => :'dsaPayor',
|
|
179
|
+
:'regional_regulated_categories' => :'regionalRegulatedCategories',
|
|
176
180
|
:'destination' => :'destination'
|
|
177
181
|
}
|
|
178
182
|
end
|
|
@@ -224,6 +228,7 @@ module Zernio
|
|
|
224
228
|
:'roas_average_floor' => :'Float',
|
|
225
229
|
:'dsa_beneficiary' => :'String',
|
|
226
230
|
:'dsa_payor' => :'String',
|
|
231
|
+
:'regional_regulated_categories' => :'Array<String>',
|
|
227
232
|
:'destination' => :'String'
|
|
228
233
|
}
|
|
229
234
|
end
|
|
@@ -415,6 +420,12 @@ module Zernio
|
|
|
415
420
|
self.dsa_payor = attributes[:'dsa_payor']
|
|
416
421
|
end
|
|
417
422
|
|
|
423
|
+
if attributes.key?(:'regional_regulated_categories')
|
|
424
|
+
if (value = attributes[:'regional_regulated_categories']).is_a?(Array)
|
|
425
|
+
self.regional_regulated_categories = value
|
|
426
|
+
end
|
|
427
|
+
end
|
|
428
|
+
|
|
418
429
|
if attributes.key?(:'destination')
|
|
419
430
|
self.destination = attributes[:'destination']
|
|
420
431
|
else
|
|
@@ -825,6 +836,7 @@ module Zernio
|
|
|
825
836
|
roas_average_floor == o.roas_average_floor &&
|
|
826
837
|
dsa_beneficiary == o.dsa_beneficiary &&
|
|
827
838
|
dsa_payor == o.dsa_payor &&
|
|
839
|
+
regional_regulated_categories == o.regional_regulated_categories &&
|
|
828
840
|
destination == o.destination
|
|
829
841
|
end
|
|
830
842
|
|
|
@@ -837,7 +849,7 @@ module Zernio
|
|
|
837
849
|
# Calculates hash code according to all attributes.
|
|
838
850
|
# @return [Integer] Hash code
|
|
839
851
|
def hash
|
|
840
|
-
[account_id, ad_account_id, name, headline, body, image_url, video, welcome_message, creatives, ad_set_id, budget_amount, budget_type, currency, end_date, countries, cities, regions, zips, metros, custom_locations, age_min, age_max, interests, audience_id, placements, advantage_audience, objective, status, campaign_status, bid_strategy, bid_amount, roas_average_floor, dsa_beneficiary, dsa_payor, destination].hash
|
|
852
|
+
[account_id, ad_account_id, name, headline, body, image_url, video, welcome_message, creatives, ad_set_id, budget_amount, budget_type, currency, end_date, countries, cities, regions, zips, metros, custom_locations, age_min, age_max, interests, audience_id, placements, advantage_audience, objective, status, campaign_status, bid_strategy, bid_amount, roas_average_floor, dsa_beneficiary, dsa_payor, regional_regulated_categories, destination].hash
|
|
841
853
|
end
|
|
842
854
|
|
|
843
855
|
# Builds the object from hash
|
|
@@ -18,7 +18,7 @@ module Zernio
|
|
|
18
18
|
# Zernio SocialAccount id (posting or ads variant).
|
|
19
19
|
attr_accessor :account_id
|
|
20
20
|
|
|
21
|
-
#
|
|
21
|
+
# Platform ad account id (Meta act_<n>, Google customer id, LinkedIn account id, ...).
|
|
22
22
|
attr_accessor :ad_account_id
|
|
23
23
|
|
|
24
24
|
# Whole currency units. Exactly one of budgetAmount / reach.
|
|
@@ -183,6 +183,9 @@ module Zernio
|
|
|
183
183
|
# Meta (metaads) only. 2-letter ISO country codes the special ad category applies to. Requires specialAdCategories to be set (400 otherwise). Ignored when joining an existing campaign via existingCampaignId (the existing campaign's category/country already governs it).
|
|
184
184
|
attr_accessor :special_ad_category_country
|
|
185
185
|
|
|
186
|
+
# Meta only. Regional regulation categories required when the ad set targets certain countries. Known values: SINGAPORE_UNIVERSAL, TAIWAN_UNIVERSAL, THAILAND_UNIVERSAL, AUSTRALIA_FINSERV, INDIA_FINSERV, TAIWAN_FINSERV. Meta rejects the ad set without this when the targeting geo includes the corresponding country.
|
|
187
|
+
attr_accessor :regional_regulated_categories
|
|
188
|
+
|
|
186
189
|
# Required for lifetime budgets
|
|
187
190
|
attr_accessor :end_date
|
|
188
191
|
|
|
@@ -358,6 +361,7 @@ module Zernio
|
|
|
358
361
|
:'raw_targeting' => :'rawTargeting',
|
|
359
362
|
:'special_ad_categories' => :'specialAdCategories',
|
|
360
363
|
:'special_ad_category_country' => :'specialAdCategoryCountry',
|
|
364
|
+
:'regional_regulated_categories' => :'regionalRegulatedCategories',
|
|
361
365
|
:'end_date' => :'endDate',
|
|
362
366
|
:'start_date' => :'startDate',
|
|
363
367
|
:'instagram_account_id' => :'instagramAccountId',
|
|
@@ -465,6 +469,7 @@ module Zernio
|
|
|
465
469
|
:'raw_targeting' => :'Hash<String, Object>',
|
|
466
470
|
:'special_ad_categories' => :'Array<String>',
|
|
467
471
|
:'special_ad_category_country' => :'Array<String>',
|
|
472
|
+
:'regional_regulated_categories' => :'Array<String>',
|
|
468
473
|
:'end_date' => :'Time',
|
|
469
474
|
:'start_date' => :'Time',
|
|
470
475
|
:'instagram_account_id' => :'String',
|
|
@@ -800,6 +805,12 @@ module Zernio
|
|
|
800
805
|
end
|
|
801
806
|
end
|
|
802
807
|
|
|
808
|
+
if attributes.key?(:'regional_regulated_categories')
|
|
809
|
+
if (value = attributes[:'regional_regulated_categories']).is_a?(Array)
|
|
810
|
+
self.regional_regulated_categories = value
|
|
811
|
+
end
|
|
812
|
+
end
|
|
813
|
+
|
|
803
814
|
if attributes.key?(:'end_date')
|
|
804
815
|
self.end_date = attributes[:'end_date']
|
|
805
816
|
end
|
|
@@ -1686,6 +1697,7 @@ module Zernio
|
|
|
1686
1697
|
raw_targeting == o.raw_targeting &&
|
|
1687
1698
|
special_ad_categories == o.special_ad_categories &&
|
|
1688
1699
|
special_ad_category_country == o.special_ad_category_country &&
|
|
1700
|
+
regional_regulated_categories == o.regional_regulated_categories &&
|
|
1689
1701
|
end_date == o.end_date &&
|
|
1690
1702
|
start_date == o.start_date &&
|
|
1691
1703
|
instagram_account_id == o.instagram_account_id &&
|
|
@@ -1729,7 +1741,7 @@ module Zernio
|
|
|
1729
1741
|
# Calculates hash code according to all attributes.
|
|
1730
1742
|
# @return [Integer] Hash code
|
|
1731
1743
|
def hash
|
|
1732
|
-
[account_id, ad_account_id, name, campaign_name, ad_set_name, ad_name, tracking, goal, optimization_goal, billing_event, buying_type, rf_prediction_id, creative_features, multi_advertiser, validate_only, budget_amount, budget_type, status, campaign_status, budget_level, currency, headline, long_headline, body, description, call_to_action, link_url, lead_gen_form_id, image_url, images, video, creatives, ad_set_id, existing_campaign_id, existing_creative_id, business_name, board_id, organization_id, targeting, countries, cities, regions, age_min, age_max, interests, zips, metros, custom_locations, behaviors, work_positions, work_employers, work_industries, income_tier, languages, placements, saved_targeting_id, raw_targeting, special_ad_categories, special_ad_category_country, end_date, start_date, instagram_account_id, dynamic_creative, carousel_cards, default_locale, translations, placement_assets, audience_id, campaign_type, keywords, negative_keywords, additional_headlines, additional_descriptions, sitelinks, callouts, structured_snippets, advantage_audience, attribution_spec, gender, bid_strategy, bid_amount, roas_average_floor, value_rule_set_id, value_rules_applied, platform_specific_data, dsa_beneficiary, dsa_payor, brand_identity, identity_type, smart_plus, promoted_object].hash
|
|
1744
|
+
[account_id, ad_account_id, name, campaign_name, ad_set_name, ad_name, tracking, goal, optimization_goal, billing_event, buying_type, rf_prediction_id, creative_features, multi_advertiser, validate_only, budget_amount, budget_type, status, campaign_status, budget_level, currency, headline, long_headline, body, description, call_to_action, link_url, lead_gen_form_id, image_url, images, video, creatives, ad_set_id, existing_campaign_id, existing_creative_id, business_name, board_id, organization_id, targeting, countries, cities, regions, age_min, age_max, interests, zips, metros, custom_locations, behaviors, work_positions, work_employers, work_industries, income_tier, languages, placements, saved_targeting_id, raw_targeting, special_ad_categories, special_ad_category_country, regional_regulated_categories, end_date, start_date, instagram_account_id, dynamic_creative, carousel_cards, default_locale, translations, placement_assets, audience_id, campaign_type, keywords, negative_keywords, additional_headlines, additional_descriptions, sitelinks, callouts, structured_snippets, advantage_audience, attribution_spec, gender, bid_strategy, bid_amount, roas_average_floor, value_rule_set_id, value_rules_applied, platform_specific_data, dsa_beneficiary, dsa_payor, brand_identity, identity_type, smart_plus, promoted_object].hash
|
|
1733
1745
|
end
|
|
1734
1746
|
|
|
1735
1747
|
# Builds the object from hash
|
|
@@ -15,10 +15,10 @@ require 'time'
|
|
|
15
15
|
|
|
16
16
|
module Zernio
|
|
17
17
|
class CreateValueRuleSetRequest < ApiModelBase
|
|
18
|
-
# Zernio SocialAccount id (posting or ads variant)
|
|
18
|
+
# Zernio SocialAccount id (posting or ads variant); its platform decides where the campaign is created.
|
|
19
19
|
attr_accessor :account_id
|
|
20
20
|
|
|
21
|
-
#
|
|
21
|
+
# Platform ad account id (Meta act_<n>, Google customer id, LinkedIn account id, ...).
|
|
22
22
|
attr_accessor :ad_account_id
|
|
23
23
|
|
|
24
24
|
attr_accessor :name
|
|
@@ -112,6 +112,9 @@ module Zernio
|
|
|
112
112
|
# Legal entity that pays for the ad. Can differ from `dsaBeneficiary` (for example, an agency paying for a client's ads). Same rules as `dsaBeneficiary`: required for EU targeting unless the ad account has a default payor.
|
|
113
113
|
attr_accessor :dsa_payor
|
|
114
114
|
|
|
115
|
+
# Meta only. Regional regulation categories required when the ad set targets certain countries (e.g. SINGAPORE_UNIVERSAL, TAIWAN_UNIVERSAL, THAILAND_UNIVERSAL, AUSTRALIA_FINSERV, INDIA_FINSERV). Forwarded to the ad set.
|
|
116
|
+
attr_accessor :regional_regulated_categories
|
|
117
|
+
|
|
115
118
|
class EnumAttributeValidator
|
|
116
119
|
attr_reader :datatype
|
|
117
120
|
attr_reader :allowable_values
|
|
@@ -170,7 +173,8 @@ module Zernio
|
|
|
170
173
|
:'bid_amount' => :'bidAmount',
|
|
171
174
|
:'roas_average_floor' => :'roasAverageFloor',
|
|
172
175
|
:'dsa_beneficiary' => :'dsaBeneficiary',
|
|
173
|
-
:'dsa_payor' => :'dsaPayor'
|
|
176
|
+
:'dsa_payor' => :'dsaPayor',
|
|
177
|
+
:'regional_regulated_categories' => :'regionalRegulatedCategories'
|
|
174
178
|
}
|
|
175
179
|
end
|
|
176
180
|
|
|
@@ -220,7 +224,8 @@ module Zernio
|
|
|
220
224
|
:'bid_amount' => :'Float',
|
|
221
225
|
:'roas_average_floor' => :'Float',
|
|
222
226
|
:'dsa_beneficiary' => :'String',
|
|
223
|
-
:'dsa_payor' => :'String'
|
|
227
|
+
:'dsa_payor' => :'String',
|
|
228
|
+
:'regional_regulated_categories' => :'Array<String>'
|
|
224
229
|
}
|
|
225
230
|
end
|
|
226
231
|
|
|
@@ -403,6 +408,12 @@ module Zernio
|
|
|
403
408
|
if attributes.key?(:'dsa_payor')
|
|
404
409
|
self.dsa_payor = attributes[:'dsa_payor']
|
|
405
410
|
end
|
|
411
|
+
|
|
412
|
+
if attributes.key?(:'regional_regulated_categories')
|
|
413
|
+
if (value = attributes[:'regional_regulated_categories']).is_a?(Array)
|
|
414
|
+
self.regional_regulated_categories = value
|
|
415
|
+
end
|
|
416
|
+
end
|
|
406
417
|
end
|
|
407
418
|
|
|
408
419
|
# Show invalid properties with the reasons. Usually used together with valid?
|
|
@@ -790,7 +801,8 @@ module Zernio
|
|
|
790
801
|
bid_amount == o.bid_amount &&
|
|
791
802
|
roas_average_floor == o.roas_average_floor &&
|
|
792
803
|
dsa_beneficiary == o.dsa_beneficiary &&
|
|
793
|
-
dsa_payor == o.dsa_payor
|
|
804
|
+
dsa_payor == o.dsa_payor &&
|
|
805
|
+
regional_regulated_categories == o.regional_regulated_categories
|
|
794
806
|
end
|
|
795
807
|
|
|
796
808
|
# @see the `==` method
|
|
@@ -802,7 +814,7 @@ module Zernio
|
|
|
802
814
|
# Calculates hash code according to all attributes.
|
|
803
815
|
# @return [Integer] Hash code
|
|
804
816
|
def hash
|
|
805
|
-
[account_id, ad_account_id, name, headline, body, image_url, video, welcome_message, creatives, ad_set_id, budget_amount, budget_type, currency, end_date, countries, cities, regions, zips, metros, custom_locations, age_min, age_max, interests, audience_id, placements, advantage_audience, objective, status, campaign_status, bid_strategy, bid_amount, roas_average_floor, dsa_beneficiary, dsa_payor].hash
|
|
817
|
+
[account_id, ad_account_id, name, headline, body, image_url, video, welcome_message, creatives, ad_set_id, budget_amount, budget_type, currency, end_date, countries, cities, regions, zips, metros, custom_locations, age_min, age_max, interests, audience_id, placements, advantage_audience, objective, status, campaign_status, bid_strategy, bid_amount, roas_average_floor, dsa_beneficiary, dsa_payor, regional_regulated_categories].hash
|
|
806
818
|
end
|
|
807
819
|
|
|
808
820
|
# Builds the object from hash
|
|
@@ -18,7 +18,7 @@ module Zernio
|
|
|
18
18
|
# Zernio SocialAccount id used to resolve the Meta token.
|
|
19
19
|
attr_accessor :account_id
|
|
20
20
|
|
|
21
|
-
#
|
|
21
|
+
# Platform ad account id (Meta act_<n>, Google customer id, LinkedIn account id, ...).
|
|
22
22
|
attr_accessor :ad_account_id
|
|
23
23
|
|
|
24
24
|
# Meta ad_format values, one preview per format. Defaults to [DESKTOP_FEED_STANDARD].
|
|
@@ -15,7 +15,7 @@ require 'time'
|
|
|
15
15
|
|
|
16
16
|
module Zernio
|
|
17
17
|
class UpdateAdCreativeRequest < ApiModelBase
|
|
18
|
-
# Zernio SocialAccount id (posting or ads variant)
|
|
18
|
+
# Zernio SocialAccount id (posting or ads variant); its platform decides where the campaign is created.
|
|
19
19
|
attr_accessor :account_id
|
|
20
20
|
|
|
21
21
|
attr_accessor :name
|
|
@@ -15,7 +15,7 @@ require 'time'
|
|
|
15
15
|
|
|
16
16
|
module Zernio
|
|
17
17
|
class UpdateValueRuleSetRequest < ApiModelBase
|
|
18
|
-
# Zernio SocialAccount id (posting or ads variant)
|
|
18
|
+
# Zernio SocialAccount id (posting or ads variant); its platform decides where the campaign is created.
|
|
19
19
|
attr_accessor :account_id
|
|
20
20
|
|
|
21
21
|
# Required: the update replaces the whole set.
|
|
@@ -15,10 +15,10 @@ require 'time'
|
|
|
15
15
|
|
|
16
16
|
module Zernio
|
|
17
17
|
class UploadAdImageRequest < ApiModelBase
|
|
18
|
-
# Zernio SocialAccount id (posting or ads variant)
|
|
18
|
+
# Zernio SocialAccount id (posting or ads variant); its platform decides where the campaign is created.
|
|
19
19
|
attr_accessor :account_id
|
|
20
20
|
|
|
21
|
-
#
|
|
21
|
+
# Platform ad account id (Meta act_<n>, Google customer id, LinkedIn account id, ...).
|
|
22
22
|
attr_accessor :ad_account_id
|
|
23
23
|
|
|
24
24
|
# Raw base64 image bytes, or a full data URL (the data:image/...;base64, prefix is stripped).
|
|
@@ -15,10 +15,10 @@ require 'time'
|
|
|
15
15
|
|
|
16
16
|
module Zernio
|
|
17
17
|
class UploadAdVideoRequest < ApiModelBase
|
|
18
|
-
# Zernio SocialAccount id (posting or ads variant)
|
|
18
|
+
# Zernio SocialAccount id (posting or ads variant); its platform decides where the campaign is created.
|
|
19
19
|
attr_accessor :account_id
|
|
20
20
|
|
|
21
|
-
#
|
|
21
|
+
# Platform ad account id (Meta act_<n>, Google customer id, LinkedIn account id, ...).
|
|
22
22
|
attr_accessor :ad_account_id
|
|
23
23
|
|
|
24
24
|
# Public https URL of the video; downloaded server-side (SSRF-guarded) before chunked upload. Provide exactly one of videoUrl or videoBase64.
|
data/lib/zernio-sdk/version.rb
CHANGED
data/openapi.yaml
CHANGED
|
@@ -1174,6 +1174,10 @@ components:
|
|
|
1174
1174
|
(for example, an agency paying for a client's ads). Same rules as
|
|
1175
1175
|
`dsaBeneficiary`: required for EU targeting unless the ad account has
|
|
1176
1176
|
a default payor.
|
|
1177
|
+
regionalRegulatedCategories:
|
|
1178
|
+
type: array
|
|
1179
|
+
description: 'Meta only. Regional regulation categories required when the ad set targets certain countries (e.g. SINGAPORE_UNIVERSAL, TAIWAN_UNIVERSAL, THAILAND_UNIVERSAL, AUSTRALIA_FINSERV, INDIA_FINSERV). Forwarded to the ad set.'
|
|
1180
|
+
items: { type: string }
|
|
1177
1181
|
WorkflowNode:
|
|
1178
1182
|
type: object
|
|
1179
1183
|
required: [id, type]
|
|
@@ -40605,14 +40609,19 @@ paths:
|
|
|
40605
40609
|
x-resource-group: "ads"
|
|
40606
40610
|
operationId: createAdCampaign
|
|
40607
40611
|
tags: ["Ad Campaigns"]
|
|
40608
|
-
x-platforms: ["meta"]
|
|
40612
|
+
x-platforms: ["meta", "google", "linkedin", "tiktok", "x", "pinterest", "openai"]
|
|
40609
40613
|
summary: Create a standalone campaign
|
|
40610
40614
|
description: |-
|
|
40611
|
-
Creates a campaign WITHOUT its first ad set / ad
|
|
40612
|
-
later via `existingCampaignId` on the create endpoints.
|
|
40613
|
-
|
|
40614
|
-
|
|
40615
|
-
|
|
40615
|
+
Creates a campaign WITHOUT its first ad set / ad, on the platform of the given
|
|
40616
|
+
`accountId`. Ad sets join it later via `existingCampaignId` on the create endpoints.
|
|
40617
|
+
Platform notes: on Meta a budget here is campaign-level (CBO) by definition; omit it
|
|
40618
|
+
for ABO (each ad set carries its own budget), and `specialAdCategories` /
|
|
40619
|
+
`bidStrategy` are Meta-only (400 elsewhere). Google, X and OpenAI require a budget
|
|
40620
|
+
(422 without one; OpenAI accepts only `budgetType: lifetime`). LinkedIn creates the
|
|
40621
|
+
campaign GROUP (our campaign level) and rejects a budget, which lives on the
|
|
40622
|
+
campaign (ad set) level there; it comes back `status: DRAFT`. TikTok campaigns are
|
|
40623
|
+
created without a status and report `ENABLE`. Created `PAUSED` unless
|
|
40624
|
+
`status: ACTIVE` where the platform supports it.
|
|
40616
40625
|
|
|
40617
40626
|
**Idempotency:** send an `Idempotency-Key` header to make retries safe.
|
|
40618
40627
|
security:
|
|
@@ -40636,8 +40645,8 @@ paths:
|
|
|
40636
40645
|
type: object
|
|
40637
40646
|
required: [accountId, adAccountId, name, goal]
|
|
40638
40647
|
properties:
|
|
40639
|
-
accountId: { type: string, description: "Zernio SocialAccount id (posting or ads variant)
|
|
40640
|
-
adAccountId: { type: string, description: "
|
|
40648
|
+
accountId: { type: string, description: "Zernio SocialAccount id (posting or ads variant); its platform decides where the campaign is created." }
|
|
40649
|
+
adAccountId: { type: string, description: "Platform ad account id (Meta act_<n>, Google customer id, LinkedIn account id, ...)." }
|
|
40641
40650
|
name: { type: string, maxLength: 255 }
|
|
40642
40651
|
goal:
|
|
40643
40652
|
type: string
|
|
@@ -41955,7 +41964,7 @@ paths:
|
|
|
41955
41964
|
required: [accountId, adAccountId]
|
|
41956
41965
|
properties:
|
|
41957
41966
|
accountId: { type: string, description: "Zernio SocialAccount id used to resolve the Meta token." }
|
|
41958
|
-
adAccountId: { type: string, description: "
|
|
41967
|
+
adAccountId: { type: string, description: "Platform ad account id (Meta act_<n>, Google customer id, LinkedIn account id, ...)." }
|
|
41959
41968
|
formats:
|
|
41960
41969
|
type: array
|
|
41961
41970
|
minItems: 1
|
|
@@ -42722,7 +42731,7 @@ paths:
|
|
|
42722
42731
|
required: [accountId, adAccountId, startDate, endDate]
|
|
42723
42732
|
properties:
|
|
42724
42733
|
accountId: { type: string, description: "Zernio SocialAccount id (posting or ads variant)." }
|
|
42725
|
-
adAccountId: { type: string, description: "
|
|
42734
|
+
adAccountId: { type: string, description: "Platform ad account id (Meta act_<n>, Google customer id, LinkedIn account id, ...)." }
|
|
42726
42735
|
budgetAmount: { type: number, description: "Whole currency units. Exactly one of budgetAmount / reach." }
|
|
42727
42736
|
reach: { type: integer, description: "Target unique reach. Exactly one of budgetAmount / reach." }
|
|
42728
42737
|
startDate: { type: string, format: date-time, description: "Campaign window start (must be in the future)." }
|
|
@@ -43096,7 +43105,7 @@ paths:
|
|
|
43096
43105
|
required: [accountId, adAccountId, headline, body, linkUrl]
|
|
43097
43106
|
properties:
|
|
43098
43107
|
accountId: { type: string, description: "Zernio SocialAccount id (posting or ads variant) used to resolve the Meta token and Page." }
|
|
43099
|
-
adAccountId: { type: string, description: "
|
|
43108
|
+
adAccountId: { type: string, description: "Platform ad account id (Meta act_<n>, Google customer id, LinkedIn account id, ...)." }
|
|
43100
43109
|
headline: { type: string, maxLength: 255 }
|
|
43101
43110
|
body: { type: string, description: Primary text }
|
|
43102
43111
|
description: { type: string, maxLength: 255, description: "Link description below the headline; omitted = Meta scrapes the destination's OG description." }
|
|
@@ -43192,7 +43201,7 @@ paths:
|
|
|
43192
43201
|
type: object
|
|
43193
43202
|
required: [accountId, name]
|
|
43194
43203
|
properties:
|
|
43195
|
-
accountId: { type: string, description: "Zernio SocialAccount id (posting or ads variant)
|
|
43204
|
+
accountId: { type: string, description: "Zernio SocialAccount id (posting or ads variant); its platform decides where the campaign is created." }
|
|
43196
43205
|
name: { type: string, maxLength: 255 }
|
|
43197
43206
|
responses:
|
|
43198
43207
|
'200':
|
|
@@ -43335,8 +43344,8 @@ paths:
|
|
|
43335
43344
|
type: object
|
|
43336
43345
|
required: [accountId, adAccountId, name, rules]
|
|
43337
43346
|
properties:
|
|
43338
|
-
accountId: { type: string, description: "Zernio SocialAccount id (posting or ads variant)
|
|
43339
|
-
adAccountId: { type: string, description: "
|
|
43347
|
+
accountId: { type: string, description: "Zernio SocialAccount id (posting or ads variant); its platform decides where the campaign is created." }
|
|
43348
|
+
adAccountId: { type: string, description: "Platform ad account id (Meta act_<n>, Google customer id, LinkedIn account id, ...)." }
|
|
43340
43349
|
name: { type: string, minLength: 1, maxLength: 255 }
|
|
43341
43350
|
rules:
|
|
43342
43351
|
type: array
|
|
@@ -43426,7 +43435,7 @@ paths:
|
|
|
43426
43435
|
type: object
|
|
43427
43436
|
required: [accountId, name, rules]
|
|
43428
43437
|
properties:
|
|
43429
|
-
accountId: { type: string, description: "Zernio SocialAccount id (posting or ads variant)
|
|
43438
|
+
accountId: { type: string, description: "Zernio SocialAccount id (posting or ads variant); its platform decides where the campaign is created." }
|
|
43430
43439
|
name: { type: string, minLength: 1, maxLength: 255, description: "Required: the update replaces the whole set." }
|
|
43431
43440
|
rules:
|
|
43432
43441
|
type: array
|
|
@@ -43951,6 +43960,10 @@ paths:
|
|
|
43951
43960
|
type: array
|
|
43952
43961
|
description: 'Meta (metaads) only. 2-letter ISO country codes the special ad category applies to. Requires specialAdCategories to be set (400 otherwise).'
|
|
43953
43962
|
items: { type: string }
|
|
43963
|
+
regionalRegulatedCategories:
|
|
43964
|
+
type: array
|
|
43965
|
+
description: 'Meta only. Regional regulation categories required when the ad set targets certain countries (e.g. SINGAPORE_UNIVERSAL, TAIWAN_UNIVERSAL, THAILAND_UNIVERSAL, AUSTRALIA_FINSERV, INDIA_FINSERV). Forwarded to the ad set.'
|
|
43966
|
+
items: { type: string }
|
|
43954
43967
|
linkUrl:
|
|
43955
43968
|
type: string
|
|
43956
43969
|
format: uri
|
|
@@ -44488,6 +44501,14 @@ paths:
|
|
|
44488
44501
|
specialAdCategories to be set (400 otherwise). Ignored when joining an existing campaign via
|
|
44489
44502
|
existingCampaignId (the existing campaign's category/country already governs it).
|
|
44490
44503
|
items: { type: string }
|
|
44504
|
+
regionalRegulatedCategories:
|
|
44505
|
+
type: array
|
|
44506
|
+
description: |
|
|
44507
|
+
Meta only. Regional regulation categories required when the ad set targets certain countries.
|
|
44508
|
+
Known values: SINGAPORE_UNIVERSAL, TAIWAN_UNIVERSAL, THAILAND_UNIVERSAL, AUSTRALIA_FINSERV,
|
|
44509
|
+
INDIA_FINSERV, TAIWAN_FINSERV. Meta rejects the ad set without this when the targeting geo
|
|
44510
|
+
includes the corresponding country.
|
|
44511
|
+
items: { type: string }
|
|
44491
44512
|
endDate: { type: string, format: date-time, description: Required for lifetime budgets }
|
|
44492
44513
|
startDate:
|
|
44493
44514
|
type: string
|
|
@@ -45492,8 +45513,8 @@ paths:
|
|
|
45492
45513
|
type: object
|
|
45493
45514
|
required: [accountId, adAccountId, imageBase64]
|
|
45494
45515
|
properties:
|
|
45495
|
-
accountId: { type: string, description: "Zernio SocialAccount id (posting or ads variant)
|
|
45496
|
-
adAccountId: { type: string, description: "
|
|
45516
|
+
accountId: { type: string, description: "Zernio SocialAccount id (posting or ads variant); its platform decides where the campaign is created." }
|
|
45517
|
+
adAccountId: { type: string, description: "Platform ad account id (Meta act_<n>, Google customer id, LinkedIn account id, ...)." }
|
|
45497
45518
|
imageBase64: { type: string, description: "Raw base64 image bytes, or a full data URL (the data:image/...;base64, prefix is stripped)." }
|
|
45498
45519
|
filename: { type: string, description: "Optional filename shown in Meta's image library. Defaults to ad_image.jpg." }
|
|
45499
45520
|
responses:
|
|
@@ -45584,8 +45605,8 @@ paths:
|
|
|
45584
45605
|
type: object
|
|
45585
45606
|
required: [accountId, adAccountId]
|
|
45586
45607
|
properties:
|
|
45587
|
-
accountId: { type: string, description: "Zernio SocialAccount id (posting or ads variant)
|
|
45588
|
-
adAccountId: { type: string, description: "
|
|
45608
|
+
accountId: { type: string, description: "Zernio SocialAccount id (posting or ads variant); its platform decides where the campaign is created." }
|
|
45609
|
+
adAccountId: { type: string, description: "Platform ad account id (Meta act_<n>, Google customer id, LinkedIn account id, ...)." }
|
|
45589
45610
|
videoUrl: { type: string, description: "Public https URL of the video; downloaded server-side (SSRF-guarded) before chunked upload. Provide exactly one of videoUrl or videoBase64." }
|
|
45590
45611
|
videoBase64: { type: string, description: "Raw base64 video bytes, or a full data URL (the data:video/...;base64, prefix is stripped). Capped by Vercel's body limit (~4.5 MB payload). Provide exactly one of videoUrl or videoBase64." }
|
|
45591
45612
|
filename: { type: string, description: "Optional filename shown alongside the upload session. Applied only when uploading via videoBase64." }
|
|
@@ -47958,7 +47979,7 @@ paths:
|
|
|
47958
47979
|
type: object
|
|
47959
47980
|
required: [adAccountId, name, pixelId, customEventType, rule]
|
|
47960
47981
|
properties:
|
|
47961
|
-
adAccountId: { type: string, description: "
|
|
47982
|
+
adAccountId: { type: string, description: "Platform ad account id (Meta act_<n>, Google customer id, LinkedIn account id, ...)." }
|
|
47962
47983
|
name: { type: string, maxLength: 255, description: "Also the reuse key, together with pixelId." }
|
|
47963
47984
|
pixelId: { type: string, description: "Meta pixel id (event_source_id). From GET /v1/accounts/{accountId}/tracking-tags." }
|
|
47964
47985
|
customEventType: { type: string, description: "Meta custom_event_type, e.g. LEAD, PURCHASE, OTHER." }
|
|
@@ -72,7 +72,7 @@ describe 'AdCampaignsApi' do
|
|
|
72
72
|
|
|
73
73
|
# unit tests for create_ad_campaign
|
|
74
74
|
# Create a standalone campaign
|
|
75
|
-
# Creates a campaign WITHOUT its first ad set / ad
|
|
75
|
+
# Creates a campaign WITHOUT its first ad set / ad, on the platform of the given `accountId`. Ad sets join it later via `existingCampaignId` on the create endpoints. Platform notes: on Meta a budget here is campaign-level (CBO) by definition; omit it for ABO (each ad set carries its own budget), and `specialAdCategories` / `bidStrategy` are Meta-only (400 elsewhere). Google, X and OpenAI require a budget (422 without one; OpenAI accepts only `budgetType: lifetime`). LinkedIn creates the campaign GROUP (our campaign level) and rejects a budget, which lives on the campaign (ad set) level there; it comes back `status: DRAFT`. TikTok campaigns are created without a status and report `ENABLE`. Created `PAUSED` unless `status: ACTIVE` where the platform supports it. **Idempotency:** send an `Idempotency-Key` header to make retries safe.
|
|
76
76
|
# @param create_ad_campaign_request
|
|
77
77
|
# @param [Hash] opts the optional parameters
|
|
78
78
|
# @option opts [String] :idempotency_key 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.
|
|
@@ -165,6 +165,12 @@ describe Zernio::BoostPostRequest do
|
|
|
165
165
|
end
|
|
166
166
|
end
|
|
167
167
|
|
|
168
|
+
describe 'test attribute "regional_regulated_categories"' do
|
|
169
|
+
it 'should work' do
|
|
170
|
+
# assertion here. ref: https://rspec.info/features/3-12/rspec-expectations/built-in-matchers/
|
|
171
|
+
end
|
|
172
|
+
end
|
|
173
|
+
|
|
168
174
|
describe 'test attribute "link_url"' do
|
|
169
175
|
it 'should work' do
|
|
170
176
|
# assertion here. ref: https://rspec.info/features/3-12/rspec-expectations/built-in-matchers/
|
|
@@ -255,6 +255,12 @@ describe Zernio::CreateCallAdRequest do
|
|
|
255
255
|
end
|
|
256
256
|
end
|
|
257
257
|
|
|
258
|
+
describe 'test attribute "regional_regulated_categories"' do
|
|
259
|
+
it 'should work' do
|
|
260
|
+
# assertion here. ref: https://rspec.info/features/3-12/rspec-expectations/built-in-matchers/
|
|
261
|
+
end
|
|
262
|
+
end
|
|
263
|
+
|
|
258
264
|
describe 'test attribute "phone_number"' do
|
|
259
265
|
it 'should work' do
|
|
260
266
|
# assertion here. ref: https://rspec.info/features/3-12/rspec-expectations/built-in-matchers/
|
|
@@ -255,6 +255,12 @@ describe Zernio::CreateMessagingAdRequest do
|
|
|
255
255
|
end
|
|
256
256
|
end
|
|
257
257
|
|
|
258
|
+
describe 'test attribute "regional_regulated_categories"' do
|
|
259
|
+
it 'should work' do
|
|
260
|
+
# assertion here. ref: https://rspec.info/features/3-12/rspec-expectations/built-in-matchers/
|
|
261
|
+
end
|
|
262
|
+
end
|
|
263
|
+
|
|
258
264
|
describe 'test attribute "destination"' do
|
|
259
265
|
it 'should work' do
|
|
260
266
|
# assertion here. ref: https://rspec.info/features/3-12/rspec-expectations/built-in-matchers/
|
|
@@ -425,6 +425,12 @@ describe Zernio::CreateStandaloneAdRequest do
|
|
|
425
425
|
end
|
|
426
426
|
end
|
|
427
427
|
|
|
428
|
+
describe 'test attribute "regional_regulated_categories"' do
|
|
429
|
+
it 'should work' do
|
|
430
|
+
# assertion here. ref: https://rspec.info/features/3-12/rspec-expectations/built-in-matchers/
|
|
431
|
+
end
|
|
432
|
+
end
|
|
433
|
+
|
|
428
434
|
describe 'test attribute "end_date"' do
|
|
429
435
|
it 'should work' do
|
|
430
436
|
# assertion here. ref: https://rspec.info/features/3-12/rspec-expectations/built-in-matchers/
|
|
@@ -255,4 +255,10 @@ describe Zernio::CtwaAdRequestBody do
|
|
|
255
255
|
end
|
|
256
256
|
end
|
|
257
257
|
|
|
258
|
+
describe 'test attribute "regional_regulated_categories"' do
|
|
259
|
+
it 'should work' do
|
|
260
|
+
# assertion here. ref: https://rspec.info/features/3-12/rspec-expectations/built-in-matchers/
|
|
261
|
+
end
|
|
262
|
+
end
|
|
263
|
+
|
|
258
264
|
end
|
metadata
CHANGED
|
@@ -1,14 +1,14 @@
|
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
|
2
2
|
name: zernio-sdk
|
|
3
3
|
version: !ruby/object:Gem::Version
|
|
4
|
-
version: 0.0.
|
|
4
|
+
version: 0.0.820
|
|
5
5
|
platform: ruby
|
|
6
6
|
authors:
|
|
7
7
|
- OpenAPI-Generator
|
|
8
8
|
autorequire:
|
|
9
9
|
bindir: bin
|
|
10
10
|
cert_chain: []
|
|
11
|
-
date: 2026-09-
|
|
11
|
+
date: 2026-09-02 00:00:00.000000000 Z
|
|
12
12
|
dependencies:
|
|
13
13
|
- !ruby/object:Gem::Dependency
|
|
14
14
|
name: typhoeus
|