Class: ChannelAdvisor::Services::AdminService

Inherits:
BaseService
  • Object
show all
Defined in:
lib/channeladvisor/services/admin_service.rb

Class Method Summary collapse

Class Method Details

.get_authorization_list(local_id = nil) ⇒ HTTPI::Response

Retrieve a list of account authorizations for the given developer key

Returns:

  • (HTTPI::Response)

    HTTP response object containing the SOAP XML response


35
36
37
38
39
40
41
42
43
# File 'lib/channeladvisor/services/admin_service.rb', line 35

def get_authorization_list(local_id=nil)
  soap_response = client.request :get_authorization_list do
    soap.header = soap_header
    soap.body = {"localID" => local_id} if local_id
  end

  @last_request = client.http
  @last_response = soap_response
end

.pingHTTPI::Response

Check authorization for and availability of the admin service

Returns:

  • (HTTPI::Response)

    HTTP response object containing the SOAP XML response


10
11
12
13
14
15
16
17
# File 'lib/channeladvisor/services/admin_service.rb', line 10

def ping
  soap_response = client.request :ping do
    soap.header = soap_header
  end

  @last_request = client.http
  @last_response = soap_response
end

.request_access(local_id) ⇒ HTTPI::Response

Request access to a ChannelAdvisor account

Returns:

  • (HTTPI::Response)

    HTTP response object containing the SOAP XML response


22
23
24
25
26
27
28
29
30
# File 'lib/channeladvisor/services/admin_service.rb', line 22

def request_access(local_id)
  soap_response = client.request :request_access do
    soap.header = soap_header
    soap.body = {"localID" => local_id}
  end

  @last_request = client.http
  @last_response = soap_response
end