code: def _get_session(self, session):
          
  
          if not session:
              logger.debug('(SESSION_CREATE) User: %s' % self._user)
              s = requests.Session()
              s.auth = HTTPBasicAuth(self._user, self._password)
          else:
              logger.debug('(SESSION_CREATE) Object: %s' % session)
              s = session
  
          s.headers.update(
              {
                  'content-type': 'application/json',
                  'accept': 'application/json',
                  'User-Agent': 'pysnow/%s' % pysnow.__version__
              }
          )
  
          return s
docs: Creates a new session with basic auth, unless one was provided, and sets headers.
  
          :param session: (optional) Session to re-use
          :return:
              - :class:`requests.Session` object