Class: Levelup::Endpoints::SpecificOrder

Inherits:
Base
  • Object
show all
Defined in:
lib/levelup/endpoints/specific_order.rb

Overview

Endpoint holding all functions relating to a specified order.

Instance Method Summary collapse

Constructor Details

#initialize(order_uuid) ⇒ SpecificOrder


5
6
7
# File 'lib/levelup/endpoints/specific_order.rb', line 5

def initialize(order_uuid)
  self.uuid = order_uuid
end

Instance Method Details

#refund(merchant_access_token) ⇒ Object

Refunds the order specified by this endpoint.


11
12
13
14
# File 'lib/levelup/endpoints/specific_order.rb', line 11

def refund(merchant_access_token)
  Requests::RefundOrder.new(merchant_access_token: merchant_access_token).
    send_to_api(:post, endpoint_path + '/refund')
end