private ExportResult<PhotosContainerResource> requestNonAlbumPhotos(
      TokensAndUrlAuthData authData, PaginationData paginationData, UUID jobId) throws IOException {

    int page = paginationData == null ? 0 : ((IntPaginationToken) paginationData).getStart();

    String url = format(ALL_PHOTOS_URL_TEMPLATE, page);
    Set<PhotoAlbum> albums = new HashSet<>();
    List<PhotoModel> photos = new ArrayList<>();

    List<Map<String, Object>> items = requestData(authData, url);

    boolean hasMore = (items != null && items.size() != 0);

    for (Map<String, Object> item : items) {
      String photoId = (String) item.get("id");

      // Select photos which are not included to the collection of retrieved album photos
      if (!albumPhotos.contains(photoId)) {
        PhotoModel photoModel =
            new PhotoModel(
                (String) item.get("name"),
                (String) item.get("link"),
                (String) item.get("description"),
                (String) item.get("type"),
                (String) item.get("id"),
                DEFAULT_ALBUM_ID,
                true);
        photos.add(photoModel);

        InputStream inputStream = getImageAsStream(photoModel.getFetchableUrl());
        jobStore.create(jobId, photoModel.getFetchableUrl(), inputStream);
      }
    }

    if (!containsNonAlbumPhotos && photos.size() > 0) {
      // Add album for non-album photos
      albums.add(new PhotoAlbum(DEFAULT_ALBUM_ID, "Non-album photos", "Contains non-album photos"));
      // Make sure album will not be added multiply times on subsequent calls
      containsNonAlbumPhotos = true;
    }

    PaginationData newPage = null;
    if (hasMore) {
      newPage = new IntPaginationToken(page + 1);
      monitor.info(() -> format("added non-album photos, size: %s", photos.size()));
    }

    PhotosContainerResource photosContainerResource = new PhotosContainerResource(albums, photos);
    ContinuationData continuationData = new ContinuationData(newPage);

    ExportResult.ResultType resultType = ExportResult.ResultType.CONTINUE;
    if (newPage == null) {
      resultType = ExportResult.ResultType.END;
    }
    return new ExportResult<>(resultType, photosContainerResource, continuationData);
  }
Queries all photos for the account. Chooses photos which are not included to the collection of
photos from albums.

@param authData authentication information
@param paginationData pagination information to use for subsequent calls.
extensions/data-transfer/portability-data-transfer-imgur/src/main/java/org/datatransferproject/datatransfer/imgur/photos/ImgurPhotosExporter.java