SP.FileVersion object

Represents a version of a SP.File object.

Applies to: apps for SharePoint | SharePoint Foundation 2013 | SharePoint Server 2013

var object = new SP.FileVersion()

Members

The FileVersion object has the following members.

Constructor

The FileVersion object has the following constructor.

Constructor

Description

FileVersion

Initializes a new instance of the SP.FileVersion object.

Methods

The FileVersion object has the following methods.

Method

Description

deleteObject

initPropertiesFromJson

Properties

The FileVersion object has the following properties.

Property

Description

checkInComment

Gets a value that specifies the check-in comment.

created

Gets a value that specifies the creation date and time for the file version.

createdBy

Gets a value that specifies the user that represents the creator of the file version.

id

Gets the internal identifier for the file version.

isCurrentVersion

Gets a value that specifies whether the file version is the current version.

size

url

Gets a value that specifies the relative URL of the file version based on the URL for the site or subsite.

versionLabel

Gets a value that specifies the implementation specific identifier of the file.

REST resource endpoint

See FileVersion resource for more information.

Endpoint URI structure

http://<sitecollection>/<site>/_api/web/folders/getbyurl(folderrelativeurl)/files/getbyurl(filerelativeurlfilerelativeurl})/versions(versionid

HTTP requests

This resource supports the following HTTP commands:

DELETE syntax

DELETE http://<sitecollection>/<site>/_api/web/folders/getbyurl(folderrelativeurl)/files/getbyurl(filerelativeurlfilerelativeurl})/versions(versionid

POST syntax

POST http://<sitecollection>/<site>/_api/web/folders/getbyurl(folderrelativeurl)/files/getbyurl(filerelativeurlfilerelativeurl})/versions(versionid