Count Revisions
-
You can get the number of revisions a document has by using the advance session method
GetCountFor
. -
In this page:
Get revisions count
// Get the number of revisions for document 'companies/1-A"
var revisionsCount = session.Advanced.Revisions.GetCountFor("companies/1-A");
// Get the number of revisions for document 'companies/1-A"
var revisionsCount = await asyncSession.Advanced.Revisions.GetCountForAsync("companies/1-A");
Syntax
long GetCountFor(string id);
Parameter | Type | Description |
---|---|---|
id | string | Document ID for which revisions are counted |
Return value | |
---|---|
long |
The number of revisions for the specified document |