svix 0.83.1 → 0.84.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (70) hide show
  1. checksums.yaml +4 -4
  2. data/Gemfile.lock +1 -1
  3. data/lib/svix/api/application_api.rb +247 -181
  4. data/lib/svix/api/authentication_api.rb +82 -150
  5. data/lib/svix/api/background_tasks_api.rb +161 -0
  6. data/lib/svix/api/endpoint_api.rb +561 -485
  7. data/lib/svix/api/environment_api.rb +16 -16
  8. data/lib/svix/api/environment_settings_api.rb +7 -10
  9. data/lib/svix/api/event_type_api.rb +152 -81
  10. data/lib/svix/api/health_api.rb +6 -9
  11. data/lib/svix/api/integration_api.rb +123 -134
  12. data/lib/svix/api/message_api.rb +96 -102
  13. data/lib/svix/api/message_attempt_api.rb +382 -406
  14. data/lib/svix/api/statistics_api.rb +107 -45
  15. data/lib/svix/api_client.rb +0 -1
  16. data/lib/svix/application_api.rb +22 -22
  17. data/lib/svix/authentication_api.rb +3 -3
  18. data/lib/svix/configuration.rb +0 -7
  19. data/lib/svix/endpoint_api.rb +16 -16
  20. data/lib/svix/event_type_api.rb +19 -19
  21. data/lib/svix/integration_api.rb +26 -26
  22. data/lib/svix/message_api.rb +4 -4
  23. data/lib/svix/message_attempt_api.rb +8 -8
  24. data/lib/svix/models/app_portal_access_in.rb +1 -0
  25. data/lib/svix/models/application_in.rb +34 -1
  26. data/lib/svix/models/application_out.rb +20 -2
  27. data/lib/svix/models/application_patch.rb +299 -0
  28. data/lib/svix/models/application_stats.rb +0 -1
  29. data/lib/svix/models/{webhook_types.rb → background_task_out.rb} +40 -69
  30. data/lib/svix/models/background_task_out_common.rb +251 -0
  31. data/lib/svix/models/background_task_status.rb +38 -0
  32. data/lib/svix/models/background_task_type.rb +38 -0
  33. data/lib/svix/models/calculate_app_stats_in.rb +255 -0
  34. data/lib/svix/models/endpoint_created_event.rb +5 -0
  35. data/lib/svix/models/endpoint_created_event_data.rb +0 -2
  36. data/lib/svix/models/endpoint_deleted_event.rb +5 -0
  37. data/lib/svix/models/endpoint_deleted_event_data.rb +0 -2
  38. data/lib/svix/models/endpoint_disabled_event.rb +5 -0
  39. data/lib/svix/models/endpoint_disabled_event_data.rb +1 -2
  40. data/lib/svix/models/endpoint_in.rb +19 -10
  41. data/lib/svix/models/endpoint_message_out.rb +1 -0
  42. data/lib/svix/models/endpoint_out.rb +33 -15
  43. data/lib/svix/models/endpoint_patch.rb +405 -0
  44. data/lib/svix/models/endpoint_secret_rotate_in.rb +2 -0
  45. data/lib/svix/models/endpoint_transformation_in.rb +0 -2
  46. data/lib/svix/models/endpoint_transformation_simulate_in.rb +6 -0
  47. data/lib/svix/models/endpoint_update.rb +19 -10
  48. data/lib/svix/models/endpoint_updated_event.rb +5 -0
  49. data/lib/svix/models/endpoint_updated_event_data.rb +0 -2
  50. data/lib/svix/models/event_type_example_out.rb +4 -2
  51. data/lib/svix/models/event_type_patch.rb +275 -0
  52. data/lib/svix/models/event_type_schema_in.rb +0 -1
  53. data/lib/svix/models/http_validation_error.rb +5 -0
  54. data/lib/svix/models/list_response_application_stats.rb +15 -5
  55. data/lib/svix/models/list_response_background_task_out.rb +259 -0
  56. data/lib/svix/models/list_response_integration_out.rb +15 -5
  57. data/lib/svix/models/list_response_message_endpoint_out.rb +15 -5
  58. data/lib/svix/models/message_attempt_exhausted_event.rb +5 -0
  59. data/lib/svix/models/message_attempt_exhausted_event_data.rb +1 -2
  60. data/lib/svix/models/message_attempt_failing_event.rb +5 -0
  61. data/lib/svix/models/message_attempt_failing_event_data.rb +1 -2
  62. data/lib/svix/models/message_attempt_headers_out.rb +27 -1
  63. data/lib/svix/models/message_endpoint_out.rb +45 -29
  64. data/lib/svix/models/message_in.rb +0 -1
  65. data/lib/svix/models/{one_time_token_out.rb → recover_out.rb} +41 -13
  66. data/lib/svix/models/{one_time_token_in.rb → replay_out.rb} +41 -13
  67. data/lib/svix/models/transformation_http_method.rb +1 -1
  68. data/lib/svix/models/validation_error.rb +4 -0
  69. data/lib/svix/version.rb +1 -1
  70. metadata +14 -5
@@ -75,7 +75,6 @@ module Svix
75
75
  Set.new([
76
76
  :'channels',
77
77
  :'filter_types',
78
- :'metadata',
79
78
  :'rate_limit',
80
79
  :'uid',
81
80
  ])
@@ -159,10 +158,6 @@ module Svix
159
158
  invalid_properties.push('invalid value for "filter_types", number of items must be greater than or equal to 1.')
160
159
  end
161
160
 
162
- if !@rate_limit.nil? && @rate_limit > 65535
163
- invalid_properties.push('invalid value for "rate_limit", must be smaller than or equal to 65535.')
164
- end
165
-
166
161
  if !@rate_limit.nil? && @rate_limit < 1
167
162
  invalid_properties.push('invalid value for "rate_limit", must be greater than or equal to 1.')
168
163
  end
@@ -196,6 +191,10 @@ module Svix
196
191
  invalid_properties.push('invalid value for "version", version cannot be nil.')
197
192
  end
198
193
 
194
+ if @version < 1
195
+ invalid_properties.push('invalid value for "version", must be greater than or equal to 1.')
196
+ end
197
+
199
198
  invalid_properties
200
199
  end
201
200
 
@@ -205,7 +204,6 @@ module Svix
205
204
  return false if !@channels.nil? && @channels.length > 10
206
205
  return false if !@channels.nil? && @channels.length < 1
207
206
  return false if !@filter_types.nil? && @filter_types.length < 1
208
- return false if !@rate_limit.nil? && @rate_limit > 65535
209
207
  return false if !@rate_limit.nil? && @rate_limit < 1
210
208
  return false if !@uid.nil? && @uid.to_s.length > 256
211
209
  return false if !@uid.nil? && @uid.to_s.length < 1
@@ -214,6 +212,7 @@ module Svix
214
212
  return false if @url.to_s.length > 65536
215
213
  return false if @url.to_s.length < 1
216
214
  return false if @version.nil?
215
+ return false if @version < 1
217
216
  true
218
217
  end
219
218
 
@@ -244,10 +243,6 @@ module Svix
244
243
  # Custom attribute writer method with validation
245
244
  # @param [Object] rate_limit Value to be assigned
246
245
  def rate_limit=(rate_limit)
247
- if !rate_limit.nil? && rate_limit > 65535
248
- fail ArgumentError, 'invalid value for "rate_limit", must be smaller than or equal to 65535.'
249
- end
250
-
251
246
  if !rate_limit.nil? && rate_limit < 1
252
247
  fail ArgumentError, 'invalid value for "rate_limit", must be greater than or equal to 1.'
253
248
  end
@@ -292,6 +287,20 @@ module Svix
292
287
  @url = url
293
288
  end
294
289
 
290
+ # Custom attribute writer method with validation
291
+ # @param [Object] version Value to be assigned
292
+ def version=(version)
293
+ if version.nil?
294
+ fail ArgumentError, 'version cannot be nil'
295
+ end
296
+
297
+ if version < 1
298
+ fail ArgumentError, 'invalid value for "version", must be greater than or equal to 1.'
299
+ end
300
+
301
+ @version = version
302
+ end
303
+
295
304
  # Checks equality by comparing each attribute.
296
305
  # @param [Object] Object to be compared
297
306
  def ==(o)
@@ -103,6 +103,10 @@ module Svix
103
103
  invalid_properties.push('invalid value for "data", data cannot be nil.')
104
104
  end
105
105
 
106
+ if @type.nil?
107
+ invalid_properties.push('invalid value for "type", type cannot be nil.')
108
+ end
109
+
106
110
  invalid_properties
107
111
  end
108
112
 
@@ -110,6 +114,7 @@ module Svix
110
114
  # @return true if the model is valid
111
115
  def valid?
112
116
  return false if @data.nil?
117
+ return false if @type.nil?
113
118
  type_validator = EnumAttributeValidator.new('String', ["endpoint.updated"])
114
119
  return false unless type_validator.valid?(@type)
115
120
  true
@@ -17,12 +17,10 @@ module Svix
17
17
  class EndpointUpdatedEventData
18
18
  attr_accessor :app_id
19
19
 
20
- # Optional unique identifier for the application
21
20
  attr_accessor :app_uid
22
21
 
23
22
  attr_accessor :endpoint_id
24
23
 
25
- # Optional unique identifier for the endpoint
26
24
  attr_accessor :endpoint_uid
27
25
 
28
26
  # Attribute mapping from ruby-style variable name to JSON key.
@@ -32,7 +32,7 @@ module Svix
32
32
  # Attribute type mapping.
33
33
  def self.openapi_types
34
34
  {
35
- :'example' => :'Object'
35
+ :'example' => :'Hash<String, Object>'
36
36
  }
37
37
  end
38
38
 
@@ -58,7 +58,9 @@ module Svix
58
58
  }
59
59
 
60
60
  if attributes.key?(:'example')
61
- self.example = attributes[:'example']
61
+ if (value = attributes[:'example']).is_a?(Hash)
62
+ self.example = value
63
+ end
62
64
  end
63
65
  end
64
66
 
@@ -0,0 +1,275 @@
1
+ =begin
2
+ #Svix API
3
+
4
+ #Welcome to the Svix API documentation! Useful links: [Homepage](https://www.svix.com) | [Support email](mailto:support+docs@svix.com) | [Blog](https://www.svix.com/blog/) | [Slack Community](https://www.svix.com/slack/) # Introduction This is the reference documentation and schemas for the [Svix webhook service](https://www.svix.com) API. For tutorials and other documentation please refer to [the documentation](https://docs.svix.com). ## Main concepts In Svix you have four important entities you will be interacting with: - `messages`: these are the webhooks being sent. They can have contents and a few other properties. - `application`: this is where `messages` are sent to. Usually you want to create one application for each user on your platform. - `endpoint`: endpoints are the URLs messages will be sent to. Each application can have multiple `endpoints` and each message sent to that application will be sent to all of them (unless they are not subscribed to the sent event type). - `event-type`: event types are identifiers denoting the type of the message being sent. Event types are primarily used to decide which events are sent to which endpoint. ## Authentication Get your authentication token (`AUTH_TOKEN`) from the [Svix dashboard](https://dashboard.svix.com) and use it as part of the `Authorization` header as such: `Authorization: Bearer ${AUTH_TOKEN}`. <SecurityDefinitions /> ## Code samples The code samples assume you already have the respective libraries installed and you know how to use them. For the latest information on how to do that, please refer to [the documentation](https://docs.svix.com/). ## Idempotency Svix supports [idempotency](https://en.wikipedia.org/wiki/Idempotence) for safely retrying requests without accidentally performing the same operation twice. This is useful when an API call is disrupted in transit and you do not receive a response. To perform an idempotent request, pass the idempotency key in the `Idempotency-Key` header to the request. The idempotency key should be a unique value generated by the client. You can create the key in however way you like, though we suggest using UUID v4, or any other string with enough entropy to avoid collisions. Svix's idempotency works by saving the resulting status code and body of the first request made for any given idempotency key for any successful request. Subsequent requests with the same key return the same result. Please note that idempotency is only supported for `POST` requests. ## Cross-Origin Resource Sharing This API features Cross-Origin Resource Sharing (CORS) implemented in compliance with [W3C spec](https://www.w3.org/TR/cors/). And that allows cross-domain communication from the browser. All responses have a wildcard same-origin which makes them completely public and accessible to everyone, including any code on any site.
5
+
6
+ The version of the OpenAPI document: 1.4
7
+
8
+ Generated by: https://openapi-generator.tech
9
+ OpenAPI Generator version: 5.2.0
10
+
11
+ =end
12
+
13
+ require 'date'
14
+ require 'time'
15
+
16
+ module Svix
17
+ class EventTypePatch
18
+ attr_accessor :archived
19
+
20
+ attr_accessor :description
21
+
22
+ attr_accessor :feature_flag
23
+
24
+ attr_accessor :schemas
25
+
26
+ # Attribute mapping from ruby-style variable name to JSON key.
27
+ def self.attribute_map
28
+ {
29
+ :'archived' => :'archived',
30
+ :'description' => :'description',
31
+ :'feature_flag' => :'featureFlag',
32
+ :'schemas' => :'schemas'
33
+ }
34
+ end
35
+
36
+ # Returns all the JSON keys this model knows about
37
+ def self.acceptable_attributes
38
+ attribute_map.values
39
+ end
40
+
41
+ # Attribute type mapping.
42
+ def self.openapi_types
43
+ {
44
+ :'archived' => :'Boolean',
45
+ :'description' => :'String',
46
+ :'feature_flag' => :'String',
47
+ :'schemas' => :'Hash<String, Object>'
48
+ }
49
+ end
50
+
51
+ # List of attributes with nullable: true
52
+ def self.openapi_nullable
53
+ Set.new([
54
+ :'feature_flag',
55
+ :'schemas'
56
+ ])
57
+ end
58
+
59
+ # Initializes the object
60
+ # @param [Hash] attributes Model attributes in the form of hash
61
+ def initialize(attributes = {})
62
+ if (!attributes.is_a?(Hash))
63
+ fail ArgumentError, "The input argument (attributes) must be a hash in `Svix::EventTypePatch` initialize method"
64
+ end
65
+
66
+ # check to see if the attribute exists and convert string to symbol for hash key
67
+ attributes = attributes.each_with_object({}) { |(k, v), h|
68
+ if (!self.class.attribute_map.key?(k.to_sym))
69
+ fail ArgumentError, "`#{k}` is not a valid attribute in `Svix::EventTypePatch`. Please check the name to make sure it's valid. List of attributes: " + self.class.attribute_map.keys.inspect
70
+ end
71
+ h[k.to_sym] = v
72
+ }
73
+
74
+ if attributes.key?(:'archived')
75
+ self.archived = attributes[:'archived']
76
+ end
77
+
78
+ if attributes.key?(:'description')
79
+ self.description = attributes[:'description']
80
+ end
81
+
82
+ if attributes.key?(:'feature_flag')
83
+ self.feature_flag = attributes[:'feature_flag']
84
+ end
85
+
86
+ if attributes.key?(:'schemas')
87
+ if (value = attributes[:'schemas']).is_a?(Hash)
88
+ self.schemas = value
89
+ end
90
+ end
91
+ end
92
+
93
+ # Show invalid properties with the reasons. Usually used together with valid?
94
+ # @return Array for valid properties with the reasons
95
+ def list_invalid_properties
96
+ invalid_properties = Array.new
97
+ if !@feature_flag.nil? && @feature_flag.to_s.length > 256
98
+ invalid_properties.push('invalid value for "feature_flag", the character length must be smaller than or equal to 256.')
99
+ end
100
+
101
+ pattern = Regexp.new(/^[a-zA-Z0-9\-_.]+$/)
102
+ if !@feature_flag.nil? && @feature_flag !~ pattern
103
+ invalid_properties.push("invalid value for \"feature_flag\", must conform to the pattern #{pattern}.")
104
+ end
105
+
106
+ invalid_properties
107
+ end
108
+
109
+ # Check to see if the all the properties in the model are valid
110
+ # @return true if the model is valid
111
+ def valid?
112
+ return false if !@feature_flag.nil? && @feature_flag.to_s.length > 256
113
+ return false if !@feature_flag.nil? && @feature_flag !~ Regexp.new(/^[a-zA-Z0-9\-_.]+$/)
114
+ true
115
+ end
116
+
117
+ # Custom attribute writer method with validation
118
+ # @param [Object] feature_flag Value to be assigned
119
+ def feature_flag=(feature_flag)
120
+ if !feature_flag.nil? && feature_flag.to_s.length > 256
121
+ fail ArgumentError, 'invalid value for "feature_flag", the character length must be smaller than or equal to 256.'
122
+ end
123
+
124
+ pattern = Regexp.new(/^[a-zA-Z0-9\-_.]+$/)
125
+ if !feature_flag.nil? && feature_flag !~ pattern
126
+ fail ArgumentError, "invalid value for \"feature_flag\", must conform to the pattern #{pattern}."
127
+ end
128
+
129
+ @feature_flag = feature_flag
130
+ end
131
+
132
+ # Checks equality by comparing each attribute.
133
+ # @param [Object] Object to be compared
134
+ def ==(o)
135
+ return true if self.equal?(o)
136
+ self.class == o.class &&
137
+ archived == o.archived &&
138
+ description == o.description &&
139
+ feature_flag == o.feature_flag &&
140
+ schemas == o.schemas
141
+ end
142
+
143
+ # @see the `==` method
144
+ # @param [Object] Object to be compared
145
+ def eql?(o)
146
+ self == o
147
+ end
148
+
149
+ # Calculates hash code according to all attributes.
150
+ # @return [Integer] Hash code
151
+ def hash
152
+ [archived, description, feature_flag, schemas].hash
153
+ end
154
+
155
+ # Builds the object from hash
156
+ # @param [Hash] attributes Model attributes in the form of hash
157
+ # @return [Object] Returns the model itself
158
+ def self.build_from_hash(attributes)
159
+ new.build_from_hash(attributes)
160
+ end
161
+
162
+ # Builds the object from hash
163
+ # @param [Hash] attributes Model attributes in the form of hash
164
+ # @return [Object] Returns the model itself
165
+ def build_from_hash(attributes)
166
+ return nil unless attributes.is_a?(Hash)
167
+ self.class.openapi_types.each_pair do |key, type|
168
+ if attributes[self.class.attribute_map[key]].nil? && self.class.openapi_nullable.include?(key)
169
+ self.send("#{key}=", nil)
170
+ elsif type =~ /\AArray<(.*)>/i
171
+ # check to ensure the input is an array given that the attribute
172
+ # is documented as an array but the input is not
173
+ if attributes[self.class.attribute_map[key]].is_a?(Array)
174
+ self.send("#{key}=", attributes[self.class.attribute_map[key]].map { |v| _deserialize($1, v) })
175
+ end
176
+ elsif !attributes[self.class.attribute_map[key]].nil?
177
+ self.send("#{key}=", _deserialize(type, attributes[self.class.attribute_map[key]]))
178
+ end
179
+ end
180
+
181
+ self
182
+ end
183
+
184
+ # Deserializes the data based on type
185
+ # @param string type Data type
186
+ # @param string value Value to be deserialized
187
+ # @return [Object] Deserialized data
188
+ def _deserialize(type, value)
189
+ case type.to_sym
190
+ when :Time
191
+ Time.parse(value)
192
+ when :Date
193
+ Date.parse(value)
194
+ when :String
195
+ value.to_s
196
+ when :Integer
197
+ value.to_i
198
+ when :Float
199
+ value.to_f
200
+ when :Boolean
201
+ if value.to_s =~ /\A(true|t|yes|y|1)\z/i
202
+ true
203
+ else
204
+ false
205
+ end
206
+ when :Object
207
+ # generic object (usually a Hash), return directly
208
+ value
209
+ when /\AArray<(?<inner_type>.+)>\z/
210
+ inner_type = Regexp.last_match[:inner_type]
211
+ value.map { |v| _deserialize(inner_type, v) }
212
+ when /\AHash<(?<k_type>.+?), (?<v_type>.+)>\z/
213
+ k_type = Regexp.last_match[:k_type]
214
+ v_type = Regexp.last_match[:v_type]
215
+ {}.tap do |hash|
216
+ value.each do |k, v|
217
+ hash[_deserialize(k_type, k)] = _deserialize(v_type, v)
218
+ end
219
+ end
220
+ else # model
221
+ # models (e.g. Pet) or oneOf
222
+ klass = Svix.const_get(type)
223
+ klass.respond_to?(:openapi_one_of) ? klass.build(value) : klass.build_from_hash(value)
224
+ end
225
+ end
226
+
227
+ # Returns the string representation of the object
228
+ # @return [String] String presentation of the object
229
+ def to_s
230
+ to_hash.to_s
231
+ end
232
+
233
+ # to_body is an alias to to_hash (backward compatibility)
234
+ # @return [Hash] Returns the object in the form of hash
235
+ def to_body
236
+ to_hash
237
+ end
238
+
239
+ # Returns the object in the form of hash
240
+ # @return [Hash] Returns the object in the form of hash
241
+ def to_hash
242
+ hash = {}
243
+ self.class.attribute_map.each_pair do |attr, param|
244
+ value = self.send(attr)
245
+ if value.nil?
246
+ is_nullable = self.class.openapi_nullable.include?(attr)
247
+ next if !is_nullable || (is_nullable && !instance_variable_defined?(:"@#{attr}"))
248
+ end
249
+
250
+ hash[param] = _to_hash(value)
251
+ end
252
+ hash
253
+ end
254
+
255
+ # Outputs non-array value in the form of hash
256
+ # For object, use to_hash. Otherwise, just return the value
257
+ # @param [Object] value Any valid value
258
+ # @return [Hash] Returns the value in the form of hash
259
+ def _to_hash(value)
260
+ if value.is_a?(Array)
261
+ value.compact.map { |v| _to_hash(v) }
262
+ elsif value.is_a?(Hash)
263
+ {}.tap do |hash|
264
+ value.each { |k, v| hash[k] = _to_hash(v) }
265
+ end
266
+ elsif value.respond_to? :to_hash
267
+ value.to_hash
268
+ else
269
+ value
270
+ end
271
+ end
272
+
273
+ end
274
+
275
+ end
@@ -15,7 +15,6 @@ require 'time'
15
15
 
16
16
  module Svix
17
17
  class EventTypeSchemaIn
18
- # The schema for an event type
19
18
  attr_accessor :schema
20
19
 
21
20
  # Attribute mapping from ruby-style variable name to JSON key.
@@ -68,12 +68,17 @@ module Svix
68
68
  # @return Array for valid properties with the reasons
69
69
  def list_invalid_properties
70
70
  invalid_properties = Array.new
71
+ if @detail.nil?
72
+ invalid_properties.push('invalid value for "detail", detail cannot be nil.')
73
+ end
74
+
71
75
  invalid_properties
72
76
  end
73
77
 
74
78
  # Check to see if the all the properties in the model are valid
75
79
  # @return true if the model is valid
76
80
  def valid?
81
+ return false if @detail.nil?
77
82
  true
78
83
  end
79
84
 
@@ -21,12 +21,15 @@ module Svix
21
21
 
22
22
  attr_accessor :iterator
23
23
 
24
+ attr_accessor :prev_iterator
25
+
24
26
  # Attribute mapping from ruby-style variable name to JSON key.
25
27
  def self.attribute_map
26
28
  {
27
29
  :'data' => :'data',
28
30
  :'done' => :'done',
29
- :'iterator' => :'iterator'
31
+ :'iterator' => :'iterator',
32
+ :'prev_iterator' => :'prevIterator'
30
33
  }
31
34
  end
32
35
 
@@ -40,14 +43,16 @@ module Svix
40
43
  {
41
44
  :'data' => :'Array<ApplicationStats>',
42
45
  :'done' => :'Boolean',
43
- :'iterator' => :'String'
46
+ :'iterator' => :'String',
47
+ :'prev_iterator' => :'String'
44
48
  }
45
49
  end
46
50
 
47
51
  # List of attributes with nullable: true
48
52
  def self.openapi_nullable
49
53
  Set.new([
50
- :'iterator'
54
+ :'iterator',
55
+ :'prev_iterator'
51
56
  ])
52
57
  end
53
58
 
@@ -79,6 +84,10 @@ module Svix
79
84
  if attributes.key?(:'iterator')
80
85
  self.iterator = attributes[:'iterator']
81
86
  end
87
+
88
+ if attributes.key?(:'prev_iterator')
89
+ self.prev_iterator = attributes[:'prev_iterator']
90
+ end
82
91
  end
83
92
 
84
93
  # Show invalid properties with the reasons. Usually used together with valid?
@@ -111,7 +120,8 @@ module Svix
111
120
  self.class == o.class &&
112
121
  data == o.data &&
113
122
  done == o.done &&
114
- iterator == o.iterator
123
+ iterator == o.iterator &&
124
+ prev_iterator == o.prev_iterator
115
125
  end
116
126
 
117
127
  # @see the `==` method
@@ -123,7 +133,7 @@ module Svix
123
133
  # Calculates hash code according to all attributes.
124
134
  # @return [Integer] Hash code
125
135
  def hash
126
- [data, done, iterator].hash
136
+ [data, done, iterator, prev_iterator].hash
127
137
  end
128
138
 
129
139
  # Builds the object from hash