Class: Stigg::Resources::V1::Events::DataExport::Destinations
- Inherits:
-
Object
- Object
- Stigg::Resources::V1::Events::DataExport::Destinations
- Defined in:
- lib/stigg/resources/v1/events/data_export/destinations.rb
Instance Method Summary collapse
-
#create(destination_id:, destination_type:, x_account_id: nil, x_environment_id: nil, request_options: {}) ⇒ Stigg::Models::V1::Events::DataExport::DestinationCreateResponse
Some parameter documentations has been truncated, see Models::V1::Events::DataExport::DestinationCreateParams for more details.
-
#delete(destination_id, x_account_id: nil, x_environment_id: nil, request_options: {}) ⇒ Stigg::Models::V1::Events::DataExport::DestinationDeleteResponse
Some parameter documentations has been truncated, see Models::V1::Events::DataExport::DestinationDeleteParams for more details.
-
#initialize(client:) ⇒ Destinations
constructor
private
A new instance of Destinations.
Constructor Details
#initialize(client:) ⇒ Destinations
This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.
Returns a new instance of Destinations.
81 82 83 |
# File 'lib/stigg/resources/v1/events/data_export/destinations.rb', line 81 def initialize(client:) @client = client end |
Instance Method Details
#create(destination_id:, destination_type:, x_account_id: nil, x_environment_id: nil, request_options: {}) ⇒ Stigg::Models::V1::Events::DataExport::DestinationCreateResponse
Some parameter documentations has been truncated, see Models::V1::Events::DataExport::DestinationCreateParams for more details.
Register a destination on the environment’s DATA_EXPORT integration. Lazy-creates the integration row + provider recipient on first call. Idempotent on destinationId.
32 33 34 35 36 37 38 39 40 41 42 43 |
# File 'lib/stigg/resources/v1/events/data_export/destinations.rb', line 32 def create(params) parsed, = Stigg::V1::Events::DataExport::DestinationCreateParams.dump_request(params) header_params = {x_account_id: "x-account-id", x_environment_id: "x-environment-id"} @client.request( method: :post, path: "api/v1/data-export/destinations", headers: parsed.slice(*header_params.keys).transform_keys(header_params), body: parsed.except(*header_params.keys), model: Stigg::Models::V1::Events::DataExport::DestinationCreateResponse, options: ) end |
#delete(destination_id, x_account_id: nil, x_environment_id: nil, request_options: {}) ⇒ Stigg::Models::V1::Events::DataExport::DestinationDeleteResponse
Some parameter documentations has been truncated, see Models::V1::Events::DataExport::DestinationDeleteParams for more details.
Remove a destination from the DATA_EXPORT integration metadata. Idempotent.
64 65 66 67 68 69 70 71 72 73 74 75 76 |
# File 'lib/stigg/resources/v1/events/data_export/destinations.rb', line 64 def delete(destination_id, params = {}) parsed, = Stigg::V1::Events::DataExport::DestinationDeleteParams.dump_request(params) @client.request( method: :delete, path: ["api/v1/data-export/destinations/%1$s", destination_id], headers: parsed.transform_keys( x_account_id: "x-account-id", x_environment_id: "x-environment-id" ), model: Stigg::Models::V1::Events::DataExport::DestinationDeleteResponse, options: ) end |