Sha256: d5adf1a4e83116419977887e398e74fc40fdca32cdb443719fb141d34d8af98c

Contents?: true

Size: 1.72 KB

Versions: 1

Compression:

Stored size: 1.72 KB

Contents

module Amazon
  module MWS

    class GetFeedSubmissionResultResponse < Response
      class Header < Response
        xml_reader :document_version, :as => Float
        xml_reader :merchant_id, :from => "MerchantIdentifier"
      end

      class ProcessingSummary < Response
        xml_name "ProcessingSummary"

        xml_reader :messages_processed,    :as => Integer
        xml_reader :messages_successful,   :as => Integer
        xml_reader :messages_with_error,   :as => Integer
        xml_reader :messages_with_warning, :as => Integer
      end

      class Result < Response
        xml_name "Result"

        xml_reader :message_id, :from => "MessageID", :as => Integer
        xml_reader :result_code
        xml_reader :message_code, :from => "ResultMessageCode"
        xml_reader :description, :from => "ResultDescription"
        xml_reader :sku, :from => "SKU", :in => "AdditionalInfo"
      end

      class Message < Response
        xml_name "Message"

        xml_reader :id, :from => "MessageID", :as => Integer
        xml_reader :document_transaction_id, :from => "DocumentTransactionID", :in => "ProcessingReport"
        xml_reader :status_code, :in => "ProcessingReport"
        xml_reader :processing_summary, :as => ProcessingSummary, :in => "ProcessingReport"
        xml_reader :results, :as => [Result], :in => "ProcessingReport"
      end
    end

    class GetFeedSubmissionResultResponse
      xml_name "AmazonEnvelope"

      xml_reader :header, :as => Header
      # flattened header
      xml_reader :document_version, :as => Float, :in => "Header"
      xml_reader :merchant_id, :from => "MerchantIdentifier", :in => "Header"

      xml_reader :message_type
      xml_reader :message, :as => Message
    end

  end
end

Version data entries

1 entries across 1 versions & 1 rubygems

Version Path
amazon-mws-plus-0.1.3 lib/amazon/mws/response/feed/get_feed_submission_result_response.rb