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
@@ -19,52 +19,69 @@ module Svix
19
19
  def initialize(api_client = ApiClient.default)
20
20
  @api_client = api_client
21
21
  end
22
- # Create Endpoint
23
- # Create a new endpoint for the application. When `secret` is `null` the secret is automatically generated (recommended)
22
+ # Patch Endpoint
23
+ # Partially update an endpoint.
24
24
  # @param app_id [String]
25
- # @param endpoint_in [EndpointIn]
25
+ # @param endpoint_id [String]
26
+ # @param endpoint_patch [EndpointPatch]
26
27
  # @param [Hash] opts the optional parameters
27
- # @option opts [String] :idempotency_key The request's idempotency key
28
28
  # @return [EndpointOut]
29
- def create_endpoint_api_v1_app_app_id_endpoint_post(app_id, endpoint_in, opts = {})
30
- data, _status_code, _headers = create_endpoint_api_v1_app_app_id_endpoint_post_with_http_info(app_id, endpoint_in, opts)
29
+ def patch_endpoint(app_id, endpoint_id, endpoint_patch, opts = {})
30
+ data, _status_code, _headers = patch_endpoint_with_http_info(app_id, endpoint_id, endpoint_patch, opts)
31
31
  data
32
32
  end
33
33
 
34
- # Create Endpoint
35
- # Create a new endpoint for the application. When `secret` is `null` the secret is automatically generated (recommended)
34
+ # Patch Endpoint
35
+ # Partially update an endpoint.
36
36
  # @param app_id [String]
37
- # @param endpoint_in [EndpointIn]
37
+ # @param endpoint_id [String]
38
+ # @param endpoint_patch [EndpointPatch]
38
39
  # @param [Hash] opts the optional parameters
39
- # @option opts [String] :idempotency_key The request's idempotency key
40
40
  # @return [Array<(EndpointOut, Integer, Hash)>] EndpointOut data, response status code and response headers
41
- def create_endpoint_api_v1_app_app_id_endpoint_post_with_http_info(app_id, endpoint_in, opts = {})
41
+ def patch_endpoint_with_http_info(app_id, endpoint_id, endpoint_patch, opts = {})
42
42
  if @api_client.config.debugging
43
- @api_client.config.logger.debug 'Calling API: EndpointApi.create_endpoint_api_v1_app_app_id_endpoint_post ...'
43
+ @api_client.config.logger.debug 'Calling API: EndpointApi.patch_endpoint ...'
44
44
  end
45
45
  # verify the required parameter 'app_id' is set
46
46
  if @api_client.config.client_side_validation && app_id.nil?
47
- fail ArgumentError, "Missing the required parameter 'app_id' when calling EndpointApi.create_endpoint_api_v1_app_app_id_endpoint_post"
47
+ fail ArgumentError, "Missing the required parameter 'app_id' when calling EndpointApi.patch_endpoint"
48
48
  end
49
49
  if @api_client.config.client_side_validation && app_id.to_s.length > 256
50
- fail ArgumentError, 'invalid value for "app_id" when calling EndpointApi.create_endpoint_api_v1_app_app_id_endpoint_post, the character length must be smaller than or equal to 256.'
50
+ fail ArgumentError, 'invalid value for "app_id" when calling EndpointApi.patch_endpoint, the character length must be smaller than or equal to 256.'
51
51
  end
52
52
 
53
53
  if @api_client.config.client_side_validation && app_id.to_s.length < 1
54
- fail ArgumentError, 'invalid value for "app_id" when calling EndpointApi.create_endpoint_api_v1_app_app_id_endpoint_post, the character length must be great than or equal to 1.'
54
+ fail ArgumentError, 'invalid value for "app_id" when calling EndpointApi.patch_endpoint, the character length must be great than or equal to 1.'
55
55
  end
56
56
 
57
57
  pattern = Regexp.new(/^[a-zA-Z0-9\-_.]+$/)
58
58
  if @api_client.config.client_side_validation && app_id !~ pattern
59
- fail ArgumentError, "invalid value for 'app_id' when calling EndpointApi.create_endpoint_api_v1_app_app_id_endpoint_post, must conform to the pattern #{pattern}."
59
+ fail ArgumentError, "invalid value for 'app_id' when calling EndpointApi.patch_endpoint, must conform to the pattern #{pattern}."
60
60
  end
61
61
 
62
- # verify the required parameter 'endpoint_in' is set
63
- if @api_client.config.client_side_validation && endpoint_in.nil?
64
- fail ArgumentError, "Missing the required parameter 'endpoint_in' when calling EndpointApi.create_endpoint_api_v1_app_app_id_endpoint_post"
62
+ # verify the required parameter 'endpoint_id' is set
63
+ if @api_client.config.client_side_validation && endpoint_id.nil?
64
+ fail ArgumentError, "Missing the required parameter 'endpoint_id' when calling EndpointApi.patch_endpoint"
65
+ end
66
+ if @api_client.config.client_side_validation && endpoint_id.to_s.length > 256
67
+ fail ArgumentError, 'invalid value for "endpoint_id" when calling EndpointApi.patch_endpoint, the character length must be smaller than or equal to 256.'
68
+ end
69
+
70
+ if @api_client.config.client_side_validation && endpoint_id.to_s.length < 1
71
+ fail ArgumentError, 'invalid value for "endpoint_id" when calling EndpointApi.patch_endpoint, the character length must be great than or equal to 1.'
72
+ end
73
+
74
+ pattern = Regexp.new(/^[a-zA-Z0-9\-_.]+$/)
75
+ if @api_client.config.client_side_validation && endpoint_id !~ pattern
76
+ fail ArgumentError, "invalid value for 'endpoint_id' when calling EndpointApi.patch_endpoint, must conform to the pattern #{pattern}."
77
+ end
78
+
79
+ # verify the required parameter 'endpoint_patch' is set
80
+ if @api_client.config.client_side_validation && endpoint_patch.nil?
81
+ fail ArgumentError, "Missing the required parameter 'endpoint_patch' when calling EndpointApi.patch_endpoint"
65
82
  end
66
83
  # resource path
67
- local_var_path = '/api/v1/app/{app_id}/endpoint/'.sub('{' + 'app_id' + '}', CGI.escape(app_id.to_s))
84
+ local_var_path = '/api/v1/app/{app_id}/endpoint/{endpoint_id}/'.sub('{' + 'app_id' + '}', CGI.escape(app_id.to_s)).sub('{' + 'endpoint_id' + '}', CGI.escape(endpoint_id.to_s))
68
85
 
69
86
  # query parameters
70
87
  query_params = opts[:query_params] || {}
@@ -75,22 +92,21 @@ module Svix
75
92
  header_params['Accept'] = @api_client.select_header_accept(['application/json'])
76
93
  # HTTP header 'Content-Type'
77
94
  header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])
78
- header_params[:'idempotency-key'] = opts[:'idempotency_key'] if !opts[:'idempotency_key'].nil?
79
95
 
80
96
  # form parameters
81
97
  form_params = opts[:form_params] || {}
82
98
 
83
99
  # http body (model)
84
- post_body = opts[:debug_body] || @api_client.object_to_http_body(endpoint_in)
100
+ post_body = opts[:debug_body] || @api_client.object_to_http_body(endpoint_patch)
85
101
 
86
102
  # return_type
87
103
  return_type = opts[:debug_return_type] || 'EndpointOut'
88
104
 
89
105
  # auth_names
90
- auth_names = opts[:debug_auth_names] || ['HTTPBearer']
106
+ auth_names = opts[:debug_auth_names] || []
91
107
 
92
108
  new_options = opts.merge(
93
- :operation => :"EndpointApi.create_endpoint_api_v1_app_app_id_endpoint_post",
109
+ :operation => :"EndpointApi.patch_endpoint",
94
110
  :header_params => header_params,
95
111
  :query_params => query_params,
96
112
  :form_params => form_params,
@@ -99,72 +115,59 @@ module Svix
99
115
  :return_type => return_type
100
116
  )
101
117
 
102
- data, status_code, headers = @api_client.call_api(:POST, local_var_path, new_options)
118
+ data, status_code, headers = @api_client.call_api(:PATCH, local_var_path, new_options)
103
119
  if @api_client.config.debugging
104
- @api_client.config.logger.debug "API called: EndpointApi#create_endpoint_api_v1_app_app_id_endpoint_post\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
120
+ @api_client.config.logger.debug "API called: EndpointApi#patch_endpoint\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
105
121
  end
106
122
  return data, status_code, headers
107
123
  end
108
124
 
109
- # Delete Endpoint
110
- # Delete an endpoint.
111
- # @param endpoint_id [String]
125
+ # Create Endpoint
126
+ # Create a new endpoint for the application. When `secret` is `null` the secret is automatically generated (recommended)
112
127
  # @param app_id [String]
128
+ # @param endpoint_in [EndpointIn]
113
129
  # @param [Hash] opts the optional parameters
114
130
  # @option opts [String] :idempotency_key The request&#39;s idempotency key
115
- # @return [nil]
116
- def delete_endpoint_api_v1_app_app_id_endpoint_endpoint_id_delete(endpoint_id, app_id, opts = {})
117
- delete_endpoint_api_v1_app_app_id_endpoint_endpoint_id_delete_with_http_info(endpoint_id, app_id, opts)
118
- nil
131
+ # @return [EndpointOut]
132
+ def v1_endpoint_create(app_id, endpoint_in, opts = {})
133
+ data, _status_code, _headers = v1_endpoint_create_with_http_info(app_id, endpoint_in, opts)
134
+ data
119
135
  end
120
136
 
121
- # Delete Endpoint
122
- # Delete an endpoint.
123
- # @param endpoint_id [String]
137
+ # Create Endpoint
138
+ # Create a new endpoint for the application. When &#x60;secret&#x60; is &#x60;null&#x60; the secret is automatically generated (recommended)
124
139
  # @param app_id [String]
140
+ # @param endpoint_in [EndpointIn]
125
141
  # @param [Hash] opts the optional parameters
126
142
  # @option opts [String] :idempotency_key The request&#39;s idempotency key
127
- # @return [Array<(nil, Integer, Hash)>] nil, response status code and response headers
128
- def delete_endpoint_api_v1_app_app_id_endpoint_endpoint_id_delete_with_http_info(endpoint_id, app_id, opts = {})
143
+ # @return [Array<(EndpointOut, Integer, Hash)>] EndpointOut data, response status code and response headers
144
+ def v1_endpoint_create_with_http_info(app_id, endpoint_in, opts = {})
129
145
  if @api_client.config.debugging
130
- @api_client.config.logger.debug 'Calling API: EndpointApi.delete_endpoint_api_v1_app_app_id_endpoint_endpoint_id_delete ...'
131
- end
132
- # verify the required parameter 'endpoint_id' is set
133
- if @api_client.config.client_side_validation && endpoint_id.nil?
134
- fail ArgumentError, "Missing the required parameter 'endpoint_id' when calling EndpointApi.delete_endpoint_api_v1_app_app_id_endpoint_endpoint_id_delete"
135
- end
136
- if @api_client.config.client_side_validation && endpoint_id.to_s.length > 256
137
- fail ArgumentError, 'invalid value for "endpoint_id" when calling EndpointApi.delete_endpoint_api_v1_app_app_id_endpoint_endpoint_id_delete, the character length must be smaller than or equal to 256.'
138
- end
139
-
140
- if @api_client.config.client_side_validation && endpoint_id.to_s.length < 1
141
- fail ArgumentError, 'invalid value for "endpoint_id" when calling EndpointApi.delete_endpoint_api_v1_app_app_id_endpoint_endpoint_id_delete, the character length must be great than or equal to 1.'
146
+ @api_client.config.logger.debug 'Calling API: EndpointApi.v1_endpoint_create ...'
142
147
  end
143
-
144
- pattern = Regexp.new(/^[a-zA-Z0-9\-_.]+$/)
145
- if @api_client.config.client_side_validation && endpoint_id !~ pattern
146
- fail ArgumentError, "invalid value for 'endpoint_id' when calling EndpointApi.delete_endpoint_api_v1_app_app_id_endpoint_endpoint_id_delete, must conform to the pattern #{pattern}."
147
- end
148
-
149
148
  # verify the required parameter 'app_id' is set
150
149
  if @api_client.config.client_side_validation && app_id.nil?
151
- fail ArgumentError, "Missing the required parameter 'app_id' when calling EndpointApi.delete_endpoint_api_v1_app_app_id_endpoint_endpoint_id_delete"
150
+ fail ArgumentError, "Missing the required parameter 'app_id' when calling EndpointApi.v1_endpoint_create"
152
151
  end
153
152
  if @api_client.config.client_side_validation && app_id.to_s.length > 256
154
- fail ArgumentError, 'invalid value for "app_id" when calling EndpointApi.delete_endpoint_api_v1_app_app_id_endpoint_endpoint_id_delete, the character length must be smaller than or equal to 256.'
153
+ fail ArgumentError, 'invalid value for "app_id" when calling EndpointApi.v1_endpoint_create, the character length must be smaller than or equal to 256.'
155
154
  end
156
155
 
157
156
  if @api_client.config.client_side_validation && app_id.to_s.length < 1
158
- fail ArgumentError, 'invalid value for "app_id" when calling EndpointApi.delete_endpoint_api_v1_app_app_id_endpoint_endpoint_id_delete, the character length must be great than or equal to 1.'
157
+ fail ArgumentError, 'invalid value for "app_id" when calling EndpointApi.v1_endpoint_create, the character length must be great than or equal to 1.'
159
158
  end
160
159
 
161
160
  pattern = Regexp.new(/^[a-zA-Z0-9\-_.]+$/)
162
161
  if @api_client.config.client_side_validation && app_id !~ pattern
163
- fail ArgumentError, "invalid value for 'app_id' when calling EndpointApi.delete_endpoint_api_v1_app_app_id_endpoint_endpoint_id_delete, must conform to the pattern #{pattern}."
162
+ fail ArgumentError, "invalid value for 'app_id' when calling EndpointApi.v1_endpoint_create, must conform to the pattern #{pattern}."
164
163
  end
165
164
 
165
+ # verify the required parameter 'endpoint_in' is set
166
+ if @api_client.config.client_side_validation && endpoint_in.nil?
167
+ fail ArgumentError, "Missing the required parameter 'endpoint_in' when calling EndpointApi.v1_endpoint_create"
168
+ end
166
169
  # resource path
167
- local_var_path = '/api/v1/app/{app_id}/endpoint/{endpoint_id}/'.sub('{' + 'endpoint_id' + '}', CGI.escape(endpoint_id.to_s)).sub('{' + 'app_id' + '}', CGI.escape(app_id.to_s))
170
+ local_var_path = '/api/v1/app/{app_id}/endpoint/'.sub('{' + 'app_id' + '}', CGI.escape(app_id.to_s))
168
171
 
169
172
  # query parameters
170
173
  query_params = opts[:query_params] || {}
@@ -173,22 +176,24 @@ module Svix
173
176
  header_params = opts[:header_params] || {}
174
177
  # HTTP header 'Accept' (if needed)
175
178
  header_params['Accept'] = @api_client.select_header_accept(['application/json'])
179
+ # HTTP header 'Content-Type'
180
+ header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])
176
181
  header_params[:'idempotency-key'] = opts[:'idempotency_key'] if !opts[:'idempotency_key'].nil?
177
182
 
178
183
  # form parameters
179
184
  form_params = opts[:form_params] || {}
180
185
 
181
186
  # http body (model)
182
- post_body = opts[:debug_body]
187
+ post_body = opts[:debug_body] || @api_client.object_to_http_body(endpoint_in)
183
188
 
184
189
  # return_type
185
- return_type = opts[:debug_return_type]
190
+ return_type = opts[:debug_return_type] || 'EndpointOut'
186
191
 
187
192
  # auth_names
188
- auth_names = opts[:debug_auth_names] || ['HTTPBearer']
193
+ auth_names = opts[:debug_auth_names] || []
189
194
 
190
195
  new_options = opts.merge(
191
- :operation => :"EndpointApi.delete_endpoint_api_v1_app_app_id_endpoint_endpoint_id_delete",
196
+ :operation => :"EndpointApi.v1_endpoint_create",
192
197
  :header_params => header_params,
193
198
  :query_params => query_params,
194
199
  :form_params => form_params,
@@ -197,72 +202,70 @@ module Svix
197
202
  :return_type => return_type
198
203
  )
199
204
 
200
- data, status_code, headers = @api_client.call_api(:DELETE, local_var_path, new_options)
205
+ data, status_code, headers = @api_client.call_api(:POST, local_var_path, new_options)
201
206
  if @api_client.config.debugging
202
- @api_client.config.logger.debug "API called: EndpointApi#delete_endpoint_api_v1_app_app_id_endpoint_endpoint_id_delete\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
207
+ @api_client.config.logger.debug "API called: EndpointApi#v1_endpoint_create\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
203
208
  end
204
209
  return data, status_code, headers
205
210
  end
206
211
 
207
- # Get Endpoint
208
- # Get an application.
209
- # @param endpoint_id [String]
212
+ # Delete Endpoint
213
+ # Delete an endpoint.
210
214
  # @param app_id [String]
215
+ # @param endpoint_id [String]
211
216
  # @param [Hash] opts the optional parameters
212
- # @option opts [String] :idempotency_key The request&#39;s idempotency key
213
- # @return [EndpointOut]
214
- def get_endpoint_api_v1_app_app_id_endpoint_endpoint_id_get(endpoint_id, app_id, opts = {})
215
- data, _status_code, _headers = get_endpoint_api_v1_app_app_id_endpoint_endpoint_id_get_with_http_info(endpoint_id, app_id, opts)
216
- data
217
+ # @return [nil]
218
+ def v1_endpoint_delete(app_id, endpoint_id, opts = {})
219
+ v1_endpoint_delete_with_http_info(app_id, endpoint_id, opts)
220
+ nil
217
221
  end
218
222
 
219
- # Get Endpoint
220
- # Get an application.
221
- # @param endpoint_id [String]
223
+ # Delete Endpoint
224
+ # Delete an endpoint.
222
225
  # @param app_id [String]
226
+ # @param endpoint_id [String]
223
227
  # @param [Hash] opts the optional parameters
224
- # @option opts [String] :idempotency_key The request&#39;s idempotency key
225
- # @return [Array<(EndpointOut, Integer, Hash)>] EndpointOut data, response status code and response headers
226
- def get_endpoint_api_v1_app_app_id_endpoint_endpoint_id_get_with_http_info(endpoint_id, app_id, opts = {})
228
+ # @return [Array<(nil, Integer, Hash)>] nil, response status code and response headers
229
+ def v1_endpoint_delete_with_http_info(app_id, endpoint_id, opts = {})
227
230
  if @api_client.config.debugging
228
- @api_client.config.logger.debug 'Calling API: EndpointApi.get_endpoint_api_v1_app_app_id_endpoint_endpoint_id_get ...'
231
+ @api_client.config.logger.debug 'Calling API: EndpointApi.v1_endpoint_delete ...'
229
232
  end
230
- # verify the required parameter 'endpoint_id' is set
231
- if @api_client.config.client_side_validation && endpoint_id.nil?
232
- fail ArgumentError, "Missing the required parameter 'endpoint_id' when calling EndpointApi.get_endpoint_api_v1_app_app_id_endpoint_endpoint_id_get"
233
+ # verify the required parameter 'app_id' is set
234
+ if @api_client.config.client_side_validation && app_id.nil?
235
+ fail ArgumentError, "Missing the required parameter 'app_id' when calling EndpointApi.v1_endpoint_delete"
233
236
  end
234
- if @api_client.config.client_side_validation && endpoint_id.to_s.length > 256
235
- fail ArgumentError, 'invalid value for "endpoint_id" when calling EndpointApi.get_endpoint_api_v1_app_app_id_endpoint_endpoint_id_get, the character length must be smaller than or equal to 256.'
237
+ if @api_client.config.client_side_validation && app_id.to_s.length > 256
238
+ fail ArgumentError, 'invalid value for "app_id" when calling EndpointApi.v1_endpoint_delete, the character length must be smaller than or equal to 256.'
236
239
  end
237
240
 
238
- if @api_client.config.client_side_validation && endpoint_id.to_s.length < 1
239
- fail ArgumentError, 'invalid value for "endpoint_id" when calling EndpointApi.get_endpoint_api_v1_app_app_id_endpoint_endpoint_id_get, the character length must be great than or equal to 1.'
241
+ if @api_client.config.client_side_validation && app_id.to_s.length < 1
242
+ fail ArgumentError, 'invalid value for "app_id" when calling EndpointApi.v1_endpoint_delete, the character length must be great than or equal to 1.'
240
243
  end
241
244
 
242
245
  pattern = Regexp.new(/^[a-zA-Z0-9\-_.]+$/)
243
- if @api_client.config.client_side_validation && endpoint_id !~ pattern
244
- fail ArgumentError, "invalid value for 'endpoint_id' when calling EndpointApi.get_endpoint_api_v1_app_app_id_endpoint_endpoint_id_get, must conform to the pattern #{pattern}."
246
+ if @api_client.config.client_side_validation && app_id !~ pattern
247
+ fail ArgumentError, "invalid value for 'app_id' when calling EndpointApi.v1_endpoint_delete, must conform to the pattern #{pattern}."
245
248
  end
246
249
 
247
- # verify the required parameter 'app_id' is set
248
- if @api_client.config.client_side_validation && app_id.nil?
249
- fail ArgumentError, "Missing the required parameter 'app_id' when calling EndpointApi.get_endpoint_api_v1_app_app_id_endpoint_endpoint_id_get"
250
+ # verify the required parameter 'endpoint_id' is set
251
+ if @api_client.config.client_side_validation && endpoint_id.nil?
252
+ fail ArgumentError, "Missing the required parameter 'endpoint_id' when calling EndpointApi.v1_endpoint_delete"
250
253
  end
251
- if @api_client.config.client_side_validation && app_id.to_s.length > 256
252
- fail ArgumentError, 'invalid value for "app_id" when calling EndpointApi.get_endpoint_api_v1_app_app_id_endpoint_endpoint_id_get, the character length must be smaller than or equal to 256.'
254
+ if @api_client.config.client_side_validation && endpoint_id.to_s.length > 256
255
+ fail ArgumentError, 'invalid value for "endpoint_id" when calling EndpointApi.v1_endpoint_delete, the character length must be smaller than or equal to 256.'
253
256
  end
254
257
 
255
- if @api_client.config.client_side_validation && app_id.to_s.length < 1
256
- fail ArgumentError, 'invalid value for "app_id" when calling EndpointApi.get_endpoint_api_v1_app_app_id_endpoint_endpoint_id_get, the character length must be great than or equal to 1.'
258
+ if @api_client.config.client_side_validation && endpoint_id.to_s.length < 1
259
+ fail ArgumentError, 'invalid value for "endpoint_id" when calling EndpointApi.v1_endpoint_delete, the character length must be great than or equal to 1.'
257
260
  end
258
261
 
259
262
  pattern = Regexp.new(/^[a-zA-Z0-9\-_.]+$/)
260
- if @api_client.config.client_side_validation && app_id !~ pattern
261
- fail ArgumentError, "invalid value for 'app_id' when calling EndpointApi.get_endpoint_api_v1_app_app_id_endpoint_endpoint_id_get, must conform to the pattern #{pattern}."
263
+ if @api_client.config.client_side_validation && endpoint_id !~ pattern
264
+ fail ArgumentError, "invalid value for 'endpoint_id' when calling EndpointApi.v1_endpoint_delete, must conform to the pattern #{pattern}."
262
265
  end
263
266
 
264
267
  # resource path
265
- local_var_path = '/api/v1/app/{app_id}/endpoint/{endpoint_id}/'.sub('{' + 'endpoint_id' + '}', CGI.escape(endpoint_id.to_s)).sub('{' + 'app_id' + '}', CGI.escape(app_id.to_s))
268
+ local_var_path = '/api/v1/app/{app_id}/endpoint/{endpoint_id}/'.sub('{' + 'app_id' + '}', CGI.escape(app_id.to_s)).sub('{' + 'endpoint_id' + '}', CGI.escape(endpoint_id.to_s))
266
269
 
267
270
  # query parameters
268
271
  query_params = opts[:query_params] || {}
@@ -271,7 +274,6 @@ module Svix
271
274
  header_params = opts[:header_params] || {}
272
275
  # HTTP header 'Accept' (if needed)
273
276
  header_params['Accept'] = @api_client.select_header_accept(['application/json'])
274
- header_params[:'idempotency-key'] = opts[:'idempotency_key'] if !opts[:'idempotency_key'].nil?
275
277
 
276
278
  # form parameters
277
279
  form_params = opts[:form_params] || {}
@@ -280,13 +282,13 @@ module Svix
280
282
  post_body = opts[:debug_body]
281
283
 
282
284
  # return_type
283
- return_type = opts[:debug_return_type] || 'EndpointOut'
285
+ return_type = opts[:debug_return_type]
284
286
 
285
287
  # auth_names
286
- auth_names = opts[:debug_auth_names] || ['HTTPBearer']
288
+ auth_names = opts[:debug_auth_names] || []
287
289
 
288
290
  new_options = opts.merge(
289
- :operation => :"EndpointApi.get_endpoint_api_v1_app_app_id_endpoint_endpoint_id_get",
291
+ :operation => :"EndpointApi.v1_endpoint_delete",
290
292
  :header_params => header_params,
291
293
  :query_params => query_params,
292
294
  :form_params => form_params,
@@ -295,72 +297,70 @@ module Svix
295
297
  :return_type => return_type
296
298
  )
297
299
 
298
- data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
300
+ data, status_code, headers = @api_client.call_api(:DELETE, local_var_path, new_options)
299
301
  if @api_client.config.debugging
300
- @api_client.config.logger.debug "API called: EndpointApi#get_endpoint_api_v1_app_app_id_endpoint_endpoint_id_get\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
302
+ @api_client.config.logger.debug "API called: EndpointApi#v1_endpoint_delete\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
301
303
  end
302
304
  return data, status_code, headers
303
305
  end
304
306
 
305
- # Get Endpoint Headers
306
- # Get the additional headers to be sent with the webhook
307
- # @param endpoint_id [String]
307
+ # Get Endpoint
308
+ # Get an endpoint.
308
309
  # @param app_id [String]
310
+ # @param endpoint_id [String]
309
311
  # @param [Hash] opts the optional parameters
310
- # @option opts [String] :idempotency_key The request&#39;s idempotency key
311
- # @return [EndpointHeadersOut]
312
- def get_endpoint_headers_api_v1_app_app_id_endpoint_endpoint_id_headers_get(endpoint_id, app_id, opts = {})
313
- data, _status_code, _headers = get_endpoint_headers_api_v1_app_app_id_endpoint_endpoint_id_headers_get_with_http_info(endpoint_id, app_id, opts)
312
+ # @return [EndpointOut]
313
+ def v1_endpoint_get(app_id, endpoint_id, opts = {})
314
+ data, _status_code, _headers = v1_endpoint_get_with_http_info(app_id, endpoint_id, opts)
314
315
  data
315
316
  end
316
317
 
317
- # Get Endpoint Headers
318
- # Get the additional headers to be sent with the webhook
319
- # @param endpoint_id [String]
318
+ # Get Endpoint
319
+ # Get an endpoint.
320
320
  # @param app_id [String]
321
+ # @param endpoint_id [String]
321
322
  # @param [Hash] opts the optional parameters
322
- # @option opts [String] :idempotency_key The request&#39;s idempotency key
323
- # @return [Array<(EndpointHeadersOut, Integer, Hash)>] EndpointHeadersOut data, response status code and response headers
324
- def get_endpoint_headers_api_v1_app_app_id_endpoint_endpoint_id_headers_get_with_http_info(endpoint_id, app_id, opts = {})
323
+ # @return [Array<(EndpointOut, Integer, Hash)>] EndpointOut data, response status code and response headers
324
+ def v1_endpoint_get_with_http_info(app_id, endpoint_id, opts = {})
325
325
  if @api_client.config.debugging
326
- @api_client.config.logger.debug 'Calling API: EndpointApi.get_endpoint_headers_api_v1_app_app_id_endpoint_endpoint_id_headers_get ...'
326
+ @api_client.config.logger.debug 'Calling API: EndpointApi.v1_endpoint_get ...'
327
327
  end
328
- # verify the required parameter 'endpoint_id' is set
329
- if @api_client.config.client_side_validation && endpoint_id.nil?
330
- fail ArgumentError, "Missing the required parameter 'endpoint_id' when calling EndpointApi.get_endpoint_headers_api_v1_app_app_id_endpoint_endpoint_id_headers_get"
328
+ # verify the required parameter 'app_id' is set
329
+ if @api_client.config.client_side_validation && app_id.nil?
330
+ fail ArgumentError, "Missing the required parameter 'app_id' when calling EndpointApi.v1_endpoint_get"
331
331
  end
332
- if @api_client.config.client_side_validation && endpoint_id.to_s.length > 256
333
- fail ArgumentError, 'invalid value for "endpoint_id" when calling EndpointApi.get_endpoint_headers_api_v1_app_app_id_endpoint_endpoint_id_headers_get, the character length must be smaller than or equal to 256.'
332
+ if @api_client.config.client_side_validation && app_id.to_s.length > 256
333
+ fail ArgumentError, 'invalid value for "app_id" when calling EndpointApi.v1_endpoint_get, the character length must be smaller than or equal to 256.'
334
334
  end
335
335
 
336
- if @api_client.config.client_side_validation && endpoint_id.to_s.length < 1
337
- fail ArgumentError, 'invalid value for "endpoint_id" when calling EndpointApi.get_endpoint_headers_api_v1_app_app_id_endpoint_endpoint_id_headers_get, the character length must be great than or equal to 1.'
336
+ if @api_client.config.client_side_validation && app_id.to_s.length < 1
337
+ fail ArgumentError, 'invalid value for "app_id" when calling EndpointApi.v1_endpoint_get, the character length must be great than or equal to 1.'
338
338
  end
339
339
 
340
340
  pattern = Regexp.new(/^[a-zA-Z0-9\-_.]+$/)
341
- if @api_client.config.client_side_validation && endpoint_id !~ pattern
342
- fail ArgumentError, "invalid value for 'endpoint_id' when calling EndpointApi.get_endpoint_headers_api_v1_app_app_id_endpoint_endpoint_id_headers_get, must conform to the pattern #{pattern}."
341
+ if @api_client.config.client_side_validation && app_id !~ pattern
342
+ fail ArgumentError, "invalid value for 'app_id' when calling EndpointApi.v1_endpoint_get, must conform to the pattern #{pattern}."
343
343
  end
344
344
 
345
- # verify the required parameter 'app_id' is set
346
- if @api_client.config.client_side_validation && app_id.nil?
347
- fail ArgumentError, "Missing the required parameter 'app_id' when calling EndpointApi.get_endpoint_headers_api_v1_app_app_id_endpoint_endpoint_id_headers_get"
345
+ # verify the required parameter 'endpoint_id' is set
346
+ if @api_client.config.client_side_validation && endpoint_id.nil?
347
+ fail ArgumentError, "Missing the required parameter 'endpoint_id' when calling EndpointApi.v1_endpoint_get"
348
348
  end
349
- if @api_client.config.client_side_validation && app_id.to_s.length > 256
350
- fail ArgumentError, 'invalid value for "app_id" when calling EndpointApi.get_endpoint_headers_api_v1_app_app_id_endpoint_endpoint_id_headers_get, the character length must be smaller than or equal to 256.'
349
+ if @api_client.config.client_side_validation && endpoint_id.to_s.length > 256
350
+ fail ArgumentError, 'invalid value for "endpoint_id" when calling EndpointApi.v1_endpoint_get, the character length must be smaller than or equal to 256.'
351
351
  end
352
352
 
353
- if @api_client.config.client_side_validation && app_id.to_s.length < 1
354
- fail ArgumentError, 'invalid value for "app_id" when calling EndpointApi.get_endpoint_headers_api_v1_app_app_id_endpoint_endpoint_id_headers_get, the character length must be great than or equal to 1.'
353
+ if @api_client.config.client_side_validation && endpoint_id.to_s.length < 1
354
+ fail ArgumentError, 'invalid value for "endpoint_id" when calling EndpointApi.v1_endpoint_get, the character length must be great than or equal to 1.'
355
355
  end
356
356
 
357
357
  pattern = Regexp.new(/^[a-zA-Z0-9\-_.]+$/)
358
- if @api_client.config.client_side_validation && app_id !~ pattern
359
- fail ArgumentError, "invalid value for 'app_id' when calling EndpointApi.get_endpoint_headers_api_v1_app_app_id_endpoint_endpoint_id_headers_get, must conform to the pattern #{pattern}."
358
+ if @api_client.config.client_side_validation && endpoint_id !~ pattern
359
+ fail ArgumentError, "invalid value for 'endpoint_id' when calling EndpointApi.v1_endpoint_get, must conform to the pattern #{pattern}."
360
360
  end
361
361
 
362
362
  # resource path
363
- local_var_path = '/api/v1/app/{app_id}/endpoint/{endpoint_id}/headers/'.sub('{' + 'endpoint_id' + '}', CGI.escape(endpoint_id.to_s)).sub('{' + 'app_id' + '}', CGI.escape(app_id.to_s))
363
+ local_var_path = '/api/v1/app/{app_id}/endpoint/{endpoint_id}/'.sub('{' + 'app_id' + '}', CGI.escape(app_id.to_s)).sub('{' + 'endpoint_id' + '}', CGI.escape(endpoint_id.to_s))
364
364
 
365
365
  # query parameters
366
366
  query_params = opts[:query_params] || {}
@@ -369,7 +369,6 @@ module Svix
369
369
  header_params = opts[:header_params] || {}
370
370
  # HTTP header 'Accept' (if needed)
371
371
  header_params['Accept'] = @api_client.select_header_accept(['application/json'])
372
- header_params[:'idempotency-key'] = opts[:'idempotency_key'] if !opts[:'idempotency_key'].nil?
373
372
 
374
373
  # form parameters
375
374
  form_params = opts[:form_params] || {}
@@ -378,13 +377,13 @@ module Svix
378
377
  post_body = opts[:debug_body]
379
378
 
380
379
  # return_type
381
- return_type = opts[:debug_return_type] || 'EndpointHeadersOut'
380
+ return_type = opts[:debug_return_type] || 'EndpointOut'
382
381
 
383
382
  # auth_names
384
- auth_names = opts[:debug_auth_names] || ['HTTPBearer']
383
+ auth_names = opts[:debug_auth_names] || []
385
384
 
386
385
  new_options = opts.merge(
387
- :operation => :"EndpointApi.get_endpoint_headers_api_v1_app_app_id_endpoint_endpoint_id_headers_get",
386
+ :operation => :"EndpointApi.v1_endpoint_get",
388
387
  :header_params => header_params,
389
388
  :query_params => query_params,
390
389
  :form_params => form_params,
@@ -395,70 +394,68 @@ module Svix
395
394
 
396
395
  data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
397
396
  if @api_client.config.debugging
398
- @api_client.config.logger.debug "API called: EndpointApi#get_endpoint_headers_api_v1_app_app_id_endpoint_endpoint_id_headers_get\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
397
+ @api_client.config.logger.debug "API called: EndpointApi#v1_endpoint_get\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
399
398
  end
400
399
  return data, status_code, headers
401
400
  end
402
401
 
403
- # Get Endpoint Secret
404
- # Get the endpoint's signing secret. This is used to verify the authenticity of the webhook. For more information please refer to [the consuming webhooks docs](https://docs.svix.com/consuming-webhooks/).
405
- # @param endpoint_id [String]
402
+ # Get Endpoint Headers
403
+ # Get the additional headers to be sent with the webhook
406
404
  # @param app_id [String]
405
+ # @param endpoint_id [String]
407
406
  # @param [Hash] opts the optional parameters
408
- # @option opts [String] :idempotency_key The request&#39;s idempotency key
409
- # @return [EndpointSecretOut]
410
- def get_endpoint_secret_api_v1_app_app_id_endpoint_endpoint_id_secret_get(endpoint_id, app_id, opts = {})
411
- data, _status_code, _headers = get_endpoint_secret_api_v1_app_app_id_endpoint_endpoint_id_secret_get_with_http_info(endpoint_id, app_id, opts)
407
+ # @return [EndpointHeadersOut]
408
+ def v1_endpoint_get_headers(app_id, endpoint_id, opts = {})
409
+ data, _status_code, _headers = v1_endpoint_get_headers_with_http_info(app_id, endpoint_id, opts)
412
410
  data
413
411
  end
414
412
 
415
- # Get Endpoint Secret
416
- # Get the endpoint&#39;s signing secret. This is used to verify the authenticity of the webhook. For more information please refer to [the consuming webhooks docs](https://docs.svix.com/consuming-webhooks/).
417
- # @param endpoint_id [String]
413
+ # Get Endpoint Headers
414
+ # Get the additional headers to be sent with the webhook
418
415
  # @param app_id [String]
416
+ # @param endpoint_id [String]
419
417
  # @param [Hash] opts the optional parameters
420
- # @option opts [String] :idempotency_key The request&#39;s idempotency key
421
- # @return [Array<(EndpointSecretOut, Integer, Hash)>] EndpointSecretOut data, response status code and response headers
422
- def get_endpoint_secret_api_v1_app_app_id_endpoint_endpoint_id_secret_get_with_http_info(endpoint_id, app_id, opts = {})
418
+ # @return [Array<(EndpointHeadersOut, Integer, Hash)>] EndpointHeadersOut data, response status code and response headers
419
+ def v1_endpoint_get_headers_with_http_info(app_id, endpoint_id, opts = {})
423
420
  if @api_client.config.debugging
424
- @api_client.config.logger.debug 'Calling API: EndpointApi.get_endpoint_secret_api_v1_app_app_id_endpoint_endpoint_id_secret_get ...'
421
+ @api_client.config.logger.debug 'Calling API: EndpointApi.v1_endpoint_get_headers ...'
425
422
  end
426
- # verify the required parameter 'endpoint_id' is set
427
- if @api_client.config.client_side_validation && endpoint_id.nil?
428
- fail ArgumentError, "Missing the required parameter 'endpoint_id' when calling EndpointApi.get_endpoint_secret_api_v1_app_app_id_endpoint_endpoint_id_secret_get"
423
+ # verify the required parameter 'app_id' is set
424
+ if @api_client.config.client_side_validation && app_id.nil?
425
+ fail ArgumentError, "Missing the required parameter 'app_id' when calling EndpointApi.v1_endpoint_get_headers"
429
426
  end
430
- if @api_client.config.client_side_validation && endpoint_id.to_s.length > 256
431
- fail ArgumentError, 'invalid value for "endpoint_id" when calling EndpointApi.get_endpoint_secret_api_v1_app_app_id_endpoint_endpoint_id_secret_get, the character length must be smaller than or equal to 256.'
427
+ if @api_client.config.client_side_validation && app_id.to_s.length > 256
428
+ fail ArgumentError, 'invalid value for "app_id" when calling EndpointApi.v1_endpoint_get_headers, the character length must be smaller than or equal to 256.'
432
429
  end
433
430
 
434
- if @api_client.config.client_side_validation && endpoint_id.to_s.length < 1
435
- fail ArgumentError, 'invalid value for "endpoint_id" when calling EndpointApi.get_endpoint_secret_api_v1_app_app_id_endpoint_endpoint_id_secret_get, the character length must be great than or equal to 1.'
431
+ if @api_client.config.client_side_validation && app_id.to_s.length < 1
432
+ fail ArgumentError, 'invalid value for "app_id" when calling EndpointApi.v1_endpoint_get_headers, the character length must be great than or equal to 1.'
436
433
  end
437
434
 
438
435
  pattern = Regexp.new(/^[a-zA-Z0-9\-_.]+$/)
439
- if @api_client.config.client_side_validation && endpoint_id !~ pattern
440
- fail ArgumentError, "invalid value for 'endpoint_id' when calling EndpointApi.get_endpoint_secret_api_v1_app_app_id_endpoint_endpoint_id_secret_get, must conform to the pattern #{pattern}."
436
+ if @api_client.config.client_side_validation && app_id !~ pattern
437
+ fail ArgumentError, "invalid value for 'app_id' when calling EndpointApi.v1_endpoint_get_headers, must conform to the pattern #{pattern}."
441
438
  end
442
439
 
443
- # verify the required parameter 'app_id' is set
444
- if @api_client.config.client_side_validation && app_id.nil?
445
- fail ArgumentError, "Missing the required parameter 'app_id' when calling EndpointApi.get_endpoint_secret_api_v1_app_app_id_endpoint_endpoint_id_secret_get"
440
+ # verify the required parameter 'endpoint_id' is set
441
+ if @api_client.config.client_side_validation && endpoint_id.nil?
442
+ fail ArgumentError, "Missing the required parameter 'endpoint_id' when calling EndpointApi.v1_endpoint_get_headers"
446
443
  end
447
- if @api_client.config.client_side_validation && app_id.to_s.length > 256
448
- fail ArgumentError, 'invalid value for "app_id" when calling EndpointApi.get_endpoint_secret_api_v1_app_app_id_endpoint_endpoint_id_secret_get, the character length must be smaller than or equal to 256.'
444
+ if @api_client.config.client_side_validation && endpoint_id.to_s.length > 256
445
+ fail ArgumentError, 'invalid value for "endpoint_id" when calling EndpointApi.v1_endpoint_get_headers, the character length must be smaller than or equal to 256.'
449
446
  end
450
447
 
451
- if @api_client.config.client_side_validation && app_id.to_s.length < 1
452
- fail ArgumentError, 'invalid value for "app_id" when calling EndpointApi.get_endpoint_secret_api_v1_app_app_id_endpoint_endpoint_id_secret_get, the character length must be great than or equal to 1.'
448
+ if @api_client.config.client_side_validation && endpoint_id.to_s.length < 1
449
+ fail ArgumentError, 'invalid value for "endpoint_id" when calling EndpointApi.v1_endpoint_get_headers, the character length must be great than or equal to 1.'
453
450
  end
454
451
 
455
452
  pattern = Regexp.new(/^[a-zA-Z0-9\-_.]+$/)
456
- if @api_client.config.client_side_validation && app_id !~ pattern
457
- fail ArgumentError, "invalid value for 'app_id' when calling EndpointApi.get_endpoint_secret_api_v1_app_app_id_endpoint_endpoint_id_secret_get, must conform to the pattern #{pattern}."
453
+ if @api_client.config.client_side_validation && endpoint_id !~ pattern
454
+ fail ArgumentError, "invalid value for 'endpoint_id' when calling EndpointApi.v1_endpoint_get_headers, must conform to the pattern #{pattern}."
458
455
  end
459
456
 
460
457
  # resource path
461
- local_var_path = '/api/v1/app/{app_id}/endpoint/{endpoint_id}/secret/'.sub('{' + 'endpoint_id' + '}', CGI.escape(endpoint_id.to_s)).sub('{' + 'app_id' + '}', CGI.escape(app_id.to_s))
458
+ local_var_path = '/api/v1/app/{app_id}/endpoint/{endpoint_id}/headers/'.sub('{' + 'app_id' + '}', CGI.escape(app_id.to_s)).sub('{' + 'endpoint_id' + '}', CGI.escape(endpoint_id.to_s))
462
459
 
463
460
  # query parameters
464
461
  query_params = opts[:query_params] || {}
@@ -467,7 +464,6 @@ module Svix
467
464
  header_params = opts[:header_params] || {}
468
465
  # HTTP header 'Accept' (if needed)
469
466
  header_params['Accept'] = @api_client.select_header_accept(['application/json'])
470
- header_params[:'idempotency-key'] = opts[:'idempotency_key'] if !opts[:'idempotency_key'].nil?
471
467
 
472
468
  # form parameters
473
469
  form_params = opts[:form_params] || {}
@@ -476,13 +472,13 @@ module Svix
476
472
  post_body = opts[:debug_body]
477
473
 
478
474
  # return_type
479
- return_type = opts[:debug_return_type] || 'EndpointSecretOut'
475
+ return_type = opts[:debug_return_type] || 'EndpointHeadersOut'
480
476
 
481
477
  # auth_names
482
- auth_names = opts[:debug_auth_names] || ['HTTPBearer']
478
+ auth_names = opts[:debug_auth_names] || []
483
479
 
484
480
  new_options = opts.merge(
485
- :operation => :"EndpointApi.get_endpoint_secret_api_v1_app_app_id_endpoint_endpoint_id_secret_get",
481
+ :operation => :"EndpointApi.v1_endpoint_get_headers",
486
482
  :header_params => header_params,
487
483
  :query_params => query_params,
488
484
  :form_params => form_params,
@@ -493,70 +489,68 @@ module Svix
493
489
 
494
490
  data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
495
491
  if @api_client.config.debugging
496
- @api_client.config.logger.debug "API called: EndpointApi#get_endpoint_secret_api_v1_app_app_id_endpoint_endpoint_id_secret_get\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
492
+ @api_client.config.logger.debug "API called: EndpointApi#v1_endpoint_get_headers\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
497
493
  end
498
494
  return data, status_code, headers
499
495
  end
500
496
 
501
- # Get Endpoint Stats
502
- # Get basic statistics for the endpoint.
503
- # @param endpoint_id [String]
497
+ # Get Endpoint Secret
498
+ # Get the endpoint's signing secret. This is used to verify the authenticity of the webhook. For more information please refer to [the consuming webhooks docs](https://docs.svix.com/consuming-webhooks/).
504
499
  # @param app_id [String]
500
+ # @param endpoint_id [String]
505
501
  # @param [Hash] opts the optional parameters
506
- # @option opts [String] :idempotency_key The request&#39;s idempotency key
507
- # @return [EndpointStats]
508
- def get_endpoint_stats_api_v1_app_app_id_endpoint_endpoint_id_stats_get(endpoint_id, app_id, opts = {})
509
- data, _status_code, _headers = get_endpoint_stats_api_v1_app_app_id_endpoint_endpoint_id_stats_get_with_http_info(endpoint_id, app_id, opts)
502
+ # @return [EndpointSecretOut]
503
+ def v1_endpoint_get_secret(app_id, endpoint_id, opts = {})
504
+ data, _status_code, _headers = v1_endpoint_get_secret_with_http_info(app_id, endpoint_id, opts)
510
505
  data
511
506
  end
512
507
 
513
- # Get Endpoint Stats
514
- # Get basic statistics for the endpoint.
515
- # @param endpoint_id [String]
508
+ # Get Endpoint Secret
509
+ # Get the endpoint&#39;s signing secret. This is used to verify the authenticity of the webhook. For more information please refer to [the consuming webhooks docs](https://docs.svix.com/consuming-webhooks/).
516
510
  # @param app_id [String]
511
+ # @param endpoint_id [String]
517
512
  # @param [Hash] opts the optional parameters
518
- # @option opts [String] :idempotency_key The request&#39;s idempotency key
519
- # @return [Array<(EndpointStats, Integer, Hash)>] EndpointStats data, response status code and response headers
520
- def get_endpoint_stats_api_v1_app_app_id_endpoint_endpoint_id_stats_get_with_http_info(endpoint_id, app_id, opts = {})
513
+ # @return [Array<(EndpointSecretOut, Integer, Hash)>] EndpointSecretOut data, response status code and response headers
514
+ def v1_endpoint_get_secret_with_http_info(app_id, endpoint_id, opts = {})
521
515
  if @api_client.config.debugging
522
- @api_client.config.logger.debug 'Calling API: EndpointApi.get_endpoint_stats_api_v1_app_app_id_endpoint_endpoint_id_stats_get ...'
516
+ @api_client.config.logger.debug 'Calling API: EndpointApi.v1_endpoint_get_secret ...'
523
517
  end
524
- # verify the required parameter 'endpoint_id' is set
525
- if @api_client.config.client_side_validation && endpoint_id.nil?
526
- fail ArgumentError, "Missing the required parameter 'endpoint_id' when calling EndpointApi.get_endpoint_stats_api_v1_app_app_id_endpoint_endpoint_id_stats_get"
518
+ # verify the required parameter 'app_id' is set
519
+ if @api_client.config.client_side_validation && app_id.nil?
520
+ fail ArgumentError, "Missing the required parameter 'app_id' when calling EndpointApi.v1_endpoint_get_secret"
527
521
  end
528
- if @api_client.config.client_side_validation && endpoint_id.to_s.length > 256
529
- fail ArgumentError, 'invalid value for "endpoint_id" when calling EndpointApi.get_endpoint_stats_api_v1_app_app_id_endpoint_endpoint_id_stats_get, the character length must be smaller than or equal to 256.'
522
+ if @api_client.config.client_side_validation && app_id.to_s.length > 256
523
+ fail ArgumentError, 'invalid value for "app_id" when calling EndpointApi.v1_endpoint_get_secret, the character length must be smaller than or equal to 256.'
530
524
  end
531
525
 
532
- if @api_client.config.client_side_validation && endpoint_id.to_s.length < 1
533
- fail ArgumentError, 'invalid value for "endpoint_id" when calling EndpointApi.get_endpoint_stats_api_v1_app_app_id_endpoint_endpoint_id_stats_get, the character length must be great than or equal to 1.'
526
+ if @api_client.config.client_side_validation && app_id.to_s.length < 1
527
+ fail ArgumentError, 'invalid value for "app_id" when calling EndpointApi.v1_endpoint_get_secret, the character length must be great than or equal to 1.'
534
528
  end
535
529
 
536
530
  pattern = Regexp.new(/^[a-zA-Z0-9\-_.]+$/)
537
- if @api_client.config.client_side_validation && endpoint_id !~ pattern
538
- fail ArgumentError, "invalid value for 'endpoint_id' when calling EndpointApi.get_endpoint_stats_api_v1_app_app_id_endpoint_endpoint_id_stats_get, must conform to the pattern #{pattern}."
531
+ if @api_client.config.client_side_validation && app_id !~ pattern
532
+ fail ArgumentError, "invalid value for 'app_id' when calling EndpointApi.v1_endpoint_get_secret, must conform to the pattern #{pattern}."
539
533
  end
540
534
 
541
- # verify the required parameter 'app_id' is set
542
- if @api_client.config.client_side_validation && app_id.nil?
543
- fail ArgumentError, "Missing the required parameter 'app_id' when calling EndpointApi.get_endpoint_stats_api_v1_app_app_id_endpoint_endpoint_id_stats_get"
535
+ # verify the required parameter 'endpoint_id' is set
536
+ if @api_client.config.client_side_validation && endpoint_id.nil?
537
+ fail ArgumentError, "Missing the required parameter 'endpoint_id' when calling EndpointApi.v1_endpoint_get_secret"
544
538
  end
545
- if @api_client.config.client_side_validation && app_id.to_s.length > 256
546
- fail ArgumentError, 'invalid value for "app_id" when calling EndpointApi.get_endpoint_stats_api_v1_app_app_id_endpoint_endpoint_id_stats_get, the character length must be smaller than or equal to 256.'
539
+ if @api_client.config.client_side_validation && endpoint_id.to_s.length > 256
540
+ fail ArgumentError, 'invalid value for "endpoint_id" when calling EndpointApi.v1_endpoint_get_secret, the character length must be smaller than or equal to 256.'
547
541
  end
548
542
 
549
- if @api_client.config.client_side_validation && app_id.to_s.length < 1
550
- fail ArgumentError, 'invalid value for "app_id" when calling EndpointApi.get_endpoint_stats_api_v1_app_app_id_endpoint_endpoint_id_stats_get, the character length must be great than or equal to 1.'
543
+ if @api_client.config.client_side_validation && endpoint_id.to_s.length < 1
544
+ fail ArgumentError, 'invalid value for "endpoint_id" when calling EndpointApi.v1_endpoint_get_secret, the character length must be great than or equal to 1.'
551
545
  end
552
546
 
553
547
  pattern = Regexp.new(/^[a-zA-Z0-9\-_.]+$/)
554
- if @api_client.config.client_side_validation && app_id !~ pattern
555
- fail ArgumentError, "invalid value for 'app_id' when calling EndpointApi.get_endpoint_stats_api_v1_app_app_id_endpoint_endpoint_id_stats_get, must conform to the pattern #{pattern}."
548
+ if @api_client.config.client_side_validation && endpoint_id !~ pattern
549
+ fail ArgumentError, "invalid value for 'endpoint_id' when calling EndpointApi.v1_endpoint_get_secret, must conform to the pattern #{pattern}."
556
550
  end
557
551
 
558
552
  # resource path
559
- local_var_path = '/api/v1/app/{app_id}/endpoint/{endpoint_id}/stats/'.sub('{' + 'endpoint_id' + '}', CGI.escape(endpoint_id.to_s)).sub('{' + 'app_id' + '}', CGI.escape(app_id.to_s))
553
+ local_var_path = '/api/v1/app/{app_id}/endpoint/{endpoint_id}/secret/'.sub('{' + 'app_id' + '}', CGI.escape(app_id.to_s)).sub('{' + 'endpoint_id' + '}', CGI.escape(endpoint_id.to_s))
560
554
 
561
555
  # query parameters
562
556
  query_params = opts[:query_params] || {}
@@ -565,7 +559,6 @@ module Svix
565
559
  header_params = opts[:header_params] || {}
566
560
  # HTTP header 'Accept' (if needed)
567
561
  header_params['Accept'] = @api_client.select_header_accept(['application/json'])
568
- header_params[:'idempotency-key'] = opts[:'idempotency_key'] if !opts[:'idempotency_key'].nil?
569
562
 
570
563
  # form parameters
571
564
  form_params = opts[:form_params] || {}
@@ -574,13 +567,13 @@ module Svix
574
567
  post_body = opts[:debug_body]
575
568
 
576
569
  # return_type
577
- return_type = opts[:debug_return_type] || 'EndpointStats'
570
+ return_type = opts[:debug_return_type] || 'EndpointSecretOut'
578
571
 
579
572
  # auth_names
580
- auth_names = opts[:debug_auth_names] || ['HTTPBearer']
573
+ auth_names = opts[:debug_auth_names] || []
581
574
 
582
575
  new_options = opts.merge(
583
- :operation => :"EndpointApi.get_endpoint_stats_api_v1_app_app_id_endpoint_endpoint_id_stats_get",
576
+ :operation => :"EndpointApi.v1_endpoint_get_secret",
584
577
  :header_params => header_params,
585
578
  :query_params => query_params,
586
579
  :form_params => form_params,
@@ -591,79 +584,82 @@ module Svix
591
584
 
592
585
  data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
593
586
  if @api_client.config.debugging
594
- @api_client.config.logger.debug "API called: EndpointApi#get_endpoint_stats_api_v1_app_app_id_endpoint_endpoint_id_stats_get\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
587
+ @api_client.config.logger.debug "API called: EndpointApi#v1_endpoint_get_secret\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
595
588
  end
596
589
  return data, status_code, headers
597
590
  end
598
591
 
599
- # Get Endpoint Transformation
600
- # Get the transformation code associated with this endpoint
601
- # @param endpoint_id [String]
592
+ # Endpoint Stats
593
+ # Get basic statistics for the endpoint.
602
594
  # @param app_id [String]
595
+ # @param endpoint_id [String]
603
596
  # @param [Hash] opts the optional parameters
604
- # @option opts [String] :idempotency_key The request&#39;s idempotency key
605
- # @return [EndpointTransformationOut]
606
- def get_endpoint_transformation_api_v1_app_app_id_endpoint_endpoint_id_transformation_get(endpoint_id, app_id, opts = {})
607
- data, _status_code, _headers = get_endpoint_transformation_api_v1_app_app_id_endpoint_endpoint_id_transformation_get_with_http_info(endpoint_id, app_id, opts)
597
+ # @option opts [Time] :since
598
+ # @option opts [Time] :_until
599
+ # @return [EndpointStats]
600
+ def v1_endpoint_get_stats(app_id, endpoint_id, opts = {})
601
+ data, _status_code, _headers = v1_endpoint_get_stats_with_http_info(app_id, endpoint_id, opts)
608
602
  data
609
603
  end
610
604
 
611
- # Get Endpoint Transformation
612
- # Get the transformation code associated with this endpoint
613
- # @param endpoint_id [String]
605
+ # Endpoint Stats
606
+ # Get basic statistics for the endpoint.
614
607
  # @param app_id [String]
608
+ # @param endpoint_id [String]
615
609
  # @param [Hash] opts the optional parameters
616
- # @option opts [String] :idempotency_key The request&#39;s idempotency key
617
- # @return [Array<(EndpointTransformationOut, Integer, Hash)>] EndpointTransformationOut data, response status code and response headers
618
- def get_endpoint_transformation_api_v1_app_app_id_endpoint_endpoint_id_transformation_get_with_http_info(endpoint_id, app_id, opts = {})
610
+ # @option opts [Time] :since
611
+ # @option opts [Time] :_until
612
+ # @return [Array<(EndpointStats, Integer, Hash)>] EndpointStats data, response status code and response headers
613
+ def v1_endpoint_get_stats_with_http_info(app_id, endpoint_id, opts = {})
619
614
  if @api_client.config.debugging
620
- @api_client.config.logger.debug 'Calling API: EndpointApi.get_endpoint_transformation_api_v1_app_app_id_endpoint_endpoint_id_transformation_get ...'
615
+ @api_client.config.logger.debug 'Calling API: EndpointApi.v1_endpoint_get_stats ...'
621
616
  end
622
- # verify the required parameter 'endpoint_id' is set
623
- if @api_client.config.client_side_validation && endpoint_id.nil?
624
- fail ArgumentError, "Missing the required parameter 'endpoint_id' when calling EndpointApi.get_endpoint_transformation_api_v1_app_app_id_endpoint_endpoint_id_transformation_get"
617
+ # verify the required parameter 'app_id' is set
618
+ if @api_client.config.client_side_validation && app_id.nil?
619
+ fail ArgumentError, "Missing the required parameter 'app_id' when calling EndpointApi.v1_endpoint_get_stats"
625
620
  end
626
- if @api_client.config.client_side_validation && endpoint_id.to_s.length > 256
627
- fail ArgumentError, 'invalid value for "endpoint_id" when calling EndpointApi.get_endpoint_transformation_api_v1_app_app_id_endpoint_endpoint_id_transformation_get, the character length must be smaller than or equal to 256.'
621
+ if @api_client.config.client_side_validation && app_id.to_s.length > 256
622
+ fail ArgumentError, 'invalid value for "app_id" when calling EndpointApi.v1_endpoint_get_stats, the character length must be smaller than or equal to 256.'
628
623
  end
629
624
 
630
- if @api_client.config.client_side_validation && endpoint_id.to_s.length < 1
631
- fail ArgumentError, 'invalid value for "endpoint_id" when calling EndpointApi.get_endpoint_transformation_api_v1_app_app_id_endpoint_endpoint_id_transformation_get, the character length must be great than or equal to 1.'
625
+ if @api_client.config.client_side_validation && app_id.to_s.length < 1
626
+ fail ArgumentError, 'invalid value for "app_id" when calling EndpointApi.v1_endpoint_get_stats, the character length must be great than or equal to 1.'
632
627
  end
633
628
 
634
629
  pattern = Regexp.new(/^[a-zA-Z0-9\-_.]+$/)
635
- if @api_client.config.client_side_validation && endpoint_id !~ pattern
636
- fail ArgumentError, "invalid value for 'endpoint_id' when calling EndpointApi.get_endpoint_transformation_api_v1_app_app_id_endpoint_endpoint_id_transformation_get, must conform to the pattern #{pattern}."
630
+ if @api_client.config.client_side_validation && app_id !~ pattern
631
+ fail ArgumentError, "invalid value for 'app_id' when calling EndpointApi.v1_endpoint_get_stats, must conform to the pattern #{pattern}."
637
632
  end
638
633
 
639
- # verify the required parameter 'app_id' is set
640
- if @api_client.config.client_side_validation && app_id.nil?
641
- fail ArgumentError, "Missing the required parameter 'app_id' when calling EndpointApi.get_endpoint_transformation_api_v1_app_app_id_endpoint_endpoint_id_transformation_get"
634
+ # verify the required parameter 'endpoint_id' is set
635
+ if @api_client.config.client_side_validation && endpoint_id.nil?
636
+ fail ArgumentError, "Missing the required parameter 'endpoint_id' when calling EndpointApi.v1_endpoint_get_stats"
642
637
  end
643
- if @api_client.config.client_side_validation && app_id.to_s.length > 256
644
- fail ArgumentError, 'invalid value for "app_id" when calling EndpointApi.get_endpoint_transformation_api_v1_app_app_id_endpoint_endpoint_id_transformation_get, the character length must be smaller than or equal to 256.'
638
+ if @api_client.config.client_side_validation && endpoint_id.to_s.length > 256
639
+ fail ArgumentError, 'invalid value for "endpoint_id" when calling EndpointApi.v1_endpoint_get_stats, the character length must be smaller than or equal to 256.'
645
640
  end
646
641
 
647
- if @api_client.config.client_side_validation && app_id.to_s.length < 1
648
- fail ArgumentError, 'invalid value for "app_id" when calling EndpointApi.get_endpoint_transformation_api_v1_app_app_id_endpoint_endpoint_id_transformation_get, the character length must be great than or equal to 1.'
642
+ if @api_client.config.client_side_validation && endpoint_id.to_s.length < 1
643
+ fail ArgumentError, 'invalid value for "endpoint_id" when calling EndpointApi.v1_endpoint_get_stats, the character length must be great than or equal to 1.'
649
644
  end
650
645
 
651
646
  pattern = Regexp.new(/^[a-zA-Z0-9\-_.]+$/)
652
- if @api_client.config.client_side_validation && app_id !~ pattern
653
- fail ArgumentError, "invalid value for 'app_id' when calling EndpointApi.get_endpoint_transformation_api_v1_app_app_id_endpoint_endpoint_id_transformation_get, must conform to the pattern #{pattern}."
647
+ if @api_client.config.client_side_validation && endpoint_id !~ pattern
648
+ fail ArgumentError, "invalid value for 'endpoint_id' when calling EndpointApi.v1_endpoint_get_stats, must conform to the pattern #{pattern}."
654
649
  end
655
650
 
656
651
  # resource path
657
- local_var_path = '/api/v1/app/{app_id}/endpoint/{endpoint_id}/transformation/'.sub('{' + 'endpoint_id' + '}', CGI.escape(endpoint_id.to_s)).sub('{' + 'app_id' + '}', CGI.escape(app_id.to_s))
652
+ local_var_path = '/api/v1/app/{app_id}/endpoint/{endpoint_id}/stats/'.sub('{' + 'app_id' + '}', CGI.escape(app_id.to_s)).sub('{' + 'endpoint_id' + '}', CGI.escape(endpoint_id.to_s))
658
653
 
659
654
  # query parameters
660
655
  query_params = opts[:query_params] || {}
656
+ query_params[:'since'] = opts[:'since'] if !opts[:'since'].nil?
657
+ query_params[:'until'] = opts[:'_until'] if !opts[:'_until'].nil?
661
658
 
662
659
  # header parameters
663
660
  header_params = opts[:header_params] || {}
664
661
  # HTTP header 'Accept' (if needed)
665
662
  header_params['Accept'] = @api_client.select_header_accept(['application/json'])
666
- header_params[:'idempotency-key'] = opts[:'idempotency_key'] if !opts[:'idempotency_key'].nil?
667
663
 
668
664
  # form parameters
669
665
  form_params = opts[:form_params] || {}
@@ -672,13 +668,13 @@ module Svix
672
668
  post_body = opts[:debug_body]
673
669
 
674
670
  # return_type
675
- return_type = opts[:debug_return_type] || 'EndpointTransformationOut'
671
+ return_type = opts[:debug_return_type] || 'EndpointStats'
676
672
 
677
673
  # auth_names
678
- auth_names = opts[:debug_auth_names] || ['HTTPBearer']
674
+ auth_names = opts[:debug_auth_names] || []
679
675
 
680
676
  new_options = opts.merge(
681
- :operation => :"EndpointApi.get_endpoint_transformation_api_v1_app_app_id_endpoint_endpoint_id_transformation_get",
677
+ :operation => :"EndpointApi.v1_endpoint_get_stats",
682
678
  :header_params => header_params,
683
679
  :query_params => query_params,
684
680
  :form_params => form_params,
@@ -689,7 +685,7 @@ module Svix
689
685
 
690
686
  data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
691
687
  if @api_client.config.debugging
692
- @api_client.config.logger.debug "API called: EndpointApi#get_endpoint_transformation_api_v1_app_app_id_endpoint_endpoint_id_transformation_get\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
688
+ @api_client.config.logger.debug "API called: EndpointApi#v1_endpoint_get_stats\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
693
689
  end
694
690
  return data, status_code, headers
695
691
  end
@@ -698,13 +694,12 @@ module Svix
698
694
  # List the application's endpoints.
699
695
  # @param app_id [String]
700
696
  # @param [Hash] opts the optional parameters
697
+ # @option opts [Integer] :limit
701
698
  # @option opts [String] :iterator
702
- # @option opts [Integer] :limit (default to 50)
703
699
  # @option opts [Ordering] :order
704
- # @option opts [String] :idempotency_key The request&#39;s idempotency key
705
700
  # @return [ListResponseEndpointOut]
706
- def list_endpoints_api_v1_app_app_id_endpoint_get(app_id, opts = {})
707
- data, _status_code, _headers = list_endpoints_api_v1_app_app_id_endpoint_get_with_http_info(app_id, opts)
701
+ def v1_endpoint_list(app_id, opts = {})
702
+ data, _status_code, _headers = v1_endpoint_list_with_http_info(app_id, opts)
708
703
  data
709
704
  end
710
705
 
@@ -712,34 +707,33 @@ module Svix
712
707
  # List the application&#39;s endpoints.
713
708
  # @param app_id [String]
714
709
  # @param [Hash] opts the optional parameters
715
- # @option opts [String] :iterator
716
710
  # @option opts [Integer] :limit
711
+ # @option opts [String] :iterator
717
712
  # @option opts [Ordering] :order
718
- # @option opts [String] :idempotency_key The request&#39;s idempotency key
719
713
  # @return [Array<(ListResponseEndpointOut, Integer, Hash)>] ListResponseEndpointOut data, response status code and response headers
720
- def list_endpoints_api_v1_app_app_id_endpoint_get_with_http_info(app_id, opts = {})
714
+ def v1_endpoint_list_with_http_info(app_id, opts = {})
721
715
  if @api_client.config.debugging
722
- @api_client.config.logger.debug 'Calling API: EndpointApi.list_endpoints_api_v1_app_app_id_endpoint_get ...'
716
+ @api_client.config.logger.debug 'Calling API: EndpointApi.v1_endpoint_list ...'
723
717
  end
724
718
  # verify the required parameter 'app_id' is set
725
719
  if @api_client.config.client_side_validation && app_id.nil?
726
- fail ArgumentError, "Missing the required parameter 'app_id' when calling EndpointApi.list_endpoints_api_v1_app_app_id_endpoint_get"
720
+ fail ArgumentError, "Missing the required parameter 'app_id' when calling EndpointApi.v1_endpoint_list"
727
721
  end
728
722
  if @api_client.config.client_side_validation && app_id.to_s.length > 256
729
- fail ArgumentError, 'invalid value for "app_id" when calling EndpointApi.list_endpoints_api_v1_app_app_id_endpoint_get, the character length must be smaller than or equal to 256.'
723
+ fail ArgumentError, 'invalid value for "app_id" when calling EndpointApi.v1_endpoint_list, the character length must be smaller than or equal to 256.'
730
724
  end
731
725
 
732
726
  if @api_client.config.client_side_validation && app_id.to_s.length < 1
733
- fail ArgumentError, 'invalid value for "app_id" when calling EndpointApi.list_endpoints_api_v1_app_app_id_endpoint_get, the character length must be great than or equal to 1.'
727
+ fail ArgumentError, 'invalid value for "app_id" when calling EndpointApi.v1_endpoint_list, the character length must be great than or equal to 1.'
734
728
  end
735
729
 
736
730
  pattern = Regexp.new(/^[a-zA-Z0-9\-_.]+$/)
737
731
  if @api_client.config.client_side_validation && app_id !~ pattern
738
- fail ArgumentError, "invalid value for 'app_id' when calling EndpointApi.list_endpoints_api_v1_app_app_id_endpoint_get, must conform to the pattern #{pattern}."
732
+ fail ArgumentError, "invalid value for 'app_id' when calling EndpointApi.v1_endpoint_list, must conform to the pattern #{pattern}."
739
733
  end
740
734
 
741
- if @api_client.config.client_side_validation && !opts[:'limit'].nil? && opts[:'limit'] > 250
742
- fail ArgumentError, 'invalid value for "opts[:"limit"]" when calling EndpointApi.list_endpoints_api_v1_app_app_id_endpoint_get, must be smaller than or equal to 250.'
735
+ if @api_client.config.client_side_validation && !opts[:'limit'].nil? && opts[:'limit'] < 0
736
+ fail ArgumentError, 'invalid value for "opts[:"limit"]" when calling EndpointApi.v1_endpoint_list, must be greater than or equal to 0.'
743
737
  end
744
738
 
745
739
  # resource path
@@ -747,15 +741,14 @@ module Svix
747
741
 
748
742
  # query parameters
749
743
  query_params = opts[:query_params] || {}
750
- query_params[:'iterator'] = opts[:'iterator'] if !opts[:'iterator'].nil?
751
744
  query_params[:'limit'] = opts[:'limit'] if !opts[:'limit'].nil?
745
+ query_params[:'iterator'] = opts[:'iterator'] if !opts[:'iterator'].nil?
752
746
  query_params[:'order'] = opts[:'order'] if !opts[:'order'].nil?
753
747
 
754
748
  # header parameters
755
749
  header_params = opts[:header_params] || {}
756
750
  # HTTP header 'Accept' (if needed)
757
751
  header_params['Accept'] = @api_client.select_header_accept(['application/json'])
758
- header_params[:'idempotency-key'] = opts[:'idempotency_key'] if !opts[:'idempotency_key'].nil?
759
752
 
760
753
  # form parameters
761
754
  form_params = opts[:form_params] || {}
@@ -767,10 +760,10 @@ module Svix
767
760
  return_type = opts[:debug_return_type] || 'ListResponseEndpointOut'
768
761
 
769
762
  # auth_names
770
- auth_names = opts[:debug_auth_names] || ['HTTPBearer']
763
+ auth_names = opts[:debug_auth_names] || []
771
764
 
772
765
  new_options = opts.merge(
773
- :operation => :"EndpointApi.list_endpoints_api_v1_app_app_id_endpoint_get",
766
+ :operation => :"EndpointApi.v1_endpoint_list",
774
767
  :header_params => header_params,
775
768
  :query_params => query_params,
776
769
  :form_params => form_params,
@@ -781,7 +774,7 @@ module Svix
781
774
 
782
775
  data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
783
776
  if @api_client.config.debugging
784
- @api_client.config.logger.debug "API called: EndpointApi#list_endpoints_api_v1_app_app_id_endpoint_get\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
777
+ @api_client.config.logger.debug "API called: EndpointApi#v1_endpoint_list\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
785
778
  end
786
779
  return data, status_code, headers
787
780
  end
@@ -792,10 +785,9 @@ module Svix
792
785
  # @param endpoint_id [String]
793
786
  # @param endpoint_headers_patch_in [EndpointHeadersPatchIn]
794
787
  # @param [Hash] opts the optional parameters
795
- # @option opts [String] :idempotency_key The request&#39;s idempotency key
796
788
  # @return [nil]
797
- def patch_endpoint_headers_api_v1_app_app_id_endpoint_endpoint_id_headers_patch(app_id, endpoint_id, endpoint_headers_patch_in, opts = {})
798
- patch_endpoint_headers_api_v1_app_app_id_endpoint_endpoint_id_headers_patch_with_http_info(app_id, endpoint_id, endpoint_headers_patch_in, opts)
789
+ def v1_endpoint_patch_headers(app_id, endpoint_id, endpoint_headers_patch_in, opts = {})
790
+ v1_endpoint_patch_headers_with_http_info(app_id, endpoint_id, endpoint_headers_patch_in, opts)
799
791
  nil
800
792
  end
801
793
 
@@ -805,49 +797,48 @@ module Svix
805
797
  # @param endpoint_id [String]
806
798
  # @param endpoint_headers_patch_in [EndpointHeadersPatchIn]
807
799
  # @param [Hash] opts the optional parameters
808
- # @option opts [String] :idempotency_key The request&#39;s idempotency key
809
800
  # @return [Array<(nil, Integer, Hash)>] nil, response status code and response headers
810
- def patch_endpoint_headers_api_v1_app_app_id_endpoint_endpoint_id_headers_patch_with_http_info(app_id, endpoint_id, endpoint_headers_patch_in, opts = {})
801
+ def v1_endpoint_patch_headers_with_http_info(app_id, endpoint_id, endpoint_headers_patch_in, opts = {})
811
802
  if @api_client.config.debugging
812
- @api_client.config.logger.debug 'Calling API: EndpointApi.patch_endpoint_headers_api_v1_app_app_id_endpoint_endpoint_id_headers_patch ...'
803
+ @api_client.config.logger.debug 'Calling API: EndpointApi.v1_endpoint_patch_headers ...'
813
804
  end
814
805
  # verify the required parameter 'app_id' is set
815
806
  if @api_client.config.client_side_validation && app_id.nil?
816
- fail ArgumentError, "Missing the required parameter 'app_id' when calling EndpointApi.patch_endpoint_headers_api_v1_app_app_id_endpoint_endpoint_id_headers_patch"
807
+ fail ArgumentError, "Missing the required parameter 'app_id' when calling EndpointApi.v1_endpoint_patch_headers"
817
808
  end
818
809
  if @api_client.config.client_side_validation && app_id.to_s.length > 256
819
- fail ArgumentError, 'invalid value for "app_id" when calling EndpointApi.patch_endpoint_headers_api_v1_app_app_id_endpoint_endpoint_id_headers_patch, the character length must be smaller than or equal to 256.'
810
+ fail ArgumentError, 'invalid value for "app_id" when calling EndpointApi.v1_endpoint_patch_headers, the character length must be smaller than or equal to 256.'
820
811
  end
821
812
 
822
813
  if @api_client.config.client_side_validation && app_id.to_s.length < 1
823
- fail ArgumentError, 'invalid value for "app_id" when calling EndpointApi.patch_endpoint_headers_api_v1_app_app_id_endpoint_endpoint_id_headers_patch, the character length must be great than or equal to 1.'
814
+ fail ArgumentError, 'invalid value for "app_id" when calling EndpointApi.v1_endpoint_patch_headers, the character length must be great than or equal to 1.'
824
815
  end
825
816
 
826
817
  pattern = Regexp.new(/^[a-zA-Z0-9\-_.]+$/)
827
818
  if @api_client.config.client_side_validation && app_id !~ pattern
828
- fail ArgumentError, "invalid value for 'app_id' when calling EndpointApi.patch_endpoint_headers_api_v1_app_app_id_endpoint_endpoint_id_headers_patch, must conform to the pattern #{pattern}."
819
+ fail ArgumentError, "invalid value for 'app_id' when calling EndpointApi.v1_endpoint_patch_headers, must conform to the pattern #{pattern}."
829
820
  end
830
821
 
831
822
  # verify the required parameter 'endpoint_id' is set
832
823
  if @api_client.config.client_side_validation && endpoint_id.nil?
833
- fail ArgumentError, "Missing the required parameter 'endpoint_id' when calling EndpointApi.patch_endpoint_headers_api_v1_app_app_id_endpoint_endpoint_id_headers_patch"
824
+ fail ArgumentError, "Missing the required parameter 'endpoint_id' when calling EndpointApi.v1_endpoint_patch_headers"
834
825
  end
835
826
  if @api_client.config.client_side_validation && endpoint_id.to_s.length > 256
836
- fail ArgumentError, 'invalid value for "endpoint_id" when calling EndpointApi.patch_endpoint_headers_api_v1_app_app_id_endpoint_endpoint_id_headers_patch, the character length must be smaller than or equal to 256.'
827
+ fail ArgumentError, 'invalid value for "endpoint_id" when calling EndpointApi.v1_endpoint_patch_headers, the character length must be smaller than or equal to 256.'
837
828
  end
838
829
 
839
830
  if @api_client.config.client_side_validation && endpoint_id.to_s.length < 1
840
- fail ArgumentError, 'invalid value for "endpoint_id" when calling EndpointApi.patch_endpoint_headers_api_v1_app_app_id_endpoint_endpoint_id_headers_patch, the character length must be great than or equal to 1.'
831
+ fail ArgumentError, 'invalid value for "endpoint_id" when calling EndpointApi.v1_endpoint_patch_headers, the character length must be great than or equal to 1.'
841
832
  end
842
833
 
843
834
  pattern = Regexp.new(/^[a-zA-Z0-9\-_.]+$/)
844
835
  if @api_client.config.client_side_validation && endpoint_id !~ pattern
845
- fail ArgumentError, "invalid value for 'endpoint_id' when calling EndpointApi.patch_endpoint_headers_api_v1_app_app_id_endpoint_endpoint_id_headers_patch, must conform to the pattern #{pattern}."
836
+ fail ArgumentError, "invalid value for 'endpoint_id' when calling EndpointApi.v1_endpoint_patch_headers, must conform to the pattern #{pattern}."
846
837
  end
847
838
 
848
839
  # verify the required parameter 'endpoint_headers_patch_in' is set
849
840
  if @api_client.config.client_side_validation && endpoint_headers_patch_in.nil?
850
- fail ArgumentError, "Missing the required parameter 'endpoint_headers_patch_in' when calling EndpointApi.patch_endpoint_headers_api_v1_app_app_id_endpoint_endpoint_id_headers_patch"
841
+ fail ArgumentError, "Missing the required parameter 'endpoint_headers_patch_in' when calling EndpointApi.v1_endpoint_patch_headers"
851
842
  end
852
843
  # resource path
853
844
  local_var_path = '/api/v1/app/{app_id}/endpoint/{endpoint_id}/headers/'.sub('{' + 'app_id' + '}', CGI.escape(app_id.to_s)).sub('{' + 'endpoint_id' + '}', CGI.escape(endpoint_id.to_s))
@@ -861,7 +852,6 @@ module Svix
861
852
  header_params['Accept'] = @api_client.select_header_accept(['application/json'])
862
853
  # HTTP header 'Content-Type'
863
854
  header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])
864
- header_params[:'idempotency-key'] = opts[:'idempotency_key'] if !opts[:'idempotency_key'].nil?
865
855
 
866
856
  # form parameters
867
857
  form_params = opts[:form_params] || {}
@@ -873,10 +863,10 @@ module Svix
873
863
  return_type = opts[:debug_return_type]
874
864
 
875
865
  # auth_names
876
- auth_names = opts[:debug_auth_names] || ['HTTPBearer']
866
+ auth_names = opts[:debug_auth_names] || []
877
867
 
878
868
  new_options = opts.merge(
879
- :operation => :"EndpointApi.patch_endpoint_headers_api_v1_app_app_id_endpoint_endpoint_id_headers_patch",
869
+ :operation => :"EndpointApi.v1_endpoint_patch_headers",
880
870
  :header_params => header_params,
881
871
  :query_params => query_params,
882
872
  :form_params => form_params,
@@ -887,7 +877,7 @@ module Svix
887
877
 
888
878
  data, status_code, headers = @api_client.call_api(:PATCH, local_var_path, new_options)
889
879
  if @api_client.config.debugging
890
- @api_client.config.logger.debug "API called: EndpointApi#patch_endpoint_headers_api_v1_app_app_id_endpoint_endpoint_id_headers_patch\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
880
+ @api_client.config.logger.debug "API called: EndpointApi#v1_endpoint_patch_headers\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
891
881
  end
892
882
  return data, status_code, headers
893
883
  end
@@ -899,9 +889,9 @@ module Svix
899
889
  # @param recover_in [RecoverIn]
900
890
  # @param [Hash] opts the optional parameters
901
891
  # @option opts [String] :idempotency_key The request&#39;s idempotency key
902
- # @return [Object]
903
- def recover_failed_webhooks_api_v1_app_app_id_endpoint_endpoint_id_recover_post(app_id, endpoint_id, recover_in, opts = {})
904
- data, _status_code, _headers = recover_failed_webhooks_api_v1_app_app_id_endpoint_endpoint_id_recover_post_with_http_info(app_id, endpoint_id, recover_in, opts)
892
+ # @return [RecoverOut]
893
+ def v1_endpoint_recover(app_id, endpoint_id, recover_in, opts = {})
894
+ data, _status_code, _headers = v1_endpoint_recover_with_http_info(app_id, endpoint_id, recover_in, opts)
905
895
  data
906
896
  end
907
897
 
@@ -912,48 +902,48 @@ module Svix
912
902
  # @param recover_in [RecoverIn]
913
903
  # @param [Hash] opts the optional parameters
914
904
  # @option opts [String] :idempotency_key The request&#39;s idempotency key
915
- # @return [Array<(Object, Integer, Hash)>] Object data, response status code and response headers
916
- def recover_failed_webhooks_api_v1_app_app_id_endpoint_endpoint_id_recover_post_with_http_info(app_id, endpoint_id, recover_in, opts = {})
905
+ # @return [Array<(RecoverOut, Integer, Hash)>] RecoverOut data, response status code and response headers
906
+ def v1_endpoint_recover_with_http_info(app_id, endpoint_id, recover_in, opts = {})
917
907
  if @api_client.config.debugging
918
- @api_client.config.logger.debug 'Calling API: EndpointApi.recover_failed_webhooks_api_v1_app_app_id_endpoint_endpoint_id_recover_post ...'
908
+ @api_client.config.logger.debug 'Calling API: EndpointApi.v1_endpoint_recover ...'
919
909
  end
920
910
  # verify the required parameter 'app_id' is set
921
911
  if @api_client.config.client_side_validation && app_id.nil?
922
- fail ArgumentError, "Missing the required parameter 'app_id' when calling EndpointApi.recover_failed_webhooks_api_v1_app_app_id_endpoint_endpoint_id_recover_post"
912
+ fail ArgumentError, "Missing the required parameter 'app_id' when calling EndpointApi.v1_endpoint_recover"
923
913
  end
924
914
  if @api_client.config.client_side_validation && app_id.to_s.length > 256
925
- fail ArgumentError, 'invalid value for "app_id" when calling EndpointApi.recover_failed_webhooks_api_v1_app_app_id_endpoint_endpoint_id_recover_post, the character length must be smaller than or equal to 256.'
915
+ fail ArgumentError, 'invalid value for "app_id" when calling EndpointApi.v1_endpoint_recover, the character length must be smaller than or equal to 256.'
926
916
  end
927
917
 
928
918
  if @api_client.config.client_side_validation && app_id.to_s.length < 1
929
- fail ArgumentError, 'invalid value for "app_id" when calling EndpointApi.recover_failed_webhooks_api_v1_app_app_id_endpoint_endpoint_id_recover_post, the character length must be great than or equal to 1.'
919
+ fail ArgumentError, 'invalid value for "app_id" when calling EndpointApi.v1_endpoint_recover, the character length must be great than or equal to 1.'
930
920
  end
931
921
 
932
922
  pattern = Regexp.new(/^[a-zA-Z0-9\-_.]+$/)
933
923
  if @api_client.config.client_side_validation && app_id !~ pattern
934
- fail ArgumentError, "invalid value for 'app_id' when calling EndpointApi.recover_failed_webhooks_api_v1_app_app_id_endpoint_endpoint_id_recover_post, must conform to the pattern #{pattern}."
924
+ fail ArgumentError, "invalid value for 'app_id' when calling EndpointApi.v1_endpoint_recover, must conform to the pattern #{pattern}."
935
925
  end
936
926
 
937
927
  # verify the required parameter 'endpoint_id' is set
938
928
  if @api_client.config.client_side_validation && endpoint_id.nil?
939
- fail ArgumentError, "Missing the required parameter 'endpoint_id' when calling EndpointApi.recover_failed_webhooks_api_v1_app_app_id_endpoint_endpoint_id_recover_post"
929
+ fail ArgumentError, "Missing the required parameter 'endpoint_id' when calling EndpointApi.v1_endpoint_recover"
940
930
  end
941
931
  if @api_client.config.client_side_validation && endpoint_id.to_s.length > 256
942
- fail ArgumentError, 'invalid value for "endpoint_id" when calling EndpointApi.recover_failed_webhooks_api_v1_app_app_id_endpoint_endpoint_id_recover_post, the character length must be smaller than or equal to 256.'
932
+ fail ArgumentError, 'invalid value for "endpoint_id" when calling EndpointApi.v1_endpoint_recover, the character length must be smaller than or equal to 256.'
943
933
  end
944
934
 
945
935
  if @api_client.config.client_side_validation && endpoint_id.to_s.length < 1
946
- fail ArgumentError, 'invalid value for "endpoint_id" when calling EndpointApi.recover_failed_webhooks_api_v1_app_app_id_endpoint_endpoint_id_recover_post, the character length must be great than or equal to 1.'
936
+ fail ArgumentError, 'invalid value for "endpoint_id" when calling EndpointApi.v1_endpoint_recover, the character length must be great than or equal to 1.'
947
937
  end
948
938
 
949
939
  pattern = Regexp.new(/^[a-zA-Z0-9\-_.]+$/)
950
940
  if @api_client.config.client_side_validation && endpoint_id !~ pattern
951
- fail ArgumentError, "invalid value for 'endpoint_id' when calling EndpointApi.recover_failed_webhooks_api_v1_app_app_id_endpoint_endpoint_id_recover_post, must conform to the pattern #{pattern}."
941
+ fail ArgumentError, "invalid value for 'endpoint_id' when calling EndpointApi.v1_endpoint_recover, must conform to the pattern #{pattern}."
952
942
  end
953
943
 
954
944
  # verify the required parameter 'recover_in' is set
955
945
  if @api_client.config.client_side_validation && recover_in.nil?
956
- fail ArgumentError, "Missing the required parameter 'recover_in' when calling EndpointApi.recover_failed_webhooks_api_v1_app_app_id_endpoint_endpoint_id_recover_post"
946
+ fail ArgumentError, "Missing the required parameter 'recover_in' when calling EndpointApi.v1_endpoint_recover"
957
947
  end
958
948
  # resource path
959
949
  local_var_path = '/api/v1/app/{app_id}/endpoint/{endpoint_id}/recover/'.sub('{' + 'app_id' + '}', CGI.escape(app_id.to_s)).sub('{' + 'endpoint_id' + '}', CGI.escape(endpoint_id.to_s))
@@ -976,13 +966,13 @@ module Svix
976
966
  post_body = opts[:debug_body] || @api_client.object_to_http_body(recover_in)
977
967
 
978
968
  # return_type
979
- return_type = opts[:debug_return_type] || 'Object'
969
+ return_type = opts[:debug_return_type] || 'RecoverOut'
980
970
 
981
971
  # auth_names
982
- auth_names = opts[:debug_auth_names] || ['HTTPBearer']
972
+ auth_names = opts[:debug_auth_names] || []
983
973
 
984
974
  new_options = opts.merge(
985
- :operation => :"EndpointApi.recover_failed_webhooks_api_v1_app_app_id_endpoint_endpoint_id_recover_post",
975
+ :operation => :"EndpointApi.v1_endpoint_recover",
986
976
  :header_params => header_params,
987
977
  :query_params => query_params,
988
978
  :form_params => form_params,
@@ -993,7 +983,7 @@ module Svix
993
983
 
994
984
  data, status_code, headers = @api_client.call_api(:POST, local_var_path, new_options)
995
985
  if @api_client.config.debugging
996
- @api_client.config.logger.debug "API called: EndpointApi#recover_failed_webhooks_api_v1_app_app_id_endpoint_endpoint_id_recover_post\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
986
+ @api_client.config.logger.debug "API called: EndpointApi#v1_endpoint_recover\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
997
987
  end
998
988
  return data, status_code, headers
999
989
  end
@@ -1005,9 +995,9 @@ module Svix
1005
995
  # @param replay_in [ReplayIn]
1006
996
  # @param [Hash] opts the optional parameters
1007
997
  # @option opts [String] :idempotency_key The request&#39;s idempotency key
1008
- # @return [Object]
1009
- def replay_missing_webhooks_api_v1_app_app_id_endpoint_endpoint_id_replay_missing_post(app_id, endpoint_id, replay_in, opts = {})
1010
- data, _status_code, _headers = replay_missing_webhooks_api_v1_app_app_id_endpoint_endpoint_id_replay_missing_post_with_http_info(app_id, endpoint_id, replay_in, opts)
998
+ # @return [ReplayOut]
999
+ def v1_endpoint_replay(app_id, endpoint_id, replay_in, opts = {})
1000
+ data, _status_code, _headers = v1_endpoint_replay_with_http_info(app_id, endpoint_id, replay_in, opts)
1011
1001
  data
1012
1002
  end
1013
1003
 
@@ -1018,48 +1008,48 @@ module Svix
1018
1008
  # @param replay_in [ReplayIn]
1019
1009
  # @param [Hash] opts the optional parameters
1020
1010
  # @option opts [String] :idempotency_key The request&#39;s idempotency key
1021
- # @return [Array<(Object, Integer, Hash)>] Object data, response status code and response headers
1022
- def replay_missing_webhooks_api_v1_app_app_id_endpoint_endpoint_id_replay_missing_post_with_http_info(app_id, endpoint_id, replay_in, opts = {})
1011
+ # @return [Array<(ReplayOut, Integer, Hash)>] ReplayOut data, response status code and response headers
1012
+ def v1_endpoint_replay_with_http_info(app_id, endpoint_id, replay_in, opts = {})
1023
1013
  if @api_client.config.debugging
1024
- @api_client.config.logger.debug 'Calling API: EndpointApi.replay_missing_webhooks_api_v1_app_app_id_endpoint_endpoint_id_replay_missing_post ...'
1014
+ @api_client.config.logger.debug 'Calling API: EndpointApi.v1_endpoint_replay ...'
1025
1015
  end
1026
1016
  # verify the required parameter 'app_id' is set
1027
1017
  if @api_client.config.client_side_validation && app_id.nil?
1028
- fail ArgumentError, "Missing the required parameter 'app_id' when calling EndpointApi.replay_missing_webhooks_api_v1_app_app_id_endpoint_endpoint_id_replay_missing_post"
1018
+ fail ArgumentError, "Missing the required parameter 'app_id' when calling EndpointApi.v1_endpoint_replay"
1029
1019
  end
1030
1020
  if @api_client.config.client_side_validation && app_id.to_s.length > 256
1031
- fail ArgumentError, 'invalid value for "app_id" when calling EndpointApi.replay_missing_webhooks_api_v1_app_app_id_endpoint_endpoint_id_replay_missing_post, the character length must be smaller than or equal to 256.'
1021
+ fail ArgumentError, 'invalid value for "app_id" when calling EndpointApi.v1_endpoint_replay, the character length must be smaller than or equal to 256.'
1032
1022
  end
1033
1023
 
1034
1024
  if @api_client.config.client_side_validation && app_id.to_s.length < 1
1035
- fail ArgumentError, 'invalid value for "app_id" when calling EndpointApi.replay_missing_webhooks_api_v1_app_app_id_endpoint_endpoint_id_replay_missing_post, the character length must be great than or equal to 1.'
1025
+ fail ArgumentError, 'invalid value for "app_id" when calling EndpointApi.v1_endpoint_replay, the character length must be great than or equal to 1.'
1036
1026
  end
1037
1027
 
1038
1028
  pattern = Regexp.new(/^[a-zA-Z0-9\-_.]+$/)
1039
1029
  if @api_client.config.client_side_validation && app_id !~ pattern
1040
- fail ArgumentError, "invalid value for 'app_id' when calling EndpointApi.replay_missing_webhooks_api_v1_app_app_id_endpoint_endpoint_id_replay_missing_post, must conform to the pattern #{pattern}."
1030
+ fail ArgumentError, "invalid value for 'app_id' when calling EndpointApi.v1_endpoint_replay, must conform to the pattern #{pattern}."
1041
1031
  end
1042
1032
 
1043
1033
  # verify the required parameter 'endpoint_id' is set
1044
1034
  if @api_client.config.client_side_validation && endpoint_id.nil?
1045
- fail ArgumentError, "Missing the required parameter 'endpoint_id' when calling EndpointApi.replay_missing_webhooks_api_v1_app_app_id_endpoint_endpoint_id_replay_missing_post"
1035
+ fail ArgumentError, "Missing the required parameter 'endpoint_id' when calling EndpointApi.v1_endpoint_replay"
1046
1036
  end
1047
1037
  if @api_client.config.client_side_validation && endpoint_id.to_s.length > 256
1048
- fail ArgumentError, 'invalid value for "endpoint_id" when calling EndpointApi.replay_missing_webhooks_api_v1_app_app_id_endpoint_endpoint_id_replay_missing_post, the character length must be smaller than or equal to 256.'
1038
+ fail ArgumentError, 'invalid value for "endpoint_id" when calling EndpointApi.v1_endpoint_replay, the character length must be smaller than or equal to 256.'
1049
1039
  end
1050
1040
 
1051
1041
  if @api_client.config.client_side_validation && endpoint_id.to_s.length < 1
1052
- fail ArgumentError, 'invalid value for "endpoint_id" when calling EndpointApi.replay_missing_webhooks_api_v1_app_app_id_endpoint_endpoint_id_replay_missing_post, the character length must be great than or equal to 1.'
1042
+ fail ArgumentError, 'invalid value for "endpoint_id" when calling EndpointApi.v1_endpoint_replay, the character length must be great than or equal to 1.'
1053
1043
  end
1054
1044
 
1055
1045
  pattern = Regexp.new(/^[a-zA-Z0-9\-_.]+$/)
1056
1046
  if @api_client.config.client_side_validation && endpoint_id !~ pattern
1057
- fail ArgumentError, "invalid value for 'endpoint_id' when calling EndpointApi.replay_missing_webhooks_api_v1_app_app_id_endpoint_endpoint_id_replay_missing_post, must conform to the pattern #{pattern}."
1047
+ fail ArgumentError, "invalid value for 'endpoint_id' when calling EndpointApi.v1_endpoint_replay, must conform to the pattern #{pattern}."
1058
1048
  end
1059
1049
 
1060
1050
  # verify the required parameter 'replay_in' is set
1061
1051
  if @api_client.config.client_side_validation && replay_in.nil?
1062
- fail ArgumentError, "Missing the required parameter 'replay_in' when calling EndpointApi.replay_missing_webhooks_api_v1_app_app_id_endpoint_endpoint_id_replay_missing_post"
1052
+ fail ArgumentError, "Missing the required parameter 'replay_in' when calling EndpointApi.v1_endpoint_replay"
1063
1053
  end
1064
1054
  # resource path
1065
1055
  local_var_path = '/api/v1/app/{app_id}/endpoint/{endpoint_id}/replay-missing/'.sub('{' + 'app_id' + '}', CGI.escape(app_id.to_s)).sub('{' + 'endpoint_id' + '}', CGI.escape(endpoint_id.to_s))
@@ -1082,13 +1072,13 @@ module Svix
1082
1072
  post_body = opts[:debug_body] || @api_client.object_to_http_body(replay_in)
1083
1073
 
1084
1074
  # return_type
1085
- return_type = opts[:debug_return_type] || 'Object'
1075
+ return_type = opts[:debug_return_type] || 'ReplayOut'
1086
1076
 
1087
1077
  # auth_names
1088
- auth_names = opts[:debug_auth_names] || ['HTTPBearer']
1078
+ auth_names = opts[:debug_auth_names] || []
1089
1079
 
1090
1080
  new_options = opts.merge(
1091
- :operation => :"EndpointApi.replay_missing_webhooks_api_v1_app_app_id_endpoint_endpoint_id_replay_missing_post",
1081
+ :operation => :"EndpointApi.v1_endpoint_replay",
1092
1082
  :header_params => header_params,
1093
1083
  :query_params => query_params,
1094
1084
  :form_params => form_params,
@@ -1099,76 +1089,76 @@ module Svix
1099
1089
 
1100
1090
  data, status_code, headers = @api_client.call_api(:POST, local_var_path, new_options)
1101
1091
  if @api_client.config.debugging
1102
- @api_client.config.logger.debug "API called: EndpointApi#replay_missing_webhooks_api_v1_app_app_id_endpoint_endpoint_id_replay_missing_post\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
1092
+ @api_client.config.logger.debug "API called: EndpointApi#v1_endpoint_replay\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
1103
1093
  end
1104
1094
  return data, status_code, headers
1105
1095
  end
1106
1096
 
1107
1097
  # Rotate Endpoint Secret
1108
1098
  # Rotates the endpoint's signing secret. The previous secret will be valid for the next 24 hours.
1109
- # @param endpoint_id [String]
1110
1099
  # @param app_id [String]
1100
+ # @param endpoint_id [String]
1111
1101
  # @param endpoint_secret_rotate_in [EndpointSecretRotateIn]
1112
1102
  # @param [Hash] opts the optional parameters
1113
1103
  # @option opts [String] :idempotency_key The request&#39;s idempotency key
1114
1104
  # @return [nil]
1115
- def rotate_endpoint_secret_api_v1_app_app_id_endpoint_endpoint_id_secret_rotate_post(endpoint_id, app_id, endpoint_secret_rotate_in, opts = {})
1116
- rotate_endpoint_secret_api_v1_app_app_id_endpoint_endpoint_id_secret_rotate_post_with_http_info(endpoint_id, app_id, endpoint_secret_rotate_in, opts)
1105
+ def v1_endpoint_rotate_secret(app_id, endpoint_id, endpoint_secret_rotate_in, opts = {})
1106
+ v1_endpoint_rotate_secret_with_http_info(app_id, endpoint_id, endpoint_secret_rotate_in, opts)
1117
1107
  nil
1118
1108
  end
1119
1109
 
1120
1110
  # Rotate Endpoint Secret
1121
1111
  # Rotates the endpoint&#39;s signing secret. The previous secret will be valid for the next 24 hours.
1122
- # @param endpoint_id [String]
1123
1112
  # @param app_id [String]
1113
+ # @param endpoint_id [String]
1124
1114
  # @param endpoint_secret_rotate_in [EndpointSecretRotateIn]
1125
1115
  # @param [Hash] opts the optional parameters
1126
1116
  # @option opts [String] :idempotency_key The request&#39;s idempotency key
1127
1117
  # @return [Array<(nil, Integer, Hash)>] nil, response status code and response headers
1128
- def rotate_endpoint_secret_api_v1_app_app_id_endpoint_endpoint_id_secret_rotate_post_with_http_info(endpoint_id, app_id, endpoint_secret_rotate_in, opts = {})
1118
+ def v1_endpoint_rotate_secret_with_http_info(app_id, endpoint_id, endpoint_secret_rotate_in, opts = {})
1129
1119
  if @api_client.config.debugging
1130
- @api_client.config.logger.debug 'Calling API: EndpointApi.rotate_endpoint_secret_api_v1_app_app_id_endpoint_endpoint_id_secret_rotate_post ...'
1120
+ @api_client.config.logger.debug 'Calling API: EndpointApi.v1_endpoint_rotate_secret ...'
1131
1121
  end
1132
- # verify the required parameter 'endpoint_id' is set
1133
- if @api_client.config.client_side_validation && endpoint_id.nil?
1134
- fail ArgumentError, "Missing the required parameter 'endpoint_id' when calling EndpointApi.rotate_endpoint_secret_api_v1_app_app_id_endpoint_endpoint_id_secret_rotate_post"
1122
+ # verify the required parameter 'app_id' is set
1123
+ if @api_client.config.client_side_validation && app_id.nil?
1124
+ fail ArgumentError, "Missing the required parameter 'app_id' when calling EndpointApi.v1_endpoint_rotate_secret"
1135
1125
  end
1136
- if @api_client.config.client_side_validation && endpoint_id.to_s.length > 256
1137
- fail ArgumentError, 'invalid value for "endpoint_id" when calling EndpointApi.rotate_endpoint_secret_api_v1_app_app_id_endpoint_endpoint_id_secret_rotate_post, the character length must be smaller than or equal to 256.'
1126
+ if @api_client.config.client_side_validation && app_id.to_s.length > 256
1127
+ fail ArgumentError, 'invalid value for "app_id" when calling EndpointApi.v1_endpoint_rotate_secret, the character length must be smaller than or equal to 256.'
1138
1128
  end
1139
1129
 
1140
- if @api_client.config.client_side_validation && endpoint_id.to_s.length < 1
1141
- fail ArgumentError, 'invalid value for "endpoint_id" when calling EndpointApi.rotate_endpoint_secret_api_v1_app_app_id_endpoint_endpoint_id_secret_rotate_post, the character length must be great than or equal to 1.'
1130
+ if @api_client.config.client_side_validation && app_id.to_s.length < 1
1131
+ fail ArgumentError, 'invalid value for "app_id" when calling EndpointApi.v1_endpoint_rotate_secret, the character length must be great than or equal to 1.'
1142
1132
  end
1143
1133
 
1144
1134
  pattern = Regexp.new(/^[a-zA-Z0-9\-_.]+$/)
1145
- if @api_client.config.client_side_validation && endpoint_id !~ pattern
1146
- fail ArgumentError, "invalid value for 'endpoint_id' when calling EndpointApi.rotate_endpoint_secret_api_v1_app_app_id_endpoint_endpoint_id_secret_rotate_post, must conform to the pattern #{pattern}."
1135
+ if @api_client.config.client_side_validation && app_id !~ pattern
1136
+ fail ArgumentError, "invalid value for 'app_id' when calling EndpointApi.v1_endpoint_rotate_secret, must conform to the pattern #{pattern}."
1147
1137
  end
1148
1138
 
1149
- # verify the required parameter 'app_id' is set
1150
- if @api_client.config.client_side_validation && app_id.nil?
1151
- fail ArgumentError, "Missing the required parameter 'app_id' when calling EndpointApi.rotate_endpoint_secret_api_v1_app_app_id_endpoint_endpoint_id_secret_rotate_post"
1139
+ # verify the required parameter 'endpoint_id' is set
1140
+ if @api_client.config.client_side_validation && endpoint_id.nil?
1141
+ fail ArgumentError, "Missing the required parameter 'endpoint_id' when calling EndpointApi.v1_endpoint_rotate_secret"
1152
1142
  end
1153
- if @api_client.config.client_side_validation && app_id.to_s.length > 256
1154
- fail ArgumentError, 'invalid value for "app_id" when calling EndpointApi.rotate_endpoint_secret_api_v1_app_app_id_endpoint_endpoint_id_secret_rotate_post, the character length must be smaller than or equal to 256.'
1143
+ if @api_client.config.client_side_validation && endpoint_id.to_s.length > 256
1144
+ fail ArgumentError, 'invalid value for "endpoint_id" when calling EndpointApi.v1_endpoint_rotate_secret, the character length must be smaller than or equal to 256.'
1155
1145
  end
1156
1146
 
1157
- if @api_client.config.client_side_validation && app_id.to_s.length < 1
1158
- fail ArgumentError, 'invalid value for "app_id" when calling EndpointApi.rotate_endpoint_secret_api_v1_app_app_id_endpoint_endpoint_id_secret_rotate_post, the character length must be great than or equal to 1.'
1147
+ if @api_client.config.client_side_validation && endpoint_id.to_s.length < 1
1148
+ fail ArgumentError, 'invalid value for "endpoint_id" when calling EndpointApi.v1_endpoint_rotate_secret, the character length must be great than or equal to 1.'
1159
1149
  end
1160
1150
 
1161
1151
  pattern = Regexp.new(/^[a-zA-Z0-9\-_.]+$/)
1162
- if @api_client.config.client_side_validation && app_id !~ pattern
1163
- fail ArgumentError, "invalid value for 'app_id' when calling EndpointApi.rotate_endpoint_secret_api_v1_app_app_id_endpoint_endpoint_id_secret_rotate_post, must conform to the pattern #{pattern}."
1152
+ if @api_client.config.client_side_validation && endpoint_id !~ pattern
1153
+ fail ArgumentError, "invalid value for 'endpoint_id' when calling EndpointApi.v1_endpoint_rotate_secret, must conform to the pattern #{pattern}."
1164
1154
  end
1165
1155
 
1166
1156
  # verify the required parameter 'endpoint_secret_rotate_in' is set
1167
1157
  if @api_client.config.client_side_validation && endpoint_secret_rotate_in.nil?
1168
- fail ArgumentError, "Missing the required parameter 'endpoint_secret_rotate_in' when calling EndpointApi.rotate_endpoint_secret_api_v1_app_app_id_endpoint_endpoint_id_secret_rotate_post"
1158
+ fail ArgumentError, "Missing the required parameter 'endpoint_secret_rotate_in' when calling EndpointApi.v1_endpoint_rotate_secret"
1169
1159
  end
1170
1160
  # resource path
1171
- local_var_path = '/api/v1/app/{app_id}/endpoint/{endpoint_id}/secret/rotate/'.sub('{' + 'endpoint_id' + '}', CGI.escape(endpoint_id.to_s)).sub('{' + 'app_id' + '}', CGI.escape(app_id.to_s))
1161
+ local_var_path = '/api/v1/app/{app_id}/endpoint/{endpoint_id}/secret/rotate/'.sub('{' + 'app_id' + '}', CGI.escape(app_id.to_s)).sub('{' + 'endpoint_id' + '}', CGI.escape(endpoint_id.to_s))
1172
1162
 
1173
1163
  # query parameters
1174
1164
  query_params = opts[:query_params] || {}
@@ -1191,10 +1181,10 @@ module Svix
1191
1181
  return_type = opts[:debug_return_type]
1192
1182
 
1193
1183
  # auth_names
1194
- auth_names = opts[:debug_auth_names] || ['HTTPBearer']
1184
+ auth_names = opts[:debug_auth_names] || []
1195
1185
 
1196
1186
  new_options = opts.merge(
1197
- :operation => :"EndpointApi.rotate_endpoint_secret_api_v1_app_app_id_endpoint_endpoint_id_secret_rotate_post",
1187
+ :operation => :"EndpointApi.v1_endpoint_rotate_secret",
1198
1188
  :header_params => header_params,
1199
1189
  :query_params => query_params,
1200
1190
  :form_params => form_params,
@@ -1205,12 +1195,12 @@ module Svix
1205
1195
 
1206
1196
  data, status_code, headers = @api_client.call_api(:POST, local_var_path, new_options)
1207
1197
  if @api_client.config.debugging
1208
- @api_client.config.logger.debug "API called: EndpointApi#rotate_endpoint_secret_api_v1_app_app_id_endpoint_endpoint_id_secret_rotate_post\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
1198
+ @api_client.config.logger.debug "API called: EndpointApi#v1_endpoint_rotate_secret\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
1209
1199
  end
1210
1200
  return data, status_code, headers
1211
1201
  end
1212
1202
 
1213
- # Send Event Type Example Message
1203
+ # Send Example
1214
1204
  # Send an example message for event
1215
1205
  # @param app_id [String]
1216
1206
  # @param endpoint_id [String]
@@ -1218,12 +1208,12 @@ module Svix
1218
1208
  # @param [Hash] opts the optional parameters
1219
1209
  # @option opts [String] :idempotency_key The request&#39;s idempotency key
1220
1210
  # @return [MessageOut]
1221
- def send_event_type_example_message_api_v1_app_app_id_endpoint_endpoint_id_send_example_post(app_id, endpoint_id, event_example_in, opts = {})
1222
- data, _status_code, _headers = send_event_type_example_message_api_v1_app_app_id_endpoint_endpoint_id_send_example_post_with_http_info(app_id, endpoint_id, event_example_in, opts)
1211
+ def v1_endpoint_send_example(app_id, endpoint_id, event_example_in, opts = {})
1212
+ data, _status_code, _headers = v1_endpoint_send_example_with_http_info(app_id, endpoint_id, event_example_in, opts)
1223
1213
  data
1224
1214
  end
1225
1215
 
1226
- # Send Event Type Example Message
1216
+ # Send Example
1227
1217
  # Send an example message for event
1228
1218
  # @param app_id [String]
1229
1219
  # @param endpoint_id [String]
@@ -1231,47 +1221,47 @@ module Svix
1231
1221
  # @param [Hash] opts the optional parameters
1232
1222
  # @option opts [String] :idempotency_key The request&#39;s idempotency key
1233
1223
  # @return [Array<(MessageOut, Integer, Hash)>] MessageOut data, response status code and response headers
1234
- def send_event_type_example_message_api_v1_app_app_id_endpoint_endpoint_id_send_example_post_with_http_info(app_id, endpoint_id, event_example_in, opts = {})
1224
+ def v1_endpoint_send_example_with_http_info(app_id, endpoint_id, event_example_in, opts = {})
1235
1225
  if @api_client.config.debugging
1236
- @api_client.config.logger.debug 'Calling API: EndpointApi.send_event_type_example_message_api_v1_app_app_id_endpoint_endpoint_id_send_example_post ...'
1226
+ @api_client.config.logger.debug 'Calling API: EndpointApi.v1_endpoint_send_example ...'
1237
1227
  end
1238
1228
  # verify the required parameter 'app_id' is set
1239
1229
  if @api_client.config.client_side_validation && app_id.nil?
1240
- fail ArgumentError, "Missing the required parameter 'app_id' when calling EndpointApi.send_event_type_example_message_api_v1_app_app_id_endpoint_endpoint_id_send_example_post"
1230
+ fail ArgumentError, "Missing the required parameter 'app_id' when calling EndpointApi.v1_endpoint_send_example"
1241
1231
  end
1242
1232
  if @api_client.config.client_side_validation && app_id.to_s.length > 256
1243
- fail ArgumentError, 'invalid value for "app_id" when calling EndpointApi.send_event_type_example_message_api_v1_app_app_id_endpoint_endpoint_id_send_example_post, the character length must be smaller than or equal to 256.'
1233
+ fail ArgumentError, 'invalid value for "app_id" when calling EndpointApi.v1_endpoint_send_example, the character length must be smaller than or equal to 256.'
1244
1234
  end
1245
1235
 
1246
1236
  if @api_client.config.client_side_validation && app_id.to_s.length < 1
1247
- fail ArgumentError, 'invalid value for "app_id" when calling EndpointApi.send_event_type_example_message_api_v1_app_app_id_endpoint_endpoint_id_send_example_post, the character length must be great than or equal to 1.'
1237
+ fail ArgumentError, 'invalid value for "app_id" when calling EndpointApi.v1_endpoint_send_example, the character length must be great than or equal to 1.'
1248
1238
  end
1249
1239
 
1250
1240
  pattern = Regexp.new(/^[a-zA-Z0-9\-_.]+$/)
1251
1241
  if @api_client.config.client_side_validation && app_id !~ pattern
1252
- fail ArgumentError, "invalid value for 'app_id' when calling EndpointApi.send_event_type_example_message_api_v1_app_app_id_endpoint_endpoint_id_send_example_post, must conform to the pattern #{pattern}."
1242
+ fail ArgumentError, "invalid value for 'app_id' when calling EndpointApi.v1_endpoint_send_example, must conform to the pattern #{pattern}."
1253
1243
  end
1254
1244
 
1255
1245
  # verify the required parameter 'endpoint_id' is set
1256
1246
  if @api_client.config.client_side_validation && endpoint_id.nil?
1257
- fail ArgumentError, "Missing the required parameter 'endpoint_id' when calling EndpointApi.send_event_type_example_message_api_v1_app_app_id_endpoint_endpoint_id_send_example_post"
1247
+ fail ArgumentError, "Missing the required parameter 'endpoint_id' when calling EndpointApi.v1_endpoint_send_example"
1258
1248
  end
1259
1249
  if @api_client.config.client_side_validation && endpoint_id.to_s.length > 256
1260
- fail ArgumentError, 'invalid value for "endpoint_id" when calling EndpointApi.send_event_type_example_message_api_v1_app_app_id_endpoint_endpoint_id_send_example_post, the character length must be smaller than or equal to 256.'
1250
+ fail ArgumentError, 'invalid value for "endpoint_id" when calling EndpointApi.v1_endpoint_send_example, the character length must be smaller than or equal to 256.'
1261
1251
  end
1262
1252
 
1263
1253
  if @api_client.config.client_side_validation && endpoint_id.to_s.length < 1
1264
- fail ArgumentError, 'invalid value for "endpoint_id" when calling EndpointApi.send_event_type_example_message_api_v1_app_app_id_endpoint_endpoint_id_send_example_post, the character length must be great than or equal to 1.'
1254
+ fail ArgumentError, 'invalid value for "endpoint_id" when calling EndpointApi.v1_endpoint_send_example, the character length must be great than or equal to 1.'
1265
1255
  end
1266
1256
 
1267
1257
  pattern = Regexp.new(/^[a-zA-Z0-9\-_.]+$/)
1268
1258
  if @api_client.config.client_side_validation && endpoint_id !~ pattern
1269
- fail ArgumentError, "invalid value for 'endpoint_id' when calling EndpointApi.send_event_type_example_message_api_v1_app_app_id_endpoint_endpoint_id_send_example_post, must conform to the pattern #{pattern}."
1259
+ fail ArgumentError, "invalid value for 'endpoint_id' when calling EndpointApi.v1_endpoint_send_example, must conform to the pattern #{pattern}."
1270
1260
  end
1271
1261
 
1272
1262
  # verify the required parameter 'event_example_in' is set
1273
1263
  if @api_client.config.client_side_validation && event_example_in.nil?
1274
- fail ArgumentError, "Missing the required parameter 'event_example_in' when calling EndpointApi.send_event_type_example_message_api_v1_app_app_id_endpoint_endpoint_id_send_example_post"
1264
+ fail ArgumentError, "Missing the required parameter 'event_example_in' when calling EndpointApi.v1_endpoint_send_example"
1275
1265
  end
1276
1266
  # resource path
1277
1267
  local_var_path = '/api/v1/app/{app_id}/endpoint/{endpoint_id}/send-example/'.sub('{' + 'app_id' + '}', CGI.escape(app_id.to_s)).sub('{' + 'endpoint_id' + '}', CGI.escape(endpoint_id.to_s))
@@ -1297,10 +1287,10 @@ module Svix
1297
1287
  return_type = opts[:debug_return_type] || 'MessageOut'
1298
1288
 
1299
1289
  # auth_names
1300
- auth_names = opts[:debug_auth_names] || ['HTTPBearer']
1290
+ auth_names = opts[:debug_auth_names] || []
1301
1291
 
1302
1292
  new_options = opts.merge(
1303
- :operation => :"EndpointApi.send_event_type_example_message_api_v1_app_app_id_endpoint_endpoint_id_send_example_post",
1293
+ :operation => :"EndpointApi.v1_endpoint_send_example",
1304
1294
  :header_params => header_params,
1305
1295
  :query_params => query_params,
1306
1296
  :form_params => form_params,
@@ -1311,73 +1301,166 @@ module Svix
1311
1301
 
1312
1302
  data, status_code, headers = @api_client.call_api(:POST, local_var_path, new_options)
1313
1303
  if @api_client.config.debugging
1314
- @api_client.config.logger.debug "API called: EndpointApi#send_event_type_example_message_api_v1_app_app_id_endpoint_endpoint_id_send_example_post\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
1304
+ @api_client.config.logger.debug "API called: EndpointApi#v1_endpoint_send_example\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
1315
1305
  end
1316
1306
  return data, status_code, headers
1317
1307
  end
1318
1308
 
1319
- # Set Endpoint Transformation
1309
+ # Get Endpoint Transformations
1310
+ # Get the transformation code associated with this endpoint
1311
+ # @param app_id [String]
1312
+ # @param endpoint_id [String]
1313
+ # @param [Hash] opts the optional parameters
1314
+ # @return [EndpointTransformationOut]
1315
+ def v1_endpoint_transformation_get(app_id, endpoint_id, opts = {})
1316
+ data, _status_code, _headers = v1_endpoint_transformation_get_with_http_info(app_id, endpoint_id, opts)
1317
+ data
1318
+ end
1319
+
1320
+ # Get Endpoint Transformations
1321
+ # Get the transformation code associated with this endpoint
1322
+ # @param app_id [String]
1323
+ # @param endpoint_id [String]
1324
+ # @param [Hash] opts the optional parameters
1325
+ # @return [Array<(EndpointTransformationOut, Integer, Hash)>] EndpointTransformationOut data, response status code and response headers
1326
+ def v1_endpoint_transformation_get_with_http_info(app_id, endpoint_id, opts = {})
1327
+ if @api_client.config.debugging
1328
+ @api_client.config.logger.debug 'Calling API: EndpointApi.v1_endpoint_transformation_get ...'
1329
+ end
1330
+ # verify the required parameter 'app_id' is set
1331
+ if @api_client.config.client_side_validation && app_id.nil?
1332
+ fail ArgumentError, "Missing the required parameter 'app_id' when calling EndpointApi.v1_endpoint_transformation_get"
1333
+ end
1334
+ if @api_client.config.client_side_validation && app_id.to_s.length > 256
1335
+ fail ArgumentError, 'invalid value for "app_id" when calling EndpointApi.v1_endpoint_transformation_get, the character length must be smaller than or equal to 256.'
1336
+ end
1337
+
1338
+ if @api_client.config.client_side_validation && app_id.to_s.length < 1
1339
+ fail ArgumentError, 'invalid value for "app_id" when calling EndpointApi.v1_endpoint_transformation_get, the character length must be great than or equal to 1.'
1340
+ end
1341
+
1342
+ pattern = Regexp.new(/^[a-zA-Z0-9\-_.]+$/)
1343
+ if @api_client.config.client_side_validation && app_id !~ pattern
1344
+ fail ArgumentError, "invalid value for 'app_id' when calling EndpointApi.v1_endpoint_transformation_get, must conform to the pattern #{pattern}."
1345
+ end
1346
+
1347
+ # verify the required parameter 'endpoint_id' is set
1348
+ if @api_client.config.client_side_validation && endpoint_id.nil?
1349
+ fail ArgumentError, "Missing the required parameter 'endpoint_id' when calling EndpointApi.v1_endpoint_transformation_get"
1350
+ end
1351
+ if @api_client.config.client_side_validation && endpoint_id.to_s.length > 256
1352
+ fail ArgumentError, 'invalid value for "endpoint_id" when calling EndpointApi.v1_endpoint_transformation_get, the character length must be smaller than or equal to 256.'
1353
+ end
1354
+
1355
+ if @api_client.config.client_side_validation && endpoint_id.to_s.length < 1
1356
+ fail ArgumentError, 'invalid value for "endpoint_id" when calling EndpointApi.v1_endpoint_transformation_get, the character length must be great than or equal to 1.'
1357
+ end
1358
+
1359
+ pattern = Regexp.new(/^[a-zA-Z0-9\-_.]+$/)
1360
+ if @api_client.config.client_side_validation && endpoint_id !~ pattern
1361
+ fail ArgumentError, "invalid value for 'endpoint_id' when calling EndpointApi.v1_endpoint_transformation_get, must conform to the pattern #{pattern}."
1362
+ end
1363
+
1364
+ # resource path
1365
+ local_var_path = '/api/v1/app/{app_id}/endpoint/{endpoint_id}/transformation/'.sub('{' + 'app_id' + '}', CGI.escape(app_id.to_s)).sub('{' + 'endpoint_id' + '}', CGI.escape(endpoint_id.to_s))
1366
+
1367
+ # query parameters
1368
+ query_params = opts[:query_params] || {}
1369
+
1370
+ # header parameters
1371
+ header_params = opts[:header_params] || {}
1372
+ # HTTP header 'Accept' (if needed)
1373
+ header_params['Accept'] = @api_client.select_header_accept(['application/json'])
1374
+
1375
+ # form parameters
1376
+ form_params = opts[:form_params] || {}
1377
+
1378
+ # http body (model)
1379
+ post_body = opts[:debug_body]
1380
+
1381
+ # return_type
1382
+ return_type = opts[:debug_return_type] || 'EndpointTransformationOut'
1383
+
1384
+ # auth_names
1385
+ auth_names = opts[:debug_auth_names] || []
1386
+
1387
+ new_options = opts.merge(
1388
+ :operation => :"EndpointApi.v1_endpoint_transformation_get",
1389
+ :header_params => header_params,
1390
+ :query_params => query_params,
1391
+ :form_params => form_params,
1392
+ :body => post_body,
1393
+ :auth_names => auth_names,
1394
+ :return_type => return_type
1395
+ )
1396
+
1397
+ data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
1398
+ if @api_client.config.debugging
1399
+ @api_client.config.logger.debug "API called: EndpointApi#v1_endpoint_transformation_get\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
1400
+ end
1401
+ return data, status_code, headers
1402
+ end
1403
+
1404
+ # Set Endpoint Transformations
1320
1405
  # Set or unset the transformation code associated with this endpoint
1321
1406
  # @param app_id [String]
1322
1407
  # @param endpoint_id [String]
1323
1408
  # @param endpoint_transformation_in [EndpointTransformationIn]
1324
1409
  # @param [Hash] opts the optional parameters
1325
- # @option opts [String] :idempotency_key The request&#39;s idempotency key
1326
1410
  # @return [nil]
1327
- def set_endpoint_transformation_api_v1_app_app_id_endpoint_endpoint_id_transformation_patch(app_id, endpoint_id, endpoint_transformation_in, opts = {})
1328
- set_endpoint_transformation_api_v1_app_app_id_endpoint_endpoint_id_transformation_patch_with_http_info(app_id, endpoint_id, endpoint_transformation_in, opts)
1411
+ def v1_endpoint_transformation_partial_update(app_id, endpoint_id, endpoint_transformation_in, opts = {})
1412
+ v1_endpoint_transformation_partial_update_with_http_info(app_id, endpoint_id, endpoint_transformation_in, opts)
1329
1413
  nil
1330
1414
  end
1331
1415
 
1332
- # Set Endpoint Transformation
1416
+ # Set Endpoint Transformations
1333
1417
  # Set or unset the transformation code associated with this endpoint
1334
1418
  # @param app_id [String]
1335
1419
  # @param endpoint_id [String]
1336
1420
  # @param endpoint_transformation_in [EndpointTransformationIn]
1337
1421
  # @param [Hash] opts the optional parameters
1338
- # @option opts [String] :idempotency_key The request&#39;s idempotency key
1339
1422
  # @return [Array<(nil, Integer, Hash)>] nil, response status code and response headers
1340
- def set_endpoint_transformation_api_v1_app_app_id_endpoint_endpoint_id_transformation_patch_with_http_info(app_id, endpoint_id, endpoint_transformation_in, opts = {})
1423
+ def v1_endpoint_transformation_partial_update_with_http_info(app_id, endpoint_id, endpoint_transformation_in, opts = {})
1341
1424
  if @api_client.config.debugging
1342
- @api_client.config.logger.debug 'Calling API: EndpointApi.set_endpoint_transformation_api_v1_app_app_id_endpoint_endpoint_id_transformation_patch ...'
1425
+ @api_client.config.logger.debug 'Calling API: EndpointApi.v1_endpoint_transformation_partial_update ...'
1343
1426
  end
1344
1427
  # verify the required parameter 'app_id' is set
1345
1428
  if @api_client.config.client_side_validation && app_id.nil?
1346
- fail ArgumentError, "Missing the required parameter 'app_id' when calling EndpointApi.set_endpoint_transformation_api_v1_app_app_id_endpoint_endpoint_id_transformation_patch"
1429
+ fail ArgumentError, "Missing the required parameter 'app_id' when calling EndpointApi.v1_endpoint_transformation_partial_update"
1347
1430
  end
1348
1431
  if @api_client.config.client_side_validation && app_id.to_s.length > 256
1349
- fail ArgumentError, 'invalid value for "app_id" when calling EndpointApi.set_endpoint_transformation_api_v1_app_app_id_endpoint_endpoint_id_transformation_patch, the character length must be smaller than or equal to 256.'
1432
+ fail ArgumentError, 'invalid value for "app_id" when calling EndpointApi.v1_endpoint_transformation_partial_update, the character length must be smaller than or equal to 256.'
1350
1433
  end
1351
1434
 
1352
1435
  if @api_client.config.client_side_validation && app_id.to_s.length < 1
1353
- fail ArgumentError, 'invalid value for "app_id" when calling EndpointApi.set_endpoint_transformation_api_v1_app_app_id_endpoint_endpoint_id_transformation_patch, the character length must be great than or equal to 1.'
1436
+ fail ArgumentError, 'invalid value for "app_id" when calling EndpointApi.v1_endpoint_transformation_partial_update, the character length must be great than or equal to 1.'
1354
1437
  end
1355
1438
 
1356
1439
  pattern = Regexp.new(/^[a-zA-Z0-9\-_.]+$/)
1357
1440
  if @api_client.config.client_side_validation && app_id !~ pattern
1358
- fail ArgumentError, "invalid value for 'app_id' when calling EndpointApi.set_endpoint_transformation_api_v1_app_app_id_endpoint_endpoint_id_transformation_patch, must conform to the pattern #{pattern}."
1441
+ fail ArgumentError, "invalid value for 'app_id' when calling EndpointApi.v1_endpoint_transformation_partial_update, must conform to the pattern #{pattern}."
1359
1442
  end
1360
1443
 
1361
1444
  # verify the required parameter 'endpoint_id' is set
1362
1445
  if @api_client.config.client_side_validation && endpoint_id.nil?
1363
- fail ArgumentError, "Missing the required parameter 'endpoint_id' when calling EndpointApi.set_endpoint_transformation_api_v1_app_app_id_endpoint_endpoint_id_transformation_patch"
1446
+ fail ArgumentError, "Missing the required parameter 'endpoint_id' when calling EndpointApi.v1_endpoint_transformation_partial_update"
1364
1447
  end
1365
1448
  if @api_client.config.client_side_validation && endpoint_id.to_s.length > 256
1366
- fail ArgumentError, 'invalid value for "endpoint_id" when calling EndpointApi.set_endpoint_transformation_api_v1_app_app_id_endpoint_endpoint_id_transformation_patch, the character length must be smaller than or equal to 256.'
1449
+ fail ArgumentError, 'invalid value for "endpoint_id" when calling EndpointApi.v1_endpoint_transformation_partial_update, the character length must be smaller than or equal to 256.'
1367
1450
  end
1368
1451
 
1369
1452
  if @api_client.config.client_side_validation && endpoint_id.to_s.length < 1
1370
- fail ArgumentError, 'invalid value for "endpoint_id" when calling EndpointApi.set_endpoint_transformation_api_v1_app_app_id_endpoint_endpoint_id_transformation_patch, the character length must be great than or equal to 1.'
1453
+ fail ArgumentError, 'invalid value for "endpoint_id" when calling EndpointApi.v1_endpoint_transformation_partial_update, the character length must be great than or equal to 1.'
1371
1454
  end
1372
1455
 
1373
1456
  pattern = Regexp.new(/^[a-zA-Z0-9\-_.]+$/)
1374
1457
  if @api_client.config.client_side_validation && endpoint_id !~ pattern
1375
- fail ArgumentError, "invalid value for 'endpoint_id' when calling EndpointApi.set_endpoint_transformation_api_v1_app_app_id_endpoint_endpoint_id_transformation_patch, must conform to the pattern #{pattern}."
1458
+ fail ArgumentError, "invalid value for 'endpoint_id' when calling EndpointApi.v1_endpoint_transformation_partial_update, must conform to the pattern #{pattern}."
1376
1459
  end
1377
1460
 
1378
1461
  # verify the required parameter 'endpoint_transformation_in' is set
1379
1462
  if @api_client.config.client_side_validation && endpoint_transformation_in.nil?
1380
- fail ArgumentError, "Missing the required parameter 'endpoint_transformation_in' when calling EndpointApi.set_endpoint_transformation_api_v1_app_app_id_endpoint_endpoint_id_transformation_patch"
1463
+ fail ArgumentError, "Missing the required parameter 'endpoint_transformation_in' when calling EndpointApi.v1_endpoint_transformation_partial_update"
1381
1464
  end
1382
1465
  # resource path
1383
1466
  local_var_path = '/api/v1/app/{app_id}/endpoint/{endpoint_id}/transformation/'.sub('{' + 'app_id' + '}', CGI.escape(app_id.to_s)).sub('{' + 'endpoint_id' + '}', CGI.escape(endpoint_id.to_s))
@@ -1391,7 +1474,6 @@ module Svix
1391
1474
  header_params['Accept'] = @api_client.select_header_accept(['application/json'])
1392
1475
  # HTTP header 'Content-Type'
1393
1476
  header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])
1394
- header_params[:'idempotency-key'] = opts[:'idempotency_key'] if !opts[:'idempotency_key'].nil?
1395
1477
 
1396
1478
  # form parameters
1397
1479
  form_params = opts[:form_params] || {}
@@ -1403,10 +1485,10 @@ module Svix
1403
1485
  return_type = opts[:debug_return_type]
1404
1486
 
1405
1487
  # auth_names
1406
- auth_names = opts[:debug_auth_names] || ['HTTPBearer']
1488
+ auth_names = opts[:debug_auth_names] || []
1407
1489
 
1408
1490
  new_options = opts.merge(
1409
- :operation => :"EndpointApi.set_endpoint_transformation_api_v1_app_app_id_endpoint_endpoint_id_transformation_patch",
1491
+ :operation => :"EndpointApi.v1_endpoint_transformation_partial_update",
1410
1492
  :header_params => header_params,
1411
1493
  :query_params => query_params,
1412
1494
  :form_params => form_params,
@@ -1417,76 +1499,76 @@ module Svix
1417
1499
 
1418
1500
  data, status_code, headers = @api_client.call_api(:PATCH, local_var_path, new_options)
1419
1501
  if @api_client.config.debugging
1420
- @api_client.config.logger.debug "API called: EndpointApi#set_endpoint_transformation_api_v1_app_app_id_endpoint_endpoint_id_transformation_patch\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
1502
+ @api_client.config.logger.debug "API called: EndpointApi#v1_endpoint_transformation_partial_update\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
1421
1503
  end
1422
1504
  return data, status_code, headers
1423
1505
  end
1424
1506
 
1425
- # Simulate Endpoint Transformation
1507
+ # Simulate
1426
1508
  # Simulate running the transformation on the payload and code
1427
- # @param endpoint_id [String]
1428
1509
  # @param app_id [String]
1510
+ # @param endpoint_id [String]
1429
1511
  # @param endpoint_transformation_simulate_in [EndpointTransformationSimulateIn]
1430
1512
  # @param [Hash] opts the optional parameters
1431
1513
  # @option opts [String] :idempotency_key The request&#39;s idempotency key
1432
1514
  # @return [EndpointTransformationSimulateOut]
1433
- def simulate_endpoint_transformation_api_v1_app_app_id_endpoint_endpoint_id_transformation_simulate_post(endpoint_id, app_id, endpoint_transformation_simulate_in, opts = {})
1434
- data, _status_code, _headers = simulate_endpoint_transformation_api_v1_app_app_id_endpoint_endpoint_id_transformation_simulate_post_with_http_info(endpoint_id, app_id, endpoint_transformation_simulate_in, opts)
1515
+ def v1_endpoint_transformation_simulate(app_id, endpoint_id, endpoint_transformation_simulate_in, opts = {})
1516
+ data, _status_code, _headers = v1_endpoint_transformation_simulate_with_http_info(app_id, endpoint_id, endpoint_transformation_simulate_in, opts)
1435
1517
  data
1436
1518
  end
1437
1519
 
1438
- # Simulate Endpoint Transformation
1520
+ # Simulate
1439
1521
  # Simulate running the transformation on the payload and code
1440
- # @param endpoint_id [String]
1441
1522
  # @param app_id [String]
1523
+ # @param endpoint_id [String]
1442
1524
  # @param endpoint_transformation_simulate_in [EndpointTransformationSimulateIn]
1443
1525
  # @param [Hash] opts the optional parameters
1444
1526
  # @option opts [String] :idempotency_key The request&#39;s idempotency key
1445
1527
  # @return [Array<(EndpointTransformationSimulateOut, Integer, Hash)>] EndpointTransformationSimulateOut data, response status code and response headers
1446
- def simulate_endpoint_transformation_api_v1_app_app_id_endpoint_endpoint_id_transformation_simulate_post_with_http_info(endpoint_id, app_id, endpoint_transformation_simulate_in, opts = {})
1528
+ def v1_endpoint_transformation_simulate_with_http_info(app_id, endpoint_id, endpoint_transformation_simulate_in, opts = {})
1447
1529
  if @api_client.config.debugging
1448
- @api_client.config.logger.debug 'Calling API: EndpointApi.simulate_endpoint_transformation_api_v1_app_app_id_endpoint_endpoint_id_transformation_simulate_post ...'
1530
+ @api_client.config.logger.debug 'Calling API: EndpointApi.v1_endpoint_transformation_simulate ...'
1449
1531
  end
1450
- # verify the required parameter 'endpoint_id' is set
1451
- if @api_client.config.client_side_validation && endpoint_id.nil?
1452
- fail ArgumentError, "Missing the required parameter 'endpoint_id' when calling EndpointApi.simulate_endpoint_transformation_api_v1_app_app_id_endpoint_endpoint_id_transformation_simulate_post"
1532
+ # verify the required parameter 'app_id' is set
1533
+ if @api_client.config.client_side_validation && app_id.nil?
1534
+ fail ArgumentError, "Missing the required parameter 'app_id' when calling EndpointApi.v1_endpoint_transformation_simulate"
1453
1535
  end
1454
- if @api_client.config.client_side_validation && endpoint_id.to_s.length > 256
1455
- fail ArgumentError, 'invalid value for "endpoint_id" when calling EndpointApi.simulate_endpoint_transformation_api_v1_app_app_id_endpoint_endpoint_id_transformation_simulate_post, the character length must be smaller than or equal to 256.'
1536
+ if @api_client.config.client_side_validation && app_id.to_s.length > 256
1537
+ fail ArgumentError, 'invalid value for "app_id" when calling EndpointApi.v1_endpoint_transformation_simulate, the character length must be smaller than or equal to 256.'
1456
1538
  end
1457
1539
 
1458
- if @api_client.config.client_side_validation && endpoint_id.to_s.length < 1
1459
- fail ArgumentError, 'invalid value for "endpoint_id" when calling EndpointApi.simulate_endpoint_transformation_api_v1_app_app_id_endpoint_endpoint_id_transformation_simulate_post, the character length must be great than or equal to 1.'
1540
+ if @api_client.config.client_side_validation && app_id.to_s.length < 1
1541
+ fail ArgumentError, 'invalid value for "app_id" when calling EndpointApi.v1_endpoint_transformation_simulate, the character length must be great than or equal to 1.'
1460
1542
  end
1461
1543
 
1462
1544
  pattern = Regexp.new(/^[a-zA-Z0-9\-_.]+$/)
1463
- if @api_client.config.client_side_validation && endpoint_id !~ pattern
1464
- fail ArgumentError, "invalid value for 'endpoint_id' when calling EndpointApi.simulate_endpoint_transformation_api_v1_app_app_id_endpoint_endpoint_id_transformation_simulate_post, must conform to the pattern #{pattern}."
1545
+ if @api_client.config.client_side_validation && app_id !~ pattern
1546
+ fail ArgumentError, "invalid value for 'app_id' when calling EndpointApi.v1_endpoint_transformation_simulate, must conform to the pattern #{pattern}."
1465
1547
  end
1466
1548
 
1467
- # verify the required parameter 'app_id' is set
1468
- if @api_client.config.client_side_validation && app_id.nil?
1469
- fail ArgumentError, "Missing the required parameter 'app_id' when calling EndpointApi.simulate_endpoint_transformation_api_v1_app_app_id_endpoint_endpoint_id_transformation_simulate_post"
1549
+ # verify the required parameter 'endpoint_id' is set
1550
+ if @api_client.config.client_side_validation && endpoint_id.nil?
1551
+ fail ArgumentError, "Missing the required parameter 'endpoint_id' when calling EndpointApi.v1_endpoint_transformation_simulate"
1470
1552
  end
1471
- if @api_client.config.client_side_validation && app_id.to_s.length > 256
1472
- fail ArgumentError, 'invalid value for "app_id" when calling EndpointApi.simulate_endpoint_transformation_api_v1_app_app_id_endpoint_endpoint_id_transformation_simulate_post, the character length must be smaller than or equal to 256.'
1553
+ if @api_client.config.client_side_validation && endpoint_id.to_s.length > 256
1554
+ fail ArgumentError, 'invalid value for "endpoint_id" when calling EndpointApi.v1_endpoint_transformation_simulate, the character length must be smaller than or equal to 256.'
1473
1555
  end
1474
1556
 
1475
- if @api_client.config.client_side_validation && app_id.to_s.length < 1
1476
- fail ArgumentError, 'invalid value for "app_id" when calling EndpointApi.simulate_endpoint_transformation_api_v1_app_app_id_endpoint_endpoint_id_transformation_simulate_post, the character length must be great than or equal to 1.'
1557
+ if @api_client.config.client_side_validation && endpoint_id.to_s.length < 1
1558
+ fail ArgumentError, 'invalid value for "endpoint_id" when calling EndpointApi.v1_endpoint_transformation_simulate, the character length must be great than or equal to 1.'
1477
1559
  end
1478
1560
 
1479
1561
  pattern = Regexp.new(/^[a-zA-Z0-9\-_.]+$/)
1480
- if @api_client.config.client_side_validation && app_id !~ pattern
1481
- fail ArgumentError, "invalid value for 'app_id' when calling EndpointApi.simulate_endpoint_transformation_api_v1_app_app_id_endpoint_endpoint_id_transformation_simulate_post, must conform to the pattern #{pattern}."
1562
+ if @api_client.config.client_side_validation && endpoint_id !~ pattern
1563
+ fail ArgumentError, "invalid value for 'endpoint_id' when calling EndpointApi.v1_endpoint_transformation_simulate, must conform to the pattern #{pattern}."
1482
1564
  end
1483
1565
 
1484
1566
  # verify the required parameter 'endpoint_transformation_simulate_in' is set
1485
1567
  if @api_client.config.client_side_validation && endpoint_transformation_simulate_in.nil?
1486
- fail ArgumentError, "Missing the required parameter 'endpoint_transformation_simulate_in' when calling EndpointApi.simulate_endpoint_transformation_api_v1_app_app_id_endpoint_endpoint_id_transformation_simulate_post"
1568
+ fail ArgumentError, "Missing the required parameter 'endpoint_transformation_simulate_in' when calling EndpointApi.v1_endpoint_transformation_simulate"
1487
1569
  end
1488
1570
  # resource path
1489
- local_var_path = '/api/v1/app/{app_id}/endpoint/{endpoint_id}/transformation/simulate/'.sub('{' + 'endpoint_id' + '}', CGI.escape(endpoint_id.to_s)).sub('{' + 'app_id' + '}', CGI.escape(app_id.to_s))
1571
+ local_var_path = '/api/v1/app/{app_id}/endpoint/{endpoint_id}/transformation/simulate/'.sub('{' + 'app_id' + '}', CGI.escape(app_id.to_s)).sub('{' + 'endpoint_id' + '}', CGI.escape(endpoint_id.to_s))
1490
1572
 
1491
1573
  # query parameters
1492
1574
  query_params = opts[:query_params] || {}
@@ -1509,10 +1591,10 @@ module Svix
1509
1591
  return_type = opts[:debug_return_type] || 'EndpointTransformationSimulateOut'
1510
1592
 
1511
1593
  # auth_names
1512
- auth_names = opts[:debug_auth_names] || ['HTTPBearer']
1594
+ auth_names = opts[:debug_auth_names] || []
1513
1595
 
1514
1596
  new_options = opts.merge(
1515
- :operation => :"EndpointApi.simulate_endpoint_transformation_api_v1_app_app_id_endpoint_endpoint_id_transformation_simulate_post",
1597
+ :operation => :"EndpointApi.v1_endpoint_transformation_simulate",
1516
1598
  :header_params => header_params,
1517
1599
  :query_params => query_params,
1518
1600
  :form_params => form_params,
@@ -1523,76 +1605,74 @@ module Svix
1523
1605
 
1524
1606
  data, status_code, headers = @api_client.call_api(:POST, local_var_path, new_options)
1525
1607
  if @api_client.config.debugging
1526
- @api_client.config.logger.debug "API called: EndpointApi#simulate_endpoint_transformation_api_v1_app_app_id_endpoint_endpoint_id_transformation_simulate_post\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
1608
+ @api_client.config.logger.debug "API called: EndpointApi#v1_endpoint_transformation_simulate\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
1527
1609
  end
1528
1610
  return data, status_code, headers
1529
1611
  end
1530
1612
 
1531
1613
  # Update Endpoint
1532
1614
  # Update an endpoint.
1533
- # @param endpoint_id [String]
1534
1615
  # @param app_id [String]
1616
+ # @param endpoint_id [String]
1535
1617
  # @param endpoint_update [EndpointUpdate]
1536
1618
  # @param [Hash] opts the optional parameters
1537
- # @option opts [String] :idempotency_key The request&#39;s idempotency key
1538
1619
  # @return [EndpointOut]
1539
- def update_endpoint_api_v1_app_app_id_endpoint_endpoint_id_put(endpoint_id, app_id, endpoint_update, opts = {})
1540
- data, _status_code, _headers = update_endpoint_api_v1_app_app_id_endpoint_endpoint_id_put_with_http_info(endpoint_id, app_id, endpoint_update, opts)
1620
+ def v1_endpoint_update(app_id, endpoint_id, endpoint_update, opts = {})
1621
+ data, _status_code, _headers = v1_endpoint_update_with_http_info(app_id, endpoint_id, endpoint_update, opts)
1541
1622
  data
1542
1623
  end
1543
1624
 
1544
1625
  # Update Endpoint
1545
1626
  # Update an endpoint.
1546
- # @param endpoint_id [String]
1547
1627
  # @param app_id [String]
1628
+ # @param endpoint_id [String]
1548
1629
  # @param endpoint_update [EndpointUpdate]
1549
1630
  # @param [Hash] opts the optional parameters
1550
- # @option opts [String] :idempotency_key The request&#39;s idempotency key
1551
1631
  # @return [Array<(EndpointOut, Integer, Hash)>] EndpointOut data, response status code and response headers
1552
- def update_endpoint_api_v1_app_app_id_endpoint_endpoint_id_put_with_http_info(endpoint_id, app_id, endpoint_update, opts = {})
1632
+ def v1_endpoint_update_with_http_info(app_id, endpoint_id, endpoint_update, opts = {})
1553
1633
  if @api_client.config.debugging
1554
- @api_client.config.logger.debug 'Calling API: EndpointApi.update_endpoint_api_v1_app_app_id_endpoint_endpoint_id_put ...'
1634
+ @api_client.config.logger.debug 'Calling API: EndpointApi.v1_endpoint_update ...'
1555
1635
  end
1556
- # verify the required parameter 'endpoint_id' is set
1557
- if @api_client.config.client_side_validation && endpoint_id.nil?
1558
- fail ArgumentError, "Missing the required parameter 'endpoint_id' when calling EndpointApi.update_endpoint_api_v1_app_app_id_endpoint_endpoint_id_put"
1636
+ # verify the required parameter 'app_id' is set
1637
+ if @api_client.config.client_side_validation && app_id.nil?
1638
+ fail ArgumentError, "Missing the required parameter 'app_id' when calling EndpointApi.v1_endpoint_update"
1559
1639
  end
1560
- if @api_client.config.client_side_validation && endpoint_id.to_s.length > 256
1561
- fail ArgumentError, 'invalid value for "endpoint_id" when calling EndpointApi.update_endpoint_api_v1_app_app_id_endpoint_endpoint_id_put, the character length must be smaller than or equal to 256.'
1640
+ if @api_client.config.client_side_validation && app_id.to_s.length > 256
1641
+ fail ArgumentError, 'invalid value for "app_id" when calling EndpointApi.v1_endpoint_update, the character length must be smaller than or equal to 256.'
1562
1642
  end
1563
1643
 
1564
- if @api_client.config.client_side_validation && endpoint_id.to_s.length < 1
1565
- fail ArgumentError, 'invalid value for "endpoint_id" when calling EndpointApi.update_endpoint_api_v1_app_app_id_endpoint_endpoint_id_put, the character length must be great than or equal to 1.'
1644
+ if @api_client.config.client_side_validation && app_id.to_s.length < 1
1645
+ fail ArgumentError, 'invalid value for "app_id" when calling EndpointApi.v1_endpoint_update, the character length must be great than or equal to 1.'
1566
1646
  end
1567
1647
 
1568
1648
  pattern = Regexp.new(/^[a-zA-Z0-9\-_.]+$/)
1569
- if @api_client.config.client_side_validation && endpoint_id !~ pattern
1570
- fail ArgumentError, "invalid value for 'endpoint_id' when calling EndpointApi.update_endpoint_api_v1_app_app_id_endpoint_endpoint_id_put, must conform to the pattern #{pattern}."
1649
+ if @api_client.config.client_side_validation && app_id !~ pattern
1650
+ fail ArgumentError, "invalid value for 'app_id' when calling EndpointApi.v1_endpoint_update, must conform to the pattern #{pattern}."
1571
1651
  end
1572
1652
 
1573
- # verify the required parameter 'app_id' is set
1574
- if @api_client.config.client_side_validation && app_id.nil?
1575
- fail ArgumentError, "Missing the required parameter 'app_id' when calling EndpointApi.update_endpoint_api_v1_app_app_id_endpoint_endpoint_id_put"
1653
+ # verify the required parameter 'endpoint_id' is set
1654
+ if @api_client.config.client_side_validation && endpoint_id.nil?
1655
+ fail ArgumentError, "Missing the required parameter 'endpoint_id' when calling EndpointApi.v1_endpoint_update"
1576
1656
  end
1577
- if @api_client.config.client_side_validation && app_id.to_s.length > 256
1578
- fail ArgumentError, 'invalid value for "app_id" when calling EndpointApi.update_endpoint_api_v1_app_app_id_endpoint_endpoint_id_put, the character length must be smaller than or equal to 256.'
1657
+ if @api_client.config.client_side_validation && endpoint_id.to_s.length > 256
1658
+ fail ArgumentError, 'invalid value for "endpoint_id" when calling EndpointApi.v1_endpoint_update, the character length must be smaller than or equal to 256.'
1579
1659
  end
1580
1660
 
1581
- if @api_client.config.client_side_validation && app_id.to_s.length < 1
1582
- fail ArgumentError, 'invalid value for "app_id" when calling EndpointApi.update_endpoint_api_v1_app_app_id_endpoint_endpoint_id_put, the character length must be great than or equal to 1.'
1661
+ if @api_client.config.client_side_validation && endpoint_id.to_s.length < 1
1662
+ fail ArgumentError, 'invalid value for "endpoint_id" when calling EndpointApi.v1_endpoint_update, the character length must be great than or equal to 1.'
1583
1663
  end
1584
1664
 
1585
1665
  pattern = Regexp.new(/^[a-zA-Z0-9\-_.]+$/)
1586
- if @api_client.config.client_side_validation && app_id !~ pattern
1587
- fail ArgumentError, "invalid value for 'app_id' when calling EndpointApi.update_endpoint_api_v1_app_app_id_endpoint_endpoint_id_put, must conform to the pattern #{pattern}."
1666
+ if @api_client.config.client_side_validation && endpoint_id !~ pattern
1667
+ fail ArgumentError, "invalid value for 'endpoint_id' when calling EndpointApi.v1_endpoint_update, must conform to the pattern #{pattern}."
1588
1668
  end
1589
1669
 
1590
1670
  # verify the required parameter 'endpoint_update' is set
1591
1671
  if @api_client.config.client_side_validation && endpoint_update.nil?
1592
- fail ArgumentError, "Missing the required parameter 'endpoint_update' when calling EndpointApi.update_endpoint_api_v1_app_app_id_endpoint_endpoint_id_put"
1672
+ fail ArgumentError, "Missing the required parameter 'endpoint_update' when calling EndpointApi.v1_endpoint_update"
1593
1673
  end
1594
1674
  # resource path
1595
- local_var_path = '/api/v1/app/{app_id}/endpoint/{endpoint_id}/'.sub('{' + 'endpoint_id' + '}', CGI.escape(endpoint_id.to_s)).sub('{' + 'app_id' + '}', CGI.escape(app_id.to_s))
1675
+ local_var_path = '/api/v1/app/{app_id}/endpoint/{endpoint_id}/'.sub('{' + 'app_id' + '}', CGI.escape(app_id.to_s)).sub('{' + 'endpoint_id' + '}', CGI.escape(endpoint_id.to_s))
1596
1676
 
1597
1677
  # query parameters
1598
1678
  query_params = opts[:query_params] || {}
@@ -1603,7 +1683,6 @@ module Svix
1603
1683
  header_params['Accept'] = @api_client.select_header_accept(['application/json'])
1604
1684
  # HTTP header 'Content-Type'
1605
1685
  header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])
1606
- header_params[:'idempotency-key'] = opts[:'idempotency_key'] if !opts[:'idempotency_key'].nil?
1607
1686
 
1608
1687
  # form parameters
1609
1688
  form_params = opts[:form_params] || {}
@@ -1615,10 +1694,10 @@ module Svix
1615
1694
  return_type = opts[:debug_return_type] || 'EndpointOut'
1616
1695
 
1617
1696
  # auth_names
1618
- auth_names = opts[:debug_auth_names] || ['HTTPBearer']
1697
+ auth_names = opts[:debug_auth_names] || []
1619
1698
 
1620
1699
  new_options = opts.merge(
1621
- :operation => :"EndpointApi.update_endpoint_api_v1_app_app_id_endpoint_endpoint_id_put",
1700
+ :operation => :"EndpointApi.v1_endpoint_update",
1622
1701
  :header_params => header_params,
1623
1702
  :query_params => query_params,
1624
1703
  :form_params => form_params,
@@ -1629,7 +1708,7 @@ module Svix
1629
1708
 
1630
1709
  data, status_code, headers = @api_client.call_api(:PUT, local_var_path, new_options)
1631
1710
  if @api_client.config.debugging
1632
- @api_client.config.logger.debug "API called: EndpointApi#update_endpoint_api_v1_app_app_id_endpoint_endpoint_id_put\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
1711
+ @api_client.config.logger.debug "API called: EndpointApi#v1_endpoint_update\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
1633
1712
  end
1634
1713
  return data, status_code, headers
1635
1714
  end
@@ -1640,10 +1719,9 @@ module Svix
1640
1719
  # @param endpoint_id [String]
1641
1720
  # @param endpoint_headers_in [EndpointHeadersIn]
1642
1721
  # @param [Hash] opts the optional parameters
1643
- # @option opts [String] :idempotency_key The request&#39;s idempotency key
1644
1722
  # @return [nil]
1645
- def update_endpoint_headers_api_v1_app_app_id_endpoint_endpoint_id_headers_put(app_id, endpoint_id, endpoint_headers_in, opts = {})
1646
- update_endpoint_headers_api_v1_app_app_id_endpoint_endpoint_id_headers_put_with_http_info(app_id, endpoint_id, endpoint_headers_in, opts)
1723
+ def v1_endpoint_update_headers(app_id, endpoint_id, endpoint_headers_in, opts = {})
1724
+ v1_endpoint_update_headers_with_http_info(app_id, endpoint_id, endpoint_headers_in, opts)
1647
1725
  nil
1648
1726
  end
1649
1727
 
@@ -1653,49 +1731,48 @@ module Svix
1653
1731
  # @param endpoint_id [String]
1654
1732
  # @param endpoint_headers_in [EndpointHeadersIn]
1655
1733
  # @param [Hash] opts the optional parameters
1656
- # @option opts [String] :idempotency_key The request&#39;s idempotency key
1657
1734
  # @return [Array<(nil, Integer, Hash)>] nil, response status code and response headers
1658
- def update_endpoint_headers_api_v1_app_app_id_endpoint_endpoint_id_headers_put_with_http_info(app_id, endpoint_id, endpoint_headers_in, opts = {})
1735
+ def v1_endpoint_update_headers_with_http_info(app_id, endpoint_id, endpoint_headers_in, opts = {})
1659
1736
  if @api_client.config.debugging
1660
- @api_client.config.logger.debug 'Calling API: EndpointApi.update_endpoint_headers_api_v1_app_app_id_endpoint_endpoint_id_headers_put ...'
1737
+ @api_client.config.logger.debug 'Calling API: EndpointApi.v1_endpoint_update_headers ...'
1661
1738
  end
1662
1739
  # verify the required parameter 'app_id' is set
1663
1740
  if @api_client.config.client_side_validation && app_id.nil?
1664
- fail ArgumentError, "Missing the required parameter 'app_id' when calling EndpointApi.update_endpoint_headers_api_v1_app_app_id_endpoint_endpoint_id_headers_put"
1741
+ fail ArgumentError, "Missing the required parameter 'app_id' when calling EndpointApi.v1_endpoint_update_headers"
1665
1742
  end
1666
1743
  if @api_client.config.client_side_validation && app_id.to_s.length > 256
1667
- fail ArgumentError, 'invalid value for "app_id" when calling EndpointApi.update_endpoint_headers_api_v1_app_app_id_endpoint_endpoint_id_headers_put, the character length must be smaller than or equal to 256.'
1744
+ fail ArgumentError, 'invalid value for "app_id" when calling EndpointApi.v1_endpoint_update_headers, the character length must be smaller than or equal to 256.'
1668
1745
  end
1669
1746
 
1670
1747
  if @api_client.config.client_side_validation && app_id.to_s.length < 1
1671
- fail ArgumentError, 'invalid value for "app_id" when calling EndpointApi.update_endpoint_headers_api_v1_app_app_id_endpoint_endpoint_id_headers_put, the character length must be great than or equal to 1.'
1748
+ fail ArgumentError, 'invalid value for "app_id" when calling EndpointApi.v1_endpoint_update_headers, the character length must be great than or equal to 1.'
1672
1749
  end
1673
1750
 
1674
1751
  pattern = Regexp.new(/^[a-zA-Z0-9\-_.]+$/)
1675
1752
  if @api_client.config.client_side_validation && app_id !~ pattern
1676
- fail ArgumentError, "invalid value for 'app_id' when calling EndpointApi.update_endpoint_headers_api_v1_app_app_id_endpoint_endpoint_id_headers_put, must conform to the pattern #{pattern}."
1753
+ fail ArgumentError, "invalid value for 'app_id' when calling EndpointApi.v1_endpoint_update_headers, must conform to the pattern #{pattern}."
1677
1754
  end
1678
1755
 
1679
1756
  # verify the required parameter 'endpoint_id' is set
1680
1757
  if @api_client.config.client_side_validation && endpoint_id.nil?
1681
- fail ArgumentError, "Missing the required parameter 'endpoint_id' when calling EndpointApi.update_endpoint_headers_api_v1_app_app_id_endpoint_endpoint_id_headers_put"
1758
+ fail ArgumentError, "Missing the required parameter 'endpoint_id' when calling EndpointApi.v1_endpoint_update_headers"
1682
1759
  end
1683
1760
  if @api_client.config.client_side_validation && endpoint_id.to_s.length > 256
1684
- fail ArgumentError, 'invalid value for "endpoint_id" when calling EndpointApi.update_endpoint_headers_api_v1_app_app_id_endpoint_endpoint_id_headers_put, the character length must be smaller than or equal to 256.'
1761
+ fail ArgumentError, 'invalid value for "endpoint_id" when calling EndpointApi.v1_endpoint_update_headers, the character length must be smaller than or equal to 256.'
1685
1762
  end
1686
1763
 
1687
1764
  if @api_client.config.client_side_validation && endpoint_id.to_s.length < 1
1688
- fail ArgumentError, 'invalid value for "endpoint_id" when calling EndpointApi.update_endpoint_headers_api_v1_app_app_id_endpoint_endpoint_id_headers_put, the character length must be great than or equal to 1.'
1765
+ fail ArgumentError, 'invalid value for "endpoint_id" when calling EndpointApi.v1_endpoint_update_headers, the character length must be great than or equal to 1.'
1689
1766
  end
1690
1767
 
1691
1768
  pattern = Regexp.new(/^[a-zA-Z0-9\-_.]+$/)
1692
1769
  if @api_client.config.client_side_validation && endpoint_id !~ pattern
1693
- fail ArgumentError, "invalid value for 'endpoint_id' when calling EndpointApi.update_endpoint_headers_api_v1_app_app_id_endpoint_endpoint_id_headers_put, must conform to the pattern #{pattern}."
1770
+ fail ArgumentError, "invalid value for 'endpoint_id' when calling EndpointApi.v1_endpoint_update_headers, must conform to the pattern #{pattern}."
1694
1771
  end
1695
1772
 
1696
1773
  # verify the required parameter 'endpoint_headers_in' is set
1697
1774
  if @api_client.config.client_side_validation && endpoint_headers_in.nil?
1698
- fail ArgumentError, "Missing the required parameter 'endpoint_headers_in' when calling EndpointApi.update_endpoint_headers_api_v1_app_app_id_endpoint_endpoint_id_headers_put"
1775
+ fail ArgumentError, "Missing the required parameter 'endpoint_headers_in' when calling EndpointApi.v1_endpoint_update_headers"
1699
1776
  end
1700
1777
  # resource path
1701
1778
  local_var_path = '/api/v1/app/{app_id}/endpoint/{endpoint_id}/headers/'.sub('{' + 'app_id' + '}', CGI.escape(app_id.to_s)).sub('{' + 'endpoint_id' + '}', CGI.escape(endpoint_id.to_s))
@@ -1709,7 +1786,6 @@ module Svix
1709
1786
  header_params['Accept'] = @api_client.select_header_accept(['application/json'])
1710
1787
  # HTTP header 'Content-Type'
1711
1788
  header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])
1712
- header_params[:'idempotency-key'] = opts[:'idempotency_key'] if !opts[:'idempotency_key'].nil?
1713
1789
 
1714
1790
  # form parameters
1715
1791
  form_params = opts[:form_params] || {}
@@ -1721,10 +1797,10 @@ module Svix
1721
1797
  return_type = opts[:debug_return_type]
1722
1798
 
1723
1799
  # auth_names
1724
- auth_names = opts[:debug_auth_names] || ['HTTPBearer']
1800
+ auth_names = opts[:debug_auth_names] || []
1725
1801
 
1726
1802
  new_options = opts.merge(
1727
- :operation => :"EndpointApi.update_endpoint_headers_api_v1_app_app_id_endpoint_endpoint_id_headers_put",
1803
+ :operation => :"EndpointApi.v1_endpoint_update_headers",
1728
1804
  :header_params => header_params,
1729
1805
  :query_params => query_params,
1730
1806
  :form_params => form_params,
@@ -1735,7 +1811,7 @@ module Svix
1735
1811
 
1736
1812
  data, status_code, headers = @api_client.call_api(:PUT, local_var_path, new_options)
1737
1813
  if @api_client.config.debugging
1738
- @api_client.config.logger.debug "API called: EndpointApi#update_endpoint_headers_api_v1_app_app_id_endpoint_endpoint_id_headers_put\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
1814
+ @api_client.config.logger.debug "API called: EndpointApi#v1_endpoint_update_headers\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
1739
1815
  end
1740
1816
  return data, status_code, headers
1741
1817
  end