Class: EasyPost::Services::CustomsItem
- Defined in:
 - lib/easypost/services/customs_item.rb
 
Constant Summary collapse
- MODEL_CLASS =
 EasyPost::Models::CustomsItem
Instance Method Summary collapse
- 
  
    
      #create(params)  ⇒ Object 
    
    
  
  
  
  
  
  
  
  
  
    
Create a CustomsItem object.
 - 
  
    
      #retrieve(id)  ⇒ Object 
    
    
  
  
  
  
  
  
  
  
  
    
Retrieve a CustomsItem object.
 
Methods inherited from Service
Constructor Details
This class inherits a constructor from EasyPost::Services::Service
Instance Method Details
#create(params) ⇒ Object
Create a CustomsItem object
      7 8 9 10 11  | 
    
      # File 'lib/easypost/services/customs_item.rb', line 7 def create(params) response = @client.make_request(:post, 'customs_items', params) EasyPost::InternalUtilities::Json.convert_json_to_object(response, MODEL_CLASS) end  | 
  
#retrieve(id) ⇒ Object
Retrieve a CustomsItem object
      14 15 16 17 18  | 
    
      # File 'lib/easypost/services/customs_item.rb', line 14 def retrieve(id) response = @client.make_request(:get, "customs_items/#{id}") EasyPost::InternalUtilities::Json.convert_json_to_object(response, MODEL_CLASS) end  |