Version 1.5 - Updated on 03/23/2017
commitChunkedUpload(requestObject)
copyFile(requestObject)
createFolder(requestObject)
deleteFile(requestObject)
fileuploadIntent(requestObject)
fullview(requestObject)
getDownloadUrl(path)
getThumbnailUrl(contentToken, size, th, tw)
metadata(requestObject)
move(requestObject)
rename(requestObject)
search(requestObject)
commitChunkedUpload(requestObject)
Used to finalize a chunked file upload. Until this method is called a chunked upload is not available to the user.
requestObject
— Callbacks and parametersrequestObject.commiturl
— Commit URL returned from a call to fileuploadIntent
when chunked
parameter is set to truerequestObject.success
— Success callback function. Returns the response in the first argument.requestObject.failure
— Failure callback function. Returns the response in the first argument.copyFile(requestObject)
Copies a file or a folder.
Parameters:
requestObject
— Callbacks and parametersrequestObject.src
— Full path of the file or folderrequestObject.target
— Full path of the target file or folder to be copied. In the case of files, the changed name should be included in the target.requestObject.safe
requestObject.conflictsolve
— Defines how name conflicts are resolved if the safe parameter is set to true.
requestObject.success
— Success callback function. Returns the response in the first argument.
requestObject.failure
— Failure callback function. Returns the response in the first argument.
Returns: None. This method is asynchronous. Clients should use callback methods.
createFolder(requestObject)
Creates a folder.
requestObject
— Callbacks and parametersrequestObject.success
— Success callback function. Returns the response in the first argument.requestObject.failure
— Failure callback function. Returns the response in the first argument.requestObject.name
— Name of the folder to be created.requestObject.path
— Path of the parent folder where the folder is to be created.NOTE:
You cannot perform the createFolder
operation on a virutal folder.
deleteFile(requestObject)
Deletes a file or a folder.
requestObject
— Callbacks and parametersrequestObject.success
— Success callback function. Returns the response in the first argument.requestObject.failure
— Failure callback function. Returns the response in the first argument.requestObject.path
— Path of the file or folder to be deleted.NOTE:
You cannot perform the deleteFile
operation on a virutal folder.
fileuploadIntent(requestObject)
Starts the upload process. Clients can request either chunked or un-chunked uploads. Chunked uploads must be used for files larger than 100 MB.
requestObject
— Callbacks and parametersrequestObject.size
— Size of the file to be uploadedrequestObject.chunk
requestObject.path
— full path of the folder where the file is getting uploadedrequestObject.name
— Name of the file to be uploadedrequestObject.checksum
— SHA256 checksum of the filerequestObject.success
— Success callback function. Returns the response in the first argument.requestObject.failure
— Failure callback function. Return the response in the first argument.NOTE:
You cannot perform the fileuploadIntent
operation on a virutal folder.
fullview(requestObject)
Retrieves information about files and folders inside a user’s Personal Cloud Storage. Returns an etag that can be passed in subsequent calls to fullviews
to stay in sync with deltas.
requestObject
— Callbacks and parametersrequestObject.success
— Success callback function. Returns the response in the first argument.requestObject.failure
— Failure callback function. Returns the response in the first argument.requestObject.etag
— Value received from a previous fullview
call, used to keep clients in sync with a user’s changes.getDownloadUrl(path)
Retrieves a URL that can be used to download a file. The client must use the URL.
path
— Path to the filegetThumbnailUrl(contentToken, size, th, tw)
Retrieves the URL of a thumbnail representing a file. The call is not successful until used by a client.
contentToken
— Content token obtained from a call to metadata
or fullview
.size
— Size and width of the thumbnailth
— Height of the thumbnailtw
— Width of the thumbnailh
— URL of the thumbnailmetadata(requestObject)
Metadata API call used to list the contents of directories inside the file system, analagous to the linux ‘ls’ operation. If no path is provided the root ‘/’ is assumed.
requestObject
— Callbacks and parametersrequestObject.success
— Success callback function. Returns the response in the first argument.requestObject.failure
— Failure callback function. Returns the response in the first argumentrequestObject.path
— Path to the folder for which the user wants to retrieve metadata. If no path is given the root ‘/’ is assumed.move(requestObject)
Moves a file or a folder.
requestObject
— Callbacks and parametersrequestObject.success
— Success callback function. Returns the response in the first argument.requestObject.failure
— Failure callback function. Returns the response in the first argument.requestObject.src
— Path of the file or folderrequestObject.target
— Path of the target file or folder to be moved. In case of files, the the changed path should be included in the target.requestObject.safe
requestObject.conflictsolve
— Defines how name conflicts are resolved if the safe parameter is set to true. If set to copy, a new file is written to the destination folder with a non-conflicting name. If not set, the operation is rolled back and returns 409 Conflict error message.rename(requestObject)
Renames a file or a folder.
requestObject
— Callbacks and parametersrequestObject.success
— Success callback function. Returns the response in the first argument.requestObject.failure
— Failure callback function. Returns the response in the first argument.requestObject.src
— Path of the file or folderrequestObject.target
— Path of the target file or folder to rename. In case of files, the changed name should be included in the target.requestObject.safe
requestObject.conflictsolve
— Defines how name conflicts are resolved if the safe parameter is set to true. If set to copy, a new file is written to the destination folder with a non-conflicting name. If not set, the operation is rolled back and returns 409 Conflict error message.NOTE:
You cannot perform the rename
operation on a virutal folder.
search(requestObject)
Search method used to find files or folders matching a query.
requestObject
— Callbacks and parametersrequestObject.count
— Maximum number of items to include in a paginated response. Required, if start is specified. Default is 20, maximum is 100.requestObject.query
— Contains the text to be searched for and supports a number of query fields that allow clients to restrict the search to a particular parts of a file’s or folder’s metadata.requestObject.sort
— Specifies the sort order for a folder response. Syntax is: {field}+{asc or desc}
. Valid values are: name, type, versionCreated, size, extension, album, artist, captureDate, compilation, contentType, creationDate, favorite, genre, height, modificationDate, priority, source, tags, title, timelineDate.requestObject.start
— Specifies which pages are to be returned in the response. Default is 1.requestObject.success
— Success callback function. Returns the response in the first argument.requestObject.failure
— Failure callback function. Returns the response in the first argument.Copyright © 2015-2017, Verizon and/or its Licensors. All rights reserved.