svix 1.22.0 → 1.23.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: eb4ce7474d5f55a002336bf404a0f198aee86ad0d52e8ad201bb5a6df8c5871a
4
- data.tar.gz: 3ce0597f82e3b6843694c23ead0aef184026af650ef14bdea8e4c87f267e519f
3
+ metadata.gz: d9a1e975f63d58999f477f489e1e061c71a0087f4a21654539ade169531a0af2
4
+ data.tar.gz: dab74fe571f4656d1e2d90fde91fdc238a8cf51058adaceeab78ffb2bbf6f37f
5
5
  SHA512:
6
- metadata.gz: 1072c5ea48f780fe017aae8d6a62be76b81cf24399ce28a60fc6a2a931078906855939be63d9a5609d1d4c5bd8629aa72cd0f5db3c0561f161838231b9a25daa
7
- data.tar.gz: 65154a5696a5e2e18579ecc463a98fa8715a77e4b93ec6adb7d1ac2f59d12cfe9bc6c48bf7498da5a686405241753301ead515f85ebf23edeb1bf61daf6c90a8
6
+ metadata.gz: 27ae734208b86525182e502086dc065f446dff33e4ae47709d28a56973bfbc966bdac0bfe7558751f068d2c9ef755ed64b7eac12c564fec6fb538da72fbe46d2
7
+ data.tar.gz: 1931001d9a9b84643ea3627a91b415d727f195fe5045e2ec90cf60b908a228d7bcfaaa59412caa8d24507221dafb11c7b0ed91d584313bf514a1443056e73106
data/Gemfile.lock CHANGED
@@ -1,7 +1,7 @@
1
1
  PATH
2
2
  remote: .
3
3
  specs:
4
- svix (1.22.0)
4
+ svix (1.23.0)
5
5
  typhoeus (~> 1.0, >= 1.0.1)
6
6
 
7
7
  GEM
@@ -201,6 +201,101 @@ module Svix
201
201
  return data, status_code, headers
202
202
  end
203
203
 
204
+ # Delete Endpoint Oauth Config
205
+ # Delete endpoint OAuth configuration
206
+ # @param app_id [String] The app's ID or UID
207
+ # @param endpoint_id [String] The ep's ID or UID
208
+ # @param [Hash] opts the optional parameters
209
+ # @return [nil]
210
+ def v1_endpoint_delete_oauth_config(app_id, endpoint_id, opts = {})
211
+ v1_endpoint_delete_oauth_config_with_http_info(app_id, endpoint_id, opts)
212
+ nil
213
+ end
214
+
215
+ # Delete Endpoint Oauth Config
216
+ # Delete endpoint OAuth configuration
217
+ # @param app_id [String] The app's ID or UID
218
+ # @param endpoint_id [String] The ep's ID or UID
219
+ # @param [Hash] opts the optional parameters
220
+ # @return [Array<(nil, Integer, Hash)>] nil, response status code and response headers
221
+ def v1_endpoint_delete_oauth_config_with_http_info(app_id, endpoint_id, opts = {})
222
+ if @api_client.config.debugging
223
+ @api_client.config.logger.debug 'Calling API: EndpointApi.v1_endpoint_delete_oauth_config ...'
224
+ end
225
+ # verify the required parameter 'app_id' is set
226
+ if @api_client.config.client_side_validation && app_id.nil?
227
+ fail ArgumentError, "Missing the required parameter 'app_id' when calling EndpointApi.v1_endpoint_delete_oauth_config"
228
+ end
229
+ if @api_client.config.client_side_validation && app_id.to_s.length > 256
230
+ fail ArgumentError, 'invalid value for "app_id" when calling EndpointApi.v1_endpoint_delete_oauth_config, the character length must be smaller than or equal to 256.'
231
+ end
232
+
233
+ if @api_client.config.client_side_validation && app_id.to_s.length < 1
234
+ fail ArgumentError, 'invalid value for "app_id" when calling EndpointApi.v1_endpoint_delete_oauth_config, the character length must be great than or equal to 1.'
235
+ end
236
+
237
+ pattern = Regexp.new(/^[a-zA-Z0-9\-_.]+$/)
238
+ if @api_client.config.client_side_validation && app_id !~ pattern
239
+ fail ArgumentError, "invalid value for 'app_id' when calling EndpointApi.v1_endpoint_delete_oauth_config, must conform to the pattern #{pattern}."
240
+ end
241
+
242
+ # verify the required parameter 'endpoint_id' is set
243
+ if @api_client.config.client_side_validation && endpoint_id.nil?
244
+ fail ArgumentError, "Missing the required parameter 'endpoint_id' when calling EndpointApi.v1_endpoint_delete_oauth_config"
245
+ end
246
+ if @api_client.config.client_side_validation && endpoint_id.to_s.length > 256
247
+ fail ArgumentError, 'invalid value for "endpoint_id" when calling EndpointApi.v1_endpoint_delete_oauth_config, the character length must be smaller than or equal to 256.'
248
+ end
249
+
250
+ if @api_client.config.client_side_validation && endpoint_id.to_s.length < 1
251
+ fail ArgumentError, 'invalid value for "endpoint_id" when calling EndpointApi.v1_endpoint_delete_oauth_config, the character length must be great than or equal to 1.'
252
+ end
253
+
254
+ pattern = Regexp.new(/^[a-zA-Z0-9\-_.]+$/)
255
+ if @api_client.config.client_side_validation && endpoint_id !~ pattern
256
+ fail ArgumentError, "invalid value for 'endpoint_id' when calling EndpointApi.v1_endpoint_delete_oauth_config, must conform to the pattern #{pattern}."
257
+ end
258
+
259
+ # resource path
260
+ local_var_path = '/api/v1/app/{app_id}/endpoint/{endpoint_id}/oauth'.sub('{' + 'app_id' + '}', CGI.escape(app_id.to_s)).sub('{' + 'endpoint_id' + '}', CGI.escape(endpoint_id.to_s))
261
+
262
+ # query parameters
263
+ query_params = opts[:query_params] || {}
264
+
265
+ # header parameters
266
+ header_params = opts[:header_params] || {}
267
+ # HTTP header 'Accept' (if needed)
268
+ header_params['Accept'] = @api_client.select_header_accept(['application/json'])
269
+
270
+ # form parameters
271
+ form_params = opts[:form_params] || {}
272
+
273
+ # http body (model)
274
+ post_body = opts[:debug_body]
275
+
276
+ # return_type
277
+ return_type = opts[:debug_return_type]
278
+
279
+ # auth_names
280
+ auth_names = opts[:debug_auth_names] || ['HTTPBearer']
281
+
282
+ new_options = opts.merge(
283
+ :operation => :"EndpointApi.v1_endpoint_delete_oauth_config",
284
+ :header_params => header_params,
285
+ :query_params => query_params,
286
+ :form_params => form_params,
287
+ :body => post_body,
288
+ :auth_names => auth_names,
289
+ :return_type => return_type
290
+ )
291
+
292
+ data, status_code, headers = @api_client.call_api(:DELETE, local_var_path, new_options)
293
+ if @api_client.config.debugging
294
+ @api_client.config.logger.debug "API called: EndpointApi#v1_endpoint_delete_oauth_config\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
295
+ end
296
+ return data, status_code, headers
297
+ end
298
+
204
299
  # Get Endpoint
205
300
  # Get an endpoint.
206
301
  # @param app_id [String] The app&#39;s ID or UID
@@ -1819,5 +1914,108 @@ module Svix
1819
1914
  end
1820
1915
  return data, status_code, headers
1821
1916
  end
1917
+
1918
+ # Update Endpoint Oauth Config
1919
+ # Create/update endpoint OAuth configuration
1920
+ # @param app_id [String] The app&#39;s ID or UID
1921
+ # @param endpoint_id [String] The ep&#39;s ID or UID
1922
+ # @param endpoint_oauth_config_in [EndpointOauthConfigIn]
1923
+ # @param [Hash] opts the optional parameters
1924
+ # @return [nil]
1925
+ def v1_endpoint_update_oauth_config(app_id, endpoint_id, endpoint_oauth_config_in, opts = {})
1926
+ v1_endpoint_update_oauth_config_with_http_info(app_id, endpoint_id, endpoint_oauth_config_in, opts)
1927
+ nil
1928
+ end
1929
+
1930
+ # Update Endpoint Oauth Config
1931
+ # Create/update endpoint OAuth configuration
1932
+ # @param app_id [String] The app&#39;s ID or UID
1933
+ # @param endpoint_id [String] The ep&#39;s ID or UID
1934
+ # @param endpoint_oauth_config_in [EndpointOauthConfigIn]
1935
+ # @param [Hash] opts the optional parameters
1936
+ # @return [Array<(nil, Integer, Hash)>] nil, response status code and response headers
1937
+ def v1_endpoint_update_oauth_config_with_http_info(app_id, endpoint_id, endpoint_oauth_config_in, opts = {})
1938
+ if @api_client.config.debugging
1939
+ @api_client.config.logger.debug 'Calling API: EndpointApi.v1_endpoint_update_oauth_config ...'
1940
+ end
1941
+ # verify the required parameter 'app_id' is set
1942
+ if @api_client.config.client_side_validation && app_id.nil?
1943
+ fail ArgumentError, "Missing the required parameter 'app_id' when calling EndpointApi.v1_endpoint_update_oauth_config"
1944
+ end
1945
+ if @api_client.config.client_side_validation && app_id.to_s.length > 256
1946
+ fail ArgumentError, 'invalid value for "app_id" when calling EndpointApi.v1_endpoint_update_oauth_config, the character length must be smaller than or equal to 256.'
1947
+ end
1948
+
1949
+ if @api_client.config.client_side_validation && app_id.to_s.length < 1
1950
+ fail ArgumentError, 'invalid value for "app_id" when calling EndpointApi.v1_endpoint_update_oauth_config, the character length must be great than or equal to 1.'
1951
+ end
1952
+
1953
+ pattern = Regexp.new(/^[a-zA-Z0-9\-_.]+$/)
1954
+ if @api_client.config.client_side_validation && app_id !~ pattern
1955
+ fail ArgumentError, "invalid value for 'app_id' when calling EndpointApi.v1_endpoint_update_oauth_config, must conform to the pattern #{pattern}."
1956
+ end
1957
+
1958
+ # verify the required parameter 'endpoint_id' is set
1959
+ if @api_client.config.client_side_validation && endpoint_id.nil?
1960
+ fail ArgumentError, "Missing the required parameter 'endpoint_id' when calling EndpointApi.v1_endpoint_update_oauth_config"
1961
+ end
1962
+ if @api_client.config.client_side_validation && endpoint_id.to_s.length > 256
1963
+ fail ArgumentError, 'invalid value for "endpoint_id" when calling EndpointApi.v1_endpoint_update_oauth_config, the character length must be smaller than or equal to 256.'
1964
+ end
1965
+
1966
+ if @api_client.config.client_side_validation && endpoint_id.to_s.length < 1
1967
+ fail ArgumentError, 'invalid value for "endpoint_id" when calling EndpointApi.v1_endpoint_update_oauth_config, the character length must be great than or equal to 1.'
1968
+ end
1969
+
1970
+ pattern = Regexp.new(/^[a-zA-Z0-9\-_.]+$/)
1971
+ if @api_client.config.client_side_validation && endpoint_id !~ pattern
1972
+ fail ArgumentError, "invalid value for 'endpoint_id' when calling EndpointApi.v1_endpoint_update_oauth_config, must conform to the pattern #{pattern}."
1973
+ end
1974
+
1975
+ # verify the required parameter 'endpoint_oauth_config_in' is set
1976
+ if @api_client.config.client_side_validation && endpoint_oauth_config_in.nil?
1977
+ fail ArgumentError, "Missing the required parameter 'endpoint_oauth_config_in' when calling EndpointApi.v1_endpoint_update_oauth_config"
1978
+ end
1979
+ # resource path
1980
+ local_var_path = '/api/v1/app/{app_id}/endpoint/{endpoint_id}/oauth'.sub('{' + 'app_id' + '}', CGI.escape(app_id.to_s)).sub('{' + 'endpoint_id' + '}', CGI.escape(endpoint_id.to_s))
1981
+
1982
+ # query parameters
1983
+ query_params = opts[:query_params] || {}
1984
+
1985
+ # header parameters
1986
+ header_params = opts[:header_params] || {}
1987
+ # HTTP header 'Accept' (if needed)
1988
+ header_params['Accept'] = @api_client.select_header_accept(['application/json'])
1989
+ # HTTP header 'Content-Type'
1990
+ header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])
1991
+
1992
+ # form parameters
1993
+ form_params = opts[:form_params] || {}
1994
+
1995
+ # http body (model)
1996
+ post_body = opts[:debug_body] || @api_client.object_to_http_body(endpoint_oauth_config_in)
1997
+
1998
+ # return_type
1999
+ return_type = opts[:debug_return_type]
2000
+
2001
+ # auth_names
2002
+ auth_names = opts[:debug_auth_names] || ['HTTPBearer']
2003
+
2004
+ new_options = opts.merge(
2005
+ :operation => :"EndpointApi.v1_endpoint_update_oauth_config",
2006
+ :header_params => header_params,
2007
+ :query_params => query_params,
2008
+ :form_params => form_params,
2009
+ :body => post_body,
2010
+ :auth_names => auth_names,
2011
+ :return_type => return_type
2012
+ )
2013
+
2014
+ data, status_code, headers = @api_client.call_api(:PUT, local_var_path, new_options)
2015
+ if @api_client.config.debugging
2016
+ @api_client.config.logger.debug "API called: EndpointApi#v1_endpoint_update_oauth_config\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
2017
+ end
2018
+ return data, status_code, headers
2019
+ end
1822
2020
  end
1823
2021
  end
@@ -26,6 +26,7 @@ module Svix
26
26
  # @option opts [String] :iterator The iterator returned from a prior invocation
27
27
  # @option opts [Array<String>] :event_types Filter response based on the event type
28
28
  # @option opts [Array<String>] :channels Filter response based on the event type
29
+ # @option opts [Time] :after
29
30
  # @return [MessageStreamOut]
30
31
  def v1_events(opts = {})
31
32
  data, _status_code, _headers = v1_events_with_http_info(opts)
@@ -39,6 +40,7 @@ module Svix
39
40
  # @option opts [String] :iterator The iterator returned from a prior invocation
40
41
  # @option opts [Array<String>] :event_types Filter response based on the event type
41
42
  # @option opts [Array<String>] :channels Filter response based on the event type
43
+ # @option opts [Time] :after
42
44
  # @return [Array<(MessageStreamOut, Integer, Hash)>] MessageStreamOut data, response status code and response headers
43
45
  def v1_events_with_http_info(opts = {})
44
46
  if @api_client.config.debugging
@@ -61,6 +63,7 @@ module Svix
61
63
  query_params[:'iterator'] = opts[:'iterator'] if !opts[:'iterator'].nil?
62
64
  query_params[:'event_types'] = @api_client.build_collection_param(opts[:'event_types'], :multi) if !opts[:'event_types'].nil?
63
65
  query_params[:'channels'] = @api_client.build_collection_param(opts[:'channels'], :multi) if !opts[:'channels'].nil?
66
+ query_params[:'after'] = opts[:'after'] if !opts[:'after'].nil?
64
67
 
65
68
  # header parameters
66
69
  header_params = opts[:header_params] || {}
@@ -637,6 +637,7 @@ module Svix
637
637
  # @option opts [String] :iterator The iterator returned from a prior invocation
638
638
  # @option opts [Array<String>] :event_types Filter response based on the event type
639
639
  # @option opts [Array<String>] :channels Filter response based on the event type
640
+ # @option opts [Time] :after
640
641
  # @return [MessageStreamOut]
641
642
  def v1_message_stream(app_id, opts = {})
642
643
  data, _status_code, _headers = v1_message_stream_with_http_info(app_id, opts)
@@ -651,6 +652,7 @@ module Svix
651
652
  # @option opts [String] :iterator The iterator returned from a prior invocation
652
653
  # @option opts [Array<String>] :event_types Filter response based on the event type
653
654
  # @option opts [Array<String>] :channels Filter response based on the event type
655
+ # @option opts [Time] :after
654
656
  # @return [Array<(MessageStreamOut, Integer, Hash)>] MessageStreamOut data, response status code and response headers
655
657
  def v1_message_stream_with_http_info(app_id, opts = {})
656
658
  if @api_client.config.debugging
@@ -690,6 +692,7 @@ module Svix
690
692
  query_params[:'iterator'] = opts[:'iterator'] if !opts[:'iterator'].nil?
691
693
  query_params[:'event_types'] = @api_client.build_collection_param(opts[:'event_types'], :multi) if !opts[:'event_types'].nil?
692
694
  query_params[:'channels'] = @api_client.build_collection_param(opts[:'channels'], :multi) if !opts[:'channels'].nil?
695
+ query_params[:'after'] = opts[:'after'] if !opts[:'after'].nil?
693
696
 
694
697
  # header parameters
695
698
  header_params = opts[:header_params] || {}
data/lib/svix/version.rb CHANGED
@@ -1,5 +1,5 @@
1
1
  # frozen_string_literal: true
2
2
 
3
3
  module Svix
4
- VERSION = "1.22.0"
4
+ VERSION = "1.23.0"
5
5
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: svix
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.22.0
4
+ version: 1.23.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Svix
8
8
  autorequire:
9
9
  bindir: exe
10
10
  cert_chain: []
11
- date: 2024-04-30 00:00:00.000000000 Z
11
+ date: 2024-05-03 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: typhoeus