added packageID and entityName arguments to workflow functions