Sha256: 9568284ab8a8d52b49c31439c2304523f40649eb682a700128b6d19360abc959

Contents?: true

Size: 619 Bytes

Versions: 2

Compression:

Stored size: 619 Bytes

Contents

require 'peddler/request'
require 'mws/reports/parsers/report_acknowledgements'

module MWS
  module Reports
    module Requests
      class ReportAcknowledgements < ::Peddler::Request
        def update(acknowledged, *ids)
          parameters(:update_report_acknowledgements)
            .update(report_id_list: ids, acknowledged: acknowledged)
            .format_structured_lists!
            .camelize_keys!

          execute
        end

        def acknowledge(*ids)
          update(true, *ids)
        end

        def unacknowledge(*ids)
          update(false, *ids)
        end
      end
    end
  end
end

Version data entries

2 entries across 2 versions & 1 rubygems

Version Path
peddler-0.6.5 lib/mws/reports/requests/report_acknowledgements.rb
peddler-0.6.4 lib/mws/reports/requests/report_acknowledgements.rb