Class: StubHubApi::Alert

Inherits:
Base
  • Object
show all
Defined in:
lib/stub_hub_api/alert.rb

Instance Attribute Summary

Attributes inherited from Base

#sandbox, #token

Instance Method Summary collapse

Methods inherited from Base

#delete_query_api, #get_query_api, #initialize, #post_multi_part_query_api, #post_multi_pdfs_json_query_api, #post_query_api, #put_query_api

Constructor Details

This class inherits a constructor from StubHubApi::Base

Instance Method Details

#create(user_id, options = {}) ⇒ Object



3
4
5
# File 'lib/stub_hub_api/alert.rb', line 3

def create(user_id, options = {})
  post_query_api("/user/customers/v1/#{user_id}/pricealerts", true, options)
end

#delete(user_id, alert_id) ⇒ Object



11
12
13
# File 'lib/stub_hub_api/alert.rb', line 11

def delete(user_id, alert_id)
  delete_query_api("/user/customers/v1/#{user_id}/pricealerts/#{alert_id}")
end

#show(user_id, alert_id, options = {}) ⇒ Object



15
16
17
# File 'lib/stub_hub_api/alert.rb', line 15

def show(user_id, alert_id, options = {})
  get_query_api("/user/customers/v1/#{user_id}/pricealerts/#{alert_id}", false, options)
end

#update(user_id, options = {}) ⇒ Object



7
8
9
# File 'lib/stub_hub_api/alert.rb', line 7

def update(user_id, options = {})
  put_query_api("/user/customers/v1/#{user_id}/pricealerts/#{alert_id}", true, options)
end