Skip to content

GetLastVersion

Returns the last version of the document instance from the repository if found; otherwise, returns null.

1
$Documents.GetLastVersion(branchId: string):( Document | `"null"` )

Parameters

string branchId
    The branch ID of the document.

Remarks

The branch ID must be a GUID. Selects the highest version number across all states, including Draft, Archived, and Deleted; it does not select the latest published version. Returns null when no version exists. This trusted server API checks the tenant boundary without user ACL filtering.

See Also