func createGroup(groupName string, systemWildcard string) (*Item, error) {
	papertrailGroupCreated, err := createPapertrailGroupOperation(groupName, systemWildcard)
	if err != nil {
		return nil, err
	}
	return NewItem(papertrailGroupCreated.ID, "Group", papertrailGroupCreated.Name, true, false), nil
}
createGroup attempts to create a group in papertrail using the parameters provided as group information
package papertrail
import (
	"bytes"
	"encoding/json"
	"errors"
	"log"
	"strconv"
	"strings"
)
const papertrailApiGroupsEndpoint = papertrailApiBaseUrl + "groups.json"
func doPapertrailGroupNecessaryActions(groupName string, actionName string, systemWildcard string, deleteAllSystems bool) (*Item, error) {
	var groupItem *Item
	groupObject, err := checkGroupExists(groupName)
	if err != nil {
		return nil, err
	}
	if groupObject != nil {
		log.Printf("Group with name %s exists with id %d\n", groupName, groupObject.ID)
		if ActionIsObtain(actionName) || ActionIsCreate(actionName) {
			return NewItem(groupObject.ID, "Group", groupName, false, false), nil
		} else if ActionIsDelete(actionName) {
			groupItem, err = deleteGroup(groupObject.ID, groupObject.Name)
			if err != nil {
				return nil, err
			}
		}
	} else {
		if ActionIsCreate(actionName) {
			groupItem, err = createGroup(groupName, systemWildcard)
			if err != nil {
				return nil, err
			}
		} else if !checkConditionsForSkipGroupSearch(actionName, deleteAllSystems) {
			err := errors.New("Error: Group with name " + groupName + " doesn't exist ")
			return nil, err
		}
	}
	return groupItem, nil
}