late-sdk 0.0.956 → 0.0.957

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: 878f4e2a33ff293dff439f1c716d14da313c8b8203915429b7649c4ed82f22ef
4
- data.tar.gz: 40fccb2f5d21e8fa69f195b4332da3efe890a5f5657c01be9849646bee3adbf5
3
+ metadata.gz: 494a9a210a70196a61241eaf20b25a3ee2bab55283f282d82ea1fc1ac944f7cc
4
+ data.tar.gz: 9f58a6c39fa59b5981135b3e6125bbcf06513ca83533b13e6b0f8cd1e34fb32d
5
5
  SHA512:
6
- metadata.gz: 8bffc95bdd5bb99c6e355a48edc57ecd25efbd8a504b41b1e518b2c5553af136543c9dfbdd74ddf6e7cbbb2e9ed5c8f26ab2135b717d941255da4cfdcb7ab08a
7
- data.tar.gz: 5423ec15a7ea896cb17d30138c4bf9cbf4657243bc3bd84f69d110f6144eb9bf70750e422332a0290db2d32bea1d85ee585a856c5c7079911b3ca977b98cb76a
6
+ metadata.gz: 057d2ebfb19915ae484cdbb65b59c46f30eefa4e90f3815bdbec483291046d9847ac3a659f208552bbcc00f7f86b3ece8066299218f81c564e361f84dd1f4ece
7
+ data.tar.gz: fd730c249a2c6122f99b489165b308eb572c31488ed9c1c12e6c39d9240bf71167f7fcce097e34a7288c0e82d5cfcd8df10efe1d9f43af13f74492cdb5bd834e
data/README.md CHANGED
@@ -1335,6 +1335,7 @@ Class | Method | HTTP request | Description
1335
1335
  - [Zernio::EnrollContacts200ResponseResultsInner](docs/EnrollContacts200ResponseResultsInner.md)
1336
1336
  - [Zernio::EnrollContactsRequest](docs/EnrollContactsRequest.md)
1337
1337
  - [Zernio::ErrorResponse](docs/ErrorResponse.md)
1338
+ - [Zernio::ErrorResponseDetails](docs/ErrorResponseDetails.md)
1338
1339
  - [Zernio::EstimateAdReach200Response](docs/EstimateAdReach200Response.md)
1339
1340
  - [Zernio::EstimateAdReachRequest](docs/EstimateAdReachRequest.md)
1340
1341
  - [Zernio::Expired](docs/Expired.md)
@@ -10,7 +10,7 @@
10
10
  | **param** | **String** | The request field that caused the error, when applicable. | [optional] |
11
11
  | **platform** | **String** | Upstream platform (e.g. meta, google, tiktok), present when type is platform_error. | [optional] |
12
12
  | **platform_error** | **Hash<String, Object>** | Raw error payload from the upstream platform, passed through verbatim so integrators can read provider-specific codes. For Meta this includes error_subcode, error_user_title, and error_user_msg. | [optional] |
13
- | **details** | **Hash<String, Object>** | Additional structured context (e.g. field-level validation errors), for example `privateReplyConsumed` on the private-reply endpoint's 400 when the comment's single reply is already spent. | [optional] |
13
+ | **details** | [**ErrorResponseDetails**](ErrorResponseDetails.md) | | [optional] |
14
14
 
15
15
  ## Example
16
16
 
@@ -0,0 +1,20 @@
1
+ # Zernio::ErrorResponseDetails
2
+
3
+ ## Properties
4
+
5
+ | Name | Type | Description | Notes |
6
+ | ---- | ---- | ----------- | ----- |
7
+ | **quota_exhausted** | **Boolean** | Google Ads 429 only. True when the upstream Google Ads quota is spent rather than a Zernio limit. | [optional] |
8
+ | **quota_scope** | **String** | Google Ads 429 only, when Google names the scope. DEVELOPER is the shared developer-token budget; ACCOUNT is your ad account. | [optional] |
9
+
10
+ ## Example
11
+
12
+ ```ruby
13
+ require 'zernio-sdk'
14
+
15
+ instance = Zernio::ErrorResponseDetails.new(
16
+ quota_exhausted: null,
17
+ quota_scope: null
18
+ )
19
+ ```
20
+
@@ -34,7 +34,6 @@ module Zernio
34
34
  # Raw error payload from the upstream platform, passed through verbatim so integrators can read provider-specific codes. For Meta this includes error_subcode, error_user_title, and error_user_msg.
35
35
  attr_accessor :platform_error
36
36
 
37
- # Additional structured context (e.g. field-level validation errors), for example `privateReplyConsumed` on the private-reply endpoint's 400 when the comment's single reply is already spent.
38
37
  attr_accessor :details
39
38
 
40
39
  class EnumAttributeValidator
@@ -91,7 +90,7 @@ module Zernio
91
90
  :'param' => :'String',
92
91
  :'platform' => :'String',
93
92
  :'platform_error' => :'Hash<String, Object>',
94
- :'details' => :'Hash<String, Object>'
93
+ :'details' => :'ErrorResponseDetails'
95
94
  }
96
95
  end
97
96
 
@@ -144,9 +143,7 @@ module Zernio
144
143
  end
145
144
 
146
145
  if attributes.key?(:'details')
147
- if (value = attributes[:'details']).is_a?(Hash)
148
- self.details = value
149
- end
146
+ self.details = attributes[:'details']
150
147
  end
151
148
  end
152
149
 
@@ -0,0 +1,193 @@
1
+ =begin
2
+ #Zernio API
3
+
4
+ #API reference for Zernio. Authenticate with a Bearer API key. Base URL: https://zernio.com/api Versioning and deprecation: all endpoints are versioned in the URL path (current version: /v1). Breaking changes only ship in a new path version; existing versions keep working. Deprecated operations are marked 'deprecated: true' in this spec and announced in the changelog (https://zernio.com/changelog) before removal. Errors: every 4xx/5xx response is application/json with a machine-readable 'code' and a human-readable 'error' message (see the ErrorResponse schema).
5
+
6
+ The version of the OpenAPI document: 1.0.4
7
+ Contact: support@zernio.com
8
+ Generated by: https://openapi-generator.tech
9
+ Generator version: 7.19.0
10
+
11
+ =end
12
+
13
+ require 'date'
14
+ require 'time'
15
+
16
+ module Zernio
17
+ # Additional structured context (e.g. field-level validation errors), for example `privateReplyConsumed` on the private-reply endpoint's 400 when the comment's single reply is already spent. On a Google Ads 429 it carries `quotaExhausted: true`, which marks the failure as Google's own ads quota rather than a Zernio rate limit, so you can keep calling other platforms instead of backing off everywhere. When Google names the scope it also carries `quotaScope`: `DEVELOPER` means the shared developer-token budget (every Google account is affected and there is nothing to change on your side), `ACCOUNT` means your own ad account. A Meta 429 carries neither field.
18
+ class ErrorResponseDetails < ApiModelBase
19
+ # Google Ads 429 only. True when the upstream Google Ads quota is spent rather than a Zernio limit.
20
+ attr_accessor :quota_exhausted
21
+
22
+ # Google Ads 429 only, when Google names the scope. DEVELOPER is the shared developer-token budget; ACCOUNT is your ad account.
23
+ attr_accessor :quota_scope
24
+
25
+ class EnumAttributeValidator
26
+ attr_reader :datatype
27
+ attr_reader :allowable_values
28
+
29
+ def initialize(datatype, allowable_values)
30
+ @allowable_values = allowable_values.map do |value|
31
+ case datatype.to_s
32
+ when /Integer/i
33
+ value.to_i
34
+ when /Float/i
35
+ value.to_f
36
+ else
37
+ value
38
+ end
39
+ end
40
+ end
41
+
42
+ def valid?(value)
43
+ !value || allowable_values.include?(value)
44
+ end
45
+ end
46
+
47
+ # Attribute mapping from ruby-style variable name to JSON key.
48
+ def self.attribute_map
49
+ {
50
+ :'quota_exhausted' => :'quotaExhausted',
51
+ :'quota_scope' => :'quotaScope'
52
+ }
53
+ end
54
+
55
+ # Returns attribute mapping this model knows about
56
+ def self.acceptable_attribute_map
57
+ attribute_map
58
+ end
59
+
60
+ # Returns all the JSON keys this model knows about
61
+ def self.acceptable_attributes
62
+ acceptable_attribute_map.values
63
+ end
64
+
65
+ # Attribute type mapping.
66
+ def self.openapi_types
67
+ {
68
+ :'quota_exhausted' => :'Boolean',
69
+ :'quota_scope' => :'String'
70
+ }
71
+ end
72
+
73
+ # List of attributes with nullable: true
74
+ def self.openapi_nullable
75
+ Set.new([
76
+ ])
77
+ end
78
+
79
+ # Initializes the object
80
+ # @param [Hash] attributes Model attributes in the form of hash
81
+ def initialize(attributes = {})
82
+ if (!attributes.is_a?(Hash))
83
+ fail ArgumentError, "The input argument (attributes) must be a hash in `Zernio::ErrorResponseDetails` initialize method"
84
+ end
85
+
86
+ # check to see if the attribute exists and convert string to symbol for hash key
87
+ acceptable_attribute_map = self.class.acceptable_attribute_map
88
+ attributes = attributes.each_with_object({}) { |(k, v), h|
89
+ if (!acceptable_attribute_map.key?(k.to_sym))
90
+ fail ArgumentError, "`#{k}` is not a valid attribute in `Zernio::ErrorResponseDetails`. Please check the name to make sure it's valid. List of attributes: " + acceptable_attribute_map.keys.inspect
91
+ end
92
+ h[k.to_sym] = v
93
+ }
94
+
95
+ if attributes.key?(:'quota_exhausted')
96
+ self.quota_exhausted = attributes[:'quota_exhausted']
97
+ end
98
+
99
+ if attributes.key?(:'quota_scope')
100
+ self.quota_scope = attributes[:'quota_scope']
101
+ end
102
+ end
103
+
104
+ # Show invalid properties with the reasons. Usually used together with valid?
105
+ # @return Array for valid properties with the reasons
106
+ def list_invalid_properties
107
+ warn '[DEPRECATED] the `list_invalid_properties` method is obsolete'
108
+ invalid_properties = Array.new
109
+ invalid_properties
110
+ end
111
+
112
+ # Check to see if the all the properties in the model are valid
113
+ # @return true if the model is valid
114
+ def valid?
115
+ warn '[DEPRECATED] the `valid?` method is obsolete'
116
+ quota_scope_validator = EnumAttributeValidator.new('String', ["DEVELOPER", "ACCOUNT"])
117
+ return false unless quota_scope_validator.valid?(@quota_scope)
118
+ true
119
+ end
120
+
121
+ # Custom attribute writer method checking allowed values (enum).
122
+ # @param [Object] quota_scope Object to be assigned
123
+ def quota_scope=(quota_scope)
124
+ validator = EnumAttributeValidator.new('String', ["DEVELOPER", "ACCOUNT"])
125
+ unless validator.valid?(quota_scope)
126
+ fail ArgumentError, "invalid value for \"quota_scope\", must be one of #{validator.allowable_values}."
127
+ end
128
+ @quota_scope = quota_scope
129
+ end
130
+
131
+ # Checks equality by comparing each attribute.
132
+ # @param [Object] Object to be compared
133
+ def ==(o)
134
+ return true if self.equal?(o)
135
+ self.class == o.class &&
136
+ quota_exhausted == o.quota_exhausted &&
137
+ quota_scope == o.quota_scope
138
+ end
139
+
140
+ # @see the `==` method
141
+ # @param [Object] Object to be compared
142
+ def eql?(o)
143
+ self == o
144
+ end
145
+
146
+ # Calculates hash code according to all attributes.
147
+ # @return [Integer] Hash code
148
+ def hash
149
+ [quota_exhausted, quota_scope].hash
150
+ end
151
+
152
+ # Builds the object from hash
153
+ # @param [Hash] attributes Model attributes in the form of hash
154
+ # @return [Object] Returns the model itself
155
+ def self.build_from_hash(attributes)
156
+ return nil unless attributes.is_a?(Hash)
157
+ attributes = attributes.transform_keys(&:to_sym)
158
+ transformed_hash = {}
159
+ openapi_types.each_pair do |key, type|
160
+ if attributes.key?(attribute_map[key]) && attributes[attribute_map[key]].nil?
161
+ transformed_hash["#{key}"] = nil
162
+ elsif type =~ /\AArray<(.*)>/i
163
+ # check to ensure the input is an array given that the attribute
164
+ # is documented as an array but the input is not
165
+ if attributes[attribute_map[key]].is_a?(Array)
166
+ transformed_hash["#{key}"] = attributes[attribute_map[key]].map { |v| _deserialize($1, v) }
167
+ end
168
+ elsif !attributes[attribute_map[key]].nil?
169
+ transformed_hash["#{key}"] = _deserialize(type, attributes[attribute_map[key]])
170
+ end
171
+ end
172
+ new(transformed_hash)
173
+ end
174
+
175
+ # Returns the object in the form of hash
176
+ # @return [Hash] Returns the object in the form of hash
177
+ def to_hash
178
+ hash = {}
179
+ self.class.attribute_map.each_pair do |attr, param|
180
+ value = self.send(attr)
181
+ if value.nil?
182
+ is_nullable = self.class.openapi_nullable.include?(attr)
183
+ next if !is_nullable || (is_nullable && !instance_variable_defined?(:"@#{attr}"))
184
+ end
185
+
186
+ hash[param] = _to_hash(value)
187
+ end
188
+ hash
189
+ end
190
+
191
+ end
192
+
193
+ end
@@ -11,5 +11,5 @@ Generator version: 7.19.0
11
11
  =end
12
12
 
13
13
  module Zernio
14
- VERSION = '0.0.956'
14
+ VERSION = '0.0.957'
15
15
  end
data/lib/zernio-sdk.rb CHANGED
@@ -546,6 +546,7 @@ require 'zernio-sdk/models/enroll_contacts200_response'
546
546
  require 'zernio-sdk/models/enroll_contacts200_response_results_inner'
547
547
  require 'zernio-sdk/models/enroll_contacts_request'
548
548
  require 'zernio-sdk/models/error_response'
549
+ require 'zernio-sdk/models/error_response_details'
549
550
  require 'zernio-sdk/models/estimate_ad_reach200_response'
550
551
  require 'zernio-sdk/models/estimate_ad_reach_request'
551
552
  require 'zernio-sdk/models/expired'
data/openapi.yaml CHANGED
@@ -1833,10 +1833,25 @@ components:
1833
1833
  details:
1834
1834
  type: object
1835
1835
  additionalProperties: true
1836
- description: >-
1836
+ description: |
1837
1837
  Additional structured context (e.g. field-level validation errors), for example
1838
1838
  `privateReplyConsumed` on the private-reply endpoint's 400 when the comment's
1839
1839
  single reply is already spent.
1840
+
1841
+ On a Google Ads 429 it carries `quotaExhausted: true`, which marks the failure as
1842
+ Google's own ads quota rather than a Zernio rate limit, so you can keep calling
1843
+ other platforms instead of backing off everywhere. When Google names the scope it
1844
+ also carries `quotaScope`: `DEVELOPER` means the shared developer-token budget
1845
+ (every Google account is affected and there is nothing to change on your side),
1846
+ `ACCOUNT` means your own ad account. A Meta 429 carries neither field.
1847
+ properties:
1848
+ quotaExhausted:
1849
+ type: boolean
1850
+ description: 'Google Ads 429 only. True when the upstream Google Ads quota is spent rather than a Zernio limit.'
1851
+ quotaScope:
1852
+ type: string
1853
+ enum: [DEVELOPER, ACCOUNT]
1854
+ description: 'Google Ads 429 only, when Google names the scope. DEVELOPER is the shared developer-token budget; ACCOUNT is your ad account.'
1840
1855
  CommentAutomationAudience:
1841
1856
  type: object
1842
1857
  description: |
@@ -0,0 +1,46 @@
1
+ =begin
2
+ #Zernio API
3
+
4
+ #API reference for Zernio. Authenticate with a Bearer API key. Base URL: https://zernio.com/api Versioning and deprecation: all endpoints are versioned in the URL path (current version: /v1). Breaking changes only ship in a new path version; existing versions keep working. Deprecated operations are marked 'deprecated: true' in this spec and announced in the changelog (https://zernio.com/changelog) before removal. Errors: every 4xx/5xx response is application/json with a machine-readable 'code' and a human-readable 'error' message (see the ErrorResponse schema).
5
+
6
+ The version of the OpenAPI document: 1.0.4
7
+ Contact: support@zernio.com
8
+ Generated by: https://openapi-generator.tech
9
+ Generator version: 7.19.0
10
+
11
+ =end
12
+
13
+ require 'spec_helper'
14
+ require 'json'
15
+ require 'date'
16
+
17
+ # Unit tests for Zernio::ErrorResponseDetails
18
+ # Automatically generated by openapi-generator (https://openapi-generator.tech)
19
+ # Please update as you see appropriate
20
+ describe Zernio::ErrorResponseDetails do
21
+ #let(:instance) { Zernio::ErrorResponseDetails.new }
22
+
23
+ describe 'test an instance of ErrorResponseDetails' do
24
+ it 'should create an instance of ErrorResponseDetails' do
25
+ # uncomment below to test the instance creation
26
+ #expect(instance).to be_instance_of(Zernio::ErrorResponseDetails)
27
+ end
28
+ end
29
+
30
+ describe 'test attribute "quota_exhausted"' do
31
+ it 'should work' do
32
+ # assertion here. ref: https://rspec.info/features/3-12/rspec-expectations/built-in-matchers/
33
+ end
34
+ end
35
+
36
+ describe 'test attribute "quota_scope"' do
37
+ it 'should work' do
38
+ # assertion here. ref: https://rspec.info/features/3-12/rspec-expectations/built-in-matchers/
39
+ # validator = Petstore::EnumTest::EnumAttributeValidator.new('String', ["DEVELOPER", "ACCOUNT"])
40
+ # validator.allowable_values.each do |value|
41
+ # expect { instance.quota_scope = value }.not_to raise_error
42
+ # end
43
+ end
44
+ end
45
+
46
+ 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.956
4
+ version: 0.0.957
5
5
  platform: ruby
6
6
  authors:
7
7
  - OpenAPI-Generator
@@ -620,6 +620,7 @@ files:
620
620
  - docs/EnrollContacts200ResponseResultsInner.md
621
621
  - docs/EnrollContactsRequest.md
622
622
  - docs/ErrorResponse.md
623
+ - docs/ErrorResponseDetails.md
623
624
  - docs/EstimateAdReach200Response.md
624
625
  - docs/EstimateAdReachRequest.md
625
626
  - docs/Expired.md
@@ -2807,6 +2808,7 @@ files:
2807
2808
  - lib/zernio-sdk/models/enroll_contacts200_response_results_inner.rb
2808
2809
  - lib/zernio-sdk/models/enroll_contacts_request.rb
2809
2810
  - lib/zernio-sdk/models/error_response.rb
2811
+ - lib/zernio-sdk/models/error_response_details.rb
2810
2812
  - lib/zernio-sdk/models/estimate_ad_reach200_response.rb
2811
2813
  - lib/zernio-sdk/models/estimate_ad_reach_request.rb
2812
2814
  - lib/zernio-sdk/models/expired.rb
@@ -4942,6 +4944,7 @@ files:
4942
4944
  - spec/models/enroll_contacts200_response_results_inner_spec.rb
4943
4945
  - spec/models/enroll_contacts200_response_spec.rb
4944
4946
  - spec/models/enroll_contacts_request_spec.rb
4947
+ - spec/models/error_response_details_spec.rb
4945
4948
  - spec/models/error_response_spec.rb
4946
4949
  - spec/models/estimate_ad_reach200_response_spec.rb
4947
4950
  - spec/models/estimate_ad_reach_request_spec.rb
@@ -6481,7 +6484,7 @@ files:
6481
6484
  - spec/models/you_tube_video_retention_response_retention_curve_inner_spec.rb
6482
6485
  - spec/models/you_tube_video_retention_response_spec.rb
6483
6486
  - spec/spec_helper.rb
6484
- - zernio-sdk-0.0.956.gem
6487
+ - zernio-sdk-0.0.957.gem
6485
6488
  - zernio-sdk.gemspec
6486
6489
  homepage: https://openapi-generator.tech
6487
6490
  licenses:
@@ -8148,6 +8151,7 @@ test_files:
8148
8151
  - spec/models/get_inbox_top_accounts200_response_spec.rb
8149
8152
  - spec/models/list_business_agent_websites200_response_spec.rb
8150
8153
  - spec/models/update_google_business_place_action_request_spec.rb
8154
+ - spec/models/error_response_details_spec.rb
8151
8155
  - spec/models/create_account_group_request_spec.rb
8152
8156
  - spec/models/social_account_spec.rb
8153
8157
  - spec/models/get_daily_metrics200_response_daily_data_inner_metrics_spec.rb
Binary file