late-sdk 0.0.909 → 0.0.910

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.
Files changed (56) hide show
  1. checksums.yaml +4 -4
  2. data/README.md +32 -19
  3. data/docs/AdAccountsApi.md +88 -12
  4. data/docs/AdCampaignsApi.md +20 -20
  5. data/docs/AdCreativesApi.md +222 -0
  6. data/docs/AdInsightsApi.md +16 -16
  7. data/docs/AdTargetingApi.md +4 -4
  8. data/docs/ConversionsApi.md +8 -8
  9. data/docs/ListPartnershipAdContent200Response.md +18 -0
  10. data/docs/ListPartnershipAdContent200ResponseMediaInner.md +30 -0
  11. data/docs/ListPartnershipAdPermissions200Response.md +18 -0
  12. data/docs/ListPartnershipAdPermissions200ResponsePermissionsInner.md +22 -0
  13. data/docs/ListTikTokAdPixels200Response.md +20 -0
  14. data/docs/ListTikTokAdPixels200ResponsePixelsInner.md +26 -0
  15. data/docs/ListTikTokAdPixels200ResponsePixelsInnerEventDetailsInner.md +22 -0
  16. data/docs/ReachAndFrequencyApi.md +16 -16
  17. data/docs/SetPartnershipAdPermission200Response.md +18 -0
  18. data/docs/SetPartnershipAdPermissionRequest.md +22 -0
  19. data/lib/zernio-sdk/api/ad_accounts_api.rb +81 -6
  20. data/lib/zernio-sdk/api/ad_campaigns_api.rb +10 -10
  21. data/lib/zernio-sdk/api/ad_creatives_api.rb +218 -0
  22. data/lib/zernio-sdk/api/ad_insights_api.rb +8 -8
  23. data/lib/zernio-sdk/api/ad_targeting_api.rb +2 -2
  24. data/lib/zernio-sdk/api/conversions_api.rb +4 -4
  25. data/lib/zernio-sdk/api/reach_and_frequency_api.rb +8 -8
  26. data/lib/zernio-sdk/models/list_partnership_ad_content200_response.rb +149 -0
  27. data/lib/zernio-sdk/models/list_partnership_ad_content200_response_media_inner.rb +205 -0
  28. data/lib/zernio-sdk/models/list_partnership_ad_permissions200_response.rb +149 -0
  29. data/lib/zernio-sdk/models/list_partnership_ad_permissions200_response_permissions_inner.rb +165 -0
  30. data/lib/zernio-sdk/models/list_tik_tok_ad_pixels200_response.rb +158 -0
  31. data/lib/zernio-sdk/models/list_tik_tok_ad_pixels200_response_pixels_inner.rb +187 -0
  32. data/lib/zernio-sdk/models/list_tik_tok_ad_pixels200_response_pixels_inner_event_details_inner.rb +166 -0
  33. data/lib/zernio-sdk/models/set_partnership_ad_permission200_response.rb +147 -0
  34. data/lib/zernio-sdk/models/set_partnership_ad_permission_request.rb +219 -0
  35. data/lib/zernio-sdk/version.rb +1 -1
  36. data/lib/zernio-sdk.rb +9 -0
  37. data/openapi.yaml +632 -154
  38. data/spec/api/ad_accounts_api_spec.rb +17 -3
  39. data/spec/api/ad_campaigns_api_spec.rb +5 -5
  40. data/spec/api/ad_creatives_api_spec.rb +40 -0
  41. data/spec/api/ad_insights_api_spec.rb +4 -4
  42. data/spec/api/ad_targeting_api_spec.rb +1 -1
  43. data/spec/api/conversions_api_spec.rb +2 -2
  44. data/spec/api/reach_and_frequency_api_spec.rb +4 -4
  45. data/spec/models/list_partnership_ad_content200_response_media_inner_spec.rb +72 -0
  46. data/spec/models/list_partnership_ad_content200_response_spec.rb +36 -0
  47. data/spec/models/list_partnership_ad_permissions200_response_permissions_inner_spec.rb +48 -0
  48. data/spec/models/list_partnership_ad_permissions200_response_spec.rb +36 -0
  49. data/spec/models/list_tik_tok_ad_pixels200_response_pixels_inner_event_details_inner_spec.rb +48 -0
  50. data/spec/models/list_tik_tok_ad_pixels200_response_pixels_inner_spec.rb +60 -0
  51. data/spec/models/list_tik_tok_ad_pixels200_response_spec.rb +42 -0
  52. data/spec/models/set_partnership_ad_permission200_response_spec.rb +36 -0
  53. data/spec/models/set_partnership_ad_permission_request_spec.rb +48 -0
  54. data/zernio-sdk-0.0.910.gem +0 -0
  55. metadata +38 -2
  56. data/zernio-sdk-0.0.909.gem +0 -0
@@ -4,17 +4,17 @@ All URIs are relative to *https://zernio.com/api*
4
4
 
5
5
  | Method | HTTP request | Description |
6
6
  | ------ | ------------ | ----------- |
7
- | [**cancel_rf_reservation**](ReachAndFrequencyApi.md#cancel_rf_reservation) | **DELETE** /v1/ads/rf-predictions/{predictionId} | Cancel a Reach & Frequency reservation |
8
- | [**create_rf_prediction**](ReachAndFrequencyApi.md#create_rf_prediction) | **POST** /v1/ads/rf-predictions | Create a Reach & Frequency prediction |
9
- | [**get_rf_prediction**](ReachAndFrequencyApi.md#get_rf_prediction) | **GET** /v1/ads/rf-predictions/{predictionId} | Read a Reach & Frequency prediction |
10
- | [**reserve_rf_prediction**](ReachAndFrequencyApi.md#reserve_rf_prediction) | **POST** /v1/ads/rf-predictions/{predictionId}/reserve | Reserve a Reach & Frequency prediction |
7
+ | [**cancel_rf_reservation**](ReachAndFrequencyApi.md#cancel_rf_reservation) | **DELETE** /v1/ads/rf-predictions/{predictionId} | Cancel reach-frequency booking |
8
+ | [**create_rf_prediction**](ReachAndFrequencyApi.md#create_rf_prediction) | **POST** /v1/ads/rf-predictions | Create reach-frequency prediction |
9
+ | [**get_rf_prediction**](ReachAndFrequencyApi.md#get_rf_prediction) | **GET** /v1/ads/rf-predictions/{predictionId} | Get reach-frequency prediction |
10
+ | [**reserve_rf_prediction**](ReachAndFrequencyApi.md#reserve_rf_prediction) | **POST** /v1/ads/rf-predictions/{predictionId}/reserve | Reserve reach-frequency inventory |
11
11
 
12
12
 
13
13
  ## cancel_rf_reservation
14
14
 
15
15
  > cancel_rf_reservation(prediction_id, account_id, ad_account_id)
16
16
 
17
- Cancel a Reach & Frequency reservation
17
+ Cancel reach-frequency booking
18
18
 
19
19
  Releases a RESERVATION's locked price and inventory. Unreserved predictions expire on their own.
20
20
 
@@ -35,7 +35,7 @@ account_id = 'account_id_example' # String |
35
35
  ad_account_id = 'ad_account_id_example' # String |
36
36
 
37
37
  begin
38
- # Cancel a Reach & Frequency reservation
38
+ # Cancel reach-frequency booking
39
39
  api_instance.cancel_rf_reservation(prediction_id, account_id, ad_account_id)
40
40
  rescue Zernio::ApiError => e
41
41
  puts "Error when calling ReachAndFrequencyApi->cancel_rf_reservation: #{e}"
@@ -50,7 +50,7 @@ This returns an Array which contains the response data (`nil` in this case), sta
50
50
 
51
51
  ```ruby
52
52
  begin
53
- # Cancel a Reach & Frequency reservation
53
+ # Cancel reach-frequency booking
54
54
  data, status_code, headers = api_instance.cancel_rf_reservation_with_http_info(prediction_id, account_id, ad_account_id)
55
55
  p status_code # => 2xx
56
56
  p headers # => { ... }
@@ -86,7 +86,7 @@ nil (empty response body)
86
86
 
87
87
  > <CreateRfPrediction201Response> create_rf_prediction(create_rf_prediction_request)
88
88
 
89
- Create a Reach & Frequency prediction
89
+ Create reach-frequency prediction
90
90
 
91
91
  Creates an R&F prediction. This is a QUOTE, nothing is bought and no ad entities are created. Provide a date range plus exactly one of `budgetAmount` (Meta predicts reach) or `reach` (Meta predicts the budget). The response carries the estimate and its allowed bounds (min/max budget and reach). Predictions expire on their own; to buy, reserve one via POST /v1/ads/rf-predictions/{predictionId}/reserve and pass the RESERVED id to POST /v1/ads/create with `buyingType: \"RESERVED\"`. Reservation campaigns reject automatic placements. Top-level `placements` wins; when it is omitted, `targeting.placements` is used; when neither is set, placements default to Facebook feed (+ Instagram stream when a linked IG professional account resolves). Instagram placements require that IG account.
92
92
 
@@ -105,7 +105,7 @@ api_instance = Zernio::ReachAndFrequencyApi.new
105
105
  create_rf_prediction_request = Zernio::CreateRfPredictionRequest.new({account_id: 'account_id_example', ad_account_id: 'ad_account_id_example', start_date: Time.now, end_date: Time.now}) # CreateRfPredictionRequest |
106
106
 
107
107
  begin
108
- # Create a Reach & Frequency prediction
108
+ # Create reach-frequency prediction
109
109
  result = api_instance.create_rf_prediction(create_rf_prediction_request)
110
110
  p result
111
111
  rescue Zernio::ApiError => e
@@ -121,7 +121,7 @@ This returns an Array which contains the response data, status code and headers.
121
121
 
122
122
  ```ruby
123
123
  begin
124
- # Create a Reach & Frequency prediction
124
+ # Create reach-frequency prediction
125
125
  data, status_code, headers = api_instance.create_rf_prediction_with_http_info(create_rf_prediction_request)
126
126
  p status_code # => 2xx
127
127
  p headers # => { ... }
@@ -155,7 +155,7 @@ end
155
155
 
156
156
  > <CreateRfPrediction201Response> get_rf_prediction(prediction_id, account_id, ad_account_id)
157
157
 
158
- Read a Reach & Frequency prediction
158
+ Get reach-frequency prediction
159
159
 
160
160
  ### Examples
161
161
 
@@ -174,7 +174,7 @@ account_id = 'account_id_example' # String |
174
174
  ad_account_id = 'ad_account_id_example' # String |
175
175
 
176
176
  begin
177
- # Read a Reach & Frequency prediction
177
+ # Get reach-frequency prediction
178
178
  result = api_instance.get_rf_prediction(prediction_id, account_id, ad_account_id)
179
179
  p result
180
180
  rescue Zernio::ApiError => e
@@ -190,7 +190,7 @@ This returns an Array which contains the response data, status code and headers.
190
190
 
191
191
  ```ruby
192
192
  begin
193
- # Read a Reach & Frequency prediction
193
+ # Get reach-frequency prediction
194
194
  data, status_code, headers = api_instance.get_rf_prediction_with_http_info(prediction_id, account_id, ad_account_id)
195
195
  p status_code # => 2xx
196
196
  p headers # => { ... }
@@ -226,7 +226,7 @@ end
226
226
 
227
227
  > <ReserveRfPrediction201Response> reserve_rf_prediction(prediction_id, reserve_rf_prediction_request)
228
228
 
229
- Reserve a Reach & Frequency prediction
229
+ Reserve reach-frequency inventory
230
230
 
231
231
  Locks the quoted price + inventory until the returned `expiresAt` and mints a NEW prediction id. Pass that RESERVED id (not the original) as `rfPredictionId` on POST /v1/ads/create. Release an unused reservation via DELETE.
232
232
 
@@ -246,7 +246,7 @@ prediction_id = 'prediction_id_example' # String |
246
246
  reserve_rf_prediction_request = Zernio::ReserveRfPredictionRequest.new({account_id: 'account_id_example', ad_account_id: 'ad_account_id_example'}) # ReserveRfPredictionRequest |
247
247
 
248
248
  begin
249
- # Reserve a Reach & Frequency prediction
249
+ # Reserve reach-frequency inventory
250
250
  result = api_instance.reserve_rf_prediction(prediction_id, reserve_rf_prediction_request)
251
251
  p result
252
252
  rescue Zernio::ApiError => e
@@ -262,7 +262,7 @@ This returns an Array which contains the response data, status code and headers.
262
262
 
263
263
  ```ruby
264
264
  begin
265
- # Reserve a Reach & Frequency prediction
265
+ # Reserve reach-frequency inventory
266
266
  data, status_code, headers = api_instance.reserve_rf_prediction_with_http_info(prediction_id, reserve_rf_prediction_request)
267
267
  p status_code # => 2xx
268
268
  p headers # => { ... }
@@ -0,0 +1,18 @@
1
+ # Zernio::SetPartnershipAdPermission200Response
2
+
3
+ ## Properties
4
+
5
+ | Name | Type | Description | Notes |
6
+ | ---- | ---- | ----------- | ----- |
7
+ | **permission** | [**ListPartnershipAdPermissions200ResponsePermissionsInner**](ListPartnershipAdPermissions200ResponsePermissionsInner.md) | | [optional] |
8
+
9
+ ## Example
10
+
11
+ ```ruby
12
+ require 'zernio-sdk'
13
+
14
+ instance = Zernio::SetPartnershipAdPermission200Response.new(
15
+ permission: null
16
+ )
17
+ ```
18
+
@@ -0,0 +1,22 @@
1
+ # Zernio::SetPartnershipAdPermissionRequest
2
+
3
+ ## Properties
4
+
5
+ | Name | Type | Description | Notes |
6
+ | ---- | ---- | ----------- | ----- |
7
+ | **account_id** | **String** | | |
8
+ | **creator_username** | **String** | | |
9
+ | **revoke** | **Boolean** | | [optional] |
10
+
11
+ ## Example
12
+
13
+ ```ruby
14
+ require 'zernio-sdk'
15
+
16
+ instance = Zernio::SetPartnershipAdPermissionRequest.new(
17
+ account_id: null,
18
+ creator_username: null,
19
+ revoke: null
20
+ )
21
+ ```
22
+
@@ -359,7 +359,7 @@ module Zernio
359
359
  return data, status_code, headers
360
360
  end
361
361
 
362
- # Create or reuse a custom conversion
362
+ # Create custom conversion
363
363
  # Provision the Meta custom conversion an ads flow optimises toward, and hand back the `customConversionId` for `promotedObject.customConversionId` on POST /v1/ads/create. Removes the manual \"create it in Ads Manager first\" step. **Reuse is ours, not Meta's.** Meta's create is not idempotent, so a retried request would otherwise mint a duplicate carrying none of the original's optimisation history. A non-archived conversion with the same `name` on the same `pixelId` is returned instead of created, with `reused: true` and a 200 rather than a 201. `rule` is forwarded verbatim in Meta's own grammar (e.g. `{\"url\": {\"i_contains\": \"thank-you\"}}`); Meta validates it and rejects a malformed one with \"A conversion rule is required at creation time\".
364
364
  # @param account_id [String] Meta ads SocialAccount id.
365
365
  # @param create_custom_conversion_request [CreateCustomConversionRequest]
@@ -370,7 +370,7 @@ module Zernio
370
370
  data
371
371
  end
372
372
 
373
- # Create or reuse a custom conversion
373
+ # Create custom conversion
374
374
  # Provision the Meta custom conversion an ads flow optimises toward, and hand back the &#x60;customConversionId&#x60; for &#x60;promotedObject.customConversionId&#x60; on POST /v1/ads/create. Removes the manual \&quot;create it in Ads Manager first\&quot; step. **Reuse is ours, not Meta&#39;s.** Meta&#39;s create is not idempotent, so a retried request would otherwise mint a duplicate carrying none of the original&#39;s optimisation history. A non-archived conversion with the same &#x60;name&#x60; on the same &#x60;pixelId&#x60; is returned instead of created, with &#x60;reused: true&#x60; and a 200 rather than a 201. &#x60;rule&#x60; is forwarded verbatim in Meta&#39;s own grammar (e.g. &#x60;{\&quot;url\&quot;: {\&quot;i_contains\&quot;: \&quot;thank-you\&quot;}}&#x60;); Meta validates it and rejects a malformed one with \&quot;A conversion rule is required at creation time\&quot;.
375
375
  # @param account_id [String] Meta ads SocialAccount id.
376
376
  # @param create_custom_conversion_request [CreateCustomConversionRequest]
@@ -1235,7 +1235,7 @@ module Zernio
1235
1235
  return data, status_code, headers
1236
1236
  end
1237
1237
 
1238
- # List DSA beneficiary/payor suggestions
1238
+ # Get DSA recommendations
1239
1239
  # Returns Meta's suggested beneficiary/payor names for an ad account, derived by Meta from the account's recent activity. Useful for prefilling `dsaBeneficiary`/`dsaPayor` inputs, or the defaults sent to `PATCH /v1/ads/accounts`, in your own UI. Meta returns a single flat list. Entries are not labeled as beneficiary or payor, and since these are legal disclosures Zernio never applies them automatically: let your user pick the right entity. The list may be empty for accounts with little activity. Meta accounts only.
1240
1240
  # @param account_id [String] Account ID (metaads, or a facebook/instagram posting account)
1241
1241
  # @param ad_account_id [String] Meta ad account ID (act_...)
@@ -1246,7 +1246,7 @@ module Zernio
1246
1246
  data
1247
1247
  end
1248
1248
 
1249
- # List DSA beneficiary/payor suggestions
1249
+ # Get DSA recommendations
1250
1250
  # Returns Meta&#39;s suggested beneficiary/payor names for an ad account, derived by Meta from the account&#39;s recent activity. Useful for prefilling &#x60;dsaBeneficiary&#x60;/&#x60;dsaPayor&#x60; inputs, or the defaults sent to &#x60;PATCH /v1/ads/accounts&#x60;, in your own UI. Meta returns a single flat list. Entries are not labeled as beneficiary or payor, and since these are legal disclosures Zernio never applies them automatically: let your user pick the right entity. The list may be empty for accounts with little activity. Meta accounts only.
1251
1251
  # @param account_id [String] Account ID (metaads, or a facebook/instagram posting account)
1252
1252
  # @param ad_account_id [String] Meta ad account ID (act_...)
@@ -2407,7 +2407,7 @@ module Zernio
2407
2407
  return data, status_code, headers
2408
2408
  end
2409
2409
 
2410
- # High demand periods / budget schedules
2410
+ # List high-demand periods
2411
2411
  # Scheduled budget increases (Meta's budget-scheduling API). The Graph edge lives on the campaign and ad-set nodes only, so exactly one of `campaignId` / `adSetId` (platform ids) is required. Rows returned verbatim (budget_value, budget_value_type, time window, recurrence).
2412
2412
  # @param account_id [String] Zernio SocialAccount id (posting or ads variant) used to resolve the Meta token.
2413
2413
  # @param [Hash] opts the optional parameters
@@ -2421,7 +2421,7 @@ module Zernio
2421
2421
  data
2422
2422
  end
2423
2423
 
2424
- # High demand periods / budget schedules
2424
+ # List high-demand periods
2425
2425
  # Scheduled budget increases (Meta&#39;s budget-scheduling API). The Graph edge lives on the campaign and ad-set nodes only, so exactly one of &#x60;campaignId&#x60; / &#x60;adSetId&#x60; (platform ids) is required. Rows returned verbatim (budget_value, budget_value_type, time window, recurrence).
2426
2426
  # @param account_id [String] Zernio SocialAccount id (posting or ads variant) used to resolve the Meta token.
2427
2427
  # @param [Hash] opts the optional parameters
@@ -2569,6 +2569,81 @@ module Zernio
2569
2569
  return data, status_code, headers
2570
2570
  end
2571
2571
 
2572
+ # List TikTok ad pixels
2573
+ # Lists pixels and their supported optimization events for a connected TikTok Ads account. The advertiser defaults to the first advertiser on the connection. Reconnect if Pixel Management permission has not been granted.
2574
+ # @param account_id [String] Zernio SocialAccount ID.
2575
+ # @param [Hash] opts the optional parameters
2576
+ # @option opts [String] :advertiser_id Advertiser belonging to this connection.
2577
+ # @option opts [String] :code Filter by a Pixel Code.
2578
+ # @return [ListTikTokAdPixels200Response]
2579
+ def list_tik_tok_ad_pixels(account_id, opts = {})
2580
+ data, _status_code, _headers = list_tik_tok_ad_pixels_with_http_info(account_id, opts)
2581
+ data
2582
+ end
2583
+
2584
+ # List TikTok ad pixels
2585
+ # Lists pixels and their supported optimization events for a connected TikTok Ads account. The advertiser defaults to the first advertiser on the connection. Reconnect if Pixel Management permission has not been granted.
2586
+ # @param account_id [String] Zernio SocialAccount ID.
2587
+ # @param [Hash] opts the optional parameters
2588
+ # @option opts [String] :advertiser_id Advertiser belonging to this connection.
2589
+ # @option opts [String] :code Filter by a Pixel Code.
2590
+ # @return [Array<(ListTikTokAdPixels200Response, Integer, Hash)>] ListTikTokAdPixels200Response data, response status code and response headers
2591
+ def list_tik_tok_ad_pixels_with_http_info(account_id, opts = {})
2592
+ if @api_client.config.debugging
2593
+ @api_client.config.logger.debug 'Calling API: AdAccountsApi.list_tik_tok_ad_pixels ...'
2594
+ end
2595
+ # verify the required parameter 'account_id' is set
2596
+ if @api_client.config.client_side_validation && account_id.nil?
2597
+ fail ArgumentError, "Missing the required parameter 'account_id' when calling AdAccountsApi.list_tik_tok_ad_pixels"
2598
+ end
2599
+ pattern = Regexp.new(/^[a-fA-F0-9]{24}$/)
2600
+ if @api_client.config.client_side_validation && account_id !~ pattern
2601
+ fail ArgumentError, "invalid value for 'account_id' when calling AdAccountsApi.list_tik_tok_ad_pixels, must conform to the pattern #{pattern}."
2602
+ end
2603
+
2604
+ # resource path
2605
+ local_var_path = '/v1/ads/pixels'
2606
+
2607
+ # query parameters
2608
+ query_params = opts[:query_params] || {}
2609
+ query_params[:'accountId'] = account_id
2610
+ query_params[:'advertiserId'] = opts[:'advertiser_id'] if !opts[:'advertiser_id'].nil?
2611
+ query_params[:'code'] = opts[:'code'] if !opts[:'code'].nil?
2612
+
2613
+ # header parameters
2614
+ header_params = opts[:header_params] || {}
2615
+ # HTTP header 'Accept' (if needed)
2616
+ header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']
2617
+
2618
+ # form parameters
2619
+ form_params = opts[:form_params] || {}
2620
+
2621
+ # http body (model)
2622
+ post_body = opts[:debug_body]
2623
+
2624
+ # return_type
2625
+ return_type = opts[:debug_return_type] || 'ListTikTokAdPixels200Response'
2626
+
2627
+ # auth_names
2628
+ auth_names = opts[:debug_auth_names] || ['bearerAuth']
2629
+
2630
+ new_options = opts.merge(
2631
+ :operation => :"AdAccountsApi.list_tik_tok_ad_pixels",
2632
+ :header_params => header_params,
2633
+ :query_params => query_params,
2634
+ :form_params => form_params,
2635
+ :body => post_body,
2636
+ :auth_names => auth_names,
2637
+ :return_type => return_type
2638
+ )
2639
+
2640
+ data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
2641
+ if @api_client.config.debugging
2642
+ @api_client.config.logger.debug "API called: AdAccountsApi#list_tik_tok_ad_pixels\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
2643
+ end
2644
+ return data, status_code, headers
2645
+ end
2646
+
2572
2647
  # List value rule sets
2573
2648
  # Lists the ad account's value rule sets (Meta's `/act_X/value_rule_set`). A value rule set adjusts the auction bid up or down for audience segments you value differently; attach one to an ad set with `valueRuleSetId` on `POST /v1/ads/create` or `PUT /v1/ads/ad-sets/{adSetId}`. Rows are returned in the same camelCase shape the `PUT` body takes, ids included, so a set round-trips 1:1: **the update is a full replace, not a patch**, so you GET, mutate and send the whole thing back. Limits: 6 rule sets per ad account, 10 rules per set, 4 criteria per rule. **Rule order is semantic.** Rules are evaluated in array order and only the FIRST matching rule adjusts the bid for an overlapping audience. The order you send is the order that is stored and returned. Eligibility: value rule sets apply only to ad sets on the `LOWEST_COST_WITHOUT_CAP` (auto-bid) or `COST_CAP` bid strategies. Meta rejects the rest server-side.
2574
2649
  # @param account_id [String] Zernio SocialAccount id (posting or ads variant) used to resolve the Meta token.
@@ -19,7 +19,7 @@ module Zernio
19
19
  def initialize(api_client = ApiClient.default)
20
20
  @api_client = api_client
21
21
  end
22
- # Add Search keywords to an ad group
22
+ # Add Search ad-group keywords
23
23
  # Adds one or more keyword criteria to an existing Google Search ad group, without touching the keywords already there (unlike the whole-set diff on `PUT /v1/ads/{adId}`, `keywords`/`negativeKeywords` in `platformSpecificData`, which replaces the set). Set `negative: true` to add ad-group-level negatives instead of positive keywords.
24
24
  # @param add_ad_keywords_request [AddAdKeywordsRequest]
25
25
  # @param [Hash] opts the optional parameters
@@ -29,7 +29,7 @@ module Zernio
29
29
  data
30
30
  end
31
31
 
32
- # Add Search keywords to an ad group
32
+ # Add Search ad-group keywords
33
33
  # Adds one or more keyword criteria to an existing Google Search ad group, without touching the keywords already there (unlike the whole-set diff on &#x60;PUT /v1/ads/{adId}&#x60;, &#x60;keywords&#x60;/&#x60;negativeKeywords&#x60; in &#x60;platformSpecificData&#x60;, which replaces the set). Set &#x60;negative: true&#x60; to add ad-group-level negatives instead of positive keywords.
34
34
  # @param add_ad_keywords_request [AddAdKeywordsRequest]
35
35
  # @param [Hash] opts the optional parameters
@@ -538,7 +538,7 @@ module Zernio
538
538
  return data, status_code, headers
539
539
  end
540
540
 
541
- # Create a Google Ads portfolio bid strategy
541
+ # Create portfolio bid strategy
542
542
  # Creates a standalone bid strategy shared across campaigns. Attach it to a campaign with `portfolioBidStrategyId` on POST /v1/ads/create, PUT /v1/ads/campaigns/{campaignId}, or PUT /v1/ads/ad-sets/{adSetId}. Attaching a strategy aligned to a shared budget fails there with a 400 (Google's `BIDDING_STRATEGY_AND_BUDGET_MUST_BE_ALIGNED`); this is not retryable.
543
543
  # @param create_bid_strategy_request [CreateBidStrategyRequest]
544
544
  # @param [Hash] opts the optional parameters
@@ -548,7 +548,7 @@ module Zernio
548
548
  data
549
549
  end
550
550
 
551
- # Create a Google Ads portfolio bid strategy
551
+ # Create portfolio bid strategy
552
552
  # Creates a standalone bid strategy shared across campaigns. Attach it to a campaign with &#x60;portfolioBidStrategyId&#x60; on POST /v1/ads/create, PUT /v1/ads/campaigns/{campaignId}, or PUT /v1/ads/ad-sets/{adSetId}. Attaching a strategy aligned to a shared budget fails there with a 400 (Google&#39;s &#x60;BIDDING_STRATEGY_AND_BUDGET_MUST_BE_ALIGNED&#x60;); this is not retryable.
553
553
  # @param create_bid_strategy_request [CreateBidStrategyRequest]
554
554
  # @param [Hash] opts the optional parameters
@@ -1186,7 +1186,7 @@ module Zernio
1186
1186
  return data, status_code, headers
1187
1187
  end
1188
1188
 
1189
- # Live ad-set details incl. learning phase
1189
+ # Get live ad-set details
1190
1190
  # Reads the ad set live from Meta, returned verbatim. The default projection includes `learning_stage_info` (learning-phase status: LEARNING / SUCCESS / FAIL / WAIVING; Meta omits its `status` key on paused ad sets), delivery settings, budgets, schedule and targeting. `fields` is a raw-passthrough override; unknown fields return Meta's 400 verbatim.
1191
1191
  # @param ad_set_id [String] Meta ad set id (platformAdSetId).
1192
1192
  # @param account_id [String] Zernio SocialAccount id (posting or ads variant) used to resolve the Meta token.
@@ -1198,7 +1198,7 @@ module Zernio
1198
1198
  data
1199
1199
  end
1200
1200
 
1201
- # Live ad-set details incl. learning phase
1201
+ # Get live ad-set details
1202
1202
  # Reads the ad set live from Meta, returned verbatim. The default projection includes &#x60;learning_stage_info&#x60; (learning-phase status: LEARNING / SUCCESS / FAIL / WAIVING; Meta omits its &#x60;status&#x60; key on paused ad sets), delivery settings, budgets, schedule and targeting. &#x60;fields&#x60; is a raw-passthrough override; unknown fields return Meta&#39;s 400 verbatim.
1203
1203
  # @param ad_set_id [String] Meta ad set id (platformAdSetId).
1204
1204
  # @param account_id [String] Zernio SocialAccount id (posting or ads variant) used to resolve the Meta token.
@@ -2158,7 +2158,7 @@ module Zernio
2158
2158
  return data, status_code, headers
2159
2159
  end
2160
2160
 
2161
- # List Google Ads portfolio bid strategies
2161
+ # List portfolio bid strategies
2162
2162
  # Bidding strategy report: type, status, campaign count, clicks, cost, cost per conversion, impressions, average CPC and conversions over the date range (default last 30 days). Reads Google's `bidding_strategy` resource, cached for the quota window. Draws on the shared Google Ads operations budget. The response carries `cachedAt` and `stale`, set when a quota-exhausted call falls back to the last-good copy instead of a live read.
2163
2163
  # @param account_id [String] Google ads SocialAccount id.
2164
2164
  # @param [Hash] opts the optional parameters
@@ -2171,7 +2171,7 @@ module Zernio
2171
2171
  data
2172
2172
  end
2173
2173
 
2174
- # List Google Ads portfolio bid strategies
2174
+ # List portfolio bid strategies
2175
2175
  # Bidding strategy report: type, status, campaign count, clicks, cost, cost per conversion, impressions, average CPC and conversions over the date range (default last 30 days). Reads Google&#39;s &#x60;bidding_strategy&#x60; resource, cached for the quota window. Draws on the shared Google Ads operations budget. The response carries &#x60;cachedAt&#x60; and &#x60;stale&#x60;, set when a quota-exhausted call falls back to the last-good copy instead of a live read.
2176
2176
  # @param account_id [String] Google ads SocialAccount id.
2177
2177
  # @param [Hash] opts the optional parameters
@@ -3503,7 +3503,7 @@ module Zernio
3503
3503
  return data, status_code, headers
3504
3504
  end
3505
3505
 
3506
- # Update a Google Ads portfolio bid strategy
3506
+ # Update portfolio bid strategy
3507
3507
  # Renames or retargets a portfolio bid strategy. The strategy's status is output only on Google's side, so it cannot be changed here; remove a strategy in Google Ads. `type` is only needed alongside `targetCpa`/`targetRoas` to disambiguate the field Google writes to (TARGET_CPA and MAXIMIZE_CONVERSIONS both take a target CPA; TARGET_ROAS and MAXIMIZE_CONVERSION_VALUE both take a target ROAS); the strategy's family is otherwise immutable once created.
3508
3508
  # @param strategy_id [String] Numeric Google Ads bid strategy id.
3509
3509
  # @param update_bid_strategy_request [UpdateBidStrategyRequest]
@@ -3514,7 +3514,7 @@ module Zernio
3514
3514
  data
3515
3515
  end
3516
3516
 
3517
- # Update a Google Ads portfolio bid strategy
3517
+ # Update portfolio bid strategy
3518
3518
  # Renames or retargets a portfolio bid strategy. The strategy&#39;s status is output only on Google&#39;s side, so it cannot be changed here; remove a strategy in Google Ads. &#x60;type&#x60; is only needed alongside &#x60;targetCpa&#x60;/&#x60;targetRoas&#x60; to disambiguate the field Google writes to (TARGET_CPA and MAXIMIZE_CONVERSIONS both take a target CPA; TARGET_ROAS and MAXIMIZE_CONVERSION_VALUE both take a target ROAS); the strategy&#39;s family is otherwise immutable once created.
3519
3519
  # @param strategy_id [String] Numeric Google Ads bid strategy id.
3520
3520
  # @param update_bid_strategy_request [UpdateBidStrategyRequest]
@@ -909,6 +909,224 @@ module Zernio
909
909
  return data, status_code, headers
910
910
  end
911
911
 
912
+ # List partnership ad content
913
+ # Private beta. Lists creator Instagram posts available to the advertiser for Partnership Ads. Supply creatorUsername or postUrl. Requires instagram_branded_content_ads_brand permission and an advertiser Instagram Business Account.
914
+ # @param account_id [String] Zernio SocialAccount ID.
915
+ # @param [Hash] opts the optional parameters
916
+ # @option opts [String] :creator_username Creator username. Required unless postUrl is supplied.
917
+ # @option opts [String] :post_url Instagram post permalink. Required unless creatorUsername is supplied.
918
+ # @option opts [Boolean] :only_allowlisted Return only creators with account-level permission.
919
+ # @return [ListPartnershipAdContent200Response]
920
+ def list_partnership_ad_content(account_id, opts = {})
921
+ data, _status_code, _headers = list_partnership_ad_content_with_http_info(account_id, opts)
922
+ data
923
+ end
924
+
925
+ # List partnership ad content
926
+ # Private beta. Lists creator Instagram posts available to the advertiser for Partnership Ads. Supply creatorUsername or postUrl. Requires instagram_branded_content_ads_brand permission and an advertiser Instagram Business Account.
927
+ # @param account_id [String] Zernio SocialAccount ID.
928
+ # @param [Hash] opts the optional parameters
929
+ # @option opts [String] :creator_username Creator username. Required unless postUrl is supplied.
930
+ # @option opts [String] :post_url Instagram post permalink. Required unless creatorUsername is supplied.
931
+ # @option opts [Boolean] :only_allowlisted Return only creators with account-level permission.
932
+ # @return [Array<(ListPartnershipAdContent200Response, Integer, Hash)>] ListPartnershipAdContent200Response data, response status code and response headers
933
+ def list_partnership_ad_content_with_http_info(account_id, opts = {})
934
+ if @api_client.config.debugging
935
+ @api_client.config.logger.debug 'Calling API: AdCreativesApi.list_partnership_ad_content ...'
936
+ end
937
+ # verify the required parameter 'account_id' is set
938
+ if @api_client.config.client_side_validation && account_id.nil?
939
+ fail ArgumentError, "Missing the required parameter 'account_id' when calling AdCreativesApi.list_partnership_ad_content"
940
+ end
941
+ pattern = Regexp.new(/^[a-fA-F0-9]{24}$/)
942
+ if @api_client.config.client_side_validation && account_id !~ pattern
943
+ fail ArgumentError, "invalid value for 'account_id' when calling AdCreativesApi.list_partnership_ad_content, must conform to the pattern #{pattern}."
944
+ end
945
+
946
+ # resource path
947
+ local_var_path = '/v1/ads/partnership-content'
948
+
949
+ # query parameters
950
+ query_params = opts[:query_params] || {}
951
+ query_params[:'accountId'] = account_id
952
+ query_params[:'creatorUsername'] = opts[:'creator_username'] if !opts[:'creator_username'].nil?
953
+ query_params[:'postUrl'] = opts[:'post_url'] if !opts[:'post_url'].nil?
954
+ query_params[:'onlyAllowlisted'] = opts[:'only_allowlisted'] if !opts[:'only_allowlisted'].nil?
955
+
956
+ # header parameters
957
+ header_params = opts[:header_params] || {}
958
+ # HTTP header 'Accept' (if needed)
959
+ header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']
960
+
961
+ # form parameters
962
+ form_params = opts[:form_params] || {}
963
+
964
+ # http body (model)
965
+ post_body = opts[:debug_body]
966
+
967
+ # return_type
968
+ return_type = opts[:debug_return_type] || 'ListPartnershipAdContent200Response'
969
+
970
+ # auth_names
971
+ auth_names = opts[:debug_auth_names] || ['bearerAuth']
972
+
973
+ new_options = opts.merge(
974
+ :operation => :"AdCreativesApi.list_partnership_ad_content",
975
+ :header_params => header_params,
976
+ :query_params => query_params,
977
+ :form_params => form_params,
978
+ :body => post_body,
979
+ :auth_names => auth_names,
980
+ :return_type => return_type
981
+ )
982
+
983
+ data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
984
+ if @api_client.config.debugging
985
+ @api_client.config.logger.debug "API called: AdCreativesApi#list_partnership_ad_content\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
986
+ end
987
+ return data, status_code, headers
988
+ end
989
+
990
+ # List partnership permissions
991
+ # Private beta. Lists granted or pending creator permissions for the advertiser Instagram Business Account. Requires instagram_branded_content_ads_brand permission.
992
+ # @param account_id [String] Zernio SocialAccount ID.
993
+ # @param [Hash] opts the optional parameters
994
+ # @option opts [String] :creator_username Filter by creator username.
995
+ # @return [ListPartnershipAdPermissions200Response]
996
+ def list_partnership_ad_permissions(account_id, opts = {})
997
+ data, _status_code, _headers = list_partnership_ad_permissions_with_http_info(account_id, opts)
998
+ data
999
+ end
1000
+
1001
+ # List partnership permissions
1002
+ # Private beta. Lists granted or pending creator permissions for the advertiser Instagram Business Account. Requires instagram_branded_content_ads_brand permission.
1003
+ # @param account_id [String] Zernio SocialAccount ID.
1004
+ # @param [Hash] opts the optional parameters
1005
+ # @option opts [String] :creator_username Filter by creator username.
1006
+ # @return [Array<(ListPartnershipAdPermissions200Response, Integer, Hash)>] ListPartnershipAdPermissions200Response data, response status code and response headers
1007
+ def list_partnership_ad_permissions_with_http_info(account_id, opts = {})
1008
+ if @api_client.config.debugging
1009
+ @api_client.config.logger.debug 'Calling API: AdCreativesApi.list_partnership_ad_permissions ...'
1010
+ end
1011
+ # verify the required parameter 'account_id' is set
1012
+ if @api_client.config.client_side_validation && account_id.nil?
1013
+ fail ArgumentError, "Missing the required parameter 'account_id' when calling AdCreativesApi.list_partnership_ad_permissions"
1014
+ end
1015
+ pattern = Regexp.new(/^[a-fA-F0-9]{24}$/)
1016
+ if @api_client.config.client_side_validation && account_id !~ pattern
1017
+ fail ArgumentError, "invalid value for 'account_id' when calling AdCreativesApi.list_partnership_ad_permissions, must conform to the pattern #{pattern}."
1018
+ end
1019
+
1020
+ # resource path
1021
+ local_var_path = '/v1/ads/partnership-permissions'
1022
+
1023
+ # query parameters
1024
+ query_params = opts[:query_params] || {}
1025
+ query_params[:'accountId'] = account_id
1026
+ query_params[:'creatorUsername'] = opts[:'creator_username'] if !opts[:'creator_username'].nil?
1027
+
1028
+ # header parameters
1029
+ header_params = opts[:header_params] || {}
1030
+ # HTTP header 'Accept' (if needed)
1031
+ header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']
1032
+
1033
+ # form parameters
1034
+ form_params = opts[:form_params] || {}
1035
+
1036
+ # http body (model)
1037
+ post_body = opts[:debug_body]
1038
+
1039
+ # return_type
1040
+ return_type = opts[:debug_return_type] || 'ListPartnershipAdPermissions200Response'
1041
+
1042
+ # auth_names
1043
+ auth_names = opts[:debug_auth_names] || ['bearerAuth']
1044
+
1045
+ new_options = opts.merge(
1046
+ :operation => :"AdCreativesApi.list_partnership_ad_permissions",
1047
+ :header_params => header_params,
1048
+ :query_params => query_params,
1049
+ :form_params => form_params,
1050
+ :body => post_body,
1051
+ :auth_names => auth_names,
1052
+ :return_type => return_type
1053
+ )
1054
+
1055
+ data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
1056
+ if @api_client.config.debugging
1057
+ @api_client.config.logger.debug "API called: AdCreativesApi#list_partnership_ad_permissions\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
1058
+ end
1059
+ return data, status_code, headers
1060
+ end
1061
+
1062
+ # Set partnership permission
1063
+ # Private beta. Requests permission from a creator or revokes it when revoke is true. Requests require the creator to approve in Instagram. Requires instagram_branded_content_ads_brand permission.
1064
+ # @param set_partnership_ad_permission_request [SetPartnershipAdPermissionRequest]
1065
+ # @param [Hash] opts the optional parameters
1066
+ # @return [SetPartnershipAdPermission200Response]
1067
+ def set_partnership_ad_permission(set_partnership_ad_permission_request, opts = {})
1068
+ data, _status_code, _headers = set_partnership_ad_permission_with_http_info(set_partnership_ad_permission_request, opts)
1069
+ data
1070
+ end
1071
+
1072
+ # Set partnership permission
1073
+ # Private beta. Requests permission from a creator or revokes it when revoke is true. Requests require the creator to approve in Instagram. Requires instagram_branded_content_ads_brand permission.
1074
+ # @param set_partnership_ad_permission_request [SetPartnershipAdPermissionRequest]
1075
+ # @param [Hash] opts the optional parameters
1076
+ # @return [Array<(SetPartnershipAdPermission200Response, Integer, Hash)>] SetPartnershipAdPermission200Response data, response status code and response headers
1077
+ def set_partnership_ad_permission_with_http_info(set_partnership_ad_permission_request, opts = {})
1078
+ if @api_client.config.debugging
1079
+ @api_client.config.logger.debug 'Calling API: AdCreativesApi.set_partnership_ad_permission ...'
1080
+ end
1081
+ # verify the required parameter 'set_partnership_ad_permission_request' is set
1082
+ if @api_client.config.client_side_validation && set_partnership_ad_permission_request.nil?
1083
+ fail ArgumentError, "Missing the required parameter 'set_partnership_ad_permission_request' when calling AdCreativesApi.set_partnership_ad_permission"
1084
+ end
1085
+ # resource path
1086
+ local_var_path = '/v1/ads/partnership-permissions'
1087
+
1088
+ # query parameters
1089
+ query_params = opts[:query_params] || {}
1090
+
1091
+ # header parameters
1092
+ header_params = opts[:header_params] || {}
1093
+ # HTTP header 'Accept' (if needed)
1094
+ header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']
1095
+ # HTTP header 'Content-Type'
1096
+ content_type = @api_client.select_header_content_type(['application/json'])
1097
+ if !content_type.nil?
1098
+ header_params['Content-Type'] = content_type
1099
+ end
1100
+
1101
+ # form parameters
1102
+ form_params = opts[:form_params] || {}
1103
+
1104
+ # http body (model)
1105
+ post_body = opts[:debug_body] || @api_client.object_to_http_body(set_partnership_ad_permission_request)
1106
+
1107
+ # return_type
1108
+ return_type = opts[:debug_return_type] || 'SetPartnershipAdPermission200Response'
1109
+
1110
+ # auth_names
1111
+ auth_names = opts[:debug_auth_names] || ['bearerAuth']
1112
+
1113
+ new_options = opts.merge(
1114
+ :operation => :"AdCreativesApi.set_partnership_ad_permission",
1115
+ :header_params => header_params,
1116
+ :query_params => query_params,
1117
+ :form_params => form_params,
1118
+ :body => post_body,
1119
+ :auth_names => auth_names,
1120
+ :return_type => return_type
1121
+ )
1122
+
1123
+ data, status_code, headers = @api_client.call_api(:POST, local_var_path, new_options)
1124
+ if @api_client.config.debugging
1125
+ @api_client.config.logger.debug "API called: AdCreativesApi#set_partnership_ad_permission\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
1126
+ end
1127
+ return data, status_code, headers
1128
+ end
1129
+
912
1130
  # Rename a creative
913
1131
  # Renames a creative. Creatives are immutable on Meta beyond `name`. For content changes create a new creative (POST /v1/ads/creatives) and swap it onto the ad (PUT /v1/ads/{adId} with `creative`).
914
1132
  # @param creative_id [String] Platform creative id