svix 1.45.1 → 1.57.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.
Files changed (98) hide show
  1. checksums.yaml +4 -4
  2. data/Gemfile.lock +1 -1
  3. data/lib/svix/api/application_api.rb +115 -10
  4. data/lib/svix/api/authentication_api.rb +101 -16
  5. data/lib/svix/api/background_tasks_api.rb +43 -17
  6. data/lib/svix/api/endpoint_api.rb +312 -96
  7. data/lib/svix/api/inbound_api.rb +4 -4
  8. data/lib/svix/api/integration_api.rb +102 -24
  9. data/lib/svix/api/message_api.rb +142 -39
  10. data/lib/svix/api/message_attempt_api.rb +135 -372
  11. data/lib/svix/api/statistics_api.rb +6 -6
  12. data/lib/svix/api/stream_api.rb +203 -142
  13. data/lib/svix/api/transformation_template_api.rb +88 -23
  14. data/lib/svix/api/webhook_endpoint_api.rb +253 -77
  15. data/lib/svix/background_tasks_api.rb +2 -2
  16. data/lib/svix/message_attempt_api.rb +7 -3
  17. data/lib/svix/models/active_application_out.rb +373 -0
  18. data/lib/svix/models/active_endpoint_out.rb +355 -0
  19. data/lib/svix/models/aggregate_event_types_out.rb +40 -0
  20. data/lib/svix/models/aggregated_event_types.rb +305 -0
  21. data/lib/svix/models/app_portal_access_in.rb +18 -0
  22. data/lib/svix/models/app_usage_stats_out.rb +40 -0
  23. data/lib/svix/models/application_message_failure.rb +277 -0
  24. data/lib/svix/models/application_message_id_pair.rb +317 -0
  25. data/lib/svix/models/application_out.rb +41 -2
  26. data/lib/svix/models/application_patch.rb +1 -1
  27. data/lib/svix/models/application_stats.rb +41 -2
  28. data/lib/svix/models/application_stats_out.rb +324 -0
  29. data/lib/svix/models/auth_token_out.rb +40 -1
  30. data/lib/svix/models/background_task_finished_event.rb +272 -0
  31. data/lib/svix/models/background_task_finished_event2.rb +331 -0
  32. data/lib/svix/models/background_task_out.rb +40 -0
  33. data/lib/svix/models/background_task_type.rb +2 -1
  34. data/lib/svix/models/{template_in.rb → connector_in.rb} +4 -4
  35. data/lib/svix/models/{transformation_template_kind.rb → connector_kind.rb} +3 -3
  36. data/lib/svix/models/create_stream_in.rb +12 -12
  37. data/lib/svix/models/data.rb +108 -0
  38. data/lib/svix/models/data_any_of.rb +240 -0
  39. data/lib/svix/models/data_any_of1.rb +223 -0
  40. data/lib/svix/models/data_any_of2.rb +241 -0
  41. data/lib/svix/models/data_any_of3.rb +223 -0
  42. data/lib/svix/models/data_any_of4.rb +240 -0
  43. data/lib/svix/models/endpoint_created_event_data.rb +82 -4
  44. data/lib/svix/models/endpoint_deleted_event_data.rb +82 -4
  45. data/lib/svix/models/endpoint_disabled_event.rb +1 -1
  46. data/lib/svix/models/endpoint_disabled_event_data.rb +119 -16
  47. data/lib/svix/models/endpoint_disabled_trigger.rb +40 -0
  48. data/lib/svix/models/endpoint_enabled_event.rb +272 -0
  49. data/lib/svix/models/endpoint_enabled_event_data.rb +410 -0
  50. data/lib/svix/models/endpoint_message_out.rb +40 -1
  51. data/lib/svix/models/endpoint_mtls_config_out.rb +215 -0
  52. data/lib/svix/models/endpoint_oauth_config_in.rb +2 -2
  53. data/lib/svix/models/endpoint_oauth_config_out.rb +315 -0
  54. data/lib/svix/models/endpoint_out.rb +40 -1
  55. data/lib/svix/models/endpoint_patch.rb +1 -1
  56. data/lib/svix/models/endpoint_updated_event_data.rb +82 -4
  57. data/lib/svix/models/environment_in.rb +17 -19
  58. data/lib/svix/models/environment_settings_out.rb +23 -1
  59. data/lib/svix/models/event_type_import_open_api_in.rb +14 -2
  60. data/lib/svix/models/export_event_type_out.rb +40 -0
  61. data/lib/svix/models/expung_all_contents_out.rb +315 -0
  62. data/lib/svix/models/inbound_path_params.rb +1 -1
  63. data/lib/svix/models/integration_in.rb +41 -1
  64. data/lib/svix/models/integration_out.rb +81 -2
  65. data/lib/svix/models/integration_update.rb +41 -1
  66. data/lib/svix/models/list_response_active_application_out.rb +261 -0
  67. data/lib/svix/models/message_attempt_endpoint_out.rb +120 -3
  68. data/lib/svix/models/message_attempt_exhausted_event_data.rb +122 -5
  69. data/lib/svix/models/message_attempt_failed_data.rb +40 -1
  70. data/lib/svix/models/message_attempt_failing_event_data.rb +122 -5
  71. data/lib/svix/models/message_attempt_out.rb +120 -3
  72. data/lib/svix/models/message_attempt_recovered_event_data.rb +122 -5
  73. data/lib/svix/models/message_broadcast_out.rb +40 -0
  74. data/lib/svix/models/message_endpoint_out.rb +40 -1
  75. data/lib/svix/models/message_out.rb +40 -1
  76. data/lib/svix/models/message_precheck_in.rb +288 -0
  77. data/lib/svix/models/message_precheck_out.rb +221 -0
  78. data/lib/svix/models/{oauth2_auth_method_in.rb → oauth2_auth_method_in_out.rb} +3 -3
  79. data/lib/svix/models/{oauth2_grant_type_in.rb → oauth2_grant_type_in_out.rb} +3 -3
  80. data/lib/svix/models/operational_webhook_endpoint_headers_in.rb +223 -0
  81. data/lib/svix/models/operational_webhook_endpoint_headers_out.rb +251 -0
  82. data/lib/svix/models/operational_webhook_endpoint_out.rb +40 -1
  83. data/lib/svix/models/polling_endpoint_message_out.rb +454 -0
  84. data/lib/svix/models/polling_endpoint_out.rb +255 -0
  85. data/lib/svix/models/recover_out.rb +40 -0
  86. data/lib/svix/models/replay_out.rb +40 -0
  87. data/lib/svix/models/rotate_poller_token_in.rb +1 -1
  88. data/lib/svix/models/sink_secret_out.rb +233 -0
  89. data/lib/svix/models/stream_in.rb +6 -7
  90. data/lib/svix/models/stream_out.rb +46 -7
  91. data/lib/svix/models/stream_patch.rb +6 -7
  92. data/lib/svix/models/stream_portal_access_in.rb +293 -0
  93. data/lib/svix/models/template_out.rb +81 -1
  94. data/lib/svix/models/template_patch.rb +1 -1
  95. data/lib/svix/models/template_update.rb +1 -1
  96. data/lib/svix/version.rb +1 -1
  97. metadata +35 -7
  98. data/lib/svix/operational_webhook_endpoint_api.rb +0 -37
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 17206cce33b892853adf1582a2e1624a178fc4335f397536ba882fd11a9198d0
4
- data.tar.gz: f9acdbb48185b15902fdf7a4a3899aabee42fa02d3102e0c0b2bbf107e7cea94
3
+ metadata.gz: 9168157b17633ce40c85b8aa93a7a487490a66dd0bde992cd4413f14437ae14a
4
+ data.tar.gz: 68b61e4e33e0b706cb9321312183fbc9f2012ff256bd91d8d4676bc1de98ddd0
5
5
  SHA512:
6
- metadata.gz: e766217ee4ee4c0c2bedd5d7a8333d60d727d601ed1f9e4a12af9e61f8937fc12d71802ee051841ebc8ba07444c36fdc32b217b5a01aec15d485fef7da07a9bd
7
- data.tar.gz: a814d686a10ed0de22f6f84e9c88a6209f293216edb8a9c5430a937479315016e917ed78c6311877c1e0760f2d6c595e0c8acdf4b2ad3a045e5dafdf09d8b7cd
6
+ metadata.gz: e46351c0ff651417cc3b01d8659260e6d22a4e5870ad27214047aa1245ade5b26617d1d6dc102223ad7d31273925f008e8534ffc270f69a44cdfd39d492771c9
7
+ data.tar.gz: 06d98be291d2ff1c52bdf13ef3fdc2d903d817ab82c853bf708cfeee4882acbfdc1faf05e2a6e82e477384379877188ff40b5bb521d138bb1cf3dc0487922e43
data/Gemfile.lock CHANGED
@@ -1,7 +1,7 @@
1
1
  PATH
2
2
  remote: .
3
3
  specs:
4
- svix (1.45.1)
4
+ svix (1.57.0)
5
5
 
6
6
  GEM
7
7
  remote: https://rubygems.org/
@@ -56,6 +56,19 @@ module Svix
56
56
  fail ArgumentError, 'invalid value for "opts[:"limit"]" when calling ApplicationApi.get_app_usage_stats_api_v1_app_stats_usage_get, must be smaller than or equal to 250.'
57
57
  end
58
58
 
59
+ if @api_client.config.client_side_validation && !opts[:'iterator'].nil? && opts[:'iterator'].to_s.length > 31
60
+ fail ArgumentError, 'invalid value for "opts[:"iterator"]" when calling ApplicationApi.get_app_usage_stats_api_v1_app_stats_usage_get, the character length must be smaller than or equal to 31.'
61
+ end
62
+
63
+ if @api_client.config.client_side_validation && !opts[:'iterator'].nil? && opts[:'iterator'].to_s.length < 31
64
+ fail ArgumentError, 'invalid value for "opts[:"iterator"]" when calling ApplicationApi.get_app_usage_stats_api_v1_app_stats_usage_get, the character length must be great than or equal to 31.'
65
+ end
66
+
67
+ pattern = Regexp.new(/^app_[A-Za-z0-9]{27}$/)
68
+ if @api_client.config.client_side_validation && !opts[:'iterator'].nil? && opts[:'iterator'] !~ pattern
69
+ fail ArgumentError, "invalid value for 'opts[:\"iterator\"]' when calling ApplicationApi.get_app_usage_stats_api_v1_app_stats_usage_get, must conform to the pattern #{pattern}."
70
+ end
71
+
59
72
  # resource path
60
73
  local_var_path = '/api/v1/app/stats/usage'
61
74
 
@@ -176,7 +189,7 @@ module Svix
176
189
 
177
190
  # Delete Application
178
191
  # Delete an application.
179
- # @param app_id [String] The app&#39;s ID or UID
192
+ # @param app_id [String] The Application&#39;s ID or UID.
180
193
  # @param [Hash] opts the optional parameters
181
194
  # @return [nil]
182
195
  def v1_application_delete(app_id, opts = {})
@@ -186,7 +199,7 @@ module Svix
186
199
 
187
200
  # Delete Application
188
201
  # Delete an application.
189
- # @param app_id [String] The app&#39;s ID or UID
202
+ # @param app_id [String] The Application&#39;s ID or UID.
190
203
  # @param [Hash] opts the optional parameters
191
204
  # @return [Array<(nil, Integer, Hash)>] nil, response status code and response headers
192
205
  def v1_application_delete_with_http_info(app_id, opts = {})
@@ -252,7 +265,7 @@ module Svix
252
265
 
253
266
  # Get Application
254
267
  # Get an application.
255
- # @param app_id [String] The app&#39;s ID or UID
268
+ # @param app_id [String] The Application&#39;s ID or UID.
256
269
  # @param [Hash] opts the optional parameters
257
270
  # @return [ApplicationOut]
258
271
  def v1_application_get(app_id, opts = {})
@@ -262,7 +275,7 @@ module Svix
262
275
 
263
276
  # Get Application
264
277
  # Get an application.
265
- # @param app_id [String] The app&#39;s ID or UID
278
+ # @param app_id [String] The Application&#39;s ID or UID.
266
279
  # @param [Hash] opts the optional parameters
267
280
  # @return [Array<(ApplicationOut, Integer, Hash)>] ApplicationOut data, response status code and response headers
268
281
  def v1_application_get_with_http_info(app_id, opts = {})
@@ -330,7 +343,7 @@ module Svix
330
343
  # Get basic statistics for the application.
331
344
  # @param since [Time] Filter the range to data starting from this date.
332
345
  # @param _until [Time] Filter the range to data ending by this date.
333
- # @param app_id [String] The app&#39;s ID or UID
346
+ # @param app_id [String] The Application&#39;s ID or UID.
334
347
  # @param [Hash] opts the optional parameters
335
348
  # @return [ApplicationStats]
336
349
  def v1_application_get_stats(since, _until, app_id, opts = {})
@@ -342,7 +355,7 @@ module Svix
342
355
  # Get basic statistics for the application.
343
356
  # @param since [Time] Filter the range to data starting from this date.
344
357
  # @param _until [Time] Filter the range to data ending by this date.
345
- # @param app_id [String] The app&#39;s ID or UID
358
+ # @param app_id [String] The Application&#39;s ID or UID.
346
359
  # @param [Hash] opts the optional parameters
347
360
  # @return [Array<(ApplicationStats, Integer, Hash)>] ApplicationStats data, response status code and response headers
348
361
  def v1_application_get_stats_with_http_info(since, _until, app_id, opts = {})
@@ -447,6 +460,19 @@ module Svix
447
460
  fail ArgumentError, 'invalid value for "opts[:"limit"]" when calling ApplicationApi.v1_application_list, must be greater than or equal to 1.'
448
461
  end
449
462
 
463
+ if @api_client.config.client_side_validation && !opts[:'iterator'].nil? && opts[:'iterator'].to_s.length > 31
464
+ fail ArgumentError, 'invalid value for "opts[:"iterator"]" when calling ApplicationApi.v1_application_list, the character length must be smaller than or equal to 31.'
465
+ end
466
+
467
+ if @api_client.config.client_side_validation && !opts[:'iterator'].nil? && opts[:'iterator'].to_s.length < 31
468
+ fail ArgumentError, 'invalid value for "opts[:"iterator"]" when calling ApplicationApi.v1_application_list, the character length must be great than or equal to 31.'
469
+ end
470
+
471
+ pattern = Regexp.new(/^app_[A-Za-z0-9]{27}$/)
472
+ if @api_client.config.client_side_validation && !opts[:'iterator'].nil? && opts[:'iterator'] !~ pattern
473
+ fail ArgumentError, "invalid value for 'opts[:\"iterator\"]' when calling ApplicationApi.v1_application_list, must conform to the pattern #{pattern}."
474
+ end
475
+
450
476
  # resource path
451
477
  local_var_path = '/api/v1/app'
452
478
 
@@ -492,7 +518,7 @@ module Svix
492
518
 
493
519
  # Patch Application
494
520
  # Partially update an application.
495
- # @param app_id [String] The app&#39;s ID or UID
521
+ # @param app_id [String] The Application&#39;s ID or UID.
496
522
  # @param application_patch [ApplicationPatch]
497
523
  # @param [Hash] opts the optional parameters
498
524
  # @return [ApplicationOut]
@@ -503,7 +529,7 @@ module Svix
503
529
 
504
530
  # Patch Application
505
531
  # Partially update an application.
506
- # @param app_id [String] The app&#39;s ID or UID
532
+ # @param app_id [String] The Application&#39;s ID or UID.
507
533
  # @param application_patch [ApplicationPatch]
508
534
  # @param [Hash] opts the optional parameters
509
535
  # @return [Array<(ApplicationOut, Integer, Hash)>] ApplicationOut data, response status code and response headers
@@ -579,7 +605,7 @@ module Svix
579
605
 
580
606
  # Update Application
581
607
  # Update an application.
582
- # @param app_id [String] The app&#39;s ID or UID
608
+ # @param app_id [String] The Application&#39;s ID or UID.
583
609
  # @param application_in [ApplicationIn]
584
610
  # @param [Hash] opts the optional parameters
585
611
  # @return [ApplicationOut]
@@ -590,7 +616,7 @@ module Svix
590
616
 
591
617
  # Update Application
592
618
  # Update an application.
593
- # @param app_id [String] The app&#39;s ID or UID
619
+ # @param app_id [String] The Application&#39;s ID or UID.
594
620
  # @param application_in [ApplicationIn]
595
621
  # @param [Hash] opts the optional parameters
596
622
  # @return [Array<(ApplicationOut, Integer, Hash)>] ApplicationOut data, response status code and response headers
@@ -663,5 +689,84 @@ module Svix
663
689
  end
664
690
  return data, status_code, headers
665
691
  end
692
+
693
+ # Expunge all message contents
694
+ # Purge all message content for the application. Delete all message payloads for the application.
695
+ # @param app_id [String] The Application&#39;s ID or UID.
696
+ # @param [Hash] opts the optional parameters
697
+ # @option opts [String] :idempotency_key The request&#39;s idempotency key
698
+ # @return [ExpungAllContentsOut]
699
+ def v1_message_expunge_all_contents(app_id, opts = {})
700
+ data, _status_code, _headers = v1_message_expunge_all_contents_with_http_info(app_id, opts)
701
+ data
702
+ end
703
+
704
+ # Expunge all message contents
705
+ # Purge all message content for the application. Delete all message payloads for the application.
706
+ # @param app_id [String] The Application&#39;s ID or UID.
707
+ # @param [Hash] opts the optional parameters
708
+ # @option opts [String] :idempotency_key The request&#39;s idempotency key
709
+ # @return [Array<(ExpungAllContentsOut, Integer, Hash)>] ExpungAllContentsOut data, response status code and response headers
710
+ def v1_message_expunge_all_contents_with_http_info(app_id, opts = {})
711
+ if @api_client.config.debugging
712
+ @api_client.config.logger.debug 'Calling API: ApplicationApi.v1_message_expunge_all_contents ...'
713
+ end
714
+ # verify the required parameter 'app_id' is set
715
+ if @api_client.config.client_side_validation && app_id.nil?
716
+ fail ArgumentError, "Missing the required parameter 'app_id' when calling ApplicationApi.v1_message_expunge_all_contents"
717
+ end
718
+ if @api_client.config.client_side_validation && app_id.to_s.length > 256
719
+ fail ArgumentError, 'invalid value for "app_id" when calling ApplicationApi.v1_message_expunge_all_contents, the character length must be smaller than or equal to 256.'
720
+ end
721
+
722
+ if @api_client.config.client_side_validation && app_id.to_s.length < 1
723
+ fail ArgumentError, 'invalid value for "app_id" when calling ApplicationApi.v1_message_expunge_all_contents, the character length must be great than or equal to 1.'
724
+ end
725
+
726
+ pattern = Regexp.new(/^[a-zA-Z0-9\-_.]+$/)
727
+ if @api_client.config.client_side_validation && app_id !~ pattern
728
+ fail ArgumentError, "invalid value for 'app_id' when calling ApplicationApi.v1_message_expunge_all_contents, must conform to the pattern #{pattern}."
729
+ end
730
+
731
+ # resource path
732
+ local_var_path = '/api/v1/app/{app_id}/msg/expunge-all-contents'.sub('{' + 'app_id' + '}', CGI.escape(app_id.to_s))
733
+
734
+ # query parameters
735
+ query_params = opts[:query_params] || {}
736
+
737
+ # header parameters
738
+ header_params = opts[:header_params] || {}
739
+ # HTTP header 'Accept' (if needed)
740
+ header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']
741
+ header_params[:'idempotency-key'] = opts[:'idempotency_key'] if !opts[:'idempotency_key'].nil?
742
+
743
+ # form parameters
744
+ form_params = opts[:form_params] || {}
745
+
746
+ # http body (model)
747
+ post_body = opts[:debug_body]
748
+
749
+ # return_type
750
+ return_type = opts[:debug_return_type] || 'ExpungAllContentsOut'
751
+
752
+ # auth_names
753
+ auth_names = opts[:debug_auth_names] || ['HTTPBearer']
754
+
755
+ new_options = opts.merge(
756
+ :operation => :"ApplicationApi.v1_message_expunge_all_contents",
757
+ :header_params => header_params,
758
+ :query_params => query_params,
759
+ :form_params => form_params,
760
+ :body => post_body,
761
+ :auth_names => auth_names,
762
+ :return_type => return_type
763
+ )
764
+
765
+ data, status_code, headers = @api_client.call_api(:POST, local_var_path, new_options)
766
+ if @api_client.config.debugging
767
+ @api_client.config.logger.debug "API called: ApplicationApi#v1_message_expunge_all_contents\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
768
+ end
769
+ return data, status_code, headers
770
+ end
666
771
  end
667
772
  end
@@ -21,7 +21,7 @@ module Svix
21
21
  end
22
22
  # Get Consumer App Portal Access
23
23
  # Use this function to get magic links (and authentication codes) for connecting your users to the Consumer Application Portal.
24
- # @param app_id [String] The app&#39;s ID or UID
24
+ # @param app_id [String] The Application&#39;s ID or UID.
25
25
  # @param app_portal_access_in [AppPortalAccessIn]
26
26
  # @param [Hash] opts the optional parameters
27
27
  # @option opts [String] :idempotency_key The request&#39;s idempotency key
@@ -33,7 +33,7 @@ module Svix
33
33
 
34
34
  # Get Consumer App Portal Access
35
35
  # Use this function to get magic links (and authentication codes) for connecting your users to the Consumer Application Portal.
36
- # @param app_id [String] The app&#39;s ID or UID
36
+ # @param app_id [String] The Application&#39;s ID or UID.
37
37
  # @param app_portal_access_in [AppPortalAccessIn]
38
38
  # @param [Hash] opts the optional parameters
39
39
  # @option opts [String] :idempotency_key The request&#39;s idempotency key
@@ -111,7 +111,7 @@ module Svix
111
111
 
112
112
  # Create Cmg Token
113
113
  # Create a new access token that only allows creating messages inside this application.
114
- # @param app_id [String] The app&#39;s ID or UID
114
+ # @param app_id [String] The Application&#39;s ID or UID.
115
115
  # @param create_token_in [CreateTokenIn]
116
116
  # @param [Hash] opts the optional parameters
117
117
  # @option opts [String] :idempotency_key The request&#39;s idempotency key
@@ -123,7 +123,7 @@ module Svix
123
123
 
124
124
  # Create Cmg Token
125
125
  # Create a new access token that only allows creating messages inside this application.
126
- # @param app_id [String] The app&#39;s ID or UID
126
+ # @param app_id [String] The Application&#39;s ID or UID.
127
127
  # @param create_token_in [CreateTokenIn]
128
128
  # @param [Hash] opts the optional parameters
129
129
  # @option opts [String] :idempotency_key The request&#39;s idempotency key
@@ -201,7 +201,7 @@ module Svix
201
201
 
202
202
  # Dashboard Access
203
203
  # DEPRECATED: Please use `app-portal-access` instead. Use this function to get magic links (and authentication codes) for connecting your users to the Consumer Application Portal.
204
- # @param app_id [String] The app&#39;s ID or UID
204
+ # @param app_id [String] The Application&#39;s ID or UID.
205
205
  # @param [Hash] opts the optional parameters
206
206
  # @option opts [String] :idempotency_key The request&#39;s idempotency key
207
207
  # @return [DashboardAccessOut]
@@ -212,7 +212,7 @@ module Svix
212
212
 
213
213
  # Dashboard Access
214
214
  # DEPRECATED: Please use &#x60;app-portal-access&#x60; instead. Use this function to get magic links (and authentication codes) for connecting your users to the Consumer Application Portal.
215
- # @param app_id [String] The app&#39;s ID or UID
215
+ # @param app_id [String] The Application&#39;s ID or UID.
216
216
  # @param [Hash] opts the optional parameters
217
217
  # @option opts [String] :idempotency_key The request&#39;s idempotency key
218
218
  # @return [Array<(DashboardAccessOut, Integer, Hash)>] DashboardAccessOut data, response status code and response headers
@@ -351,7 +351,7 @@ module Svix
351
351
 
352
352
  # Expire All
353
353
  # Expire all of the tokens associated with a specific application.
354
- # @param app_id [String] The app&#39;s ID or UID
354
+ # @param app_id [String] The Application&#39;s ID or UID.
355
355
  # @param application_token_expire_in [ApplicationTokenExpireIn]
356
356
  # @param [Hash] opts the optional parameters
357
357
  # @option opts [String] :idempotency_key The request&#39;s idempotency key
@@ -363,7 +363,7 @@ module Svix
363
363
 
364
364
  # Expire All
365
365
  # Expire all of the tokens associated with a specific application.
366
- # @param app_id [String] The app&#39;s ID or UID
366
+ # @param app_id [String] The Application&#39;s ID or UID.
367
367
  # @param application_token_expire_in [ApplicationTokenExpireIn]
368
368
  # @param [Hash] opts the optional parameters
369
369
  # @option opts [String] :idempotency_key The request&#39;s idempotency key
@@ -441,8 +441,8 @@ module Svix
441
441
 
442
442
  # Get Poller Token
443
443
  # Get the current auth token for the poller.
444
- # @param app_id [String] The app&#39;s ID or UID
445
- # @param endpoint_id [String] The ep&#39;s ID or UID
444
+ # @param app_id [String] The Application&#39;s ID or UID.
445
+ # @param endpoint_id [String] The Endpoint&#39;s ID or UID.
446
446
  # @param [Hash] opts the optional parameters
447
447
  # @return [AuthTokenOut]
448
448
  def v1_authentication_get_poller_token(app_id, endpoint_id, opts = {})
@@ -452,8 +452,8 @@ module Svix
452
452
 
453
453
  # Get Poller Token
454
454
  # Get the current auth token for the poller.
455
- # @param app_id [String] The app&#39;s ID or UID
456
- # @param endpoint_id [String] The ep&#39;s ID or UID
455
+ # @param app_id [String] The Application&#39;s ID or UID.
456
+ # @param endpoint_id [String] The Endpoint&#39;s ID or UID.
457
457
  # @param [Hash] opts the optional parameters
458
458
  # @return [Array<(AuthTokenOut, Integer, Hash)>] AuthTokenOut data, response status code and response headers
459
459
  def v1_authentication_get_poller_token_with_http_info(app_id, endpoint_id, opts = {})
@@ -596,8 +596,8 @@ module Svix
596
596
 
597
597
  # Rotate Poller Token
598
598
  # Create a new auth token that can for the poller API.
599
- # @param app_id [String] The app&#39;s ID or UID
600
- # @param endpoint_id [String] The ep&#39;s ID or UID
599
+ # @param app_id [String] The Application&#39;s ID or UID.
600
+ # @param endpoint_id [String] The Endpoint&#39;s ID or UID.
601
601
  # @param rotate_poller_token_in [RotatePollerTokenIn]
602
602
  # @param [Hash] opts the optional parameters
603
603
  # @option opts [String] :idempotency_key The request&#39;s idempotency key
@@ -609,8 +609,8 @@ module Svix
609
609
 
610
610
  # Rotate Poller Token
611
611
  # Create a new auth token that can for the poller API.
612
- # @param app_id [String] The app&#39;s ID or UID
613
- # @param endpoint_id [String] The ep&#39;s ID or UID
612
+ # @param app_id [String] The Application&#39;s ID or UID.
613
+ # @param endpoint_id [String] The Endpoint&#39;s ID or UID.
614
614
  # @param rotate_poller_token_in [RotatePollerTokenIn]
615
615
  # @param [Hash] opts the optional parameters
616
616
  # @option opts [String] :idempotency_key The request&#39;s idempotency key
@@ -702,5 +702,90 @@ module Svix
702
702
  end
703
703
  return data, status_code, headers
704
704
  end
705
+
706
+ # Get Stream Portal Access
707
+ # Use this function to get magic links (and authentication codes) for connecting your users to the Stream Consumer Portal.
708
+ # @param stream_id [String] The Stream&#39;s ID or UID.
709
+ # @param stream_portal_access_in [StreamPortalAccessIn]
710
+ # @param [Hash] opts the optional parameters
711
+ # @option opts [String] :idempotency_key The request&#39;s idempotency key
712
+ # @return [AppPortalAccessOut]
713
+ def v1_authentication_stream_portal_access(stream_id, stream_portal_access_in, opts = {})
714
+ data, _status_code, _headers = v1_authentication_stream_portal_access_with_http_info(stream_id, stream_portal_access_in, opts)
715
+ data
716
+ end
717
+
718
+ # Get Stream Portal Access
719
+ # Use this function to get magic links (and authentication codes) for connecting your users to the Stream Consumer Portal.
720
+ # @param stream_id [String] The Stream&#39;s ID or UID.
721
+ # @param stream_portal_access_in [StreamPortalAccessIn]
722
+ # @param [Hash] opts the optional parameters
723
+ # @option opts [String] :idempotency_key The request&#39;s idempotency key
724
+ # @return [Array<(AppPortalAccessOut, Integer, Hash)>] AppPortalAccessOut data, response status code and response headers
725
+ def v1_authentication_stream_portal_access_with_http_info(stream_id, stream_portal_access_in, opts = {})
726
+ if @api_client.config.debugging
727
+ @api_client.config.logger.debug 'Calling API: AuthenticationApi.v1_authentication_stream_portal_access ...'
728
+ end
729
+ # verify the required parameter 'stream_id' is set
730
+ if @api_client.config.client_side_validation && stream_id.nil?
731
+ fail ArgumentError, "Missing the required parameter 'stream_id' when calling AuthenticationApi.v1_authentication_stream_portal_access"
732
+ end
733
+ if @api_client.config.client_side_validation && stream_id.to_s.length > 60
734
+ fail ArgumentError, 'invalid value for "stream_id" when calling AuthenticationApi.v1_authentication_stream_portal_access, the character length must be smaller than or equal to 60.'
735
+ end
736
+
737
+ if @api_client.config.client_side_validation && stream_id.to_s.length < 1
738
+ fail ArgumentError, 'invalid value for "stream_id" when calling AuthenticationApi.v1_authentication_stream_portal_access, the character length must be great than or equal to 1.'
739
+ end
740
+
741
+ # verify the required parameter 'stream_portal_access_in' is set
742
+ if @api_client.config.client_side_validation && stream_portal_access_in.nil?
743
+ fail ArgumentError, "Missing the required parameter 'stream_portal_access_in' when calling AuthenticationApi.v1_authentication_stream_portal_access"
744
+ end
745
+ # resource path
746
+ local_var_path = '/api/v1/auth/stream-portal-access/{stream_id}'.sub('{' + 'stream_id' + '}', CGI.escape(stream_id.to_s))
747
+
748
+ # query parameters
749
+ query_params = opts[:query_params] || {}
750
+
751
+ # header parameters
752
+ header_params = opts[:header_params] || {}
753
+ # HTTP header 'Accept' (if needed)
754
+ header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']
755
+ # HTTP header 'Content-Type'
756
+ content_type = @api_client.select_header_content_type(['application/json'])
757
+ if !content_type.nil?
758
+ header_params['Content-Type'] = content_type
759
+ end
760
+ header_params[:'idempotency-key'] = opts[:'idempotency_key'] if !opts[:'idempotency_key'].nil?
761
+
762
+ # form parameters
763
+ form_params = opts[:form_params] || {}
764
+
765
+ # http body (model)
766
+ post_body = opts[:debug_body] || @api_client.object_to_http_body(stream_portal_access_in)
767
+
768
+ # return_type
769
+ return_type = opts[:debug_return_type] || 'AppPortalAccessOut'
770
+
771
+ # auth_names
772
+ auth_names = opts[:debug_auth_names] || ['HTTPBearer']
773
+
774
+ new_options = opts.merge(
775
+ :operation => :"AuthenticationApi.v1_authentication_stream_portal_access",
776
+ :header_params => header_params,
777
+ :query_params => query_params,
778
+ :form_params => form_params,
779
+ :body => post_body,
780
+ :auth_names => auth_names,
781
+ :return_type => return_type
782
+ )
783
+
784
+ data, status_code, headers = @api_client.call_api(:POST, local_var_path, new_options)
785
+ if @api_client.config.debugging
786
+ @api_client.config.logger.debug "API called: AuthenticationApi#v1_authentication_stream_portal_access\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
787
+ end
788
+ return data, status_code, headers
789
+ end
705
790
  end
706
791
  end
@@ -21,27 +21,40 @@ module Svix
21
21
  end
22
22
  # Get Background Task
23
23
  # Get a background task by ID.
24
- # @param task_id [String]
24
+ # @param task_id [String] The QueueBackgroundTask&#39;s ID.
25
25
  # @param [Hash] opts the optional parameters
26
26
  # @return [BackgroundTaskOut]
27
- def get_background_task(task_id, opts = {})
28
- data, _status_code, _headers = get_background_task_with_http_info(task_id, opts)
27
+ def v1_background_task_get(task_id, opts = {})
28
+ data, _status_code, _headers = v1_background_task_get_with_http_info(task_id, opts)
29
29
  data
30
30
  end
31
31
 
32
32
  # Get Background Task
33
33
  # Get a background task by ID.
34
- # @param task_id [String]
34
+ # @param task_id [String] The QueueBackgroundTask&#39;s ID.
35
35
  # @param [Hash] opts the optional parameters
36
36
  # @return [Array<(BackgroundTaskOut, Integer, Hash)>] BackgroundTaskOut data, response status code and response headers
37
- def get_background_task_with_http_info(task_id, opts = {})
37
+ def v1_background_task_get_with_http_info(task_id, opts = {})
38
38
  if @api_client.config.debugging
39
- @api_client.config.logger.debug 'Calling API: BackgroundTasksApi.get_background_task ...'
39
+ @api_client.config.logger.debug 'Calling API: BackgroundTasksApi.v1_background_task_get ...'
40
40
  end
41
41
  # verify the required parameter 'task_id' is set
42
42
  if @api_client.config.client_side_validation && task_id.nil?
43
- fail ArgumentError, "Missing the required parameter 'task_id' when calling BackgroundTasksApi.get_background_task"
43
+ fail ArgumentError, "Missing the required parameter 'task_id' when calling BackgroundTasksApi.v1_background_task_get"
44
44
  end
45
+ if @api_client.config.client_side_validation && task_id.to_s.length > 33
46
+ fail ArgumentError, 'invalid value for "task_id" when calling BackgroundTasksApi.v1_background_task_get, the character length must be smaller than or equal to 33.'
47
+ end
48
+
49
+ if @api_client.config.client_side_validation && task_id.to_s.length < 33
50
+ fail ArgumentError, 'invalid value for "task_id" when calling BackgroundTasksApi.v1_background_task_get, the character length must be great than or equal to 33.'
51
+ end
52
+
53
+ pattern = Regexp.new(/^qtask_[A-Za-z0-9]{27}$/)
54
+ if @api_client.config.client_side_validation && task_id !~ pattern
55
+ fail ArgumentError, "invalid value for 'task_id' when calling BackgroundTasksApi.v1_background_task_get, must conform to the pattern #{pattern}."
56
+ end
57
+
45
58
  # resource path
46
59
  local_var_path = '/api/v1/background-task/{task_id}'.sub('{' + 'task_id' + '}', CGI.escape(task_id.to_s))
47
60
 
@@ -66,7 +79,7 @@ module Svix
66
79
  auth_names = opts[:debug_auth_names] || ['HTTPBearer']
67
80
 
68
81
  new_options = opts.merge(
69
- :operation => :"BackgroundTasksApi.get_background_task",
82
+ :operation => :"BackgroundTasksApi.v1_background_task_get",
70
83
  :header_params => header_params,
71
84
  :query_params => query_params,
72
85
  :form_params => form_params,
@@ -77,7 +90,7 @@ module Svix
77
90
 
78
91
  data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
79
92
  if @api_client.config.debugging
80
- @api_client.config.logger.debug "API called: BackgroundTasksApi#get_background_task\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
93
+ @api_client.config.logger.debug "API called: BackgroundTasksApi#v1_background_task_get\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
81
94
  end
82
95
  return data, status_code, headers
83
96
  end
@@ -91,8 +104,8 @@ module Svix
91
104
  # @option opts [String] :iterator The iterator returned from a prior invocation
92
105
  # @option opts [Ordering] :order The sorting order of the returned items
93
106
  # @return [ListResponseBackgroundTaskOut]
94
- def list_background_tasks(opts = {})
95
- data, _status_code, _headers = list_background_tasks_with_http_info(opts)
107
+ def v1_background_task_list(opts = {})
108
+ data, _status_code, _headers = v1_background_task_list_with_http_info(opts)
96
109
  data
97
110
  end
98
111
 
@@ -105,16 +118,29 @@ module Svix
105
118
  # @option opts [String] :iterator The iterator returned from a prior invocation
106
119
  # @option opts [Ordering] :order The sorting order of the returned items
107
120
  # @return [Array<(ListResponseBackgroundTaskOut, Integer, Hash)>] ListResponseBackgroundTaskOut data, response status code and response headers
108
- def list_background_tasks_with_http_info(opts = {})
121
+ def v1_background_task_list_with_http_info(opts = {})
109
122
  if @api_client.config.debugging
110
- @api_client.config.logger.debug 'Calling API: BackgroundTasksApi.list_background_tasks ...'
123
+ @api_client.config.logger.debug 'Calling API: BackgroundTasksApi.v1_background_task_list ...'
111
124
  end
112
125
  if @api_client.config.client_side_validation && !opts[:'limit'].nil? && opts[:'limit'] > 250
113
- fail ArgumentError, 'invalid value for "opts[:"limit"]" when calling BackgroundTasksApi.list_background_tasks, must be smaller than or equal to 250.'
126
+ fail ArgumentError, 'invalid value for "opts[:"limit"]" when calling BackgroundTasksApi.v1_background_task_list, must be smaller than or equal to 250.'
114
127
  end
115
128
 
116
129
  if @api_client.config.client_side_validation && !opts[:'limit'].nil? && opts[:'limit'] < 1
117
- fail ArgumentError, 'invalid value for "opts[:"limit"]" when calling BackgroundTasksApi.list_background_tasks, must be greater than or equal to 1.'
130
+ fail ArgumentError, 'invalid value for "opts[:"limit"]" when calling BackgroundTasksApi.v1_background_task_list, must be greater than or equal to 1.'
131
+ end
132
+
133
+ if @api_client.config.client_side_validation && !opts[:'iterator'].nil? && opts[:'iterator'].to_s.length > 33
134
+ fail ArgumentError, 'invalid value for "opts[:"iterator"]" when calling BackgroundTasksApi.v1_background_task_list, the character length must be smaller than or equal to 33.'
135
+ end
136
+
137
+ if @api_client.config.client_side_validation && !opts[:'iterator'].nil? && opts[:'iterator'].to_s.length < 33
138
+ fail ArgumentError, 'invalid value for "opts[:"iterator"]" when calling BackgroundTasksApi.v1_background_task_list, the character length must be great than or equal to 33.'
139
+ end
140
+
141
+ pattern = Regexp.new(/^qtask_[A-Za-z0-9]{27}$/)
142
+ if @api_client.config.client_side_validation && !opts[:'iterator'].nil? && opts[:'iterator'] !~ pattern
143
+ fail ArgumentError, "invalid value for 'opts[:\"iterator\"]' when calling BackgroundTasksApi.v1_background_task_list, must conform to the pattern #{pattern}."
118
144
  end
119
145
 
120
146
  # resource path
@@ -146,7 +172,7 @@ module Svix
146
172
  auth_names = opts[:debug_auth_names] || ['HTTPBearer']
147
173
 
148
174
  new_options = opts.merge(
149
- :operation => :"BackgroundTasksApi.list_background_tasks",
175
+ :operation => :"BackgroundTasksApi.v1_background_task_list",
150
176
  :header_params => header_params,
151
177
  :query_params => query_params,
152
178
  :form_params => form_params,
@@ -157,7 +183,7 @@ module Svix
157
183
 
158
184
  data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
159
185
  if @api_client.config.debugging
160
- @api_client.config.logger.debug "API called: BackgroundTasksApi#list_background_tasks\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
186
+ @api_client.config.logger.debug "API called: BackgroundTasksApi#v1_background_task_list\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
161
187
  end
162
188
  return data, status_code, headers
163
189
  end