Sha256: 6ec893217940ed6ac9feb84c42b959808f4c0c2236c25056d4882c4cc5ad7d25
Contents?: true
Size: 1.19 KB
Versions: 1
Compression:
Stored size: 1.19 KB
Contents
module Eligible class Ticket < APIResource def self.create(params, api_key = nil) response, api_key = Eligible.request(:post, '/tickets', api_key, params) Util.convert_to_eligible_object(response, api_key) end def self.comments(params, api_key = nil) response, api_key = Eligible.request(:post, "/tickets/#{params[:id]}/comments", api_key, params) Util.convert_to_eligible_object(response, api_key) end def self.all response, api_key = Eligible.request(:get, '/tickets', api_key) Util.convert_to_eligible_object(response, api_key) end def self.get(params, api_key = nil) response, api_key = Eligible.request(:get, "/tickets/#{params[:id]}", api_key, params) Util.convert_to_eligible_object(response, api_key) end def self.delete(params, api_key = nil) response, api_key = Eligible.request(:delete, "/tickets/#{params[:id]}", api_key, params) Util.convert_to_eligible_object(response, api_key) end def self.update(params, api_key = nil) response, api_key = Eligible.request(:put, "/tickets/#{params[:id]}", api_key, params) Util.convert_to_eligible_object(response, api_key) end end end
Version data entries
1 entries across 1 versions & 1 rubygems
Version | Path |
---|---|
eligible-2.5.0 | lib/eligible/ticket.rb |