// get path of the import tmp directory
String pathImpTmpFolder = ImportUtilities.getImportTempFolderPath();
// apply transformation
TransformManager transManager = new TransformManager();
archiveBytes = transManager.applyTransformations(archiveBytes, archiveName, pathImpTmpFolder);
impManager = ImportUtilities.getImportManagerInstance();
// prepare import environment
impManager.init(pathImpTmpFolder, archiveName, archiveBytes);
impManager.openSession();