@Override
  public ImportResult importItem(
      UUID jobId,
      IdempotentImportExecutor idempotentExecutor,
      TokensAndUrlAuthData authData,
      BlobbyStorageContainerResource data)
      throws Exception {
    String parentId;
    Drive driveInterface = getDriveInterface(authData);

    // Let the parent ID be empty for the root level
    if (Strings.isNullOrEmpty(data.getId()) || "root".equals(data.getId())) {
      parentId =
          idempotentExecutor.executeOrThrowException(
              ROOT_FOLDER_ID,
              data.getName(),
              () -> importSingleFolder(driveInterface, getRootFolderName(), null));
    } else {
      parentId = idempotentExecutor.getCachedValue(data.getId());
    }

    // Uploads folder metadata
    for (BlobbyStorageContainerResource folder : data.getFolders()) {
      idempotentExecutor.executeAndSwallowIOExceptions(
          folder.getId(),
          folder.getName(),
          () -> importSingleFolder(driveInterface, folder.getName(), parentId));
    }

    // Uploads files
    for (DigitalDocumentWrapper file : data.getFiles()) {
      idempotentExecutor.executeAndSwallowIOExceptions(
          Integer.toString(file.hashCode()),
          file.getDtpDigitalDocument().getName(),
          () -> importSingleFile(jobId, driveInterface, file, parentId));
    }

    return ImportResult.OK;
  }
An {@link Importer} to import data to Google Drive.
extensions/data-transfer/portability-data-transfer-google/src/main/java/org/datatransferproject/datatransfer/google/drive/DriveImporter.java