def build_path(self): if self._include_message_actions is False: return FetchMessages.FETCH_MESSAGES_PATH % ( self.pubnub.config.subscribe_key, utils.join_channels(self._channels)) else: return FetchMessages.FETCH_MESSAGES_WITH_ACTIONS_PATH % ( self.pubnub.config.subscribe_key, utils.url_encode(self._channels[0]))
def encoded_params(self): params = {} if self._auth_keys: params['auth'] = utils.join_items_and_encode(self._auth_keys) if self._channels: params['channel'] = utils.join_channels(self._channels) if self._groups: params['channel-group'] = utils.join_items_and_encode(self._groups) return params
def build_path(self): return GetState.GET_STATE_PATH % ( self.pubnub.config.subscribe_key, utils.join_channels(self._channels), utils.url_encode(self.pubnub.uuid) )
def build_path(self): return Leave.LEAVE_PATH % (self.pubnub.config.subscribe_key, utils.join_channels(self._channels))
def build_path(self): return MessageCount.MESSAGE_COUNT_PATH % ( self.pubnub.config.subscribe_key, utils.join_channels(self._channel) )
def build_path(self): if len(self._channels) == 0 and len(self._channel_groups) == 0: return HereNow.HERE_NOW_GLOBAL_PATH % self.pubnub.config.subscribe_key else: return HereNow.HERE_NOW_PATH % (self.pubnub.config.subscribe_key, utils.join_channels(self._channels))
def build_path(self): return SetState.SET_STATE_PATH % ( self.pubnub.config.subscribe_key, utils.join_channels(self._channels), self.pubnub.uuid )
def build_path(self): channels = utils.join_channels(self._channels) return Subscribe.SUBSCRIBE_PATH % (self.pubnub.config.subscribe_key, channels)
def build_path(self): return GetState.GET_STATE_PATH % (self.pubnub.config.subscribe_key, utils.join_channels(self._channels), utils.url_encode(self._uuid))
def build_path(self): return SetState.SET_STATE_PATH % (self.pubnub.config.subscribe_key, utils.join_channels(self._channels), self.pubnub.uuid)
def build_path(self): channels = utils.join_channels(self._channels) return Heartbeat.HEARTBEAT_PATH % (self.pubnub.config.subscribe_key, channels)