pingram 1.0.35 → 1.0.37

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 (30) hide show
  1. checksums.yaml +4 -4
  2. data/Gemfile.lock +1 -1
  3. data/lib/pingram/api/account_api.rb +244 -2
  4. data/lib/pingram/api_client.rb +1 -1
  5. data/lib/pingram/models/account_get_response.rb +13 -4
  6. data/lib/pingram/models/account_get_response_billing_alerts.rb +224 -0
  7. data/lib/pingram/models/account_patch_request.rb +13 -4
  8. data/lib/pingram/models/billing_email.rb +177 -0
  9. data/lib/pingram/models/billing_post_response_body.rb +10 -1
  10. data/lib/pingram/models/cancel_subscription_request.rb +168 -0
  11. data/lib/pingram/models/phone_verify_start_response.rb +14 -4
  12. data/lib/pingram/models/send_email_request.rb +21 -1
  13. data/lib/pingram/models/sender_post_body_options_email.rb +21 -1
  14. data/lib/pingram/models/sender_post_body_sms.rb +1 -1
  15. data/lib/pingram/models/sender_post_body_sms_auto_reply.rb +2 -1
  16. data/lib/pingram/models/slack_connect_invite_response.rb +190 -0
  17. data/lib/pingram/models/update_billing_email_request.rb +184 -0
  18. data/lib/pingram/models/webhook_event.rb +88 -6
  19. data/lib/pingram/models/webhook_event_usage_value.rb +193 -0
  20. data/lib/pingram/version.rb +1 -1
  21. data/lib/pingram.rb +6 -0
  22. data/vendor/bundle/ruby/3.2.0/extensions/x86_64-linux/3.2.0/byebug-13.0.0/gem_make.out +5 -5
  23. data/vendor/bundle/ruby/3.2.0/extensions/x86_64-linux/3.2.0/date-3.5.1/gem_make.out +5 -5
  24. data/vendor/bundle/ruby/3.2.0/extensions/x86_64-linux/3.2.0/io-console-0.9.4/gem_make.out +5 -5
  25. data/vendor/bundle/ruby/3.2.0/extensions/x86_64-linux/3.2.0/io-console-0.9.4/mkmf.log +3 -3
  26. data/vendor/bundle/ruby/3.2.0/extensions/x86_64-linux/3.2.0/jaro_winkler-1.5.6/gem_make.out +5 -5
  27. data/vendor/bundle/ruby/3.2.0/extensions/x86_64-linux/3.2.0/psych-5.5.0/gem_make.out +5 -5
  28. data/vendor/bundle/ruby/3.2.0/extensions/x86_64-linux/3.2.0/racc-1.8.1/gem_make.out +5 -5
  29. data/vendor/bundle/ruby/3.2.0/extensions/x86_64-linux/3.2.0/stringio-3.2.0/gem_make.out +5 -5
  30. metadata +8 -2
@@ -0,0 +1,190 @@
1
+ =begin
2
+ #Pingram
3
+
4
+ #Internal API for notification delivery and management
5
+
6
+ The version of the OpenAPI document: 1.0.0
7
+
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 Pingram
17
+ class SlackConnectInviteResponse < ApiModelBase
18
+ attr_accessor :channel_id
19
+
20
+ attr_accessor :channel_name
21
+
22
+ # Attribute mapping from ruby-style variable name to JSON key.
23
+ def self.attribute_map
24
+ {
25
+ :'channel_id' => :'channelId',
26
+ :'channel_name' => :'channelName'
27
+ }
28
+ end
29
+
30
+ # Returns attribute mapping this model knows about
31
+ def self.acceptable_attribute_map
32
+ attribute_map
33
+ end
34
+
35
+ # Returns all the JSON keys this model knows about
36
+ def self.acceptable_attributes
37
+ acceptable_attribute_map.values
38
+ end
39
+
40
+ # Attribute type mapping.
41
+ def self.openapi_types
42
+ {
43
+ :'channel_id' => :'String',
44
+ :'channel_name' => :'String'
45
+ }
46
+ end
47
+
48
+ # List of attributes with nullable: true
49
+ def self.openapi_nullable
50
+ Set.new([
51
+ ])
52
+ end
53
+
54
+ # Initializes the object
55
+ # @param [Hash] attributes Model attributes in the form of hash
56
+ def initialize(attributes = {})
57
+ if (!attributes.is_a?(Hash))
58
+ fail ArgumentError, "The input argument (attributes) must be a hash in `Pingram::SlackConnectInviteResponse` initialize method"
59
+ end
60
+
61
+ # check to see if the attribute exists and convert string to symbol for hash key
62
+ acceptable_attribute_map = self.class.acceptable_attribute_map
63
+ attributes = attributes.each_with_object({}) { |(k, v), h|
64
+ if (!acceptable_attribute_map.key?(k.to_sym))
65
+ fail ArgumentError, "`#{k}` is not a valid attribute in `Pingram::SlackConnectInviteResponse`. Please check the name to make sure it's valid. List of attributes: " + acceptable_attribute_map.keys.inspect
66
+ end
67
+ h[k.to_sym] = v
68
+ }
69
+
70
+ if attributes.key?(:'channel_id')
71
+ self.channel_id = attributes[:'channel_id']
72
+ else
73
+ self.channel_id = nil
74
+ end
75
+
76
+ if attributes.key?(:'channel_name')
77
+ self.channel_name = attributes[:'channel_name']
78
+ else
79
+ self.channel_name = nil
80
+ end
81
+ end
82
+
83
+ # Show invalid properties with the reasons. Usually used together with valid?
84
+ # @return Array for valid properties with the reasons
85
+ def list_invalid_properties
86
+ warn '[DEPRECATED] the `list_invalid_properties` method is obsolete'
87
+ invalid_properties = Array.new
88
+ if @channel_id.nil?
89
+ invalid_properties.push('invalid value for "channel_id", channel_id cannot be nil.')
90
+ end
91
+
92
+ if @channel_name.nil?
93
+ invalid_properties.push('invalid value for "channel_name", channel_name cannot be nil.')
94
+ end
95
+
96
+ invalid_properties
97
+ end
98
+
99
+ # Check to see if the all the properties in the model are valid
100
+ # @return true if the model is valid
101
+ def valid?
102
+ warn '[DEPRECATED] the `valid?` method is obsolete'
103
+ return false if @channel_id.nil?
104
+ return false if @channel_name.nil?
105
+ true
106
+ end
107
+
108
+ # Custom attribute writer method with validation
109
+ # @param [Object] channel_id Value to be assigned
110
+ def channel_id=(channel_id)
111
+ if channel_id.nil?
112
+ fail ArgumentError, 'channel_id cannot be nil'
113
+ end
114
+
115
+ @channel_id = channel_id
116
+ end
117
+
118
+ # Custom attribute writer method with validation
119
+ # @param [Object] channel_name Value to be assigned
120
+ def channel_name=(channel_name)
121
+ if channel_name.nil?
122
+ fail ArgumentError, 'channel_name cannot be nil'
123
+ end
124
+
125
+ @channel_name = channel_name
126
+ end
127
+
128
+ # Checks equality by comparing each attribute.
129
+ # @param [Object] Object to be compared
130
+ def ==(o)
131
+ return true if self.equal?(o)
132
+ self.class == o.class &&
133
+ channel_id == o.channel_id &&
134
+ channel_name == o.channel_name
135
+ end
136
+
137
+ # @see the `==` method
138
+ # @param [Object] Object to be compared
139
+ def eql?(o)
140
+ self == o
141
+ end
142
+
143
+ # Calculates hash code according to all attributes.
144
+ # @return [Integer] Hash code
145
+ def hash
146
+ [channel_id, channel_name].hash
147
+ end
148
+
149
+ # Builds the object from hash
150
+ # @param [Hash] attributes Model attributes in the form of hash
151
+ # @return [Object] Returns the model itself
152
+ def self.build_from_hash(attributes)
153
+ return nil unless attributes.is_a?(Hash)
154
+ attributes = attributes.transform_keys(&:to_sym)
155
+ transformed_hash = {}
156
+ openapi_types.each_pair do |key, type|
157
+ if attributes.key?(attribute_map[key]) && attributes[attribute_map[key]].nil?
158
+ transformed_hash["#{key}"] = nil
159
+ elsif type =~ /\AArray<(.*)>/i
160
+ # check to ensure the input is an array given that the attribute
161
+ # is documented as an array but the input is not
162
+ if attributes[attribute_map[key]].is_a?(Array)
163
+ transformed_hash["#{key}"] = attributes[attribute_map[key]].map { |v| _deserialize($1, v) }
164
+ end
165
+ elsif !attributes[attribute_map[key]].nil?
166
+ transformed_hash["#{key}"] = _deserialize(type, attributes[attribute_map[key]])
167
+ end
168
+ end
169
+ new(transformed_hash)
170
+ end
171
+
172
+ # Returns the object in the form of hash
173
+ # @return [Hash] Returns the object in the form of hash
174
+ def to_hash
175
+ hash = {}
176
+ self.class.attribute_map.each_pair do |attr, param|
177
+ value = self.send(attr)
178
+ if value.nil?
179
+ is_nullable = self.class.openapi_nullable.include?(attr)
180
+ next if !is_nullable || (is_nullable && !instance_variable_defined?(:"@#{attr}"))
181
+ end
182
+
183
+ hash[param] = _to_hash(value)
184
+ end
185
+ hash
186
+ end
187
+
188
+ end
189
+
190
+ end
@@ -0,0 +1,184 @@
1
+ =begin
2
+ #Pingram
3
+
4
+ #Internal API for notification delivery and management
5
+
6
+ The version of the OpenAPI document: 1.0.0
7
+
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 Pingram
17
+ # PATCH /account/billing-email request.
18
+ class UpdateBillingEmailRequest < ApiModelBase
19
+ # Address that receives invoices and receipts.
20
+ attr_accessor :email
21
+
22
+ # Attribute mapping from ruby-style variable name to JSON key.
23
+ def self.attribute_map
24
+ {
25
+ :'email' => :'email'
26
+ }
27
+ end
28
+
29
+ # Returns attribute mapping this model knows about
30
+ def self.acceptable_attribute_map
31
+ attribute_map
32
+ end
33
+
34
+ # Returns all the JSON keys this model knows about
35
+ def self.acceptable_attributes
36
+ acceptable_attribute_map.values
37
+ end
38
+
39
+ # Attribute type mapping.
40
+ def self.openapi_types
41
+ {
42
+ :'email' => :'String'
43
+ }
44
+ end
45
+
46
+ # List of attributes with nullable: true
47
+ def self.openapi_nullable
48
+ Set.new([
49
+ ])
50
+ end
51
+
52
+ # Initializes the object
53
+ # @param [Hash] attributes Model attributes in the form of hash
54
+ def initialize(attributes = {})
55
+ if (!attributes.is_a?(Hash))
56
+ fail ArgumentError, "The input argument (attributes) must be a hash in `Pingram::UpdateBillingEmailRequest` initialize method"
57
+ end
58
+
59
+ # check to see if the attribute exists and convert string to symbol for hash key
60
+ acceptable_attribute_map = self.class.acceptable_attribute_map
61
+ attributes = attributes.each_with_object({}) { |(k, v), h|
62
+ if (!acceptable_attribute_map.key?(k.to_sym))
63
+ fail ArgumentError, "`#{k}` is not a valid attribute in `Pingram::UpdateBillingEmailRequest`. Please check the name to make sure it's valid. List of attributes: " + acceptable_attribute_map.keys.inspect
64
+ end
65
+ h[k.to_sym] = v
66
+ }
67
+
68
+ if attributes.key?(:'email')
69
+ self.email = attributes[:'email']
70
+ else
71
+ self.email = nil
72
+ end
73
+ end
74
+
75
+ # Show invalid properties with the reasons. Usually used together with valid?
76
+ # @return Array for valid properties with the reasons
77
+ def list_invalid_properties
78
+ warn '[DEPRECATED] the `list_invalid_properties` method is obsolete'
79
+ invalid_properties = Array.new
80
+ if @email.nil?
81
+ invalid_properties.push('invalid value for "email", email cannot be nil.')
82
+ end
83
+
84
+ if @email.to_s.length > 320
85
+ invalid_properties.push('invalid value for "email", the character length must be smaller than or equal to 320.')
86
+ end
87
+
88
+ if @email.to_s.length < 3
89
+ invalid_properties.push('invalid value for "email", the character length must be greater than or equal to 3.')
90
+ end
91
+
92
+ invalid_properties
93
+ end
94
+
95
+ # Check to see if the all the properties in the model are valid
96
+ # @return true if the model is valid
97
+ def valid?
98
+ warn '[DEPRECATED] the `valid?` method is obsolete'
99
+ return false if @email.nil?
100
+ return false if @email.to_s.length > 320
101
+ return false if @email.to_s.length < 3
102
+ true
103
+ end
104
+
105
+ # Custom attribute writer method with validation
106
+ # @param [Object] email Value to be assigned
107
+ def email=(email)
108
+ if email.nil?
109
+ fail ArgumentError, 'email cannot be nil'
110
+ end
111
+
112
+ if email.to_s.length > 320
113
+ fail ArgumentError, 'invalid value for "email", the character length must be smaller than or equal to 320.'
114
+ end
115
+
116
+ if email.to_s.length < 3
117
+ fail ArgumentError, 'invalid value for "email", the character length must be greater than or equal to 3.'
118
+ end
119
+
120
+ @email = email
121
+ end
122
+
123
+ # Checks equality by comparing each attribute.
124
+ # @param [Object] Object to be compared
125
+ def ==(o)
126
+ return true if self.equal?(o)
127
+ self.class == o.class &&
128
+ email == o.email
129
+ end
130
+
131
+ # @see the `==` method
132
+ # @param [Object] Object to be compared
133
+ def eql?(o)
134
+ self == o
135
+ end
136
+
137
+ # Calculates hash code according to all attributes.
138
+ # @return [Integer] Hash code
139
+ def hash
140
+ [email].hash
141
+ end
142
+
143
+ # Builds the object from hash
144
+ # @param [Hash] attributes Model attributes in the form of hash
145
+ # @return [Object] Returns the model itself
146
+ def self.build_from_hash(attributes)
147
+ return nil unless attributes.is_a?(Hash)
148
+ attributes = attributes.transform_keys(&:to_sym)
149
+ transformed_hash = {}
150
+ openapi_types.each_pair do |key, type|
151
+ if attributes.key?(attribute_map[key]) && attributes[attribute_map[key]].nil?
152
+ transformed_hash["#{key}"] = nil
153
+ elsif type =~ /\AArray<(.*)>/i
154
+ # check to ensure the input is an array given that the attribute
155
+ # is documented as an array but the input is not
156
+ if attributes[attribute_map[key]].is_a?(Array)
157
+ transformed_hash["#{key}"] = attributes[attribute_map[key]].map { |v| _deserialize($1, v) }
158
+ end
159
+ elsif !attributes[attribute_map[key]].nil?
160
+ transformed_hash["#{key}"] = _deserialize(type, attributes[attribute_map[key]])
161
+ end
162
+ end
163
+ new(transformed_hash)
164
+ end
165
+
166
+ # Returns the object in the form of hash
167
+ # @return [Hash] Returns the object in the form of hash
168
+ def to_hash
169
+ hash = {}
170
+ self.class.attribute_map.each_pair do |attr, param|
171
+ value = self.send(attr)
172
+ if value.nil?
173
+ is_nullable = self.class.openapi_nullable.include?(attr)
174
+ next if !is_nullable || (is_nullable && !instance_variable_defined?(:"@#{attr}"))
175
+ end
176
+
177
+ hash[param] = _to_hash(value)
178
+ end
179
+ hash
180
+ end
181
+
182
+ end
183
+
184
+ end
@@ -38,6 +38,30 @@ module Pingram
38
38
  # Link tags for EMAIL_CLICK events.
39
39
  attr_accessor :clicked_link_tags
40
40
 
41
+ # Account id, for ACCOUNT_USAGE.
42
+ attr_accessor :account_id
43
+
44
+ # Billing period start (YYYY-MM-DD), for ACCOUNT_USAGE.
45
+ attr_accessor :year_month_day
46
+
47
+ # Date the monthly budget resets (YYYY-MM-DD), for ACCOUNT_USAGE.
48
+ attr_accessor :resets_on
49
+
50
+ # Whole percent of the monthly budget used, for ACCOUNT_USAGE.
51
+ attr_accessor :percent
52
+
53
+ # Amount spent against the monthly budget, for ACCOUNT_USAGE.
54
+ attr_accessor :spent
55
+
56
+ # Monthly budget the percent was measured against, for ACCOUNT_USAGE.
57
+ attr_accessor :cost_cap
58
+
59
+ # Whether the account raises its budget automatically, for ACCOUNT_USAGE.
60
+ attr_accessor :auto_upgrade
61
+
62
+ # Per-channel volume and cost for the current period, for ACCOUNT_USAGE.
63
+ attr_accessor :usage
64
+
41
65
  class EnumAttributeValidator
42
66
  attr_reader :datatype
43
67
  attr_reader :allowable_values
@@ -70,7 +94,15 @@ module Pingram
70
94
  :'tracking_id' => :'trackingId',
71
95
  :'failure_code' => :'failureCode',
72
96
  :'clicked_link' => :'clickedLink',
73
- :'clicked_link_tags' => :'clickedLinkTags'
97
+ :'clicked_link_tags' => :'clickedLinkTags',
98
+ :'account_id' => :'accountId',
99
+ :'year_month_day' => :'yearMonthDay',
100
+ :'resets_on' => :'resetsOn',
101
+ :'percent' => :'percent',
102
+ :'spent' => :'spent',
103
+ :'cost_cap' => :'costCap',
104
+ :'auto_upgrade' => :'autoUpgrade',
105
+ :'usage' => :'usage'
74
106
  }
75
107
  end
76
108
 
@@ -94,7 +126,15 @@ module Pingram
94
126
  :'tracking_id' => :'String',
95
127
  :'failure_code' => :'String',
96
128
  :'clicked_link' => :'String',
97
- :'clicked_link_tags' => :'Hash<String, Array<String>>'
129
+ :'clicked_link_tags' => :'Hash<String, Array<String>>',
130
+ :'account_id' => :'String',
131
+ :'year_month_day' => :'String',
132
+ :'resets_on' => :'String',
133
+ :'percent' => :'Float',
134
+ :'spent' => :'Float',
135
+ :'cost_cap' => :'Float',
136
+ :'auto_upgrade' => :'Boolean',
137
+ :'usage' => :'Hash<String, WebhookEventUsageValue>'
98
138
  }
99
139
  end
100
140
 
@@ -163,6 +203,40 @@ module Pingram
163
203
  self.clicked_link_tags = value
164
204
  end
165
205
  end
206
+
207
+ if attributes.key?(:'account_id')
208
+ self.account_id = attributes[:'account_id']
209
+ end
210
+
211
+ if attributes.key?(:'year_month_day')
212
+ self.year_month_day = attributes[:'year_month_day']
213
+ end
214
+
215
+ if attributes.key?(:'resets_on')
216
+ self.resets_on = attributes[:'resets_on']
217
+ end
218
+
219
+ if attributes.key?(:'percent')
220
+ self.percent = attributes[:'percent']
221
+ end
222
+
223
+ if attributes.key?(:'spent')
224
+ self.spent = attributes[:'spent']
225
+ end
226
+
227
+ if attributes.key?(:'cost_cap')
228
+ self.cost_cap = attributes[:'cost_cap']
229
+ end
230
+
231
+ if attributes.key?(:'auto_upgrade')
232
+ self.auto_upgrade = attributes[:'auto_upgrade']
233
+ end
234
+
235
+ if attributes.key?(:'usage')
236
+ if (value = attributes[:'usage']).is_a?(Hash)
237
+ self.usage = value
238
+ end
239
+ end
166
240
  end
167
241
 
168
242
  # Show invalid properties with the reasons. Usually used together with valid?
@@ -198,7 +272,7 @@ module Pingram
198
272
  def valid?
199
273
  warn '[DEPRECATED] the `valid?` method is obsolete'
200
274
  return false if @event_type.nil?
201
- event_type_validator = EnumAttributeValidator.new('String', ["EMAIL_OPEN", "EMAIL_CLICK", "EMAIL_FAILED", "EMAIL_DELIVERED", "EMAIL_UNSUBSCRIBE", "EMAIL_INBOUND", "INAPP_WEB_FAILED", "INAPP_WEB_UNSUBSCRIBE", "SMS_DELIVERED", "SMS_FAILED", "SMS_UNSUBSCRIBE", "SMS_SUBSCRIBE", "SMS_INBOUND", "PUSH_FAILED", "PUSH_UNSUBSCRIBE", "CALL_FAILED", "CALL_UNSUBSCRIBE", "WEB_PUSH_FAILED", "WEB_PUSH_UNSUBSCRIBE", "SLACK_FAILED", "SLACK_UNSUBSCRIBE"])
275
+ event_type_validator = EnumAttributeValidator.new('String', ["EMAIL_OPEN", "EMAIL_CLICK", "EMAIL_FAILED", "EMAIL_DELIVERED", "EMAIL_UNSUBSCRIBE", "EMAIL_INBOUND", "INAPP_WEB_FAILED", "INAPP_WEB_UNSUBSCRIBE", "SMS_DELIVERED", "SMS_FAILED", "SMS_UNSUBSCRIBE", "SMS_SUBSCRIBE", "SMS_INBOUND", "PUSH_FAILED", "PUSH_UNSUBSCRIBE", "CALL_FAILED", "CALL_UNSUBSCRIBE", "WEB_PUSH_FAILED", "WEB_PUSH_UNSUBSCRIBE", "SLACK_FAILED", "SLACK_UNSUBSCRIBE", "ACCOUNT_USAGE"])
202
276
  return false unless event_type_validator.valid?(@event_type)
203
277
  return false if @channel.nil?
204
278
  return false if @user_id.nil?
@@ -210,7 +284,7 @@ module Pingram
210
284
  # Custom attribute writer method checking allowed values (enum).
211
285
  # @param [Object] event_type Object to be assigned
212
286
  def event_type=(event_type)
213
- validator = EnumAttributeValidator.new('String', ["EMAIL_OPEN", "EMAIL_CLICK", "EMAIL_FAILED", "EMAIL_DELIVERED", "EMAIL_UNSUBSCRIBE", "EMAIL_INBOUND", "INAPP_WEB_FAILED", "INAPP_WEB_UNSUBSCRIBE", "SMS_DELIVERED", "SMS_FAILED", "SMS_UNSUBSCRIBE", "SMS_SUBSCRIBE", "SMS_INBOUND", "PUSH_FAILED", "PUSH_UNSUBSCRIBE", "CALL_FAILED", "CALL_UNSUBSCRIBE", "WEB_PUSH_FAILED", "WEB_PUSH_UNSUBSCRIBE", "SLACK_FAILED", "SLACK_UNSUBSCRIBE"])
287
+ validator = EnumAttributeValidator.new('String', ["EMAIL_OPEN", "EMAIL_CLICK", "EMAIL_FAILED", "EMAIL_DELIVERED", "EMAIL_UNSUBSCRIBE", "EMAIL_INBOUND", "INAPP_WEB_FAILED", "INAPP_WEB_UNSUBSCRIBE", "SMS_DELIVERED", "SMS_FAILED", "SMS_UNSUBSCRIBE", "SMS_SUBSCRIBE", "SMS_INBOUND", "PUSH_FAILED", "PUSH_UNSUBSCRIBE", "CALL_FAILED", "CALL_UNSUBSCRIBE", "WEB_PUSH_FAILED", "WEB_PUSH_UNSUBSCRIBE", "SLACK_FAILED", "SLACK_UNSUBSCRIBE", "ACCOUNT_USAGE"])
214
288
  unless validator.valid?(event_type)
215
289
  fail ArgumentError, "invalid value for \"event_type\", must be one of #{validator.allowable_values}."
216
290
  end
@@ -269,7 +343,15 @@ module Pingram
269
343
  tracking_id == o.tracking_id &&
270
344
  failure_code == o.failure_code &&
271
345
  clicked_link == o.clicked_link &&
272
- clicked_link_tags == o.clicked_link_tags
346
+ clicked_link_tags == o.clicked_link_tags &&
347
+ account_id == o.account_id &&
348
+ year_month_day == o.year_month_day &&
349
+ resets_on == o.resets_on &&
350
+ percent == o.percent &&
351
+ spent == o.spent &&
352
+ cost_cap == o.cost_cap &&
353
+ auto_upgrade == o.auto_upgrade &&
354
+ usage == o.usage
273
355
  end
274
356
 
275
357
  # @see the `==` method
@@ -281,7 +363,7 @@ module Pingram
281
363
  # Calculates hash code according to all attributes.
282
364
  # @return [Integer] Hash code
283
365
  def hash
284
- [event_type, channel, user_id, notification_id, tracking_id, failure_code, clicked_link, clicked_link_tags].hash
366
+ [event_type, channel, user_id, notification_id, tracking_id, failure_code, clicked_link, clicked_link_tags, account_id, year_month_day, resets_on, percent, spent, cost_cap, auto_upgrade, usage].hash
285
367
  end
286
368
 
287
369
  # Builds the object from hash