module Fulfillment::Resources::Vouchers
Public Instance Methods
find_all(params={})
click to toggle source
# File lib/fulfillment/resources/vouchers.rb, line 6 def find_all(params={}) response = Request.new("vouchers", { search: params }).get Models::Collection.new(Models::Voucher, response.body) end
redeem(params={})
click to toggle source
# File lib/fulfillment/resources/vouchers.rb, line 16 def redeem(params={}) response = Request.new("vouchers/#{params[:show_id]}/#{params[:code]}/redeem", params).patch Models::Voucher.new(response.body) end
update(params={})
click to toggle source
# File lib/fulfillment/resources/vouchers.rb, line 11 def update(params={}) response = Request.new("vouchers/#{params[:id]}", params).patch Models::Voucher.new(response.body) end