rasa/core/channels/rasa_chat.py
async def _extract_sender(self, req):
        """Fetch user from the Rasa Platform Admin API"""

        if req.headers.get("Authorization"):
            user = await self._check_token(req.headers.get("Authorization"))
            if user:
                return user["username"]

        user = await self._check_token(req.args.get('token', default=None))
        if user:
            return user["username"]

        abort(401)
Fetch user from the Rasa Platform Admin API
Fetch user from the Rasa Platform Admin API
Fetch user from the Rasa Platform Admin API
async def _extract_sender(self, req):
        if req.headers.get("Authorization"):
            user = await self._check_token(req.headers.get("Authorization"))
            if user:
                return user["username"]
        user = await self._check_token(req.args.get('token', default=None))
        if user:
            return user["username"]
        abort(401)
async def _extract_sender ( self , req ) : if req . headers . get ( "Authorization" ) : user = await self . _check_token ( req . headers . get ( "Authorization" ) ) if user : return user [ "username" ] user = await self . _check_token ( req . args . get ( 'token' , default = None ) ) if user : return user [ "username" ] abort ( 401 )
Fetch user from the Rasa Platform Admin API
Fetch user from the Rasa Platform Admin API
"""Fetch user from the Rasa Platform Admin API"""
self
req