lib/isbm_adaptor/consumer_request.rb
def open_session(uri, listener_url = nil)
      validate_presence_of uri, 'Channel URI'

      message = { 'ChannelURI' => uri }
      message['ListenerURL'] = listener_url if listener_url

      response = @client.call(:open_consumer_request_session, message: message)

      response.to_hash[:open_consumer_request_session_response][:session_id].to_s
    end
def open_session(uri, listener_url = nil)
      validate_presence_of uri, 'Channel URI'

      message = { 'ChannelURI' => uri }
      message['ListenerURL'] = listener_url if listener_url

      response = @client.call(:open_consumer_request_session, message: message)

      response.to_hash[:open_consumer_request_session_response][:session_id].to_s
    end
Creates a new ISBM ConsumerRequest client.

 @param endpoint [String] the SOAP endpoint URI
 @option options [Array<String>] :wsse_auth username and password, i.e. [username, password]
 @option options [Object] :logger (Rails.logger or $stdout) location where log should be output
 @option options [Boolean] :log (true) specify whether requests are logged
 @option options [Boolean] :pretty_print_xml (false) specify whether request and response XML are formatted
 Opens a consumer request session for a channel for posting requests and
 reading responses.

 @param uri [String] the channel URI
 @param listener_url [String] the URL for notification callbacks
 @return [String] the session id
 @raise [ArgumentError] if uri is blank