Sha256: 92261c05d1e5eef8ef6cf8870530976464e1ae20a1762c0fc0e305f3355adbfd

Contents?: true

Size: 978 Bytes

Versions: 27

Compression:

Stored size: 978 Bytes

Contents

module Eligible
  class Claim < APIResource
    def self.ack(params, opts = {})
      reference_id = Util.value(params, :reference_id)
      send_request :get, "/claims/#{reference_id}/acknowledgements.json", params, opts.merge(required_params: [:reference_id])
    end

    def self.post(params, opts = {})
      send_request :post, '/claims.json', params, opts
    end

    def self.acks(params, opts = {})
      send_request :get, '/claims/acknowledgements.json', params, opts
    end

    def self.payment_report(params, opts = {})
      reference_id = Util.value(params, :reference_id)
      require_param(reference_id, 'Reference id')
      id = Util.value(params, :id)
      url = id.nil? ? "/claims/#{reference_id}/payment_reports" : "/claims/#{reference_id}/payment_reports/#{id}"
      send_request :get, url, params, opts
    end

    def self.payment_reports(params, opts = {})
      send_request :get, '/claims/payment_reports.json', params, opts
    end
  end
end

Version data entries

27 entries across 27 versions & 1 rubygems

Version Path
eligible-3.0.0.beta28 lib/eligible/claim.rb
eligible-3.0.0.beta27 lib/eligible/claim.rb
eligible-3.0.0.beta26 lib/eligible/claim.rb
eligible-3.0.0.beta25 lib/eligible/claim.rb
eligible-3.0.0.beta24 lib/eligible/claim.rb
eligible-3.0.0.beta23 lib/eligible/claim.rb
eligible-3.0.0.beta22 lib/eligible/claim.rb
eligible-3.0.0.beta20 lib/eligible/claim.rb
eligible-3.0.0.beta19 lib/eligible/claim.rb
eligible-3.0.0.beta18 lib/eligible/claim.rb
eligible-3.0.0.beta17 lib/eligible/claim.rb
eligible-3.0.0.beta16 lib/eligible/claim.rb
eligible-3.0.0.beta15 lib/eligible/claim.rb
eligible-3.0.0.beta14 lib/eligible/claim.rb
eligible-3.0.0.beta13 lib/eligible/claim.rb
eligible-3.0.0.beta12 lib/eligible/claim.rb
eligible-3.0.0.beta11 lib/eligible/claim.rb
eligible-3.0.0.beta10 lib/eligible/claim.rb
eligible-3.0.0.beta9 lib/eligible/claim.rb
eligible-3.0.0.beta8 lib/eligible/claim.rb