Class: AfterShip::V4::LastCheckpoint

Inherits:
Base
  • Object
show all
Defined in:
lib/aftership/v4/last_checkpoint.rb

Constant Summary

Constants inherited from Base

Base::CALL_SLEEP, Base::MAX_TRIAL

Instance Attribute Summary

Attributes inherited from Base

#body, #end_point, #http_verb_method, #query

Class Method Summary collapse

Methods inherited from Base

#call, #initialize

Constructor Details

This class inherits a constructor from AfterShip::V4::Base

Class Method Details

.get(slug = '', tracking_number = '') ⇒ Object



7
8
9
10
11
12
13
# File 'lib/aftership/v4/last_checkpoint.rb', line 7

def self.get(slug = '', tracking_number = '')
  if slug.empty? || tracking_number.empty?
    raise ArgumentError.new('slug and tracking_number are required.')
  else
    new(:get, "last_checkpoint/#{slug}/#{tracking_number}").call
  end
end