svix 1.60.1 → 1.61.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 +4 -4
- data/Gemfile +5 -1
- data/Gemfile.lock +35 -21
- data/README.md +0 -7
- data/lib/svix/api/application.rb +96 -0
- data/lib/svix/api/authentication.rb +65 -0
- data/lib/svix/api/background_task.rb +39 -0
- data/lib/svix/api/endpoint.rb +202 -0
- data/lib/svix/api/environment.rb +39 -0
- data/lib/svix/api/event_type.rb +99 -0
- data/lib/svix/api/health.rb +21 -0
- data/lib/svix/api/integration.rb +91 -0
- data/lib/svix/api/message.rb +112 -0
- data/lib/svix/api/message_attempt.rb +123 -0
- data/lib/svix/api/operational_webhook_endpoint.rb +109 -0
- data/lib/svix/api/statistics.rb +36 -0
- data/lib/svix/api_error.rb +7 -17
- data/lib/svix/errors.rb +9 -9
- data/lib/svix/http_error_out.rb +18 -0
- data/lib/svix/http_validation_error.rb +18 -0
- data/lib/svix/internal.rb +0 -9
- data/lib/svix/models/aggregate_event_types_out.rb +32 -292
- data/lib/svix/models/app_portal_access_in.rb +31 -278
- data/lib/svix/models/app_portal_access_out.rb +27 -243
- data/lib/svix/models/app_usage_stats_in.rb +30 -234
- data/lib/svix/models/app_usage_stats_out.rb +31 -320
- data/lib/svix/models/application_in.rb +31 -298
- data/lib/svix/models/application_out.rb +37 -371
- data/lib/svix/models/application_patch.rb +31 -272
- data/lib/svix/models/application_token_expire_in.rb +28 -219
- data/lib/svix/models/background_task_out.rb +31 -307
- data/lib/svix/models/background_task_status.rb +14 -25
- data/lib/svix/models/background_task_type.rb +23 -26
- data/lib/svix/models/connector_in.rb +58 -385
- data/lib/svix/models/connector_kind.rb +28 -26
- data/lib/svix/models/dashboard_access_out.rb +27 -243
- data/lib/svix/models/endpoint_headers_in.rb +25 -202
- data/lib/svix/models/endpoint_headers_out.rb +30 -230
- data/lib/svix/models/endpoint_headers_patch_in.rb +28 -202
- data/lib/svix/models/endpoint_in.rb +61 -449
- data/lib/svix/models/endpoint_message_out.rb +48 -467
- data/lib/svix/models/endpoint_out.rb +67 -528
- data/lib/svix/models/endpoint_patch.rb +61 -383
- data/lib/svix/models/endpoint_secret_out.rb +25 -222
- data/lib/svix/models/endpoint_secret_rotate_in.rb +28 -212
- data/lib/svix/models/endpoint_stats.rb +31 -245
- data/lib/svix/models/endpoint_transformation_in.rb +30 -226
- data/lib/svix/models/endpoint_transformation_out.rb +30 -228
- data/lib/svix/models/endpoint_update.rb +58 -422
- data/lib/svix/models/environment_in.rb +31 -212
- data/lib/svix/models/environment_out.rb +35 -255
- data/lib/svix/models/event_example_in.rb +27 -261
- data/lib/svix/models/event_type_from_open_api.rb +35 -341
- data/lib/svix/models/event_type_import_open_api_in.rb +37 -228
- data/lib/svix/models/event_type_import_open_api_out.rb +28 -200
- data/lib/svix/models/event_type_import_open_api_out_data.rb +31 -211
- data/lib/svix/models/event_type_in.rb +37 -347
- data/lib/svix/models/event_type_out.rb +58 -389
- data/lib/svix/models/event_type_patch.rb +35 -289
- data/lib/svix/models/event_type_update.rb +35 -301
- data/lib/svix/models/expung_all_contents_out.rb +29 -292
- data/lib/svix/models/integration_in.rb +27 -239
- data/lib/svix/models/integration_key_out.rb +25 -200
- data/lib/svix/models/integration_out.rb +33 -324
- data/lib/svix/models/integration_update.rb +27 -239
- data/lib/svix/models/list_response_application_out.rb +34 -237
- data/lib/svix/models/list_response_background_task_out.rb +34 -237
- data/lib/svix/models/list_response_endpoint_message_out.rb +34 -237
- data/lib/svix/models/list_response_endpoint_out.rb +34 -237
- data/lib/svix/models/list_response_event_type_out.rb +34 -237
- data/lib/svix/models/list_response_integration_out.rb +34 -237
- data/lib/svix/models/list_response_message_attempt_out.rb +34 -237
- data/lib/svix/models/list_response_message_endpoint_out.rb +34 -237
- data/lib/svix/models/list_response_message_out.rb +34 -237
- data/lib/svix/models/list_response_operational_webhook_endpoint_out.rb +34 -237
- data/lib/svix/models/message_attempt_out.rb +64 -521
- data/lib/svix/models/message_attempt_trigger_type.rb +20 -28
- data/lib/svix/models/message_endpoint_out.rb +70 -557
- data/lib/svix/models/message_in.rb +58 -450
- data/lib/svix/models/message_out.rb +37 -414
- data/lib/svix/models/message_status.rb +24 -30
- data/lib/svix/models/operational_webhook_endpoint_headers_in.rb +28 -202
- data/lib/svix/models/operational_webhook_endpoint_headers_out.rb +30 -229
- data/lib/svix/models/operational_webhook_endpoint_in.rb +42 -380
- data/lib/svix/models/operational_webhook_endpoint_out.rb +64 -458
- data/lib/svix/models/operational_webhook_endpoint_secret_in.rb +28 -212
- data/lib/svix/models/operational_webhook_endpoint_secret_out.rb +28 -222
- data/lib/svix/models/operational_webhook_endpoint_update.rb +40 -353
- data/lib/svix/models/ordering.rb +15 -25
- data/lib/svix/models/recover_in.rb +28 -210
- data/lib/svix/models/recover_out.rb +29 -292
- data/lib/svix/models/replay_in.rb +28 -210
- data/lib/svix/models/replay_out.rb +29 -292
- data/lib/svix/models/status_code_class.rb +28 -32
- data/lib/svix/models/template_out.rb +70 -514
- data/lib/svix/svix.rb +50 -50
- data/lib/svix/svix_http_client.rb +110 -0
- data/lib/svix/util.rb +44 -25
- data/lib/svix/validation_error.rb +28 -0
- data/lib/svix/version.rb +1 -1
- data/lib/svix/webhook.rb +69 -65
- data/lib/svix.rb +51 -37
- data/svix.gemspec +1 -10
- metadata +22 -194
- data/lib/svix/api/application_api.rb +0 -772
- data/lib/svix/api/authentication_api.rb +0 -791
- data/lib/svix/api/background_tasks_api.rb +0 -191
- data/lib/svix/api/broadcast_api.rb +0 -93
- data/lib/svix/api/endpoint_api.rb +0 -2752
- data/lib/svix/api/environment_api.rb +0 -153
- data/lib/svix/api/environment_settings_api.rb +0 -79
- data/lib/svix/api/event_type_api.rb +0 -852
- data/lib/svix/api/events_api.rb +0 -102
- data/lib/svix/api/health_api.rb +0 -79
- data/lib/svix/api/inbound_api.rb +0 -209
- data/lib/svix/api/integration_api.rb +0 -707
- data/lib/svix/api/message_api.rb +0 -1192
- data/lib/svix/api/message_attempt_api.rb +0 -1245
- data/lib/svix/api/statistics_api.rb +0 -333
- data/lib/svix/api/stream_api.rb +0 -659
- data/lib/svix/api/stream_event_types_api.rb +0 -486
- data/lib/svix/api/transformation_template_api.rb +0 -967
- data/lib/svix/api/webhook_endpoint_api.rb +0 -748
- data/lib/svix/api_client.rb +0 -423
- data/lib/svix/application_api.rb +0 -35
- data/lib/svix/authentication_api.rb +0 -21
- data/lib/svix/background_tasks_api.rb +0 -17
- data/lib/svix/configuration.rb +0 -312
- data/lib/svix/endpoint_api.rb +0 -80
- data/lib/svix/event_type_api.rb +0 -37
- data/lib/svix/integration_api.rb +0 -38
- data/lib/svix/message_api.rb +0 -54
- data/lib/svix/message_attempt_api.rb +0 -51
- data/lib/svix/models/active_application_out.rb +0 -373
- data/lib/svix/models/active_endpoint_out.rb +0 -355
- data/lib/svix/models/aggregated_event_types.rb +0 -305
- data/lib/svix/models/application_message_failure.rb +0 -277
- data/lib/svix/models/application_message_id_pair.rb +0 -317
- data/lib/svix/models/application_stats.rb +0 -323
- data/lib/svix/models/application_stats_out.rb +0 -324
- data/lib/svix/models/attempt_statistics_data.rb +0 -229
- data/lib/svix/models/attempt_statistics_response.rb +0 -291
- data/lib/svix/models/auth_token_out.rb +0 -325
- data/lib/svix/models/azure_blob_storage_config.rb +0 -253
- data/lib/svix/models/background_task_finished_event.rb +0 -272
- data/lib/svix/models/background_task_finished_event2.rb +0 -331
- data/lib/svix/models/big_query_config.rb +0 -271
- data/lib/svix/models/border_radius_config.rb +0 -254
- data/lib/svix/models/border_radius_enum.rb +0 -43
- data/lib/svix/models/client_secret_jwt_params_in.rb +0 -297
- data/lib/svix/models/completion_choice.rb +0 -253
- data/lib/svix/models/completion_message.rb +0 -237
- data/lib/svix/models/count_out.rb +0 -258
- data/lib/svix/models/create_stream_in.rb +0 -232
- data/lib/svix/models/create_token_in.rb +0 -248
- data/lib/svix/models/custom_color_palette.rb +0 -295
- data/lib/svix/models/custom_strings_override.rb +0 -235
- data/lib/svix/models/custom_theme_override.rb +0 -223
- data/lib/svix/models/data.rb +0 -108
- data/lib/svix/models/data_any_of.rb +0 -240
- data/lib/svix/models/data_any_of1.rb +0 -223
- data/lib/svix/models/data_any_of2.rb +0 -241
- data/lib/svix/models/data_any_of3.rb +0 -223
- data/lib/svix/models/data_any_of4.rb +0 -240
- data/lib/svix/models/duration.rb +0 -275
- data/lib/svix/models/endpoint_created_event.rb +0 -272
- data/lib/svix/models/endpoint_created_event_data.rb +0 -410
- data/lib/svix/models/endpoint_deleted_event.rb +0 -272
- data/lib/svix/models/endpoint_deleted_event_data.rb +0 -410
- data/lib/svix/models/endpoint_disabled_event.rb +0 -272
- data/lib/svix/models/endpoint_disabled_event_data.rb +0 -451
- data/lib/svix/models/endpoint_disabled_trigger.rb +0 -40
- data/lib/svix/models/endpoint_enabled_event.rb +0 -272
- data/lib/svix/models/endpoint_enabled_event_data.rb +0 -410
- data/lib/svix/models/endpoint_mtls_config_in.rb +0 -233
- data/lib/svix/models/endpoint_mtls_config_out.rb +0 -215
- data/lib/svix/models/endpoint_oauth_config_in.rb +0 -350
- data/lib/svix/models/endpoint_oauth_config_out.rb +0 -315
- data/lib/svix/models/endpoint_transformation_simulate_in.rb +0 -330
- data/lib/svix/models/endpoint_transformation_simulate_out.rb +0 -296
- data/lib/svix/models/endpoint_updated_event.rb +0 -272
- data/lib/svix/models/endpoint_updated_event_data.rb +0 -410
- data/lib/svix/models/environment_settings_out.rb +0 -455
- data/lib/svix/models/event_in.rb +0 -258
- data/lib/svix/models/event_out.rb +0 -274
- data/lib/svix/models/event_stream_out.rb +0 -255
- data/lib/svix/models/event_type_example_out.rb +0 -221
- data/lib/svix/models/event_type_schema_in.rb +0 -221
- data/lib/svix/models/export_event_type_out.rb +0 -315
- data/lib/svix/models/font_size_config.rb +0 -230
- data/lib/svix/models/generate_in.rb +0 -221
- data/lib/svix/models/generate_out.rb +0 -287
- data/lib/svix/models/google_cloud_storage_config.rb +0 -239
- data/lib/svix/models/http_error_out.rb +0 -237
- data/lib/svix/models/http_validation_error.rb +0 -223
- data/lib/svix/models/hubspot_oauth_config_in.rb +0 -221
- data/lib/svix/models/inbound_path_params.rb +0 -277
- data/lib/svix/models/incoming_webhook_payload_out.rb +0 -235
- data/lib/svix/models/kafka_security_protocol_type.rb +0 -41
- data/lib/svix/models/list_response_active_application_out.rb +0 -261
- data/lib/svix/models/list_response_application_stats.rb +0 -261
- data/lib/svix/models/list_response_message_attempt_endpoint_out.rb +0 -261
- data/lib/svix/models/list_response_sink_out.rb +0 -261
- data/lib/svix/models/list_response_stream_event_type_out.rb +0 -261
- data/lib/svix/models/list_response_stream_out.rb +0 -261
- data/lib/svix/models/list_response_stream_sink_out.rb +0 -261
- data/lib/svix/models/list_response_template_out.rb +0 -261
- data/lib/svix/models/message_attempt_endpoint_out.rb +0 -545
- data/lib/svix/models/message_attempt_exhausted_event.rb +0 -272
- data/lib/svix/models/message_attempt_exhausted_event_data.rb +0 -482
- data/lib/svix/models/message_attempt_failed_data.rb +0 -293
- data/lib/svix/models/message_attempt_failing_event.rb +0 -272
- data/lib/svix/models/message_attempt_failing_event_data.rb +0 -482
- data/lib/svix/models/message_attempt_headers_out.rb +0 -263
- data/lib/svix/models/message_attempt_recovered_event.rb +0 -272
- data/lib/svix/models/message_attempt_recovered_event_data.rb +0 -482
- data/lib/svix/models/message_broadcast_in.rb +0 -423
- data/lib/svix/models/message_broadcast_out.rb +0 -315
- data/lib/svix/models/message_events_out.rb +0 -255
- data/lib/svix/models/message_precheck_in.rb +0 -288
- data/lib/svix/models/message_precheck_out.rb +0 -221
- data/lib/svix/models/message_raw_payload_out.rb +0 -221
- data/lib/svix/models/message_subscriber_auth_token_out.rb +0 -237
- data/lib/svix/models/o_auth_payload_in.rb +0 -237
- data/lib/svix/models/o_auth_payload_out.rb +0 -235
- data/lib/svix/models/oauth2_auth_method_in_out.rb +0 -41
- data/lib/svix/models/oauth2_grant_type_in_out.rb +0 -40
- data/lib/svix/models/oauth_jws_signing_algorithm.rb +0 -39
- data/lib/svix/models/one_time_token_in.rb +0 -221
- data/lib/svix/models/one_time_token_out.rb +0 -221
- data/lib/svix/models/polling_endpoint_message_out.rb +0 -454
- data/lib/svix/models/polling_endpoint_out.rb +0 -255
- data/lib/svix/models/redshift_config.rb +0 -317
- data/lib/svix/models/retry_schedule_in_out.rb +0 -216
- data/lib/svix/models/rotate_poller_token_in.rb +0 -280
- data/lib/svix/models/rotated_url_out.rb +0 -221
- data/lib/svix/models/s3_config.rb +0 -269
- data/lib/svix/models/sink_http_config.rb +0 -242
- data/lib/svix/models/sink_in.rb +0 -108
- data/lib/svix/models/sink_in_one_of.rb +0 -287
- data/lib/svix/models/sink_in_one_of1.rb +0 -319
- data/lib/svix/models/sink_in_one_of2.rb +0 -325
- data/lib/svix/models/sink_in_one_of3.rb +0 -271
- data/lib/svix/models/sink_in_one_of4.rb +0 -255
- data/lib/svix/models/sink_otel_v1_config.rb +0 -221
- data/lib/svix/models/sink_out.rb +0 -108
- data/lib/svix/models/sink_payload_format.rb +0 -39
- data/lib/svix/models/sink_secret_out.rb +0 -233
- data/lib/svix/models/sink_status.rb +0 -41
- data/lib/svix/models/sink_status_in.rb +0 -40
- data/lib/svix/models/sink_transform_in.rb +0 -248
- data/lib/svix/models/sink_transformation_out.rb +0 -226
- data/lib/svix/models/snowflake_config.rb +0 -287
- data/lib/svix/models/statistics_period.rb +0 -40
- data/lib/svix/models/stream_event_type_in.rb +0 -262
- data/lib/svix/models/stream_event_type_out.rb +0 -294
- data/lib/svix/models/stream_event_type_patch.rb +0 -254
- data/lib/svix/models/stream_in.rb +0 -287
- data/lib/svix/models/stream_out.rb +0 -350
- data/lib/svix/models/stream_patch.rb +0 -261
- data/lib/svix/models/stream_portal_access_in.rb +0 -293
- data/lib/svix/models/stream_sink_in.rb +0 -111
- data/lib/svix/models/stream_sink_in_one_of.rb +0 -271
- data/lib/svix/models/stream_sink_in_one_of1.rb +0 -271
- data/lib/svix/models/stream_sink_in_one_of2.rb +0 -271
- data/lib/svix/models/stream_sink_in_one_of3.rb +0 -271
- data/lib/svix/models/stream_sink_in_one_of4.rb +0 -271
- data/lib/svix/models/stream_sink_in_one_of5.rb +0 -271
- data/lib/svix/models/stream_sink_in_one_of6.rb +0 -271
- data/lib/svix/models/stream_sink_in_one_of7.rb +0 -271
- data/lib/svix/models/stream_sink_out.rb +0 -111
- data/lib/svix/models/stream_sink_patch.rb +0 -111
- data/lib/svix/models/template_patch.rb +0 -382
- data/lib/svix/models/template_update.rb +0 -402
- data/lib/svix/models/transformation_http_method.rb +0 -41
- data/lib/svix/models/transformation_simulate_in.rb +0 -330
- data/lib/svix/models/transformation_simulate_out.rb +0 -296
- data/lib/svix/models/validation_error.rb +0 -259
- data/lib/svix/statistics_api.rb +0 -17
@@ -1,707 +0,0 @@
|
|
1
|
-
=begin
|
2
|
-
#Svix API
|
3
|
-
|
4
|
-
#No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator)
|
5
|
-
|
6
|
-
The version of the OpenAPI document: 1.1.1
|
7
|
-
|
8
|
-
Generated by: https://openapi-generator.tech
|
9
|
-
Generator version: 7.9.0
|
10
|
-
|
11
|
-
=end
|
12
|
-
|
13
|
-
require 'cgi'
|
14
|
-
|
15
|
-
module Svix
|
16
|
-
class IntegrationApi
|
17
|
-
attr_accessor :api_client
|
18
|
-
|
19
|
-
def initialize(api_client = ApiClient.default)
|
20
|
-
@api_client = api_client
|
21
|
-
end
|
22
|
-
# Create Integration
|
23
|
-
# Create an integration.
|
24
|
-
# @param app_id [String] The Application's ID or UID.
|
25
|
-
# @param integration_in [IntegrationIn]
|
26
|
-
# @param [Hash] opts the optional parameters
|
27
|
-
# @option opts [String] :idempotency_key The request's idempotency key
|
28
|
-
# @return [IntegrationOut]
|
29
|
-
def v1_integration_create(app_id, integration_in, opts = {})
|
30
|
-
data, _status_code, _headers = v1_integration_create_with_http_info(app_id, integration_in, opts)
|
31
|
-
data
|
32
|
-
end
|
33
|
-
|
34
|
-
# Create Integration
|
35
|
-
# Create an integration.
|
36
|
-
# @param app_id [String] The Application's ID or UID.
|
37
|
-
# @param integration_in [IntegrationIn]
|
38
|
-
# @param [Hash] opts the optional parameters
|
39
|
-
# @option opts [String] :idempotency_key The request's idempotency key
|
40
|
-
# @return [Array<(IntegrationOut, Integer, Hash)>] IntegrationOut data, response status code and response headers
|
41
|
-
def v1_integration_create_with_http_info(app_id, integration_in, opts = {})
|
42
|
-
if @api_client.config.debugging
|
43
|
-
@api_client.config.logger.debug 'Calling API: IntegrationApi.v1_integration_create ...'
|
44
|
-
end
|
45
|
-
# verify the required parameter 'app_id' is set
|
46
|
-
if @api_client.config.client_side_validation && app_id.nil?
|
47
|
-
fail ArgumentError, "Missing the required parameter 'app_id' when calling IntegrationApi.v1_integration_create"
|
48
|
-
end
|
49
|
-
if @api_client.config.client_side_validation && app_id.to_s.length > 256
|
50
|
-
fail ArgumentError, 'invalid value for "app_id" when calling IntegrationApi.v1_integration_create, the character length must be smaller than or equal to 256.'
|
51
|
-
end
|
52
|
-
|
53
|
-
if @api_client.config.client_side_validation && app_id.to_s.length < 1
|
54
|
-
fail ArgumentError, 'invalid value for "app_id" when calling IntegrationApi.v1_integration_create, the character length must be great than or equal to 1.'
|
55
|
-
end
|
56
|
-
|
57
|
-
pattern = Regexp.new(/^[a-zA-Z0-9\-_.]+$/)
|
58
|
-
if @api_client.config.client_side_validation && app_id !~ pattern
|
59
|
-
fail ArgumentError, "invalid value for 'app_id' when calling IntegrationApi.v1_integration_create, must conform to the pattern #{pattern}."
|
60
|
-
end
|
61
|
-
|
62
|
-
# verify the required parameter 'integration_in' is set
|
63
|
-
if @api_client.config.client_side_validation && integration_in.nil?
|
64
|
-
fail ArgumentError, "Missing the required parameter 'integration_in' when calling IntegrationApi.v1_integration_create"
|
65
|
-
end
|
66
|
-
# resource path
|
67
|
-
local_var_path = '/api/v1/app/{app_id}/integration'.sub('{' + 'app_id' + '}', CGI.escape(app_id.to_s))
|
68
|
-
|
69
|
-
# query parameters
|
70
|
-
query_params = opts[:query_params] || {}
|
71
|
-
|
72
|
-
# header parameters
|
73
|
-
header_params = opts[:header_params] || {}
|
74
|
-
# HTTP header 'Accept' (if needed)
|
75
|
-
header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']
|
76
|
-
# HTTP header 'Content-Type'
|
77
|
-
content_type = @api_client.select_header_content_type(['application/json'])
|
78
|
-
if !content_type.nil?
|
79
|
-
header_params['Content-Type'] = content_type
|
80
|
-
end
|
81
|
-
header_params[:'idempotency-key'] = opts[:'idempotency_key'] if !opts[:'idempotency_key'].nil?
|
82
|
-
|
83
|
-
# form parameters
|
84
|
-
form_params = opts[:form_params] || {}
|
85
|
-
|
86
|
-
# http body (model)
|
87
|
-
post_body = opts[:debug_body] || @api_client.object_to_http_body(integration_in)
|
88
|
-
|
89
|
-
# return_type
|
90
|
-
return_type = opts[:debug_return_type] || 'IntegrationOut'
|
91
|
-
|
92
|
-
# auth_names
|
93
|
-
auth_names = opts[:debug_auth_names] || ['HTTPBearer']
|
94
|
-
|
95
|
-
new_options = opts.merge(
|
96
|
-
:operation => :"IntegrationApi.v1_integration_create",
|
97
|
-
:header_params => header_params,
|
98
|
-
:query_params => query_params,
|
99
|
-
:form_params => form_params,
|
100
|
-
:body => post_body,
|
101
|
-
:auth_names => auth_names,
|
102
|
-
:return_type => return_type
|
103
|
-
)
|
104
|
-
|
105
|
-
data, status_code, headers = @api_client.call_api(:POST, local_var_path, new_options)
|
106
|
-
if @api_client.config.debugging
|
107
|
-
@api_client.config.logger.debug "API called: IntegrationApi#v1_integration_create\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
108
|
-
end
|
109
|
-
return data, status_code, headers
|
110
|
-
end
|
111
|
-
|
112
|
-
# Delete Integration
|
113
|
-
# Delete an integration.
|
114
|
-
# @param app_id [String] The Application's ID or UID.
|
115
|
-
# @param integ_id [String] The Integration's ID.
|
116
|
-
# @param [Hash] opts the optional parameters
|
117
|
-
# @return [nil]
|
118
|
-
def v1_integration_delete(app_id, integ_id, opts = {})
|
119
|
-
v1_integration_delete_with_http_info(app_id, integ_id, opts)
|
120
|
-
nil
|
121
|
-
end
|
122
|
-
|
123
|
-
# Delete Integration
|
124
|
-
# Delete an integration.
|
125
|
-
# @param app_id [String] The Application's ID or UID.
|
126
|
-
# @param integ_id [String] The Integration's ID.
|
127
|
-
# @param [Hash] opts the optional parameters
|
128
|
-
# @return [Array<(nil, Integer, Hash)>] nil, response status code and response headers
|
129
|
-
def v1_integration_delete_with_http_info(app_id, integ_id, opts = {})
|
130
|
-
if @api_client.config.debugging
|
131
|
-
@api_client.config.logger.debug 'Calling API: IntegrationApi.v1_integration_delete ...'
|
132
|
-
end
|
133
|
-
# verify the required parameter 'app_id' is set
|
134
|
-
if @api_client.config.client_side_validation && app_id.nil?
|
135
|
-
fail ArgumentError, "Missing the required parameter 'app_id' when calling IntegrationApi.v1_integration_delete"
|
136
|
-
end
|
137
|
-
if @api_client.config.client_side_validation && app_id.to_s.length > 256
|
138
|
-
fail ArgumentError, 'invalid value for "app_id" when calling IntegrationApi.v1_integration_delete, the character length must be smaller than or equal to 256.'
|
139
|
-
end
|
140
|
-
|
141
|
-
if @api_client.config.client_side_validation && app_id.to_s.length < 1
|
142
|
-
fail ArgumentError, 'invalid value for "app_id" when calling IntegrationApi.v1_integration_delete, the character length must be great than or equal to 1.'
|
143
|
-
end
|
144
|
-
|
145
|
-
pattern = Regexp.new(/^[a-zA-Z0-9\-_.]+$/)
|
146
|
-
if @api_client.config.client_side_validation && app_id !~ pattern
|
147
|
-
fail ArgumentError, "invalid value for 'app_id' when calling IntegrationApi.v1_integration_delete, must conform to the pattern #{pattern}."
|
148
|
-
end
|
149
|
-
|
150
|
-
# verify the required parameter 'integ_id' is set
|
151
|
-
if @api_client.config.client_side_validation && integ_id.nil?
|
152
|
-
fail ArgumentError, "Missing the required parameter 'integ_id' when calling IntegrationApi.v1_integration_delete"
|
153
|
-
end
|
154
|
-
if @api_client.config.client_side_validation && integ_id.to_s.length > 33
|
155
|
-
fail ArgumentError, 'invalid value for "integ_id" when calling IntegrationApi.v1_integration_delete, the character length must be smaller than or equal to 33.'
|
156
|
-
end
|
157
|
-
|
158
|
-
if @api_client.config.client_side_validation && integ_id.to_s.length < 33
|
159
|
-
fail ArgumentError, 'invalid value for "integ_id" when calling IntegrationApi.v1_integration_delete, the character length must be great than or equal to 33.'
|
160
|
-
end
|
161
|
-
|
162
|
-
pattern = Regexp.new(/^integ_[A-Za-z0-9]{27}$/)
|
163
|
-
if @api_client.config.client_side_validation && integ_id !~ pattern
|
164
|
-
fail ArgumentError, "invalid value for 'integ_id' when calling IntegrationApi.v1_integration_delete, must conform to the pattern #{pattern}."
|
165
|
-
end
|
166
|
-
|
167
|
-
# resource path
|
168
|
-
local_var_path = '/api/v1/app/{app_id}/integration/{integ_id}'.sub('{' + 'app_id' + '}', CGI.escape(app_id.to_s)).sub('{' + 'integ_id' + '}', CGI.escape(integ_id.to_s))
|
169
|
-
|
170
|
-
# query parameters
|
171
|
-
query_params = opts[:query_params] || {}
|
172
|
-
|
173
|
-
# header parameters
|
174
|
-
header_params = opts[:header_params] || {}
|
175
|
-
# HTTP header 'Accept' (if needed)
|
176
|
-
header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']
|
177
|
-
|
178
|
-
# form parameters
|
179
|
-
form_params = opts[:form_params] || {}
|
180
|
-
|
181
|
-
# http body (model)
|
182
|
-
post_body = opts[:debug_body]
|
183
|
-
|
184
|
-
# return_type
|
185
|
-
return_type = opts[:debug_return_type]
|
186
|
-
|
187
|
-
# auth_names
|
188
|
-
auth_names = opts[:debug_auth_names] || ['HTTPBearer']
|
189
|
-
|
190
|
-
new_options = opts.merge(
|
191
|
-
:operation => :"IntegrationApi.v1_integration_delete",
|
192
|
-
:header_params => header_params,
|
193
|
-
:query_params => query_params,
|
194
|
-
:form_params => form_params,
|
195
|
-
:body => post_body,
|
196
|
-
:auth_names => auth_names,
|
197
|
-
:return_type => return_type
|
198
|
-
)
|
199
|
-
|
200
|
-
data, status_code, headers = @api_client.call_api(:DELETE, local_var_path, new_options)
|
201
|
-
if @api_client.config.debugging
|
202
|
-
@api_client.config.logger.debug "API called: IntegrationApi#v1_integration_delete\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
203
|
-
end
|
204
|
-
return data, status_code, headers
|
205
|
-
end
|
206
|
-
|
207
|
-
# Get Integration
|
208
|
-
# Get an integration.
|
209
|
-
# @param app_id [String] The Application's ID or UID.
|
210
|
-
# @param integ_id [String] The Integration's ID.
|
211
|
-
# @param [Hash] opts the optional parameters
|
212
|
-
# @return [IntegrationOut]
|
213
|
-
def v1_integration_get(app_id, integ_id, opts = {})
|
214
|
-
data, _status_code, _headers = v1_integration_get_with_http_info(app_id, integ_id, opts)
|
215
|
-
data
|
216
|
-
end
|
217
|
-
|
218
|
-
# Get Integration
|
219
|
-
# Get an integration.
|
220
|
-
# @param app_id [String] The Application's ID or UID.
|
221
|
-
# @param integ_id [String] The Integration's ID.
|
222
|
-
# @param [Hash] opts the optional parameters
|
223
|
-
# @return [Array<(IntegrationOut, Integer, Hash)>] IntegrationOut data, response status code and response headers
|
224
|
-
def v1_integration_get_with_http_info(app_id, integ_id, opts = {})
|
225
|
-
if @api_client.config.debugging
|
226
|
-
@api_client.config.logger.debug 'Calling API: IntegrationApi.v1_integration_get ...'
|
227
|
-
end
|
228
|
-
# verify the required parameter 'app_id' is set
|
229
|
-
if @api_client.config.client_side_validation && app_id.nil?
|
230
|
-
fail ArgumentError, "Missing the required parameter 'app_id' when calling IntegrationApi.v1_integration_get"
|
231
|
-
end
|
232
|
-
if @api_client.config.client_side_validation && app_id.to_s.length > 256
|
233
|
-
fail ArgumentError, 'invalid value for "app_id" when calling IntegrationApi.v1_integration_get, the character length must be smaller than or equal to 256.'
|
234
|
-
end
|
235
|
-
|
236
|
-
if @api_client.config.client_side_validation && app_id.to_s.length < 1
|
237
|
-
fail ArgumentError, 'invalid value for "app_id" when calling IntegrationApi.v1_integration_get, the character length must be great than or equal to 1.'
|
238
|
-
end
|
239
|
-
|
240
|
-
pattern = Regexp.new(/^[a-zA-Z0-9\-_.]+$/)
|
241
|
-
if @api_client.config.client_side_validation && app_id !~ pattern
|
242
|
-
fail ArgumentError, "invalid value for 'app_id' when calling IntegrationApi.v1_integration_get, must conform to the pattern #{pattern}."
|
243
|
-
end
|
244
|
-
|
245
|
-
# verify the required parameter 'integ_id' is set
|
246
|
-
if @api_client.config.client_side_validation && integ_id.nil?
|
247
|
-
fail ArgumentError, "Missing the required parameter 'integ_id' when calling IntegrationApi.v1_integration_get"
|
248
|
-
end
|
249
|
-
if @api_client.config.client_side_validation && integ_id.to_s.length > 33
|
250
|
-
fail ArgumentError, 'invalid value for "integ_id" when calling IntegrationApi.v1_integration_get, the character length must be smaller than or equal to 33.'
|
251
|
-
end
|
252
|
-
|
253
|
-
if @api_client.config.client_side_validation && integ_id.to_s.length < 33
|
254
|
-
fail ArgumentError, 'invalid value for "integ_id" when calling IntegrationApi.v1_integration_get, the character length must be great than or equal to 33.'
|
255
|
-
end
|
256
|
-
|
257
|
-
pattern = Regexp.new(/^integ_[A-Za-z0-9]{27}$/)
|
258
|
-
if @api_client.config.client_side_validation && integ_id !~ pattern
|
259
|
-
fail ArgumentError, "invalid value for 'integ_id' when calling IntegrationApi.v1_integration_get, must conform to the pattern #{pattern}."
|
260
|
-
end
|
261
|
-
|
262
|
-
# resource path
|
263
|
-
local_var_path = '/api/v1/app/{app_id}/integration/{integ_id}'.sub('{' + 'app_id' + '}', CGI.escape(app_id.to_s)).sub('{' + 'integ_id' + '}', CGI.escape(integ_id.to_s))
|
264
|
-
|
265
|
-
# query parameters
|
266
|
-
query_params = opts[:query_params] || {}
|
267
|
-
|
268
|
-
# header parameters
|
269
|
-
header_params = opts[:header_params] || {}
|
270
|
-
# HTTP header 'Accept' (if needed)
|
271
|
-
header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']
|
272
|
-
|
273
|
-
# form parameters
|
274
|
-
form_params = opts[:form_params] || {}
|
275
|
-
|
276
|
-
# http body (model)
|
277
|
-
post_body = opts[:debug_body]
|
278
|
-
|
279
|
-
# return_type
|
280
|
-
return_type = opts[:debug_return_type] || 'IntegrationOut'
|
281
|
-
|
282
|
-
# auth_names
|
283
|
-
auth_names = opts[:debug_auth_names] || ['HTTPBearer']
|
284
|
-
|
285
|
-
new_options = opts.merge(
|
286
|
-
:operation => :"IntegrationApi.v1_integration_get",
|
287
|
-
:header_params => header_params,
|
288
|
-
:query_params => query_params,
|
289
|
-
:form_params => form_params,
|
290
|
-
:body => post_body,
|
291
|
-
:auth_names => auth_names,
|
292
|
-
:return_type => return_type
|
293
|
-
)
|
294
|
-
|
295
|
-
data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
|
296
|
-
if @api_client.config.debugging
|
297
|
-
@api_client.config.logger.debug "API called: IntegrationApi#v1_integration_get\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
298
|
-
end
|
299
|
-
return data, status_code, headers
|
300
|
-
end
|
301
|
-
|
302
|
-
# Get Integration Key
|
303
|
-
# Get an integration's key.
|
304
|
-
# @param app_id [String] The Application's ID or UID.
|
305
|
-
# @param integ_id [String] The Integration's ID.
|
306
|
-
# @param [Hash] opts the optional parameters
|
307
|
-
# @return [IntegrationKeyOut]
|
308
|
-
def v1_integration_get_key(app_id, integ_id, opts = {})
|
309
|
-
data, _status_code, _headers = v1_integration_get_key_with_http_info(app_id, integ_id, opts)
|
310
|
-
data
|
311
|
-
end
|
312
|
-
|
313
|
-
# Get Integration Key
|
314
|
-
# Get an integration's key.
|
315
|
-
# @param app_id [String] The Application's ID or UID.
|
316
|
-
# @param integ_id [String] The Integration's ID.
|
317
|
-
# @param [Hash] opts the optional parameters
|
318
|
-
# @return [Array<(IntegrationKeyOut, Integer, Hash)>] IntegrationKeyOut data, response status code and response headers
|
319
|
-
def v1_integration_get_key_with_http_info(app_id, integ_id, opts = {})
|
320
|
-
if @api_client.config.debugging
|
321
|
-
@api_client.config.logger.debug 'Calling API: IntegrationApi.v1_integration_get_key ...'
|
322
|
-
end
|
323
|
-
# verify the required parameter 'app_id' is set
|
324
|
-
if @api_client.config.client_side_validation && app_id.nil?
|
325
|
-
fail ArgumentError, "Missing the required parameter 'app_id' when calling IntegrationApi.v1_integration_get_key"
|
326
|
-
end
|
327
|
-
if @api_client.config.client_side_validation && app_id.to_s.length > 256
|
328
|
-
fail ArgumentError, 'invalid value for "app_id" when calling IntegrationApi.v1_integration_get_key, the character length must be smaller than or equal to 256.'
|
329
|
-
end
|
330
|
-
|
331
|
-
if @api_client.config.client_side_validation && app_id.to_s.length < 1
|
332
|
-
fail ArgumentError, 'invalid value for "app_id" when calling IntegrationApi.v1_integration_get_key, the character length must be great than or equal to 1.'
|
333
|
-
end
|
334
|
-
|
335
|
-
pattern = Regexp.new(/^[a-zA-Z0-9\-_.]+$/)
|
336
|
-
if @api_client.config.client_side_validation && app_id !~ pattern
|
337
|
-
fail ArgumentError, "invalid value for 'app_id' when calling IntegrationApi.v1_integration_get_key, must conform to the pattern #{pattern}."
|
338
|
-
end
|
339
|
-
|
340
|
-
# verify the required parameter 'integ_id' is set
|
341
|
-
if @api_client.config.client_side_validation && integ_id.nil?
|
342
|
-
fail ArgumentError, "Missing the required parameter 'integ_id' when calling IntegrationApi.v1_integration_get_key"
|
343
|
-
end
|
344
|
-
if @api_client.config.client_side_validation && integ_id.to_s.length > 33
|
345
|
-
fail ArgumentError, 'invalid value for "integ_id" when calling IntegrationApi.v1_integration_get_key, the character length must be smaller than or equal to 33.'
|
346
|
-
end
|
347
|
-
|
348
|
-
if @api_client.config.client_side_validation && integ_id.to_s.length < 33
|
349
|
-
fail ArgumentError, 'invalid value for "integ_id" when calling IntegrationApi.v1_integration_get_key, the character length must be great than or equal to 33.'
|
350
|
-
end
|
351
|
-
|
352
|
-
pattern = Regexp.new(/^integ_[A-Za-z0-9]{27}$/)
|
353
|
-
if @api_client.config.client_side_validation && integ_id !~ pattern
|
354
|
-
fail ArgumentError, "invalid value for 'integ_id' when calling IntegrationApi.v1_integration_get_key, must conform to the pattern #{pattern}."
|
355
|
-
end
|
356
|
-
|
357
|
-
# resource path
|
358
|
-
local_var_path = '/api/v1/app/{app_id}/integration/{integ_id}/key'.sub('{' + 'app_id' + '}', CGI.escape(app_id.to_s)).sub('{' + 'integ_id' + '}', CGI.escape(integ_id.to_s))
|
359
|
-
|
360
|
-
# query parameters
|
361
|
-
query_params = opts[:query_params] || {}
|
362
|
-
|
363
|
-
# header parameters
|
364
|
-
header_params = opts[:header_params] || {}
|
365
|
-
# HTTP header 'Accept' (if needed)
|
366
|
-
header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']
|
367
|
-
|
368
|
-
# form parameters
|
369
|
-
form_params = opts[:form_params] || {}
|
370
|
-
|
371
|
-
# http body (model)
|
372
|
-
post_body = opts[:debug_body]
|
373
|
-
|
374
|
-
# return_type
|
375
|
-
return_type = opts[:debug_return_type] || 'IntegrationKeyOut'
|
376
|
-
|
377
|
-
# auth_names
|
378
|
-
auth_names = opts[:debug_auth_names] || ['HTTPBearer']
|
379
|
-
|
380
|
-
new_options = opts.merge(
|
381
|
-
:operation => :"IntegrationApi.v1_integration_get_key",
|
382
|
-
:header_params => header_params,
|
383
|
-
:query_params => query_params,
|
384
|
-
:form_params => form_params,
|
385
|
-
:body => post_body,
|
386
|
-
:auth_names => auth_names,
|
387
|
-
:return_type => return_type
|
388
|
-
)
|
389
|
-
|
390
|
-
data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
|
391
|
-
if @api_client.config.debugging
|
392
|
-
@api_client.config.logger.debug "API called: IntegrationApi#v1_integration_get_key\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
393
|
-
end
|
394
|
-
return data, status_code, headers
|
395
|
-
end
|
396
|
-
|
397
|
-
# List Integrations
|
398
|
-
# List the application's integrations.
|
399
|
-
# @param app_id [String] The Application's ID or UID.
|
400
|
-
# @param [Hash] opts the optional parameters
|
401
|
-
# @option opts [Integer] :limit Limit the number of returned items
|
402
|
-
# @option opts [String] :iterator The iterator returned from a prior invocation
|
403
|
-
# @option opts [Ordering] :order The sorting order of the returned items
|
404
|
-
# @return [ListResponseIntegrationOut]
|
405
|
-
def v1_integration_list(app_id, opts = {})
|
406
|
-
data, _status_code, _headers = v1_integration_list_with_http_info(app_id, opts)
|
407
|
-
data
|
408
|
-
end
|
409
|
-
|
410
|
-
# List Integrations
|
411
|
-
# List the application's integrations.
|
412
|
-
# @param app_id [String] The Application's ID or UID.
|
413
|
-
# @param [Hash] opts the optional parameters
|
414
|
-
# @option opts [Integer] :limit Limit the number of returned items
|
415
|
-
# @option opts [String] :iterator The iterator returned from a prior invocation
|
416
|
-
# @option opts [Ordering] :order The sorting order of the returned items
|
417
|
-
# @return [Array<(ListResponseIntegrationOut, Integer, Hash)>] ListResponseIntegrationOut data, response status code and response headers
|
418
|
-
def v1_integration_list_with_http_info(app_id, opts = {})
|
419
|
-
if @api_client.config.debugging
|
420
|
-
@api_client.config.logger.debug 'Calling API: IntegrationApi.v1_integration_list ...'
|
421
|
-
end
|
422
|
-
# verify the required parameter 'app_id' is set
|
423
|
-
if @api_client.config.client_side_validation && app_id.nil?
|
424
|
-
fail ArgumentError, "Missing the required parameter 'app_id' when calling IntegrationApi.v1_integration_list"
|
425
|
-
end
|
426
|
-
if @api_client.config.client_side_validation && app_id.to_s.length > 256
|
427
|
-
fail ArgumentError, 'invalid value for "app_id" when calling IntegrationApi.v1_integration_list, the character length must be smaller than or equal to 256.'
|
428
|
-
end
|
429
|
-
|
430
|
-
if @api_client.config.client_side_validation && app_id.to_s.length < 1
|
431
|
-
fail ArgumentError, 'invalid value for "app_id" when calling IntegrationApi.v1_integration_list, the character length must be great than or equal to 1.'
|
432
|
-
end
|
433
|
-
|
434
|
-
pattern = Regexp.new(/^[a-zA-Z0-9\-_.]+$/)
|
435
|
-
if @api_client.config.client_side_validation && app_id !~ pattern
|
436
|
-
fail ArgumentError, "invalid value for 'app_id' when calling IntegrationApi.v1_integration_list, must conform to the pattern #{pattern}."
|
437
|
-
end
|
438
|
-
|
439
|
-
if @api_client.config.client_side_validation && !opts[:'limit'].nil? && opts[:'limit'] > 250
|
440
|
-
fail ArgumentError, 'invalid value for "opts[:"limit"]" when calling IntegrationApi.v1_integration_list, must be smaller than or equal to 250.'
|
441
|
-
end
|
442
|
-
|
443
|
-
if @api_client.config.client_side_validation && !opts[:'limit'].nil? && opts[:'limit'] < 1
|
444
|
-
fail ArgumentError, 'invalid value for "opts[:"limit"]" when calling IntegrationApi.v1_integration_list, must be greater than or equal to 1.'
|
445
|
-
end
|
446
|
-
|
447
|
-
if @api_client.config.client_side_validation && !opts[:'iterator'].nil? && opts[:'iterator'].to_s.length > 33
|
448
|
-
fail ArgumentError, 'invalid value for "opts[:"iterator"]" when calling IntegrationApi.v1_integration_list, the character length must be smaller than or equal to 33.'
|
449
|
-
end
|
450
|
-
|
451
|
-
if @api_client.config.client_side_validation && !opts[:'iterator'].nil? && opts[:'iterator'].to_s.length < 33
|
452
|
-
fail ArgumentError, 'invalid value for "opts[:"iterator"]" when calling IntegrationApi.v1_integration_list, the character length must be great than or equal to 33.'
|
453
|
-
end
|
454
|
-
|
455
|
-
pattern = Regexp.new(/^integ_[A-Za-z0-9]{27}$/)
|
456
|
-
if @api_client.config.client_side_validation && !opts[:'iterator'].nil? && opts[:'iterator'] !~ pattern
|
457
|
-
fail ArgumentError, "invalid value for 'opts[:\"iterator\"]' when calling IntegrationApi.v1_integration_list, must conform to the pattern #{pattern}."
|
458
|
-
end
|
459
|
-
|
460
|
-
# resource path
|
461
|
-
local_var_path = '/api/v1/app/{app_id}/integration'.sub('{' + 'app_id' + '}', CGI.escape(app_id.to_s))
|
462
|
-
|
463
|
-
# query parameters
|
464
|
-
query_params = opts[:query_params] || {}
|
465
|
-
query_params[:'limit'] = opts[:'limit'] if !opts[:'limit'].nil?
|
466
|
-
query_params[:'iterator'] = opts[:'iterator'] if !opts[:'iterator'].nil?
|
467
|
-
query_params[:'order'] = opts[:'order'] if !opts[:'order'].nil?
|
468
|
-
|
469
|
-
# header parameters
|
470
|
-
header_params = opts[:header_params] || {}
|
471
|
-
# HTTP header 'Accept' (if needed)
|
472
|
-
header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']
|
473
|
-
|
474
|
-
# form parameters
|
475
|
-
form_params = opts[:form_params] || {}
|
476
|
-
|
477
|
-
# http body (model)
|
478
|
-
post_body = opts[:debug_body]
|
479
|
-
|
480
|
-
# return_type
|
481
|
-
return_type = opts[:debug_return_type] || 'ListResponseIntegrationOut'
|
482
|
-
|
483
|
-
# auth_names
|
484
|
-
auth_names = opts[:debug_auth_names] || ['HTTPBearer']
|
485
|
-
|
486
|
-
new_options = opts.merge(
|
487
|
-
:operation => :"IntegrationApi.v1_integration_list",
|
488
|
-
:header_params => header_params,
|
489
|
-
:query_params => query_params,
|
490
|
-
:form_params => form_params,
|
491
|
-
:body => post_body,
|
492
|
-
:auth_names => auth_names,
|
493
|
-
:return_type => return_type
|
494
|
-
)
|
495
|
-
|
496
|
-
data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
|
497
|
-
if @api_client.config.debugging
|
498
|
-
@api_client.config.logger.debug "API called: IntegrationApi#v1_integration_list\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
499
|
-
end
|
500
|
-
return data, status_code, headers
|
501
|
-
end
|
502
|
-
|
503
|
-
# Rotate Integration Key
|
504
|
-
# Rotate the integration's key. The previous key will be immediately revoked.
|
505
|
-
# @param app_id [String] The Application's ID or UID.
|
506
|
-
# @param integ_id [String] The Integration's ID.
|
507
|
-
# @param [Hash] opts the optional parameters
|
508
|
-
# @option opts [String] :idempotency_key The request's idempotency key
|
509
|
-
# @return [IntegrationKeyOut]
|
510
|
-
def v1_integration_rotate_key(app_id, integ_id, opts = {})
|
511
|
-
data, _status_code, _headers = v1_integration_rotate_key_with_http_info(app_id, integ_id, opts)
|
512
|
-
data
|
513
|
-
end
|
514
|
-
|
515
|
-
# Rotate Integration Key
|
516
|
-
# Rotate the integration's key. The previous key will be immediately revoked.
|
517
|
-
# @param app_id [String] The Application's ID or UID.
|
518
|
-
# @param integ_id [String] The Integration's ID.
|
519
|
-
# @param [Hash] opts the optional parameters
|
520
|
-
# @option opts [String] :idempotency_key The request's idempotency key
|
521
|
-
# @return [Array<(IntegrationKeyOut, Integer, Hash)>] IntegrationKeyOut data, response status code and response headers
|
522
|
-
def v1_integration_rotate_key_with_http_info(app_id, integ_id, opts = {})
|
523
|
-
if @api_client.config.debugging
|
524
|
-
@api_client.config.logger.debug 'Calling API: IntegrationApi.v1_integration_rotate_key ...'
|
525
|
-
end
|
526
|
-
# verify the required parameter 'app_id' is set
|
527
|
-
if @api_client.config.client_side_validation && app_id.nil?
|
528
|
-
fail ArgumentError, "Missing the required parameter 'app_id' when calling IntegrationApi.v1_integration_rotate_key"
|
529
|
-
end
|
530
|
-
if @api_client.config.client_side_validation && app_id.to_s.length > 256
|
531
|
-
fail ArgumentError, 'invalid value for "app_id" when calling IntegrationApi.v1_integration_rotate_key, the character length must be smaller than or equal to 256.'
|
532
|
-
end
|
533
|
-
|
534
|
-
if @api_client.config.client_side_validation && app_id.to_s.length < 1
|
535
|
-
fail ArgumentError, 'invalid value for "app_id" when calling IntegrationApi.v1_integration_rotate_key, the character length must be great than or equal to 1.'
|
536
|
-
end
|
537
|
-
|
538
|
-
pattern = Regexp.new(/^[a-zA-Z0-9\-_.]+$/)
|
539
|
-
if @api_client.config.client_side_validation && app_id !~ pattern
|
540
|
-
fail ArgumentError, "invalid value for 'app_id' when calling IntegrationApi.v1_integration_rotate_key, must conform to the pattern #{pattern}."
|
541
|
-
end
|
542
|
-
|
543
|
-
# verify the required parameter 'integ_id' is set
|
544
|
-
if @api_client.config.client_side_validation && integ_id.nil?
|
545
|
-
fail ArgumentError, "Missing the required parameter 'integ_id' when calling IntegrationApi.v1_integration_rotate_key"
|
546
|
-
end
|
547
|
-
if @api_client.config.client_side_validation && integ_id.to_s.length > 33
|
548
|
-
fail ArgumentError, 'invalid value for "integ_id" when calling IntegrationApi.v1_integration_rotate_key, the character length must be smaller than or equal to 33.'
|
549
|
-
end
|
550
|
-
|
551
|
-
if @api_client.config.client_side_validation && integ_id.to_s.length < 33
|
552
|
-
fail ArgumentError, 'invalid value for "integ_id" when calling IntegrationApi.v1_integration_rotate_key, the character length must be great than or equal to 33.'
|
553
|
-
end
|
554
|
-
|
555
|
-
pattern = Regexp.new(/^integ_[A-Za-z0-9]{27}$/)
|
556
|
-
if @api_client.config.client_side_validation && integ_id !~ pattern
|
557
|
-
fail ArgumentError, "invalid value for 'integ_id' when calling IntegrationApi.v1_integration_rotate_key, must conform to the pattern #{pattern}."
|
558
|
-
end
|
559
|
-
|
560
|
-
# resource path
|
561
|
-
local_var_path = '/api/v1/app/{app_id}/integration/{integ_id}/key/rotate'.sub('{' + 'app_id' + '}', CGI.escape(app_id.to_s)).sub('{' + 'integ_id' + '}', CGI.escape(integ_id.to_s))
|
562
|
-
|
563
|
-
# query parameters
|
564
|
-
query_params = opts[:query_params] || {}
|
565
|
-
|
566
|
-
# header parameters
|
567
|
-
header_params = opts[:header_params] || {}
|
568
|
-
# HTTP header 'Accept' (if needed)
|
569
|
-
header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']
|
570
|
-
header_params[:'idempotency-key'] = opts[:'idempotency_key'] if !opts[:'idempotency_key'].nil?
|
571
|
-
|
572
|
-
# form parameters
|
573
|
-
form_params = opts[:form_params] || {}
|
574
|
-
|
575
|
-
# http body (model)
|
576
|
-
post_body = opts[:debug_body]
|
577
|
-
|
578
|
-
# return_type
|
579
|
-
return_type = opts[:debug_return_type] || 'IntegrationKeyOut'
|
580
|
-
|
581
|
-
# auth_names
|
582
|
-
auth_names = opts[:debug_auth_names] || ['HTTPBearer']
|
583
|
-
|
584
|
-
new_options = opts.merge(
|
585
|
-
:operation => :"IntegrationApi.v1_integration_rotate_key",
|
586
|
-
:header_params => header_params,
|
587
|
-
:query_params => query_params,
|
588
|
-
:form_params => form_params,
|
589
|
-
:body => post_body,
|
590
|
-
:auth_names => auth_names,
|
591
|
-
:return_type => return_type
|
592
|
-
)
|
593
|
-
|
594
|
-
data, status_code, headers = @api_client.call_api(:POST, local_var_path, new_options)
|
595
|
-
if @api_client.config.debugging
|
596
|
-
@api_client.config.logger.debug "API called: IntegrationApi#v1_integration_rotate_key\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
597
|
-
end
|
598
|
-
return data, status_code, headers
|
599
|
-
end
|
600
|
-
|
601
|
-
# Update Integration
|
602
|
-
# Update an integration.
|
603
|
-
# @param app_id [String] The Application's ID or UID.
|
604
|
-
# @param integ_id [String] The Integration's ID.
|
605
|
-
# @param integration_update [IntegrationUpdate]
|
606
|
-
# @param [Hash] opts the optional parameters
|
607
|
-
# @return [IntegrationOut]
|
608
|
-
def v1_integration_update(app_id, integ_id, integration_update, opts = {})
|
609
|
-
data, _status_code, _headers = v1_integration_update_with_http_info(app_id, integ_id, integration_update, opts)
|
610
|
-
data
|
611
|
-
end
|
612
|
-
|
613
|
-
# Update Integration
|
614
|
-
# Update an integration.
|
615
|
-
# @param app_id [String] The Application's ID or UID.
|
616
|
-
# @param integ_id [String] The Integration's ID.
|
617
|
-
# @param integration_update [IntegrationUpdate]
|
618
|
-
# @param [Hash] opts the optional parameters
|
619
|
-
# @return [Array<(IntegrationOut, Integer, Hash)>] IntegrationOut data, response status code and response headers
|
620
|
-
def v1_integration_update_with_http_info(app_id, integ_id, integration_update, opts = {})
|
621
|
-
if @api_client.config.debugging
|
622
|
-
@api_client.config.logger.debug 'Calling API: IntegrationApi.v1_integration_update ...'
|
623
|
-
end
|
624
|
-
# verify the required parameter 'app_id' is set
|
625
|
-
if @api_client.config.client_side_validation && app_id.nil?
|
626
|
-
fail ArgumentError, "Missing the required parameter 'app_id' when calling IntegrationApi.v1_integration_update"
|
627
|
-
end
|
628
|
-
if @api_client.config.client_side_validation && app_id.to_s.length > 256
|
629
|
-
fail ArgumentError, 'invalid value for "app_id" when calling IntegrationApi.v1_integration_update, the character length must be smaller than or equal to 256.'
|
630
|
-
end
|
631
|
-
|
632
|
-
if @api_client.config.client_side_validation && app_id.to_s.length < 1
|
633
|
-
fail ArgumentError, 'invalid value for "app_id" when calling IntegrationApi.v1_integration_update, the character length must be great than or equal to 1.'
|
634
|
-
end
|
635
|
-
|
636
|
-
pattern = Regexp.new(/^[a-zA-Z0-9\-_.]+$/)
|
637
|
-
if @api_client.config.client_side_validation && app_id !~ pattern
|
638
|
-
fail ArgumentError, "invalid value for 'app_id' when calling IntegrationApi.v1_integration_update, must conform to the pattern #{pattern}."
|
639
|
-
end
|
640
|
-
|
641
|
-
# verify the required parameter 'integ_id' is set
|
642
|
-
if @api_client.config.client_side_validation && integ_id.nil?
|
643
|
-
fail ArgumentError, "Missing the required parameter 'integ_id' when calling IntegrationApi.v1_integration_update"
|
644
|
-
end
|
645
|
-
if @api_client.config.client_side_validation && integ_id.to_s.length > 33
|
646
|
-
fail ArgumentError, 'invalid value for "integ_id" when calling IntegrationApi.v1_integration_update, the character length must be smaller than or equal to 33.'
|
647
|
-
end
|
648
|
-
|
649
|
-
if @api_client.config.client_side_validation && integ_id.to_s.length < 33
|
650
|
-
fail ArgumentError, 'invalid value for "integ_id" when calling IntegrationApi.v1_integration_update, the character length must be great than or equal to 33.'
|
651
|
-
end
|
652
|
-
|
653
|
-
pattern = Regexp.new(/^integ_[A-Za-z0-9]{27}$/)
|
654
|
-
if @api_client.config.client_side_validation && integ_id !~ pattern
|
655
|
-
fail ArgumentError, "invalid value for 'integ_id' when calling IntegrationApi.v1_integration_update, must conform to the pattern #{pattern}."
|
656
|
-
end
|
657
|
-
|
658
|
-
# verify the required parameter 'integration_update' is set
|
659
|
-
if @api_client.config.client_side_validation && integration_update.nil?
|
660
|
-
fail ArgumentError, "Missing the required parameter 'integration_update' when calling IntegrationApi.v1_integration_update"
|
661
|
-
end
|
662
|
-
# resource path
|
663
|
-
local_var_path = '/api/v1/app/{app_id}/integration/{integ_id}'.sub('{' + 'app_id' + '}', CGI.escape(app_id.to_s)).sub('{' + 'integ_id' + '}', CGI.escape(integ_id.to_s))
|
664
|
-
|
665
|
-
# query parameters
|
666
|
-
query_params = opts[:query_params] || {}
|
667
|
-
|
668
|
-
# header parameters
|
669
|
-
header_params = opts[:header_params] || {}
|
670
|
-
# HTTP header 'Accept' (if needed)
|
671
|
-
header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']
|
672
|
-
# HTTP header 'Content-Type'
|
673
|
-
content_type = @api_client.select_header_content_type(['application/json'])
|
674
|
-
if !content_type.nil?
|
675
|
-
header_params['Content-Type'] = content_type
|
676
|
-
end
|
677
|
-
|
678
|
-
# form parameters
|
679
|
-
form_params = opts[:form_params] || {}
|
680
|
-
|
681
|
-
# http body (model)
|
682
|
-
post_body = opts[:debug_body] || @api_client.object_to_http_body(integration_update)
|
683
|
-
|
684
|
-
# return_type
|
685
|
-
return_type = opts[:debug_return_type] || 'IntegrationOut'
|
686
|
-
|
687
|
-
# auth_names
|
688
|
-
auth_names = opts[:debug_auth_names] || ['HTTPBearer']
|
689
|
-
|
690
|
-
new_options = opts.merge(
|
691
|
-
:operation => :"IntegrationApi.v1_integration_update",
|
692
|
-
:header_params => header_params,
|
693
|
-
:query_params => query_params,
|
694
|
-
:form_params => form_params,
|
695
|
-
:body => post_body,
|
696
|
-
:auth_names => auth_names,
|
697
|
-
:return_type => return_type
|
698
|
-
)
|
699
|
-
|
700
|
-
data, status_code, headers = @api_client.call_api(:PUT, local_var_path, new_options)
|
701
|
-
if @api_client.config.debugging
|
702
|
-
@api_client.config.logger.debug "API called: IntegrationApi#v1_integration_update\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
703
|
-
end
|
704
|
-
return data, status_code, headers
|
705
|
-
end
|
706
|
-
end
|
707
|
-
end
|