move MULTIPARTY logic to application