(self)
Create a drive client instance.

    The service can only ever retrieve the credentials from the session.
Create a drive client instance.
Create a drive client instance .
def CreateDrive(self):
    """Create a drive client instance.

    The service can only ever retrieve the credentials from the session.
    """
    # For the service, the session holds the credentials
    creds = self.GetSessionCredentials()
    if creds:
      # If the session contains credentials, use them to create a Drive service
      # instance.
      return CreateService('drive', 'v1', creds)
    else:
      # If no credentials could be loaded from the session, redirect the user to
      # the authorization page.
      self.RedirectAuth()
def CreateDrive ( self ) : # For the service, the session holds the credentials creds = self . GetSessionCredentials ( ) if creds : # If the session contains credentials, use them to create a Drive service # instance. return CreateService ( 'drive' , 'v1' , creds ) else : # If no credentials could be loaded from the session, redirect the user to # the authorization page. self . RedirectAuth ( )