svix 0.84.0 → 0.84.1
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/Gemfile.lock +1 -1
- data/lib/svix/api/application_api.rb +29 -25
- data/lib/svix/api/authentication_api.rb +13 -13
- data/lib/svix/api/background_tasks_api.rb +9 -5
- data/lib/svix/api/endpoint_api.rb +101 -97
- data/lib/svix/api/environment_api.rb +3 -3
- data/lib/svix/api/environment_settings_api.rb +2 -2
- data/lib/svix/api/event_type_api.rb +24 -20
- data/lib/svix/api/health_api.rb +1 -1
- data/lib/svix/api/integration_api.rb +40 -36
- data/lib/svix/api/message_api.rb +27 -23
- data/lib/svix/api/message_attempt_api.rb +117 -93
- data/lib/svix/api/statistics_api.rb +22 -22
- data/lib/svix/api_client.rb +2 -1
- data/lib/svix/api_error.rb +1 -1
- data/lib/svix/configuration.rb +9 -1
- data/lib/svix/models/app_portal_access_in.rb +1 -1
- data/lib/svix/models/app_portal_access_out.rb +1 -1
- data/lib/svix/models/{calculate_app_stats_in.rb → app_usage_stats_in.rb} +4 -4
- data/lib/svix/models/{background_task_out_common.rb → app_usage_stats_out.rb} +4 -4
- data/lib/svix/models/application_in.rb +1 -1
- data/lib/svix/models/application_out.rb +3 -1
- data/lib/svix/models/application_patch.rb +2 -1
- data/lib/svix/models/application_stats.rb +3 -1
- data/lib/svix/models/application_token_expire_in.rb +1 -1
- data/lib/svix/models/attempt_statistics_data.rb +1 -1
- data/lib/svix/models/attempt_statistics_response.rb +1 -1
- data/lib/svix/models/background_task_out.rb +1 -1
- data/lib/svix/models/background_task_status.rb +1 -1
- data/lib/svix/models/background_task_type.rb +1 -1
- data/lib/svix/models/border_radius_config.rb +1 -1
- data/lib/svix/models/border_radius_enum.rb +1 -1
- data/lib/svix/models/custom_color_palette.rb +1 -1
- data/lib/svix/models/custom_theme_override.rb +1 -1
- data/lib/svix/models/dashboard_access_out.rb +1 -1
- data/lib/svix/models/endpoint_created_event.rb +1 -1
- data/lib/svix/models/endpoint_created_event_data.rb +5 -1
- data/lib/svix/models/endpoint_deleted_event.rb +1 -1
- data/lib/svix/models/endpoint_deleted_event_data.rb +5 -1
- data/lib/svix/models/endpoint_disabled_event.rb +1 -1
- data/lib/svix/models/endpoint_disabled_event_data.rb +5 -1
- data/lib/svix/models/endpoint_headers_in.rb +1 -1
- data/lib/svix/models/endpoint_headers_out.rb +1 -1
- data/lib/svix/models/endpoint_headers_patch_in.rb +1 -1
- data/lib/svix/models/endpoint_in.rb +1 -1
- data/lib/svix/models/endpoint_message_out.rb +3 -1
- data/lib/svix/models/endpoint_out.rb +2 -1
- data/lib/svix/models/endpoint_patch.rb +2 -1
- data/lib/svix/models/endpoint_secret_out.rb +1 -1
- data/lib/svix/models/endpoint_secret_rotate_in.rb +1 -1
- data/lib/svix/models/endpoint_stats.rb +1 -1
- data/lib/svix/models/endpoint_transformation_in.rb +1 -1
- data/lib/svix/models/endpoint_transformation_out.rb +1 -1
- data/lib/svix/models/endpoint_transformation_simulate_in.rb +2 -1
- data/lib/svix/models/endpoint_transformation_simulate_out.rb +1 -1
- data/lib/svix/models/endpoint_update.rb +1 -1
- data/lib/svix/models/endpoint_updated_event.rb +1 -1
- data/lib/svix/models/endpoint_updated_event_data.rb +5 -1
- data/lib/svix/models/environment_in.rb +1 -1
- data/lib/svix/models/environment_out.rb +1 -1
- data/lib/svix/models/environment_settings_out.rb +1 -1
- data/lib/svix/models/event_example_in.rb +2 -1
- data/lib/svix/models/event_type_example_out.rb +1 -1
- data/lib/svix/models/event_type_in.rb +2 -1
- data/lib/svix/models/event_type_out.rb +2 -1
- data/lib/svix/models/event_type_patch.rb +1 -1
- data/lib/svix/models/event_type_schema_in.rb +1 -1
- data/lib/svix/models/event_type_update.rb +1 -1
- data/lib/svix/models/font_size_config.rb +1 -1
- data/lib/svix/models/http_error_out.rb +1 -1
- data/lib/svix/models/http_validation_error.rb +1 -1
- data/lib/svix/models/integration_in.rb +1 -1
- data/lib/svix/models/integration_key_out.rb +1 -1
- data/lib/svix/models/integration_out.rb +2 -1
- data/lib/svix/models/integration_update.rb +1 -1
- data/lib/svix/models/list_response_application_out.rb +1 -1
- data/lib/svix/models/list_response_application_stats.rb +1 -1
- data/lib/svix/models/list_response_background_task_out.rb +1 -1
- data/lib/svix/models/list_response_endpoint_message_out.rb +1 -1
- data/lib/svix/models/list_response_endpoint_out.rb +1 -1
- data/lib/svix/models/list_response_event_type_out.rb +1 -1
- data/lib/svix/models/list_response_integration_out.rb +1 -1
- data/lib/svix/models/list_response_message_attempt_endpoint_out.rb +1 -1
- data/lib/svix/models/list_response_message_attempt_out.rb +1 -1
- data/lib/svix/models/list_response_message_endpoint_out.rb +1 -1
- data/lib/svix/models/list_response_message_out.rb +1 -1
- data/lib/svix/models/message_attempt_endpoint_out.rb +4 -1
- data/lib/svix/models/message_attempt_exhausted_event.rb +1 -1
- data/lib/svix/models/message_attempt_exhausted_event_data.rb +6 -1
- data/lib/svix/models/message_attempt_failed_data.rb +2 -1
- data/lib/svix/models/message_attempt_failing_event.rb +1 -1
- data/lib/svix/models/message_attempt_failing_event_data.rb +6 -1
- data/lib/svix/models/message_attempt_headers_out.rb +1 -1
- data/lib/svix/models/message_attempt_out.rb +4 -1
- data/lib/svix/models/message_attempt_trigger_type.rb +1 -1
- data/lib/svix/models/message_endpoint_out.rb +2 -1
- data/lib/svix/models/message_in.rb +2 -1
- data/lib/svix/models/message_out.rb +3 -1
- data/lib/svix/models/message_status.rb +1 -1
- data/lib/svix/models/ordering.rb +1 -1
- data/lib/svix/models/recover_in.rb +1 -1
- data/lib/svix/models/recover_out.rb +1 -1
- data/lib/svix/models/replay_in.rb +1 -1
- data/lib/svix/models/replay_out.rb +1 -1
- data/lib/svix/models/settings_in.rb +1 -1
- data/lib/svix/models/settings_out.rb +1 -1
- data/lib/svix/models/statistics_period.rb +1 -1
- data/lib/svix/models/status_code_class.rb +1 -1
- data/lib/svix/models/transformation_http_method.rb +1 -1
- data/lib/svix/models/validation_error.rb +1 -1
- data/lib/svix/version.rb +1 -1
- metadata +4 -4
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 8eead298961cd2df35494446c3135b8ed242129eb4e7b19148392509aee5ece2
|
4
|
+
data.tar.gz: 7112abc7d05750ae9252a8b22416cf03b046f3e0f8fb35d75779118b1c29156f
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 11cd816097c5b0335e29c463c0c820fd232353d6491b68eeb3b7fe9c3536791c32c7b722741034a5b5c67e74d3cc9cb2ab5194fc327c54f59404cc73f86d5492
|
7
|
+
data.tar.gz: a47f0fd5275858c4a1c82767d73d7b6b4ee1f84abc9307bd6d2d0e65bf2fe9a94b812830ee1e7dff9df385109cbf50cbdb44f6a7be059f0ec01803a5c0b9a4ec
|
data/Gemfile.lock
CHANGED
@@ -3,7 +3,7 @@
|
|
3
3
|
|
4
4
|
#Welcome to the Svix API documentation! Useful links: [Homepage](https://www.svix.com) | [Support email](mailto:support+docs@svix.com) | [Blog](https://www.svix.com/blog/) | [Slack Community](https://www.svix.com/slack/) # Introduction This is the reference documentation and schemas for the [Svix webhook service](https://www.svix.com) API. For tutorials and other documentation please refer to [the documentation](https://docs.svix.com). ## Main concepts In Svix you have four important entities you will be interacting with: - `messages`: these are the webhooks being sent. They can have contents and a few other properties. - `application`: this is where `messages` are sent to. Usually you want to create one application for each user on your platform. - `endpoint`: endpoints are the URLs messages will be sent to. Each application can have multiple `endpoints` and each message sent to that application will be sent to all of them (unless they are not subscribed to the sent event type). - `event-type`: event types are identifiers denoting the type of the message being sent. Event types are primarily used to decide which events are sent to which endpoint. ## Authentication Get your authentication token (`AUTH_TOKEN`) from the [Svix dashboard](https://dashboard.svix.com) and use it as part of the `Authorization` header as such: `Authorization: Bearer ${AUTH_TOKEN}`. <SecurityDefinitions /> ## Code samples The code samples assume you already have the respective libraries installed and you know how to use them. For the latest information on how to do that, please refer to [the documentation](https://docs.svix.com/). ## Idempotency Svix supports [idempotency](https://en.wikipedia.org/wiki/Idempotence) for safely retrying requests without accidentally performing the same operation twice. This is useful when an API call is disrupted in transit and you do not receive a response. To perform an idempotent request, pass the idempotency key in the `Idempotency-Key` header to the request. The idempotency key should be a unique value generated by the client. You can create the key in however way you like, though we suggest using UUID v4, or any other string with enough entropy to avoid collisions. Svix's idempotency works by saving the resulting status code and body of the first request made for any given idempotency key for any successful request. Subsequent requests with the same key return the same result. Please note that idempotency is only supported for `POST` requests. ## Cross-Origin Resource Sharing This API features Cross-Origin Resource Sharing (CORS) implemented in compliance with [W3C spec](https://www.w3.org/TR/cors/). And that allows cross-domain communication from the browser. All responses have a wildcard same-origin which makes them completely public and accessible to everyone, including any code on any site.
|
5
5
|
|
6
|
-
The version of the OpenAPI document: 1.4
|
6
|
+
The version of the OpenAPI document: 1.4.1
|
7
7
|
|
8
8
|
Generated by: https://openapi-generator.tech
|
9
9
|
OpenAPI Generator version: 5.2.0
|
@@ -25,7 +25,7 @@ module Svix
|
|
25
25
|
# @param _until [Time]
|
26
26
|
# @param [Hash] opts the optional parameters
|
27
27
|
# @option opts [Integer] :limit (default to 50)
|
28
|
-
# @option opts [String] :iterator
|
28
|
+
# @option opts [String] :iterator The app's ID
|
29
29
|
# @return [ListResponseApplicationStats]
|
30
30
|
def get_app_usage_stats_api_v1_app_stats_usage_get(since, _until, opts = {})
|
31
31
|
data, _status_code, _headers = get_app_usage_stats_api_v1_app_stats_usage_get_with_http_info(since, _until, opts)
|
@@ -38,7 +38,7 @@ module Svix
|
|
38
38
|
# @param _until [Time]
|
39
39
|
# @param [Hash] opts the optional parameters
|
40
40
|
# @option opts [Integer] :limit
|
41
|
-
# @option opts [String] :iterator
|
41
|
+
# @option opts [String] :iterator The app's ID
|
42
42
|
# @return [Array<(ListResponseApplicationStats, Integer, Hash)>] ListResponseApplicationStats data, response status code and response headers
|
43
43
|
def get_app_usage_stats_api_v1_app_stats_usage_get_with_http_info(since, _until, opts = {})
|
44
44
|
if @api_client.config.debugging
|
@@ -81,7 +81,7 @@ module Svix
|
|
81
81
|
return_type = opts[:debug_return_type] || 'ListResponseApplicationStats'
|
82
82
|
|
83
83
|
# auth_names
|
84
|
-
auth_names = opts[:debug_auth_names] || []
|
84
|
+
auth_names = opts[:debug_auth_names] || ['HTTPBearer']
|
85
85
|
|
86
86
|
new_options = opts.merge(
|
87
87
|
:operation => :"ApplicationApi.get_app_usage_stats_api_v1_app_stats_usage_get",
|
@@ -102,7 +102,7 @@ module Svix
|
|
102
102
|
|
103
103
|
# Patch Application
|
104
104
|
# Partially update an application.
|
105
|
-
# @param app_id [String]
|
105
|
+
# @param app_id [String] The app's ID or UID
|
106
106
|
# @param application_patch [ApplicationPatch]
|
107
107
|
# @param [Hash] opts the optional parameters
|
108
108
|
# @return [ApplicationOut]
|
@@ -113,7 +113,7 @@ module Svix
|
|
113
113
|
|
114
114
|
# Patch Application
|
115
115
|
# Partially update an application.
|
116
|
-
# @param app_id [String]
|
116
|
+
# @param app_id [String] The app's ID or UID
|
117
117
|
# @param application_patch [ApplicationPatch]
|
118
118
|
# @param [Hash] opts the optional parameters
|
119
119
|
# @return [Array<(ApplicationOut, Integer, Hash)>] ApplicationOut data, response status code and response headers
|
@@ -165,7 +165,7 @@ module Svix
|
|
165
165
|
return_type = opts[:debug_return_type] || 'ApplicationOut'
|
166
166
|
|
167
167
|
# auth_names
|
168
|
-
auth_names = opts[:debug_auth_names] || []
|
168
|
+
auth_names = opts[:debug_auth_names] || ['HTTPBearer']
|
169
169
|
|
170
170
|
new_options = opts.merge(
|
171
171
|
:operation => :"ApplicationApi.patch_application",
|
@@ -236,7 +236,7 @@ module Svix
|
|
236
236
|
return_type = opts[:debug_return_type] || 'ApplicationOut'
|
237
237
|
|
238
238
|
# auth_names
|
239
|
-
auth_names = opts[:debug_auth_names] || []
|
239
|
+
auth_names = opts[:debug_auth_names] || ['HTTPBearer']
|
240
240
|
|
241
241
|
new_options = opts.merge(
|
242
242
|
:operation => :"ApplicationApi.v1_application_create",
|
@@ -257,7 +257,7 @@ module Svix
|
|
257
257
|
|
258
258
|
# Delete Application
|
259
259
|
# Delete an application.
|
260
|
-
# @param app_id [String]
|
260
|
+
# @param app_id [String] The app's ID or UID
|
261
261
|
# @param [Hash] opts the optional parameters
|
262
262
|
# @return [nil]
|
263
263
|
def v1_application_delete(app_id, opts = {})
|
@@ -267,7 +267,7 @@ module Svix
|
|
267
267
|
|
268
268
|
# Delete Application
|
269
269
|
# Delete an application.
|
270
|
-
# @param app_id [String]
|
270
|
+
# @param app_id [String] The app's ID or UID
|
271
271
|
# @param [Hash] opts the optional parameters
|
272
272
|
# @return [Array<(nil, Integer, Hash)>] nil, response status code and response headers
|
273
273
|
def v1_application_delete_with_http_info(app_id, opts = {})
|
@@ -312,7 +312,7 @@ module Svix
|
|
312
312
|
return_type = opts[:debug_return_type]
|
313
313
|
|
314
314
|
# auth_names
|
315
|
-
auth_names = opts[:debug_auth_names] || []
|
315
|
+
auth_names = opts[:debug_auth_names] || ['HTTPBearer']
|
316
316
|
|
317
317
|
new_options = opts.merge(
|
318
318
|
:operation => :"ApplicationApi.v1_application_delete",
|
@@ -333,7 +333,7 @@ module Svix
|
|
333
333
|
|
334
334
|
# Get Application
|
335
335
|
# Get an application.
|
336
|
-
# @param app_id [String]
|
336
|
+
# @param app_id [String] The app's ID or UID
|
337
337
|
# @param [Hash] opts the optional parameters
|
338
338
|
# @return [ApplicationOut]
|
339
339
|
def v1_application_get(app_id, opts = {})
|
@@ -343,7 +343,7 @@ module Svix
|
|
343
343
|
|
344
344
|
# Get Application
|
345
345
|
# Get an application.
|
346
|
-
# @param app_id [String]
|
346
|
+
# @param app_id [String] The app's ID or UID
|
347
347
|
# @param [Hash] opts the optional parameters
|
348
348
|
# @return [Array<(ApplicationOut, Integer, Hash)>] ApplicationOut data, response status code and response headers
|
349
349
|
def v1_application_get_with_http_info(app_id, opts = {})
|
@@ -388,7 +388,7 @@ module Svix
|
|
388
388
|
return_type = opts[:debug_return_type] || 'ApplicationOut'
|
389
389
|
|
390
390
|
# auth_names
|
391
|
-
auth_names = opts[:debug_auth_names] || []
|
391
|
+
auth_names = opts[:debug_auth_names] || ['HTTPBearer']
|
392
392
|
|
393
393
|
new_options = opts.merge(
|
394
394
|
:operation => :"ApplicationApi.v1_application_get",
|
@@ -411,7 +411,7 @@ module Svix
|
|
411
411
|
# Get basic statistics for the application
|
412
412
|
# @param since [Time]
|
413
413
|
# @param _until [Time]
|
414
|
-
# @param app_id [String]
|
414
|
+
# @param app_id [String] The app's ID or UID
|
415
415
|
# @param [Hash] opts the optional parameters
|
416
416
|
# @return [ApplicationStats]
|
417
417
|
def v1_application_get_stats(since, _until, app_id, opts = {})
|
@@ -423,7 +423,7 @@ module Svix
|
|
423
423
|
# Get basic statistics for the application
|
424
424
|
# @param since [Time]
|
425
425
|
# @param _until [Time]
|
426
|
-
# @param app_id [String]
|
426
|
+
# @param app_id [String] The app's ID or UID
|
427
427
|
# @param [Hash] opts the optional parameters
|
428
428
|
# @return [Array<(ApplicationStats, Integer, Hash)>] ApplicationStats data, response status code and response headers
|
429
429
|
def v1_application_get_stats_with_http_info(since, _until, app_id, opts = {})
|
@@ -478,7 +478,7 @@ module Svix
|
|
478
478
|
return_type = opts[:debug_return_type] || 'ApplicationStats'
|
479
479
|
|
480
480
|
# auth_names
|
481
|
-
auth_names = opts[:debug_auth_names] || []
|
481
|
+
auth_names = opts[:debug_auth_names] || ['HTTPBearer']
|
482
482
|
|
483
483
|
new_options = opts.merge(
|
484
484
|
:operation => :"ApplicationApi.v1_application_get_stats",
|
@@ -501,7 +501,7 @@ module Svix
|
|
501
501
|
# List of all the organization's applications.
|
502
502
|
# @param [Hash] opts the optional parameters
|
503
503
|
# @option opts [Integer] :limit
|
504
|
-
# @option opts [String] :iterator
|
504
|
+
# @option opts [String] :iterator The app's ID
|
505
505
|
# @option opts [Ordering] :order
|
506
506
|
# @return [ListResponseApplicationOut]
|
507
507
|
def v1_application_list(opts = {})
|
@@ -513,15 +513,19 @@ module Svix
|
|
513
513
|
# List of all the organization's applications.
|
514
514
|
# @param [Hash] opts the optional parameters
|
515
515
|
# @option opts [Integer] :limit
|
516
|
-
# @option opts [String] :iterator
|
516
|
+
# @option opts [String] :iterator The app's ID
|
517
517
|
# @option opts [Ordering] :order
|
518
518
|
# @return [Array<(ListResponseApplicationOut, Integer, Hash)>] ListResponseApplicationOut data, response status code and response headers
|
519
519
|
def v1_application_list_with_http_info(opts = {})
|
520
520
|
if @api_client.config.debugging
|
521
521
|
@api_client.config.logger.debug 'Calling API: ApplicationApi.v1_application_list ...'
|
522
522
|
end
|
523
|
-
if @api_client.config.client_side_validation && !opts[:'limit'].nil? && opts[:'limit']
|
524
|
-
fail ArgumentError, 'invalid value for "opts[:"limit"]" when calling ApplicationApi.v1_application_list, must be
|
523
|
+
if @api_client.config.client_side_validation && !opts[:'limit'].nil? && opts[:'limit'] > 250
|
524
|
+
fail ArgumentError, 'invalid value for "opts[:"limit"]" when calling ApplicationApi.v1_application_list, must be smaller than or equal to 250.'
|
525
|
+
end
|
526
|
+
|
527
|
+
if @api_client.config.client_side_validation && !opts[:'limit'].nil? && opts[:'limit'] < 1
|
528
|
+
fail ArgumentError, 'invalid value for "opts[:"limit"]" when calling ApplicationApi.v1_application_list, must be greater than or equal to 1.'
|
525
529
|
end
|
526
530
|
|
527
531
|
# resource path
|
@@ -548,7 +552,7 @@ module Svix
|
|
548
552
|
return_type = opts[:debug_return_type] || 'ListResponseApplicationOut'
|
549
553
|
|
550
554
|
# auth_names
|
551
|
-
auth_names = opts[:debug_auth_names] || []
|
555
|
+
auth_names = opts[:debug_auth_names] || ['HTTPBearer']
|
552
556
|
|
553
557
|
new_options = opts.merge(
|
554
558
|
:operation => :"ApplicationApi.v1_application_list",
|
@@ -569,7 +573,7 @@ module Svix
|
|
569
573
|
|
570
574
|
# Update Application
|
571
575
|
# Update an application.
|
572
|
-
# @param app_id [String]
|
576
|
+
# @param app_id [String] The app's ID or UID
|
573
577
|
# @param application_in [ApplicationIn]
|
574
578
|
# @param [Hash] opts the optional parameters
|
575
579
|
# @return [ApplicationOut]
|
@@ -580,7 +584,7 @@ module Svix
|
|
580
584
|
|
581
585
|
# Update Application
|
582
586
|
# Update an application.
|
583
|
-
# @param app_id [String]
|
587
|
+
# @param app_id [String] The app's ID or UID
|
584
588
|
# @param application_in [ApplicationIn]
|
585
589
|
# @param [Hash] opts the optional parameters
|
586
590
|
# @return [Array<(ApplicationOut, Integer, Hash)>] ApplicationOut data, response status code and response headers
|
@@ -632,7 +636,7 @@ module Svix
|
|
632
636
|
return_type = opts[:debug_return_type] || 'ApplicationOut'
|
633
637
|
|
634
638
|
# auth_names
|
635
|
-
auth_names = opts[:debug_auth_names] || []
|
639
|
+
auth_names = opts[:debug_auth_names] || ['HTTPBearer']
|
636
640
|
|
637
641
|
new_options = opts.merge(
|
638
642
|
:operation => :"ApplicationApi.v1_application_update",
|
@@ -3,7 +3,7 @@
|
|
3
3
|
|
4
4
|
#Welcome to the Svix API documentation! Useful links: [Homepage](https://www.svix.com) | [Support email](mailto:support+docs@svix.com) | [Blog](https://www.svix.com/blog/) | [Slack Community](https://www.svix.com/slack/) # Introduction This is the reference documentation and schemas for the [Svix webhook service](https://www.svix.com) API. For tutorials and other documentation please refer to [the documentation](https://docs.svix.com). ## Main concepts In Svix you have four important entities you will be interacting with: - `messages`: these are the webhooks being sent. They can have contents and a few other properties. - `application`: this is where `messages` are sent to. Usually you want to create one application for each user on your platform. - `endpoint`: endpoints are the URLs messages will be sent to. Each application can have multiple `endpoints` and each message sent to that application will be sent to all of them (unless they are not subscribed to the sent event type). - `event-type`: event types are identifiers denoting the type of the message being sent. Event types are primarily used to decide which events are sent to which endpoint. ## Authentication Get your authentication token (`AUTH_TOKEN`) from the [Svix dashboard](https://dashboard.svix.com) and use it as part of the `Authorization` header as such: `Authorization: Bearer ${AUTH_TOKEN}`. <SecurityDefinitions /> ## Code samples The code samples assume you already have the respective libraries installed and you know how to use them. For the latest information on how to do that, please refer to [the documentation](https://docs.svix.com/). ## Idempotency Svix supports [idempotency](https://en.wikipedia.org/wiki/Idempotence) for safely retrying requests without accidentally performing the same operation twice. This is useful when an API call is disrupted in transit and you do not receive a response. To perform an idempotent request, pass the idempotency key in the `Idempotency-Key` header to the request. The idempotency key should be a unique value generated by the client. You can create the key in however way you like, though we suggest using UUID v4, or any other string with enough entropy to avoid collisions. Svix's idempotency works by saving the resulting status code and body of the first request made for any given idempotency key for any successful request. Subsequent requests with the same key return the same result. Please note that idempotency is only supported for `POST` requests. ## Cross-Origin Resource Sharing This API features Cross-Origin Resource Sharing (CORS) implemented in compliance with [W3C spec](https://www.w3.org/TR/cors/). And that allows cross-domain communication from the browser. All responses have a wildcard same-origin which makes them completely public and accessible to everyone, including any code on any site.
|
5
5
|
|
6
|
-
The version of the OpenAPI document: 1.4
|
6
|
+
The version of the OpenAPI document: 1.4.1
|
7
7
|
|
8
8
|
Generated by: https://openapi-generator.tech
|
9
9
|
OpenAPI Generator version: 5.2.0
|
@@ -19,9 +19,9 @@ module Svix
|
|
19
19
|
def initialize(api_client = ApiClient.default)
|
20
20
|
@api_client = api_client
|
21
21
|
end
|
22
|
-
# App Portal Access
|
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]
|
24
|
+
# @param app_id [String] The app'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's idempotency key
|
@@ -31,9 +31,9 @@ module Svix
|
|
31
31
|
data
|
32
32
|
end
|
33
33
|
|
34
|
-
# App Portal Access
|
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]
|
36
|
+
# @param app_id [String] The app'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's idempotency key
|
@@ -87,7 +87,7 @@ module Svix
|
|
87
87
|
return_type = opts[:debug_return_type] || 'AppPortalAccessOut'
|
88
88
|
|
89
89
|
# auth_names
|
90
|
-
auth_names = opts[:debug_auth_names] || []
|
90
|
+
auth_names = opts[:debug_auth_names] || ['HTTPBearer']
|
91
91
|
|
92
92
|
new_options = opts.merge(
|
93
93
|
:operation => :"AuthenticationApi.v1_authentication_app_portal_access",
|
@@ -108,7 +108,7 @@ module Svix
|
|
108
108
|
|
109
109
|
# Dashboard Access
|
110
110
|
# 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.
|
111
|
-
# @param app_id [String]
|
111
|
+
# @param app_id [String] The app's ID or UID
|
112
112
|
# @param [Hash] opts the optional parameters
|
113
113
|
# @option opts [String] :idempotency_key The request's idempotency key
|
114
114
|
# @return [DashboardAccessOut]
|
@@ -119,7 +119,7 @@ module Svix
|
|
119
119
|
|
120
120
|
# Dashboard Access
|
121
121
|
# 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.
|
122
|
-
# @param app_id [String]
|
122
|
+
# @param app_id [String] The app's ID or UID
|
123
123
|
# @param [Hash] opts the optional parameters
|
124
124
|
# @option opts [String] :idempotency_key The request's idempotency key
|
125
125
|
# @return [Array<(DashboardAccessOut, Integer, Hash)>] DashboardAccessOut data, response status code and response headers
|
@@ -166,7 +166,7 @@ module Svix
|
|
166
166
|
return_type = opts[:debug_return_type] || 'DashboardAccessOut'
|
167
167
|
|
168
168
|
# auth_names
|
169
|
-
auth_names = opts[:debug_auth_names] || []
|
169
|
+
auth_names = opts[:debug_auth_names] || ['HTTPBearer']
|
170
170
|
|
171
171
|
new_options = opts.merge(
|
172
172
|
:operation => :"AuthenticationApi.v1_authentication_dashboard_access",
|
@@ -187,7 +187,7 @@ module Svix
|
|
187
187
|
|
188
188
|
# Expire All
|
189
189
|
# Expire all of the tokens associated with a specific Application
|
190
|
-
# @param app_id [String]
|
190
|
+
# @param app_id [String] The app's ID or UID
|
191
191
|
# @param application_token_expire_in [ApplicationTokenExpireIn]
|
192
192
|
# @param [Hash] opts the optional parameters
|
193
193
|
# @option opts [String] :idempotency_key The request's idempotency key
|
@@ -199,7 +199,7 @@ module Svix
|
|
199
199
|
|
200
200
|
# Expire All
|
201
201
|
# Expire all of the tokens associated with a specific Application
|
202
|
-
# @param app_id [String]
|
202
|
+
# @param app_id [String] The app's ID or UID
|
203
203
|
# @param application_token_expire_in [ApplicationTokenExpireIn]
|
204
204
|
# @param [Hash] opts the optional parameters
|
205
205
|
# @option opts [String] :idempotency_key The request's idempotency key
|
@@ -253,7 +253,7 @@ module Svix
|
|
253
253
|
return_type = opts[:debug_return_type]
|
254
254
|
|
255
255
|
# auth_names
|
256
|
-
auth_names = opts[:debug_auth_names] || []
|
256
|
+
auth_names = opts[:debug_auth_names] || ['HTTPBearer']
|
257
257
|
|
258
258
|
new_options = opts.merge(
|
259
259
|
:operation => :"AuthenticationApi.v1_authentication_expire_all",
|
@@ -313,7 +313,7 @@ module Svix
|
|
313
313
|
return_type = opts[:debug_return_type]
|
314
314
|
|
315
315
|
# auth_names
|
316
|
-
auth_names = opts[:debug_auth_names] || []
|
316
|
+
auth_names = opts[:debug_auth_names] || ['HTTPBearer']
|
317
317
|
|
318
318
|
new_options = opts.merge(
|
319
319
|
:operation => :"AuthenticationApi.v1_authentication_logout",
|
@@ -3,7 +3,7 @@
|
|
3
3
|
|
4
4
|
#Welcome to the Svix API documentation! Useful links: [Homepage](https://www.svix.com) | [Support email](mailto:support+docs@svix.com) | [Blog](https://www.svix.com/blog/) | [Slack Community](https://www.svix.com/slack/) # Introduction This is the reference documentation and schemas for the [Svix webhook service](https://www.svix.com) API. For tutorials and other documentation please refer to [the documentation](https://docs.svix.com). ## Main concepts In Svix you have four important entities you will be interacting with: - `messages`: these are the webhooks being sent. They can have contents and a few other properties. - `application`: this is where `messages` are sent to. Usually you want to create one application for each user on your platform. - `endpoint`: endpoints are the URLs messages will be sent to. Each application can have multiple `endpoints` and each message sent to that application will be sent to all of them (unless they are not subscribed to the sent event type). - `event-type`: event types are identifiers denoting the type of the message being sent. Event types are primarily used to decide which events are sent to which endpoint. ## Authentication Get your authentication token (`AUTH_TOKEN`) from the [Svix dashboard](https://dashboard.svix.com) and use it as part of the `Authorization` header as such: `Authorization: Bearer ${AUTH_TOKEN}`. <SecurityDefinitions /> ## Code samples The code samples assume you already have the respective libraries installed and you know how to use them. For the latest information on how to do that, please refer to [the documentation](https://docs.svix.com/). ## Idempotency Svix supports [idempotency](https://en.wikipedia.org/wiki/Idempotence) for safely retrying requests without accidentally performing the same operation twice. This is useful when an API call is disrupted in transit and you do not receive a response. To perform an idempotent request, pass the idempotency key in the `Idempotency-Key` header to the request. The idempotency key should be a unique value generated by the client. You can create the key in however way you like, though we suggest using UUID v4, or any other string with enough entropy to avoid collisions. Svix's idempotency works by saving the resulting status code and body of the first request made for any given idempotency key for any successful request. Subsequent requests with the same key return the same result. Please note that idempotency is only supported for `POST` requests. ## Cross-Origin Resource Sharing This API features Cross-Origin Resource Sharing (CORS) implemented in compliance with [W3C spec](https://www.w3.org/TR/cors/). And that allows cross-domain communication from the browser. All responses have a wildcard same-origin which makes them completely public and accessible to everyone, including any code on any site.
|
5
5
|
|
6
|
-
The version of the OpenAPI document: 1.4
|
6
|
+
The version of the OpenAPI document: 1.4.1
|
7
7
|
|
8
8
|
Generated by: https://openapi-generator.tech
|
9
9
|
OpenAPI Generator version: 5.2.0
|
@@ -63,7 +63,7 @@ module Svix
|
|
63
63
|
return_type = opts[:debug_return_type] || 'BackgroundTaskOut'
|
64
64
|
|
65
65
|
# auth_names
|
66
|
-
auth_names = opts[:debug_auth_names] || []
|
66
|
+
auth_names = opts[:debug_auth_names] || ['HTTPBearer']
|
67
67
|
|
68
68
|
new_options = opts.merge(
|
69
69
|
:operation => :"BackgroundTasksApi.get_background_task",
|
@@ -109,8 +109,12 @@ module Svix
|
|
109
109
|
if @api_client.config.debugging
|
110
110
|
@api_client.config.logger.debug 'Calling API: BackgroundTasksApi.list_background_tasks ...'
|
111
111
|
end
|
112
|
-
if @api_client.config.client_side_validation && !opts[:'limit'].nil? && opts[:'limit']
|
113
|
-
fail ArgumentError, 'invalid value for "opts[:"limit"]" when calling BackgroundTasksApi.list_background_tasks, must be
|
112
|
+
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.'
|
114
|
+
end
|
115
|
+
|
116
|
+
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.'
|
114
118
|
end
|
115
119
|
|
116
120
|
# resource path
|
@@ -139,7 +143,7 @@ module Svix
|
|
139
143
|
return_type = opts[:debug_return_type] || 'ListResponseBackgroundTaskOut'
|
140
144
|
|
141
145
|
# auth_names
|
142
|
-
auth_names = opts[:debug_auth_names] || []
|
146
|
+
auth_names = opts[:debug_auth_names] || ['HTTPBearer']
|
143
147
|
|
144
148
|
new_options = opts.merge(
|
145
149
|
:operation => :"BackgroundTasksApi.list_background_tasks",
|