late-sdk 0.0.752 → 0.0.754
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/Ad.md +1 -1
- data/docs/CreateStandaloneAdRequest.md +1 -1
- data/docs/WebhookPayloadCommentPost.md +1 -1
- data/lib/zernio-sdk/models/ad.rb +3 -3
- data/lib/zernio-sdk/models/create_ad_campaign_request.rb +2 -2
- data/lib/zernio-sdk/models/create_standalone_ad_request.rb +3 -3
- data/lib/zernio-sdk/models/webhook_payload_comment_post.rb +1 -1
- data/lib/zernio-sdk/version.rb +1 -1
- data/openapi.yaml +5 -4
- data/spec/models/ad_spec.rb +1 -1
- data/spec/models/create_ad_campaign_request_spec.rb +1 -1
- data/spec/models/create_standalone_ad_request_spec.rb +1 -1
- data/zernio-sdk-0.0.754.gem +0 -0
- metadata +2 -2
- data/zernio-sdk-0.0.752.gem +0 -0
checksums.yaml
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
SHA256:
|
|
3
|
-
metadata.gz:
|
|
4
|
-
data.tar.gz:
|
|
3
|
+
metadata.gz: 5dfed233786b86712922897663250fd0809aa8495ce782e40fec7512b6b9cd75
|
|
4
|
+
data.tar.gz: ef5b2b011af25f6b00e12f371ffd044f1aba558e496ef0b796c5368003f3c50a
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: 3bb83b85f684a3f8e1ee385ca0259f78cdc4faa7683b73aca7917c964f4d2c516853e77309d823a28511057c426fbc5ebc9e5b8f5da4c5da35e8acfc0208fcc1
|
|
7
|
+
data.tar.gz: 2404ac343f173031596b3ba87daf2b396f4d60c7c057e601fd2f997e173f720b1b37b52e907e065246ea0d16a5310fdd5990a76b9c8b1ed1e02216c979386883
|
data/docs/Ad.md
CHANGED
|
@@ -12,7 +12,7 @@
|
|
|
12
12
|
| **review_status** | [**AdReviewStatus**](AdReviewStatus.md) | Platform review state of this ad, independent of delivery `status` / `configuredStatus`. Absent when the platform reports no review signal. | [optional] |
|
|
13
13
|
| **ad_type** | **String** | | [optional] |
|
|
14
14
|
| **creative_type** | **String** | Creative format, classified from the media the creative carries. `null` when the creative carries no media to classify — an unsynced creative and a genuine text-only ad are indistinguishable, so neither is guessed at. Returned by `GET /v1/ads`, `GET /v1/ads/{adId}` and the ad nodes of `GET /v1/ads/tree`. | [optional] |
|
|
15
|
-
| **goal** | **String** | Available goals vary by platform. Meta (Facebook/Instagram) supports all
|
|
15
|
+
| **goal** | **String** | Available goals vary by platform. Meta (Facebook/Instagram) supports all 10 (incl. `lead_conversion` = website pixel lead optimization, `catalog_sales` = Advantage+ catalog ads and `page_likes` = Page Likes conversion location under Engagement). TikTok supports engagement, traffic, awareness, video_views, lead_generation, conversions, app_promotion. LinkedIn supports all Meta goals except app_promotion / lead_conversion / catalog_sales / page_likes. Twitter/X supports engagement, traffic, awareness, video_views, app_promotion. Pinterest and Google Ads support only engagement, traffic, awareness, video_views. | [optional] |
|
|
16
16
|
| **is_external** | **Boolean** | True for ads synced from platform ad managers | [optional] |
|
|
17
17
|
| **budget** | [**AdBudget**](AdBudget.md) | | [optional] |
|
|
18
18
|
| **metrics** | [**AdMetrics**](AdMetrics.md) | | [optional] |
|
|
@@ -11,7 +11,7 @@
|
|
|
11
11
|
| **ad_set_name** | **String** | Meta only. Exact ad set name. Overrides the default `<name> - Ad Set`. (For per-ad names on the multi-creative shape, set `name` on each `creatives[]` entry.) | [optional] |
|
|
12
12
|
| **ad_name** | **String** | Meta only. Exact ad name (the single-creative ad object's name). Overrides the default, which is `name`. (For per-ad names on the multi-creative shape, set `name` on each `creatives[]` entry instead.) | [optional] |
|
|
13
13
|
| **tracking** | [**CreateStandaloneAdRequestTracking**](CreateStandaloneAdRequestTracking.md) | | [optional] |
|
|
14
|
-
| **goal** | **String** | Required on legacy and multi-creative shapes; the attach shape inherits it from the ad set. Available goals vary by platform. **Meta** - `conversions`: OUTCOME_SALES. Requires `promotedObject.pixelId` and `promotedObject.customEventType` with a commerce event such as PURCHASE or START_TRIAL, or `promotedObject.customConversionId` to optimise against a Custom Conversion, or `customEventType: OTHER` + `customEventStr` to optimise against a pixel custom event. - `lead_conversion`: OUTCOME_LEADS optimizing website pixel leads. Same pixel and event fields, but with a leads-class event such as LEAD, SUBMIT_APPLICATION, SCHEDULE or CONTACT (or `promotedObject.customConversionId` to optimise against a Custom Conversion instead). Meta gates conversion events by objective, so leads-class events are rejected under `conversions`. - `lead_generation`: OUTCOME_LEADS with instant forms. Requires `leadGenFormId`. `promotedObject.pageId` is optional and auto-filled from the connected Page. - `app_promotion`: requires `promotedObject.applicationId` and `promotedObject.objectStoreUrl`. - `catalog_sales`: Advantage+ catalog ads, for example vehicle inventory. Requires `promotedObject.productSetId`, `promotedObject.pixelId` and `promotedObject.customEventType`. Builds a catalog TEMPLATE creative from the copy fields, which may carry template tags like {{product.name}} or {{vehicle.make}}. No imageUrl or video is sent; Meta renders the visuals per catalog item. Discover catalogs via GET /v1/ads/catalogs and product sets via GET /v1/ads/catalogs/{catalogId}/product-sets. Single shape only, no creatives[], adSetId, dynamicCreative or placementAssets. **TikTok** - `conversions`: website-conversion ad group. Requires `promotedObject.pixelId`, your TikTok Pixel ID. Accepts an optional `promotedObject.customEventType` with a TikTok optimization_event code your pixel tracks (newer pixels use e.g. SHOPPING for purchase events; legacy pixels use ON_WEB_ORDER, INITIATE_ORDER, ON_WEB_REGISTER or FORM). To inherit pixel and event from an existing ad group, pass `adSetId` instead. **LinkedIn** - `engagement`, `traffic`, `awareness` and `video_views` create standalone Direct Sponsored Content ads. `traffic` requires `linkUrl`; `video_views` requires `video`. - `job_applicants` requires a `platformSpecificData.jobs` creative. - For `lead_generation` or `conversions` on LinkedIn, or to promote an existing post, use POST /v1/ads/boost. **OpenAI Ads** - Only `traffic`, `awareness`, and `conversions` are supported (other goals return 400). Maps to OpenAI's `bidding_type` (clicks, impressions, conversions respectively). `conversions` requires an active conversion event setting on the account; create a tracking tag with `defaultEventType` via the tracking-tags API (`POST /v1/accounts/{accountId}/tracking-tags`), or configure a conversion event in OpenAI Ads Manager, or the request returns 422. | [optional] |
|
|
14
|
+
| **goal** | **String** | Required on legacy and multi-creative shapes; the attach shape inherits it from the ad set. Available goals vary by platform. **Meta** - `conversions`: OUTCOME_SALES. Requires `promotedObject.pixelId` and `promotedObject.customEventType` with a commerce event such as PURCHASE or START_TRIAL, or `promotedObject.customConversionId` to optimise against a Custom Conversion, or `customEventType: OTHER` + `customEventStr` to optimise against a pixel custom event. - `lead_conversion`: OUTCOME_LEADS optimizing website pixel leads. Same pixel and event fields, but with a leads-class event such as LEAD, SUBMIT_APPLICATION, SCHEDULE or CONTACT (or `promotedObject.customConversionId` to optimise against a Custom Conversion instead). Meta gates conversion events by objective, so leads-class events are rejected under `conversions`. - `lead_generation`: OUTCOME_LEADS with instant forms. Requires `leadGenFormId`. `promotedObject.pageId` is optional and auto-filled from the connected Page. - `app_promotion`: requires `promotedObject.applicationId` and `promotedObject.objectStoreUrl`. - `catalog_sales`: Advantage+ catalog ads, for example vehicle inventory. Requires `promotedObject.productSetId`, `promotedObject.pixelId` and `promotedObject.customEventType`. Builds a catalog TEMPLATE creative from the copy fields, which may carry template tags like {{product.name}} or {{vehicle.make}}. No imageUrl or video is sent; Meta renders the visuals per catalog item. Discover catalogs via GET /v1/ads/catalogs and product sets via GET /v1/ads/catalogs/{catalogId}/product-sets. Single shape only, no creatives[], adSetId, dynamicCreative or placementAssets. - `page_likes`: Page Likes conversion location under OUTCOME_ENGAGEMENT (destination_type ON_PAGE, optimization PAGE_LIKES). `promotedObject.pageId` is optional and auto-filled from the connected Page. The creative CTA is fixed to LIKE_PAGE targeting that Page; headline / body / linkUrl / callToAction / imageUrl / video are all optional (Meta derives the link and the Like button from the Page). **TikTok** - `conversions`: website-conversion ad group. Requires `promotedObject.pixelId`, your TikTok Pixel ID. Accepts an optional `promotedObject.customEventType` with a TikTok optimization_event code your pixel tracks (newer pixels use e.g. SHOPPING for purchase events; legacy pixels use ON_WEB_ORDER, INITIATE_ORDER, ON_WEB_REGISTER or FORM). To inherit pixel and event from an existing ad group, pass `adSetId` instead. **LinkedIn** - `engagement`, `traffic`, `awareness` and `video_views` create standalone Direct Sponsored Content ads. `traffic` requires `linkUrl`; `video_views` requires `video`. - `job_applicants` requires a `platformSpecificData.jobs` creative. - For `lead_generation` or `conversions` on LinkedIn, or to promote an existing post, use POST /v1/ads/boost. **OpenAI Ads** - Only `traffic`, `awareness`, and `conversions` are supported (other goals return 400). Maps to OpenAI's `bidding_type` (clicks, impressions, conversions respectively). `conversions` requires an active conversion event setting on the account; create a tracking tag with `defaultEventType` via the tracking-tags API (`POST /v1/accounts/{accountId}/tracking-tags`), or configure a conversion event in OpenAI Ads Manager, or the request returns 422. | [optional] |
|
|
15
15
|
| **optimization_goal** | **String** | Meta only. Explicit ad-set `optimization_goal` (e.g. `LANDING_PAGE_VIEWS`, `LINK_CLICKS`, `REACH`, `IMPRESSIONS`, `OFFSITE_CONVERSIONS`, `THRUPLAY`, `LEAD_GENERATION`). Overrides the default derived from `goal` (e.g. `traffic` defaults to `LINK_CLICKS`). Forwarded verbatim to Meta, which validates compatibility with the campaign objective and rejects incompatible combinations. | [optional] |
|
|
16
16
|
| **billing_event** | **String** | Meta only. Explicit ad-set `billing_event`. Defaults to `IMPRESSIONS`. Forwarded verbatim to Meta, which validates compatibility with the optimization goal. | [optional] |
|
|
17
17
|
| **buying_type** | **String** | Meta only. RESERVED = Reach & Frequency: requires `rfPredictionId` (a RESERVED prediction from /v1/ads/rf-predictions + /reserve). Budget, schedule and pricing come from the reservation, so budgetAmount/budgetType are not required and bid fields are ignored. Only the plain single-ad shape (no creatives[], adSetId, existingCampaignId or dynamicCreative). | [optional] |
|
|
@@ -8,7 +8,7 @@
|
|
|
8
8
|
| **platform_post_id** | **String** | Platform's post ID | |
|
|
9
9
|
| **content** | **String** | Post text, from our synced copy — no platform call is made on the comment path, so null when the post was never synced. | |
|
|
10
10
|
| **image_url** | **String** | Post thumbnail or first media item URL. Platform CDN URLs expire, fetch promptly. | |
|
|
11
|
-
| **permalink** | **String** | Public URL of the post. Null for
|
|
11
|
+
| **permalink** | **String** | Public URL of the post. Null when no URL was ever stored for it, for example a platform draft or a post recovered without one. | |
|
|
12
12
|
|
|
13
13
|
## Example
|
|
14
14
|
|
data/lib/zernio-sdk/models/ad.rb
CHANGED
|
@@ -35,7 +35,7 @@ module Zernio
|
|
|
35
35
|
# Creative format, classified from the media the creative carries. `null` when the creative carries no media to classify — an unsynced creative and a genuine text-only ad are indistinguishable, so neither is guessed at. Returned by `GET /v1/ads`, `GET /v1/ads/{adId}` and the ad nodes of `GET /v1/ads/tree`.
|
|
36
36
|
attr_accessor :creative_type
|
|
37
37
|
|
|
38
|
-
# Available goals vary by platform. Meta (Facebook/Instagram) supports all
|
|
38
|
+
# Available goals vary by platform. Meta (Facebook/Instagram) supports all 10 (incl. `lead_conversion` = website pixel lead optimization, `catalog_sales` = Advantage+ catalog ads and `page_likes` = Page Likes conversion location under Engagement). TikTok supports engagement, traffic, awareness, video_views, lead_generation, conversions, app_promotion. LinkedIn supports all Meta goals except app_promotion / lead_conversion / catalog_sales / page_likes. Twitter/X supports engagement, traffic, awareness, video_views, app_promotion. Pinterest and Google Ads support only engagement, traffic, awareness, video_views.
|
|
39
39
|
attr_accessor :goal
|
|
40
40
|
|
|
41
41
|
# True for ads synced from platform ad managers
|
|
@@ -400,7 +400,7 @@ module Zernio
|
|
|
400
400
|
return false unless ad_type_validator.valid?(@ad_type)
|
|
401
401
|
creative_type_validator = EnumAttributeValidator.new('String', ["carousel", "video", "document", "image"])
|
|
402
402
|
return false unless creative_type_validator.valid?(@creative_type)
|
|
403
|
-
goal_validator = EnumAttributeValidator.new('String', ["engagement", "traffic", "awareness", "video_views", "lead_generation", "lead_conversion", "conversions", "app_promotion", "catalog_sales", "job_applicants"])
|
|
403
|
+
goal_validator = EnumAttributeValidator.new('String', ["engagement", "traffic", "awareness", "video_views", "lead_generation", "lead_conversion", "conversions", "app_promotion", "catalog_sales", "page_likes", "job_applicants"])
|
|
404
404
|
return false unless goal_validator.valid?(@goal)
|
|
405
405
|
true
|
|
406
406
|
end
|
|
@@ -438,7 +438,7 @@ module Zernio
|
|
|
438
438
|
# Custom attribute writer method checking allowed values (enum).
|
|
439
439
|
# @param [Object] goal Object to be assigned
|
|
440
440
|
def goal=(goal)
|
|
441
|
-
validator = EnumAttributeValidator.new('String', ["engagement", "traffic", "awareness", "video_views", "lead_generation", "lead_conversion", "conversions", "app_promotion", "catalog_sales", "job_applicants"])
|
|
441
|
+
validator = EnumAttributeValidator.new('String', ["engagement", "traffic", "awareness", "video_views", "lead_generation", "lead_conversion", "conversions", "app_promotion", "catalog_sales", "page_likes", "job_applicants"])
|
|
442
442
|
unless validator.valid?(goal)
|
|
443
443
|
fail ArgumentError, "invalid value for \"goal\", must be one of #{validator.allowable_values}."
|
|
444
444
|
end
|
|
@@ -226,7 +226,7 @@ module Zernio
|
|
|
226
226
|
return false if @name.nil?
|
|
227
227
|
return false if @name.to_s.length > 255
|
|
228
228
|
return false if @goal.nil?
|
|
229
|
-
goal_validator = EnumAttributeValidator.new('String', ["engagement", "traffic", "awareness", "video_views", "lead_generation", "lead_conversion", "job_applicants", "conversions", "app_promotion", "catalog_sales"])
|
|
229
|
+
goal_validator = EnumAttributeValidator.new('String', ["engagement", "traffic", "awareness", "video_views", "lead_generation", "lead_conversion", "job_applicants", "conversions", "app_promotion", "catalog_sales", "page_likes"])
|
|
230
230
|
return false unless goal_validator.valid?(@goal)
|
|
231
231
|
budget_type_validator = EnumAttributeValidator.new('String', ["daily", "lifetime"])
|
|
232
232
|
return false unless budget_type_validator.valid?(@budget_type)
|
|
@@ -274,7 +274,7 @@ module Zernio
|
|
|
274
274
|
# Custom attribute writer method checking allowed values (enum).
|
|
275
275
|
# @param [Object] goal Object to be assigned
|
|
276
276
|
def goal=(goal)
|
|
277
|
-
validator = EnumAttributeValidator.new('String', ["engagement", "traffic", "awareness", "video_views", "lead_generation", "lead_conversion", "job_applicants", "conversions", "app_promotion", "catalog_sales"])
|
|
277
|
+
validator = EnumAttributeValidator.new('String', ["engagement", "traffic", "awareness", "video_views", "lead_generation", "lead_conversion", "job_applicants", "conversions", "app_promotion", "catalog_sales", "page_likes"])
|
|
278
278
|
unless validator.valid?(goal)
|
|
279
279
|
fail ArgumentError, "invalid value for \"goal\", must be one of #{validator.allowable_values}."
|
|
280
280
|
end
|
|
@@ -32,7 +32,7 @@ module Zernio
|
|
|
32
32
|
|
|
33
33
|
attr_accessor :tracking
|
|
34
34
|
|
|
35
|
-
# Required on legacy and multi-creative shapes; the attach shape inherits it from the ad set. Available goals vary by platform. **Meta** - `conversions`: OUTCOME_SALES. Requires `promotedObject.pixelId` and `promotedObject.customEventType` with a commerce event such as PURCHASE or START_TRIAL, or `promotedObject.customConversionId` to optimise against a Custom Conversion, or `customEventType: OTHER` + `customEventStr` to optimise against a pixel custom event. - `lead_conversion`: OUTCOME_LEADS optimizing website pixel leads. Same pixel and event fields, but with a leads-class event such as LEAD, SUBMIT_APPLICATION, SCHEDULE or CONTACT (or `promotedObject.customConversionId` to optimise against a Custom Conversion instead). Meta gates conversion events by objective, so leads-class events are rejected under `conversions`. - `lead_generation`: OUTCOME_LEADS with instant forms. Requires `leadGenFormId`. `promotedObject.pageId` is optional and auto-filled from the connected Page. - `app_promotion`: requires `promotedObject.applicationId` and `promotedObject.objectStoreUrl`. - `catalog_sales`: Advantage+ catalog ads, for example vehicle inventory. Requires `promotedObject.productSetId`, `promotedObject.pixelId` and `promotedObject.customEventType`. Builds a catalog TEMPLATE creative from the copy fields, which may carry template tags like {{product.name}} or {{vehicle.make}}. No imageUrl or video is sent; Meta renders the visuals per catalog item. Discover catalogs via GET /v1/ads/catalogs and product sets via GET /v1/ads/catalogs/{catalogId}/product-sets. Single shape only, no creatives[], adSetId, dynamicCreative or placementAssets. **TikTok** - `conversions`: website-conversion ad group. Requires `promotedObject.pixelId`, your TikTok Pixel ID. Accepts an optional `promotedObject.customEventType` with a TikTok optimization_event code your pixel tracks (newer pixels use e.g. SHOPPING for purchase events; legacy pixels use ON_WEB_ORDER, INITIATE_ORDER, ON_WEB_REGISTER or FORM). To inherit pixel and event from an existing ad group, pass `adSetId` instead. **LinkedIn** - `engagement`, `traffic`, `awareness` and `video_views` create standalone Direct Sponsored Content ads. `traffic` requires `linkUrl`; `video_views` requires `video`. - `job_applicants` requires a `platformSpecificData.jobs` creative. - For `lead_generation` or `conversions` on LinkedIn, or to promote an existing post, use POST /v1/ads/boost. **OpenAI Ads** - Only `traffic`, `awareness`, and `conversions` are supported (other goals return 400). Maps to OpenAI's `bidding_type` (clicks, impressions, conversions respectively). `conversions` requires an active conversion event setting on the account; create a tracking tag with `defaultEventType` via the tracking-tags API (`POST /v1/accounts/{accountId}/tracking-tags`), or configure a conversion event in OpenAI Ads Manager, or the request returns 422.
|
|
35
|
+
# Required on legacy and multi-creative shapes; the attach shape inherits it from the ad set. Available goals vary by platform. **Meta** - `conversions`: OUTCOME_SALES. Requires `promotedObject.pixelId` and `promotedObject.customEventType` with a commerce event such as PURCHASE or START_TRIAL, or `promotedObject.customConversionId` to optimise against a Custom Conversion, or `customEventType: OTHER` + `customEventStr` to optimise against a pixel custom event. - `lead_conversion`: OUTCOME_LEADS optimizing website pixel leads. Same pixel and event fields, but with a leads-class event such as LEAD, SUBMIT_APPLICATION, SCHEDULE or CONTACT (or `promotedObject.customConversionId` to optimise against a Custom Conversion instead). Meta gates conversion events by objective, so leads-class events are rejected under `conversions`. - `lead_generation`: OUTCOME_LEADS with instant forms. Requires `leadGenFormId`. `promotedObject.pageId` is optional and auto-filled from the connected Page. - `app_promotion`: requires `promotedObject.applicationId` and `promotedObject.objectStoreUrl`. - `catalog_sales`: Advantage+ catalog ads, for example vehicle inventory. Requires `promotedObject.productSetId`, `promotedObject.pixelId` and `promotedObject.customEventType`. Builds a catalog TEMPLATE creative from the copy fields, which may carry template tags like {{product.name}} or {{vehicle.make}}. No imageUrl or video is sent; Meta renders the visuals per catalog item. Discover catalogs via GET /v1/ads/catalogs and product sets via GET /v1/ads/catalogs/{catalogId}/product-sets. Single shape only, no creatives[], adSetId, dynamicCreative or placementAssets. - `page_likes`: Page Likes conversion location under OUTCOME_ENGAGEMENT (destination_type ON_PAGE, optimization PAGE_LIKES). `promotedObject.pageId` is optional and auto-filled from the connected Page. The creative CTA is fixed to LIKE_PAGE targeting that Page; headline / body / linkUrl / callToAction / imageUrl / video are all optional (Meta derives the link and the Like button from the Page). **TikTok** - `conversions`: website-conversion ad group. Requires `promotedObject.pixelId`, your TikTok Pixel ID. Accepts an optional `promotedObject.customEventType` with a TikTok optimization_event code your pixel tracks (newer pixels use e.g. SHOPPING for purchase events; legacy pixels use ON_WEB_ORDER, INITIATE_ORDER, ON_WEB_REGISTER or FORM). To inherit pixel and event from an existing ad group, pass `adSetId` instead. **LinkedIn** - `engagement`, `traffic`, `awareness` and `video_views` create standalone Direct Sponsored Content ads. `traffic` requires `linkUrl`; `video_views` requires `video`. - `job_applicants` requires a `platformSpecificData.jobs` creative. - For `lead_generation` or `conversions` on LinkedIn, or to promote an existing post, use POST /v1/ads/boost. **OpenAI Ads** - Only `traffic`, `awareness`, and `conversions` are supported (other goals return 400). Maps to OpenAI's `bidding_type` (clicks, impressions, conversions respectively). `conversions` requires an active conversion event setting on the account; create a tracking tag with `defaultEventType` via the tracking-tags API (`POST /v1/accounts/{accountId}/tracking-tags`), or configure a conversion event in OpenAI Ads Manager, or the request returns 422.
|
|
36
36
|
attr_accessor :goal
|
|
37
37
|
|
|
38
38
|
# Meta only. Explicit ad-set `optimization_goal` (e.g. `LANDING_PAGE_VIEWS`, `LINK_CLICKS`, `REACH`, `IMPRESSIONS`, `OFFSITE_CONVERSIONS`, `THRUPLAY`, `LEAD_GENERATION`). Overrides the default derived from `goal` (e.g. `traffic` defaults to `LINK_CLICKS`). Forwarded verbatim to Meta, which validates compatibility with the campaign objective and rejects incompatible combinations.
|
|
@@ -1011,7 +1011,7 @@ module Zernio
|
|
|
1011
1011
|
return false if !@campaign_name.nil? && @campaign_name.to_s.length > 255
|
|
1012
1012
|
return false if !@ad_set_name.nil? && @ad_set_name.to_s.length > 255
|
|
1013
1013
|
return false if !@ad_name.nil? && @ad_name.to_s.length > 255
|
|
1014
|
-
goal_validator = EnumAttributeValidator.new('String', ["engagement", "traffic", "awareness", "video_views", "lead_generation", "lead_conversion", "conversions", "app_promotion", "catalog_sales", "job_applicants"])
|
|
1014
|
+
goal_validator = EnumAttributeValidator.new('String', ["engagement", "traffic", "awareness", "video_views", "lead_generation", "lead_conversion", "conversions", "app_promotion", "catalog_sales", "page_likes", "job_applicants"])
|
|
1015
1015
|
return false unless goal_validator.valid?(@goal)
|
|
1016
1016
|
buying_type_validator = EnumAttributeValidator.new('String', ["AUCTION", "RESERVED"])
|
|
1017
1017
|
return false unless buying_type_validator.valid?(@buying_type)
|
|
@@ -1138,7 +1138,7 @@ module Zernio
|
|
|
1138
1138
|
# Custom attribute writer method checking allowed values (enum).
|
|
1139
1139
|
# @param [Object] goal Object to be assigned
|
|
1140
1140
|
def goal=(goal)
|
|
1141
|
-
validator = EnumAttributeValidator.new('String', ["engagement", "traffic", "awareness", "video_views", "lead_generation", "lead_conversion", "conversions", "app_promotion", "catalog_sales", "job_applicants"])
|
|
1141
|
+
validator = EnumAttributeValidator.new('String', ["engagement", "traffic", "awareness", "video_views", "lead_generation", "lead_conversion", "conversions", "app_promotion", "catalog_sales", "page_likes", "job_applicants"])
|
|
1142
1142
|
unless validator.valid?(goal)
|
|
1143
1143
|
fail ArgumentError, "invalid value for \"goal\", must be one of #{validator.allowable_values}."
|
|
1144
1144
|
end
|
|
@@ -27,7 +27,7 @@ module Zernio
|
|
|
27
27
|
# Post thumbnail or first media item URL. Platform CDN URLs expire, fetch promptly.
|
|
28
28
|
attr_accessor :image_url
|
|
29
29
|
|
|
30
|
-
# Public URL of the post. Null for
|
|
30
|
+
# Public URL of the post. Null when no URL was ever stored for it, for example a platform draft or a post recovered without one.
|
|
31
31
|
attr_accessor :permalink
|
|
32
32
|
|
|
33
33
|
# Attribute mapping from ruby-style variable name to JSON key.
|
data/lib/zernio-sdk/version.rb
CHANGED
data/openapi.yaml
CHANGED
|
@@ -2932,7 +2932,7 @@ components:
|
|
|
2932
2932
|
description: 'Post thumbnail or first media item URL. Platform CDN URLs expire, fetch promptly.'
|
|
2933
2933
|
permalink:
|
|
2934
2934
|
type: [string, "null"]
|
|
2935
|
-
description: 'Public URL of the post. Null for
|
|
2935
|
+
description: 'Public URL of the post. Null when no URL was ever stored for it, for example a platform draft or a post recovered without one.'
|
|
2936
2936
|
account:
|
|
2937
2937
|
type: object
|
|
2938
2938
|
required: [id, platform, username]
|
|
@@ -8175,7 +8175,7 @@ components:
|
|
|
8175
8175
|
enum: [carousel, video, document, image, null]
|
|
8176
8176
|
description: "Creative format, classified from the media the creative carries. `null` when the creative carries no media to classify — an unsynced creative and a genuine text-only ad are indistinguishable, so neither is guessed at. Returned by `GET /v1/ads`, `GET /v1/ads/{adId}` and the ad nodes of `GET /v1/ads/tree`."
|
|
8177
8177
|
example: video
|
|
8178
|
-
goal: { type: string, enum: [engagement, traffic, awareness, video_views, lead_generation, lead_conversion, conversions, app_promotion, catalog_sales, job_applicants], description: "Available goals vary by platform. Meta (Facebook/Instagram) supports all
|
|
8178
|
+
goal: { type: string, enum: [engagement, traffic, awareness, video_views, lead_generation, lead_conversion, conversions, app_promotion, catalog_sales, page_likes, job_applicants], description: "Available goals vary by platform. Meta (Facebook/Instagram) supports all 10 (incl. `lead_conversion` = website pixel lead optimization, `catalog_sales` = Advantage+ catalog ads and `page_likes` = Page Likes conversion location under Engagement). TikTok supports engagement, traffic, awareness, video_views, lead_generation, conversions, app_promotion. LinkedIn supports all Meta goals except app_promotion / lead_conversion / catalog_sales / page_likes. Twitter/X supports engagement, traffic, awareness, video_views, app_promotion. Pinterest and Google Ads support only engagement, traffic, awareness, video_views." }
|
|
8179
8179
|
isExternal: { type: boolean, description: True for ads synced from platform ad managers }
|
|
8180
8180
|
budget:
|
|
8181
8181
|
type: [object, "null"]
|
|
@@ -39197,7 +39197,7 @@ paths:
|
|
|
39197
39197
|
name: { type: string, maxLength: 255 }
|
|
39198
39198
|
goal:
|
|
39199
39199
|
type: string
|
|
39200
|
-
enum: [engagement, traffic, awareness, video_views, lead_generation, lead_conversion, job_applicants, conversions, app_promotion, catalog_sales]
|
|
39200
|
+
enum: [engagement, traffic, awareness, video_views, lead_generation, lead_conversion, job_applicants, conversions, app_promotion, catalog_sales, page_likes]
|
|
39201
39201
|
description: Mapped to the ODAX objective (same mapping as POST /v1/ads/create).
|
|
39202
39202
|
specialAdCategories:
|
|
39203
39203
|
type: array
|
|
@@ -42514,7 +42514,7 @@ paths:
|
|
|
42514
42514
|
value: { type: string }
|
|
42515
42515
|
goal:
|
|
42516
42516
|
type: string
|
|
42517
|
-
enum: [engagement, traffic, awareness, video_views, lead_generation, lead_conversion, conversions, app_promotion, catalog_sales, job_applicants]
|
|
42517
|
+
enum: [engagement, traffic, awareness, video_views, lead_generation, lead_conversion, conversions, app_promotion, catalog_sales, page_likes, job_applicants]
|
|
42518
42518
|
description: |
|
|
42519
42519
|
Required on legacy and multi-creative shapes; the attach shape inherits it from the ad set. Available goals vary by platform.
|
|
42520
42520
|
|
|
@@ -42524,6 +42524,7 @@ paths:
|
|
|
42524
42524
|
- `lead_generation`: OUTCOME_LEADS with instant forms. Requires `leadGenFormId`. `promotedObject.pageId` is optional and auto-filled from the connected Page.
|
|
42525
42525
|
- `app_promotion`: requires `promotedObject.applicationId` and `promotedObject.objectStoreUrl`.
|
|
42526
42526
|
- `catalog_sales`: Advantage+ catalog ads, for example vehicle inventory. Requires `promotedObject.productSetId`, `promotedObject.pixelId` and `promotedObject.customEventType`. Builds a catalog TEMPLATE creative from the copy fields, which may carry template tags like {{product.name}} or {{vehicle.make}}. No imageUrl or video is sent; Meta renders the visuals per catalog item. Discover catalogs via GET /v1/ads/catalogs and product sets via GET /v1/ads/catalogs/{catalogId}/product-sets. Single shape only, no creatives[], adSetId, dynamicCreative or placementAssets.
|
|
42527
|
+
- `page_likes`: Page Likes conversion location under OUTCOME_ENGAGEMENT (destination_type ON_PAGE, optimization PAGE_LIKES). `promotedObject.pageId` is optional and auto-filled from the connected Page. The creative CTA is fixed to LIKE_PAGE targeting that Page; headline / body / linkUrl / callToAction / imageUrl / video are all optional (Meta derives the link and the Like button from the Page).
|
|
42527
42528
|
|
|
42528
42529
|
**TikTok**
|
|
42529
42530
|
- `conversions`: website-conversion ad group. Requires `promotedObject.pixelId`, your TikTok Pixel ID. Accepts an optional `promotedObject.customEventType` with a TikTok optimization_event code your pixel tracks (newer pixels use e.g. SHOPPING for purchase events; legacy pixels use ON_WEB_ORDER, INITIATE_ORDER, ON_WEB_REGISTER or FORM). To inherit pixel and event from an existing ad group, pass `adSetId` instead.
|
data/spec/models/ad_spec.rb
CHANGED
|
@@ -90,7 +90,7 @@ describe Zernio::Ad do
|
|
|
90
90
|
describe 'test attribute "goal"' do
|
|
91
91
|
it 'should work' do
|
|
92
92
|
# assertion here. ref: https://rspec.info/features/3-12/rspec-expectations/built-in-matchers/
|
|
93
|
-
# validator = Petstore::EnumTest::EnumAttributeValidator.new('String', ["engagement", "traffic", "awareness", "video_views", "lead_generation", "lead_conversion", "conversions", "app_promotion", "catalog_sales", "job_applicants"])
|
|
93
|
+
# validator = Petstore::EnumTest::EnumAttributeValidator.new('String', ["engagement", "traffic", "awareness", "video_views", "lead_generation", "lead_conversion", "conversions", "app_promotion", "catalog_sales", "page_likes", "job_applicants"])
|
|
94
94
|
# validator.allowable_values.each do |value|
|
|
95
95
|
# expect { instance.goal = value }.not_to raise_error
|
|
96
96
|
# end
|
|
@@ -48,7 +48,7 @@ describe Zernio::CreateAdCampaignRequest do
|
|
|
48
48
|
describe 'test attribute "goal"' do
|
|
49
49
|
it 'should work' do
|
|
50
50
|
# assertion here. ref: https://rspec.info/features/3-12/rspec-expectations/built-in-matchers/
|
|
51
|
-
# validator = Petstore::EnumTest::EnumAttributeValidator.new('String', ["engagement", "traffic", "awareness", "video_views", "lead_generation", "lead_conversion", "job_applicants", "conversions", "app_promotion", "catalog_sales"])
|
|
51
|
+
# validator = Petstore::EnumTest::EnumAttributeValidator.new('String', ["engagement", "traffic", "awareness", "video_views", "lead_generation", "lead_conversion", "job_applicants", "conversions", "app_promotion", "catalog_sales", "page_likes"])
|
|
52
52
|
# validator.allowable_values.each do |value|
|
|
53
53
|
# expect { instance.goal = value }.not_to raise_error
|
|
54
54
|
# end
|
|
@@ -72,7 +72,7 @@ describe Zernio::CreateStandaloneAdRequest do
|
|
|
72
72
|
describe 'test attribute "goal"' do
|
|
73
73
|
it 'should work' do
|
|
74
74
|
# assertion here. ref: https://rspec.info/features/3-12/rspec-expectations/built-in-matchers/
|
|
75
|
-
# validator = Petstore::EnumTest::EnumAttributeValidator.new('String', ["engagement", "traffic", "awareness", "video_views", "lead_generation", "lead_conversion", "conversions", "app_promotion", "catalog_sales", "job_applicants"])
|
|
75
|
+
# validator = Petstore::EnumTest::EnumAttributeValidator.new('String', ["engagement", "traffic", "awareness", "video_views", "lead_generation", "lead_conversion", "conversions", "app_promotion", "catalog_sales", "page_likes", "job_applicants"])
|
|
76
76
|
# validator.allowable_values.each do |value|
|
|
77
77
|
# expect { instance.goal = value }.not_to raise_error
|
|
78
78
|
# end
|
|
Binary file
|
metadata
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
|
2
2
|
name: late-sdk
|
|
3
3
|
version: !ruby/object:Gem::Version
|
|
4
|
-
version: 0.0.
|
|
4
|
+
version: 0.0.754
|
|
5
5
|
platform: ruby
|
|
6
6
|
authors:
|
|
7
7
|
- OpenAPI-Generator
|
|
@@ -5422,7 +5422,7 @@ files:
|
|
|
5422
5422
|
- spec/models/you_tube_video_retention_response_retention_curve_inner_spec.rb
|
|
5423
5423
|
- spec/models/you_tube_video_retention_response_spec.rb
|
|
5424
5424
|
- spec/spec_helper.rb
|
|
5425
|
-
- zernio-sdk-0.0.
|
|
5425
|
+
- zernio-sdk-0.0.754.gem
|
|
5426
5426
|
- zernio-sdk.gemspec
|
|
5427
5427
|
homepage: https://openapi-generator.tech
|
|
5428
5428
|
licenses:
|
data/zernio-sdk-0.0.752.gem
DELETED
|
Binary file
|