zernio-sdk 0.0.834 → 0.0.836

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 CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: c3fd16dc3f325aa78d8c8a4fb1226dc581e6d2e5b9f9af9c790f2fce3a696506
4
- data.tar.gz: 1d384392bf19efeac53f317f52b5fc9d461a71f5ada0bb93baeb5760a9e210a4
3
+ metadata.gz: 6cedce61d089cf837c627842e980692ddc32a52e028fbd65ff4dcd10a4f2acbe
4
+ data.tar.gz: 17b2a371f6e12d775445bd230f9cd40a4cf65f9e602eccbe90e1746b7c5181c0
5
5
  SHA512:
6
- metadata.gz: 51c90d614a019e7cb2a1275c5626531e262d96f3f9ee35b9f44370532c5f5ee4344f7112c4fd7318f85173bd97e6cc5ab0535f666dd521d1405f4e98d8d55a84
7
- data.tar.gz: 28bcc6ab0a817b8c63bdc5b8f0a4223e76b33c4ab759461dcb7e2097bae348487e5d595899aa02841cc892ddc361d9c656da690cbf4776dead9cfc6da20840c2
6
+ metadata.gz: a4dc60bc144675b909e72471890cf87316abeadd5005e6df4756dfe690654a91fd039265cf2a99b15b750327f259680ebd1852414ff4a78e8ec0e41eb90767ea
7
+ data.tar.gz: 2d0284dd2a3ef9ca3f5f10f66c34a81c3108e67b26db8ab81fb3f51837697353e38ca289c8a4124d562284157efbf64694dbbb3c3e20ef7f07be3190e166446c
@@ -7,6 +7,8 @@
7
7
  | **bid_strategy** | [**BidStrategy**](BidStrategy.md) | | [optional] |
8
8
  | **bid_amount** | **Float** | Whole currency units (USD: 5 = $5.00). Required when bidStrategy is LOWEST_COST_WITH_BID_CAP or COST_CAP. May also be sent alone, WITHOUT bidStrategy, to set the cap on an ad set joining a COST_CAP / LOWEST_COST_WITH_BID_CAP campaign (the strategy is inherited from the campaign). On POST /v1/ads/create that shape requires existingCampaignId and is a 400 otherwise; on POST /v1/ads/boost it is promoted to LOWEST_COST_WITH_BID_CAP. | [optional] |
9
9
  | **roas_average_floor** | **Float** | Decimal ROAS multiplier (2.0 = 2.0x). Required when bidStrategy is LOWEST_COST_WITH_MIN_ROAS; sending it without bidStrategy is a 400. | [optional] |
10
+ | **daily_min_spend_target** | **Float** | Meta daily_min_spend_target on the ad set being created: the least it should spend per day, in whole currency units. It reserves a share of a CAMPAIGN budget, so it requires budgetLevel campaign or an existingCampaignId whose campaign has the budget (Advantage campaign budget / CBO); with an ad-set budget it is a 400, because Meta rejects a spend limit on an ad set that owns its budget. A target, not a guarantee. Mutually exclusive with lifetimeMinSpendTarget: the flavour must match the campaign budget type. Rejected with 400 on POST /v1/ads/boost and in adSetId attach mode: use PUT /v1/ads/ad-sets/{adSetId} for an ad set that already exists. | [optional] |
11
+ | **lifetime_min_spend_target** | **Float** | Meta lifetime_min_spend_target: the lifetime-budget flavour of dailyMinSpendTarget, in whole currency units. Same rules and same rejections. | [optional] |
10
12
 
11
13
  ## Example
12
14
 
@@ -16,7 +18,9 @@ require 'zernio-sdk'
16
18
  instance = Zernio::MetaAdsPlatformData.new(
17
19
  bid_strategy: null,
18
20
  bid_amount: null,
19
- roas_average_floor: null
21
+ roas_average_floor: null,
22
+ daily_min_spend_target: null,
23
+ lifetime_min_spend_target: null
20
24
  )
21
25
  ```
22
26
 
@@ -8,6 +8,8 @@
8
8
  | **billing_event** | **String** | Meta ad-set billing_event (e.g. IMPRESSIONS, LINK_CLICKS, THRUPLAY). | [optional] |
9
9
  | **start_date** | **String** | Ad set start_time (ISO 8601). | [optional] |
10
10
  | **end_date** | **String** | Ad set end_time (ISO 8601). | [optional] |
11
+ | **daily_min_spend_target** | **Float** | Meta `daily_min_spend_target`: the least this ad set should spend per day, in whole currency units of the ad account. It reserves a share of a CAMPAIGN budget for one ad set, so it requires a campaign using Advantage campaign budget (CBO). On an ad set that owns its budget (ABO) this returns 409 — move the budget to the campaign with `PUT /v1/ads/campaigns/{campaignId}` first. Meta treats it as a target, not a guarantee, and rejects the combined minimum of a campaign's ad sets going over the campaign budget. Mutually exclusive with `lifetimeMinSpendTarget` (400): the flavour must match the campaign budget type, a daily budget takes a daily target. Read it back with `GET /v1/ads/ad-sets/{adSetId}?fields=daily_min_spend_target`. | [optional] |
12
+ | **lifetime_min_spend_target** | **Float** | Meta `lifetime_min_spend_target`: the lifetime-budget flavour of `dailyMinSpendTarget`, in whole currency units. Send this one when the campaign budget is a lifetime budget. Same rules and same rejections. | [optional] |
11
13
  | **promoted_object** | [**UpdateAdSetRequestPlatformSpecificDataPromotedObject**](UpdateAdSetRequestPlatformSpecificDataPromotedObject.md) | | [optional] |
12
14
 
13
15
  ## Example
@@ -20,6 +22,8 @@ instance = Zernio::UpdateAdSetRequestPlatformSpecificData.new(
20
22
  billing_event: null,
21
23
  start_date: null,
22
24
  end_date: null,
25
+ daily_min_spend_target: null,
26
+ lifetime_min_spend_target: null,
23
27
  promoted_object: null
24
28
  )
25
29
  ```
@@ -14,7 +14,7 @@ require 'date'
14
14
  require 'time'
15
15
 
16
16
  module Zernio
17
- # Platform-specific options. The platform is derived from `accountId`; sending options for a different platform returns a 400. LinkedIn (campaign bidding and delivery controls) and Meta (the bid trio) have options today. **Meta**: `bidStrategy`, `bidAmount` and `roasAverageFloor` may be sent here instead of at the root — the preferred home going forward. Sending the bid fields in BOTH places returns a 400 (`mutually_exclusive_fields`), and sending any of them in `adSetId` attach mode is a 400 too (the ad set already has its bid).
17
+ # Platform-specific options. The platform is derived from `accountId`; sending options for a different platform returns a 400. LinkedIn (campaign bidding and delivery controls) and Meta (the bid trio) have options today. **Meta**: `bidStrategy`, `bidAmount` and `roasAverageFloor` may be sent here instead of at the root — the preferred home going forward. Sending the bid fields in BOTH places returns a 400 (`mutually_exclusive_fields`), and sending any of them in `adSetId` attach mode is a 400 too (the ad set already has its bid). `dailyMinSpendTarget` / `lifetimeMinSpendTarget` set the new ad set's minimum spend and live here only; they are rejected in `adSetId` attach mode as well.
18
18
  module CreateStandaloneAdRequestPlatformSpecificData
19
19
  class << self
20
20
  # List of class defined in oneOf (OpenAPI v3)
@@ -24,6 +24,12 @@ module Zernio
24
24
  # Decimal ROAS multiplier (2.0 = 2.0x). Required when bidStrategy is LOWEST_COST_WITH_MIN_ROAS; sending it without bidStrategy is a 400.
25
25
  attr_accessor :roas_average_floor
26
26
 
27
+ # Meta daily_min_spend_target on the ad set being created: the least it should spend per day, in whole currency units. It reserves a share of a CAMPAIGN budget, so it requires budgetLevel campaign or an existingCampaignId whose campaign has the budget (Advantage campaign budget / CBO); with an ad-set budget it is a 400, because Meta rejects a spend limit on an ad set that owns its budget. A target, not a guarantee. Mutually exclusive with lifetimeMinSpendTarget: the flavour must match the campaign budget type. Rejected with 400 on POST /v1/ads/boost and in adSetId attach mode: use PUT /v1/ads/ad-sets/{adSetId} for an ad set that already exists.
28
+ attr_accessor :daily_min_spend_target
29
+
30
+ # Meta lifetime_min_spend_target: the lifetime-budget flavour of dailyMinSpendTarget, in whole currency units. Same rules and same rejections.
31
+ attr_accessor :lifetime_min_spend_target
32
+
27
33
  class EnumAttributeValidator
28
34
  attr_reader :datatype
29
35
  attr_reader :allowable_values
@@ -51,7 +57,9 @@ module Zernio
51
57
  {
52
58
  :'bid_strategy' => :'bidStrategy',
53
59
  :'bid_amount' => :'bidAmount',
54
- :'roas_average_floor' => :'roasAverageFloor'
60
+ :'roas_average_floor' => :'roasAverageFloor',
61
+ :'daily_min_spend_target' => :'dailyMinSpendTarget',
62
+ :'lifetime_min_spend_target' => :'lifetimeMinSpendTarget'
55
63
  }
56
64
  end
57
65
 
@@ -70,7 +78,9 @@ module Zernio
70
78
  {
71
79
  :'bid_strategy' => :'BidStrategy',
72
80
  :'bid_amount' => :'Float',
73
- :'roas_average_floor' => :'Float'
81
+ :'roas_average_floor' => :'Float',
82
+ :'daily_min_spend_target' => :'Float',
83
+ :'lifetime_min_spend_target' => :'Float'
74
84
  }
75
85
  end
76
86
 
@@ -107,6 +117,14 @@ module Zernio
107
117
  if attributes.key?(:'roas_average_floor')
108
118
  self.roas_average_floor = attributes[:'roas_average_floor']
109
119
  end
120
+
121
+ if attributes.key?(:'daily_min_spend_target')
122
+ self.daily_min_spend_target = attributes[:'daily_min_spend_target']
123
+ end
124
+
125
+ if attributes.key?(:'lifetime_min_spend_target')
126
+ self.lifetime_min_spend_target = attributes[:'lifetime_min_spend_target']
127
+ end
110
128
  end
111
129
 
112
130
  # Show invalid properties with the reasons. Usually used together with valid?
@@ -131,7 +149,9 @@ module Zernio
131
149
  self.class == o.class &&
132
150
  bid_strategy == o.bid_strategy &&
133
151
  bid_amount == o.bid_amount &&
134
- roas_average_floor == o.roas_average_floor
152
+ roas_average_floor == o.roas_average_floor &&
153
+ daily_min_spend_target == o.daily_min_spend_target &&
154
+ lifetime_min_spend_target == o.lifetime_min_spend_target
135
155
  end
136
156
 
137
157
  # @see the `==` method
@@ -143,7 +163,7 @@ module Zernio
143
163
  # Calculates hash code according to all attributes.
144
164
  # @return [Integer] Hash code
145
165
  def hash
146
- [bid_strategy, bid_amount, roas_average_floor].hash
166
+ [bid_strategy, bid_amount, roas_average_floor, daily_min_spend_target, lifetime_min_spend_target].hash
147
167
  end
148
168
 
149
169
  # Builds the object from hash
@@ -28,6 +28,12 @@ module Zernio
28
28
  # Ad set end_time (ISO 8601).
29
29
  attr_accessor :end_date
30
30
 
31
+ # Meta `daily_min_spend_target`: the least this ad set should spend per day, in whole currency units of the ad account. It reserves a share of a CAMPAIGN budget for one ad set, so it requires a campaign using Advantage campaign budget (CBO). On an ad set that owns its budget (ABO) this returns 409 — move the budget to the campaign with `PUT /v1/ads/campaigns/{campaignId}` first. Meta treats it as a target, not a guarantee, and rejects the combined minimum of a campaign's ad sets going over the campaign budget. Mutually exclusive with `lifetimeMinSpendTarget` (400): the flavour must match the campaign budget type, a daily budget takes a daily target. Read it back with `GET /v1/ads/ad-sets/{adSetId}?fields=daily_min_spend_target`.
32
+ attr_accessor :daily_min_spend_target
33
+
34
+ # Meta `lifetime_min_spend_target`: the lifetime-budget flavour of `dailyMinSpendTarget`, in whole currency units. Send this one when the campaign budget is a lifetime budget. Same rules and same rejections.
35
+ attr_accessor :lifetime_min_spend_target
36
+
31
37
  attr_accessor :promoted_object
32
38
 
33
39
  # Attribute mapping from ruby-style variable name to JSON key.
@@ -37,6 +43,8 @@ module Zernio
37
43
  :'billing_event' => :'billingEvent',
38
44
  :'start_date' => :'startDate',
39
45
  :'end_date' => :'endDate',
46
+ :'daily_min_spend_target' => :'dailyMinSpendTarget',
47
+ :'lifetime_min_spend_target' => :'lifetimeMinSpendTarget',
40
48
  :'promoted_object' => :'promotedObject'
41
49
  }
42
50
  end
@@ -58,6 +66,8 @@ module Zernio
58
66
  :'billing_event' => :'String',
59
67
  :'start_date' => :'String',
60
68
  :'end_date' => :'String',
69
+ :'daily_min_spend_target' => :'Float',
70
+ :'lifetime_min_spend_target' => :'Float',
61
71
  :'promoted_object' => :'UpdateAdSetRequestPlatformSpecificDataPromotedObject'
62
72
  }
63
73
  end
@@ -100,6 +110,14 @@ module Zernio
100
110
  self.end_date = attributes[:'end_date']
101
111
  end
102
112
 
113
+ if attributes.key?(:'daily_min_spend_target')
114
+ self.daily_min_spend_target = attributes[:'daily_min_spend_target']
115
+ end
116
+
117
+ if attributes.key?(:'lifetime_min_spend_target')
118
+ self.lifetime_min_spend_target = attributes[:'lifetime_min_spend_target']
119
+ end
120
+
103
121
  if attributes.key?(:'promoted_object')
104
122
  self.promoted_object = attributes[:'promoted_object']
105
123
  end
@@ -129,6 +147,8 @@ module Zernio
129
147
  billing_event == o.billing_event &&
130
148
  start_date == o.start_date &&
131
149
  end_date == o.end_date &&
150
+ daily_min_spend_target == o.daily_min_spend_target &&
151
+ lifetime_min_spend_target == o.lifetime_min_spend_target &&
132
152
  promoted_object == o.promoted_object
133
153
  end
134
154
 
@@ -141,7 +161,7 @@ module Zernio
141
161
  # Calculates hash code according to all attributes.
142
162
  # @return [Integer] Hash code
143
163
  def hash
144
- [optimization_goal, billing_event, start_date, end_date, promoted_object].hash
164
+ [optimization_goal, billing_event, start_date, end_date, daily_min_spend_target, lifetime_min_spend_target, promoted_object].hash
145
165
  end
146
166
 
147
167
  # Builds the object from hash
@@ -11,5 +11,5 @@ Generator version: 7.19.0
11
11
  =end
12
12
 
13
13
  module Zernio
14
- VERSION = '0.0.834'
14
+ VERSION = '0.0.836'
15
15
  end
data/openapi.yaml CHANGED
@@ -5968,6 +5968,8 @@ components:
5968
5968
  bidStrategy: { $ref: '#/components/schemas/BidStrategy' }
5969
5969
  bidAmount: { type: number, description: "Whole currency units (USD: 5 = $5.00). Required when bidStrategy is LOWEST_COST_WITH_BID_CAP or COST_CAP. May also be sent alone, WITHOUT bidStrategy, to set the cap on an ad set joining a COST_CAP / LOWEST_COST_WITH_BID_CAP campaign (the strategy is inherited from the campaign). On POST /v1/ads/create that shape requires existingCampaignId and is a 400 otherwise; on POST /v1/ads/boost it is promoted to LOWEST_COST_WITH_BID_CAP." }
5970
5970
  roasAverageFloor: { type: number, description: "Decimal ROAS multiplier (2.0 = 2.0x). Required when bidStrategy is LOWEST_COST_WITH_MIN_ROAS; sending it without bidStrategy is a 400." }
5971
+ dailyMinSpendTarget: { type: number, description: "Meta daily_min_spend_target on the ad set being created: the least it should spend per day, in whole currency units. It reserves a share of a CAMPAIGN budget, so it requires budgetLevel campaign or an existingCampaignId whose campaign has the budget (Advantage campaign budget / CBO); with an ad-set budget it is a 400, because Meta rejects a spend limit on an ad set that owns its budget. A target, not a guarantee. Mutually exclusive with lifetimeMinSpendTarget: the flavour must match the campaign budget type. Rejected with 400 on POST /v1/ads/boost and in adSetId attach mode: use PUT /v1/ads/ad-sets/{adSetId} for an ad set that already exists." }
5972
+ lifetimeMinSpendTarget: { type: number, description: "Meta lifetime_min_spend_target: the lifetime-budget flavour of dailyMinSpendTarget, in whole currency units. Same rules and same rejections." }
5971
5973
  LinkedInAdsPlatformData:
5972
5974
  type: object
5973
5975
  additionalProperties: false
@@ -41838,6 +41840,25 @@ paths:
41838
41840
  billingEvent: { type: string, description: "Meta ad-set billing_event (e.g. IMPRESSIONS, LINK_CLICKS, THRUPLAY)." }
41839
41841
  startDate: { type: string, description: "Ad set start_time (ISO 8601)." }
41840
41842
  endDate: { type: string, description: "Ad set end_time (ISO 8601)." }
41843
+ dailyMinSpendTarget:
41844
+ type: number
41845
+ description: |
41846
+ Meta `daily_min_spend_target`: the least this ad set should spend per day, in whole
41847
+ currency units of the ad account. It reserves a share of a CAMPAIGN budget for one ad
41848
+ set, so it requires a campaign using Advantage campaign budget (CBO). On an ad set
41849
+ that owns its budget (ABO) this returns 409 — move the budget to the campaign with
41850
+ `PUT /v1/ads/campaigns/{campaignId}` first. Meta treats it as a target, not a
41851
+ guarantee, and rejects the combined minimum of a campaign's ad sets going over the
41852
+ campaign budget.
41853
+ Mutually exclusive with `lifetimeMinSpendTarget` (400): the flavour must match the
41854
+ campaign budget type, a daily budget takes a daily target.
41855
+ Read it back with `GET /v1/ads/ad-sets/{adSetId}?fields=daily_min_spend_target`.
41856
+ lifetimeMinSpendTarget:
41857
+ type: number
41858
+ description: |
41859
+ Meta `lifetime_min_spend_target`: the lifetime-budget flavour of
41860
+ `dailyMinSpendTarget`, in whole currency units. Send this one when the campaign
41861
+ budget is a lifetime budget. Same rules and same rejections.
41841
41862
  promotedObject:
41842
41863
  type: object
41843
41864
  description: "Meta ad-set promoted_object, forwarded verbatim (same shape as /v1/ads/create). Unknown keys are rejected with 400."
@@ -45475,6 +45496,9 @@ paths:
45475
45496
  Sending the bid fields in BOTH places returns a 400
45476
45497
  (`mutually_exclusive_fields`), and sending any of them in
45477
45498
  `adSetId` attach mode is a 400 too (the ad set already has its bid).
45499
+ `dailyMinSpendTarget` / `lifetimeMinSpendTarget` set the new ad set's
45500
+ minimum spend and live here only; they are rejected in `adSetId` attach
45501
+ mode as well.
45478
45502
  oneOf:
45479
45503
  - $ref: '#/components/schemas/LinkedInAdsPlatformData'
45480
45504
  - $ref: '#/components/schemas/MetaAdsPlatformData'
@@ -45,4 +45,16 @@ describe Zernio::MetaAdsPlatformData do
45
45
  end
46
46
  end
47
47
 
48
+ describe 'test attribute "daily_min_spend_target"' do
49
+ it 'should work' do
50
+ # assertion here. ref: https://rspec.info/features/3-12/rspec-expectations/built-in-matchers/
51
+ end
52
+ end
53
+
54
+ describe 'test attribute "lifetime_min_spend_target"' do
55
+ it 'should work' do
56
+ # assertion here. ref: https://rspec.info/features/3-12/rspec-expectations/built-in-matchers/
57
+ end
58
+ end
59
+
48
60
  end
@@ -51,6 +51,18 @@ describe Zernio::UpdateAdSetRequestPlatformSpecificData do
51
51
  end
52
52
  end
53
53
 
54
+ describe 'test attribute "daily_min_spend_target"' do
55
+ it 'should work' do
56
+ # assertion here. ref: https://rspec.info/features/3-12/rspec-expectations/built-in-matchers/
57
+ end
58
+ end
59
+
60
+ describe 'test attribute "lifetime_min_spend_target"' do
61
+ it 'should work' do
62
+ # assertion here. ref: https://rspec.info/features/3-12/rspec-expectations/built-in-matchers/
63
+ end
64
+ end
65
+
54
66
  describe 'test attribute "promoted_object"' do
55
67
  it 'should work' do
56
68
  # assertion here. ref: https://rspec.info/features/3-12/rspec-expectations/built-in-matchers/
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: zernio-sdk
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.0.834
4
+ version: 0.0.836
5
5
  platform: ruby
6
6
  authors:
7
7
  - OpenAPI-Generator