Module: Peddler::Types::NotificationsV1

Defined in:
lib/peddler/types/notifications_v1/error.rb,
lib/peddler/types/notifications_v1/destination.rb,
lib/peddler/types/notifications_v1/sqs_resource.rb,
lib/peddler/types/notifications_v1/subscription.rb,
lib/peddler/types/notifications_v1/aggregation_filter.rb,
lib/peddler/types/notifications_v1/marketplace_filter.rb,
lib/peddler/types/notifications_v1/aggregation_settings.rb,
lib/peddler/types/notifications_v1/destination_resource.rb,
lib/peddler/types/notifications_v1/processing_directive.rb,
lib/peddler/types/notifications_v1/event_bridge_resource.rb,
lib/peddler/types/notifications_v1/get_destination_response.rb,
lib/peddler/types/notifications_v1/order_change_type_filter.rb,
lib/peddler/types/notifications_v1/get_destinations_response.rb,
lib/peddler/types/notifications_v1/get_subscription_response.rb,
lib/peddler/types/notifications_v1/create_destination_request.rb,
lib/peddler/types/notifications_v1/create_destination_response.rb,
lib/peddler/types/notifications_v1/create_subscription_request.rb,
lib/peddler/types/notifications_v1/delete_destination_response.rb,
lib/peddler/types/notifications_v1/create_subscription_response.rb,
lib/peddler/types/notifications_v1/get_subscription_by_id_response.rb,
lib/peddler/types/notifications_v1/delete_subscription_by_id_response.rb,
lib/peddler/types/notifications_v1/destination_resource_specification.rb,
lib/peddler/types/notifications_v1/event_bridge_resource_specification.rb

Constant Summary collapse

Error =

An error response returned when the request is unsuccessful.

Structure.new do
  # @return [String] An error code that identifies the type of error that occurred.
  attribute(:code, String)

  # @return [String] A message that describes the error condition.
  attribute(:message, String)

  # @return [String] Additional details that can help the caller understand or fix the issue.
  attribute(:details, String)
end
Destination =

Information about the destination created when you call the ‘createDestination` operation.

Structure.new do
  # @return [String] The developer-defined name for this destination.
  attribute(:name, String)

  # @return [String] The destination identifier generated when you created the destination.
  attribute(:destination_id, String, from: "destinationId")

  # @return [DestinationResource] The resource that will receive notifications associated with this destination.
  attribute(:resource, DestinationResource)
end
SqsResource =

The information required to create an Amazon Simple Queue Service (Amazon SQS) queue destination.

Structure.new do
  # @return [String] The Amazon Resource Name (ARN) associated with the SQS queue.
  attribute(:arn, String)
end
Subscription =

Information about the subscription.

Structure.new do
  # @return [String] The subscription identifier generated when the subscription is created.
  attribute(:subscription_id, String, from: "subscriptionId")

  # @return [String] The version of the payload object to be used in the notification.
  attribute(:payload_version, String, from: "payloadVersion")

  # @return [String] The identifier for the destination where notifications will be delivered.
  attribute(:destination_id, String, from: "destinationId")

  # @return [ProcessingDirective]
  attribute(:processing_directive, ProcessingDirective, from: "processingDirective")
end
AggregationFilter =

A filter used to select the aggregation time period at which to send notifications (for example: limit to one notification every five minutes for high frequency notifications).

Structure.new do
  # @return [AggregationSettings]
  attribute(:aggregation_settings, AggregationSettings, from: "aggregationSettings")
end
MarketplaceFilter =

An event filter to customize your subscription to send notifications for only the specified ‘marketplaceId`s.

Structure.new do
  # @return [Array]
  attribute(:marketplace_ids, Array, from: "marketplaceIds")
end
AggregationSettings =

A container that holds all of the necessary properties to configure the aggregation of notifications.

Structure.new do
  # @return [String] The supported time period to use to perform marketplace-ASIN level aggregation.
  attribute(:aggregation_time_period, String, from: "aggregationTimePeriod")
end
DestinationResource =

The destination resource types.

Structure.new do
  # @return [SqsResource] An Amazon Simple Queue Service (SQS) queue destination.
  attribute(:sqs, SqsResource)

  # @return [EventBridgeResource] An Amazon EventBridge destination.
  attribute(:event_bridge, EventBridgeResource, from: "eventBridge")
end
ProcessingDirective =

Additional information passed to the subscription to control the processing of notifications. For example, you can use an ‘eventFilter` to customize your subscription to send notifications for only the specified `marketplaceId`s, or select the aggregation time period at which to send notifications (for example: limit to one notification every five minutes for high frequency notifications). The specific features available vary depending on the `notificationType`.

This feature is currently only supported by the ‘ANY_OFFER_CHANGED` and `ORDER_CHANGE` `notificationType`s.

Structure.new do
  # @return [Hash] A `notificationType` specific filter.
  attribute(:event_filter, Hash, from: "eventFilter")
end
EventBridgeResource =

The Amazon EventBridge destination.

Structure.new do
  # @return [String] The name of the partner event source associated with the destination.
  attribute(:name, String)

  # @return [String] The AWS region in which you receive the notifications. For AWS regions that are supported in
  # Amazon EventBridge, refer to [Amazon EventBridge endpoints and
  # quotas](https://docs.aws.amazon.com/general/latest/gr/ev.html).
  attribute(:region, String)

  # @return [String] The identifier for the AWS account that is responsible for charges related to receiving
  # notifications.
  attribute(:account_id, String, from: "accountId")
end
GetDestinationResponse =

The response schema for the ‘getDestination` operation.

Structure.new do
  # @return [Destination] The payload for the `getDestination` operation.
  attribute(:payload, Destination)

  # @return [Array<Error>] One or more unexpected errors occurred during the `getDestination` operation.
  attribute(:errors, [Error])
end
OrderChangeTypeFilter =

An event filter to customize your subscription to send notifications for only the specified ‘orderChangeType`.

Structure.new do
  # @return [Array<OrderChangeTypeEnum>]
  attribute(:order_change_types, Array, from: "orderChangeTypes")
end
GetDestinationsResponse =

The response schema for the ‘getDestinations` operation.

Structure.new do
  # @return [Array<Destination>] The payload for the `getDestinations` operation.
  attribute(:payload, [Destination])

  # @return [Array<Error>] One or more unexpected errors occurred during the `getDestinations` operation.
  attribute(:errors, [Error])
end
GetSubscriptionResponse =

The response schema for the ‘getSubscription` operation.

Structure.new do
  # @return [Subscription] The payload for the `getSubscription` operation.
  attribute(:payload, Subscription)

  # @return [Array<Error>] One or more unexpected errors occurred during the `getSubscription` operation.
  attribute(:errors, [Error])
end
CreateDestinationRequest =

The request schema for the ‘createDestination` operation.

Structure.new do
  # @return [DestinationResourceSpecification] The information required to create a destination resource.
  # Applications should use one resource type (sqs or eventBridge) per destination.
  attribute(:resource_specification, DestinationResourceSpecification, from: "resourceSpecification")

  # @return [String] A developer-defined name to help identify this destination.
  attribute(:name, String)
end
CreateDestinationResponse =

The response schema for the createDestination operation.

Structure.new do
  # @return [Destination] The payload for the `createDestination` operation.
  attribute(:payload, Destination)

  # @return [Array<Error>] One or more unexpected errors occurred during the `createDestination` operation.
  attribute(:errors, [Error])
end
CreateSubscriptionRequest =

The request schema for the ‘createSubscription` operation.

Structure.new do
  # @return [String] The version of the payload object to be used in the notification.
  attribute(:payload_version, String, from: "payloadVersion")

  # @return [String] The identifier for the destination where notifications will be delivered.
  attribute(:destination_id, String, from: "destinationId")

  # @return [ProcessingDirective]
  attribute(:processing_directive, ProcessingDirective, from: "processingDirective")
end
DeleteDestinationResponse =

The response schema for the ‘deleteDestination` operation.

Structure.new do
  # @return [Array<Error>] One or more unexpected errors occurred during the `deleteDestination` operation.
  attribute(:errors, [Error])
end
CreateSubscriptionResponse =

The response schema for the ‘createSubscription` operation.

Structure.new do
  # @return [Subscription] The payload for the `createSubscription` operation.
  attribute(:payload, Subscription)

  # @return [Array<Error>] One or more unexpected errors occurred during the `createSubscription` operation.
  attribute(:errors, [Error])
end
GetSubscriptionByIdResponse =

The response schema for the ‘getSubscriptionById` operation.

Structure.new do
  # @return [Subscription] The payload for the `getSubscriptionById` operation.
  attribute(:payload, Subscription)

  # @return [Array<Error>] An unexpected condition occurred during the `getSubscriptionById` operation.
  attribute(:errors, [Error])
end
DeleteSubscriptionByIdResponse =

The response schema for the ‘deleteSubscriptionById` operation.

Structure.new do
  # @return [Array<Error>] An unexpected condition occurred during the `deleteSubscriptionById` operation.
  attribute(:errors, [Error])
end
DestinationResourceSpecification =

The information required to create a destination resource. Applications should use one resource type (sqs or eventBridge) per destination.

Structure.new do
  # @return [SqsResource] The information required to create an Amazon Simple Queue Service (SQS) queue
  # destination.
  attribute(:sqs, SqsResource)

  # @return [EventBridgeResourceSpecification] The information required to create an Amazon EventBridge
  # destination.
  attribute(:event_bridge, EventBridgeResourceSpecification, from: "eventBridge")
end
EventBridgeResourceSpecification =

The information required to create an Amazon EventBridge destination.

Structure.new do
  # @return [String] The AWS region in which you will be receiving the notifications.
  attribute(:region, String)

  # @return [String] The identifier for the AWS account that is responsible for charges related to receiving
  # notifications.
  attribute(:account_id, String, from: "accountId")
end