Class: Rebay2::Api

Inherits:
Object
  • Object
show all
Defined in:
lib/rebay2/api.rb

Direct Known Subclasses

Finding, Merchandising, Shopping

Constant Summary collapse

EBAY_US =

default site is EBAY_US, for other available sites see eBay documentation: developer.ebay.com/DevZone/merchandising/docs/Concepts/SiteIDToGlobalID.html

0

Class Attribute Summary collapse

Class Method Summary collapse

Class Attribute Details

.app_idObject

Returns the value of attribute app_id.



12
13
14
# File 'lib/rebay2/api.rb', line 12

def app_id
  @app_id
end

.customer_idObject

Returns the value of attribute customer_id.



12
13
14
# File 'lib/rebay2/api.rb', line 12

def customer_id
  @customer_id
end

.default_site_idObject

Returns the value of attribute default_site_id.



12
13
14
# File 'lib/rebay2/api.rb', line 12

def default_site_id
  @default_site_id
end

.network_idObject

Returns the value of attribute network_id.



12
13
14
# File 'lib/rebay2/api.rb', line 12

def network_id
  @network_id
end

.sandboxObject

Returns the value of attribute sandbox.



12
13
14
# File 'lib/rebay2/api.rb', line 12

def sandbox
  @sandbox
end

.tracking_idObject

Returns the value of attribute tracking_id.



12
13
14
# File 'lib/rebay2/api.rb', line 12

def tracking_id
  @tracking_id
end

Class Method Details

.base_urlObject



14
15
16
17
18
# File 'lib/rebay2/api.rb', line 14

def base_url
  [base_url_prefix,
   sandbox ? "sandbox" : nil,
   base_url_suffix].compact.join('.')
end

.base_url_prefixObject



20
21
22
# File 'lib/rebay2/api.rb', line 20

def base_url_prefix
  "http://svcs"
end

.base_url_suffixObject



24
25
26
# File 'lib/rebay2/api.rb', line 24

def base_url_suffix
  "ebay.com"
end

.configure {|_self| ... } ⇒ Object

Yields:

  • (_self)

Yield Parameters:

  • _self (Rebay2::Api)

    the object that the method was called on



40
41
42
# File 'lib/rebay2/api.rb', line 40

def configure
  yield self if block_given?
end