code: func (s *AuthenticationService) Logout() error {
  	if s.authType != authTypeSession || s.client.session == nil {
  		return fmt.Errorf("no user is authenticated")
  	}
  
  	apiEndpoint := "rest/auth/1/session"
  	req, err := s.client.NewRequest("DELETE", apiEndpoint, nil)
  	if err != nil {
  		return fmt.Errorf("Creating the request to log the user out failed : %s", err)
  	}
  
  	resp, err := s.client.Do(req, nil)
  	if err != nil {
  		return fmt.Errorf("Error sending the logout request: %s", err)
  	}
  	if resp.StatusCode != 204 {
  		return fmt.Errorf("The logout was unsuccessful with status %d", resp.StatusCode)
  	}
  
  	// If logout successful, delete session
  	s.client.session = nil
  
  	return nil
  
  }
docs: // Logout logs out the current user that has been authenticated and the session in the client is destroyed.
  //
  // JIRA API docs: https://docs.atlassian.com/jira/REST/latest/#auth/1/session
  //
  // Deprecated: Use CookieAuthTransport to create base client.  Logging out is as simple as not using the
  // client anymore