List B2 File Versions.

Share:

Description

b2ListFileVersions lists all versions of all of the files contained in one bucket, within a user's account on the Backblaze B2 cloud storage product.

Usage

1
2
b2ListFileVersions(bucketId, startFileName = "", startFileId = "",
  maxFileCount = 100)

Arguments

bucketId

The unique identifier of the bucket containing the files to be listed. Bucket IDs may be obtained through the b2ListBucketsfunction in this package.

startFileName

The name of the file from which the list will start. If there are no files with this name, the first version of the file with the first name after the given name will be the first in the list. This is an optional parameter. Not defining this parameter will result in the list starting from the newest file first. File names may be obtained through the b2ListFileNames function in this package.

startFileId

The first file ID to return. This is an optional parameter. startFileName must also be provided if startFileId is specified.

maxFileCount

An integer defining the maximum number of file names to return. This is an optional parameter and defaults to 100. The maximum acceptable value is 1000.

Details

This function lists all versions of all of the files contained in one bucket, within a user's account on the Backblaze B2 cloud storage product. Files will be listed in alphabetical order by file name, and by reverse of date/time uploaded for versions of files with the same name. Further details regarding this API call are available here:

https://www.backblaze.com/b2/docs/b2_list_file_versions.html

bucketId is mandatory and must be user defined. startFileName, startFileId and maxFileCount are optional and may be defined by the user if so desired.

Value

If successful a list will be returned containing files, nextFileName and nextFileId for files within the specified bucket. If greater than the maximum number of specified files in maxFileCount exists, further file versions may be obtained beginning with nextFileName, as the startFileName parameter value. This may be done either alone or in combination with nextFileId, as startFileId. If successful a data frame will be returned, nested within files, containing fileId, fileName, action, size and uploadTimestamp for all file versions within the specified bucket.

Examples

1
2
3
4
5
6
7
## Not run: 
b2ListFileVersions(bucketId = "aUniqueBucketId",
startFileName = "yourFileName.png",
startFileId = "yourFileId"
maxFileCount = 500)

## End(Not run)