    def get_name(self):
        # type: () -> str
        '''
        Tries to find the best name to use when talking to a user.
        '''
        if ('profile' in self._user and
                'first_name' in self._user['profile'] and
                self._user['profile']['first_name']):
            return self._user['profile']['first_name']
        return self._user['name']
Tries to find the best name to use when talking to a user.
securitybot/user.py