Module: Peddler::Types::Finances20240601

Defined in:
lib/peddler/types/finances_2024_06_01/error.rb,
lib/peddler/types/finances_2024_06_01/error_list.rb,
lib/peddler/types/finances_2024_06_01/expiry_date.rb,
lib/peddler/types/finances_2024_06_01/payment_method_details.rb,
lib/peddler/types/finances_2024_06_01/initiate_payout_request.rb,
lib/peddler/types/finances_2024_06_01/initiate_payout_response.rb,
lib/peddler/types/finances_2024_06_01/get_payment_methods_response.rb

Constant Summary collapse

Error =

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
ErrorList =

A list of error responses returned when a request is unsuccessful.

Structure.new do
  # @return [Array<Error>] array of errors
  attribute(:errors, [Error])
end
ExpiryDate =

The expiration date of the card used for payment. If the payment method is not card, the expiration date is null.

Structure.new do
  # @return [String] The month the card expires expressed as a number from `1` to `12`.
  attribute(:month, String)

  # @return [String] Year
  attribute(:year, String)
end
PaymentMethodDetails =

The details of a payment method.

Structure.new do
  # @return [String] The name of the account holder who is registered for the payment method.
  attribute(:account_holder_name, String, from: "accountHolderName")

  # @return [String] The payment method identifier.
  attribute(:payment_method_id, String, from: "paymentMethodId")

  # @return [String] The last three or four digits of the payment method.
  attribute(:tail, String)

  # @return [ExpiryDate] The expiration date of the card used for payment.
  attribute(:expiry_date, ExpiryDate, from: "expiryDate")

  # @return [String] The two-letter country code in ISO 3166-1 alpha-2 format. For payment methods in the `card`
  # category, the code is for the country where the card was issued. For payment methods in the `bank account`
  # category, the code is for the country where the account is located.
  attribute(:country_code, String, from: "countryCode")

  # @return [String] The payment method type.
  attribute(:payment_method_type, String, from: "paymentMethodType")

  # @return [String] The payment method assignment type, whether it is assigned as default to the given
  # marketplace or not.
  attribute(:assignment_type, String, from: "assignmentType")
end
InitiatePayoutRequest =

The request schema for the initiatePayout operation.

Structure.new do
  # @return [String] The identifier of the Amazon marketplace. This API supports the following marketplaces: DE,
  # FR, IT, ES, SE, NL, PL, and BE. For a list of possible marketplace IDs, refer to [Marketplace
  # IDs](https://developer-docs.amazon.com/sp-api/docs/marketplace-ids).
  attribute(:marketplace_id, String, from: "marketplaceId")

  # @return [String] The account type in the selected marketplace for which a payout must be initiated. For
  # supported EU marketplaces, the only account type is `Standard Orders`.
  attribute(:account_type, String, from: "accountType")
end
InitiatePayoutResponse =

The response schema for the initiatePayout operation.

Structure.new do
  # @return [String] The financial event group ID for a successfully initiated payout. You can use this ID to
  # track payout information.
  attribute(:payout_reference_id, String, from: "payoutReferenceId")
end
GetPaymentMethodsResponse =

The response schema for the getPaymentMethods operation.

Structure.new do
  # @return [Array<PaymentMethodDetails>]
  attribute(:payment_methods, [PaymentMethodDetails], from: "paymentMethods")
end