           channel = KD.remote.mq.subscribe channelName
           channels[channelName] = channel
           channel.on 'broker.subscribed', -> callback channel
-          channel.exchange = kiteName
           channel.setAuthenticationInfo
             serviceType : 'kite'
             name        : "kite-#{kiteName}"

                messageHandler.bind channel, kiteName
              )
            messageString = JSON.stringify(scrubbed)
            console.log {messageString}
            channel.emit "client-message", messageString

      response = (kiteName, method, args) ->
        scrub method, args, (scrubbed) ->
          fetchChannel kiteName, (channel)=>
            channel.emit "client-message", JSON.stringify(scrubbed)

      ready =->
        console.log 'ready', arguments

      messageHandler =(kiteName, args) ->
        if args.method is 'ready'
          callback = ready
        else
          callback = localStore.get(args.method)
        scrubber = new Scrubber localStore

            remoteStore.add callbackId, ->
              response kiteName, callbackId, [].slice.call(arguments)
          remoteStore.get callbackId
        callback.apply this, unscrubbed

      getChannelName =do ->
        namesCache = {}
        (kiteName)->
          return namesCache[kiteName]  if namesCache[kiteName]
          delegate  = KD.whoami()
          nickname  = delegate?.profile.nickname ?
                      if delegate.guestId then "Guest #{delegate.guestId}" ?
                      'unknown'
          channelName = "#{Bongo.createId 128}.#{nickname}.kite-#{kiteName}"
          namesCache[kiteName] = channelName
          return channelName

      fetchChannel =(kiteName, callback)-> 
        channelName = getChannelName(kiteName)
