Package org.saidone.restless.mcp
Class NodeArchiveServiceTools
java.lang.Object
org.saidone.restless.mcp.NodeArchiveServiceTools
MCP tools backed by NodeArchiveServiceClient.
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionPermanently deletes the archive entries visible to the configured user.listTrashcan(String filter, Integer skipCount, Integer maxItems) Lists archived nodes visible to the configured repository user.purgeTrashcanNode(String nodeRef) Permanently deletes one archived node under the configured user's permissions.
-
Constructor Details
-
NodeArchiveServiceTools
public NodeArchiveServiceTools()
-
-
Method Details
-
listTrashcan
@Tool(name="alfresco_list_trashcan", description="Lists the deleted documents and folders in the Alfresco trashcan, most recently deleted first, with paging. An administrator sees every deleted node, other users only the nodes they deleted. Entries are archive://SpacesStore nodeRefs; sys:archivedDate, sys:archivedBy and sys:archivedOriginalParentAssoc tell when, by whom and from where each node was deleted. While \'hasMoreItems\' is true, increase skipCount by the page size to read the next page.") public String listTrashcan(@ToolParam(description="Optional name filter",required=false) String filter, @ToolParam(description="Number of items to skip (paging offset), 0 for the first page",required=false) Integer skipCount, @ToolParam(description="Page size, 1..1000 (default 100)",required=false) Integer maxItems) Lists archived nodes visible to the configured repository user.- Parameters:
filter- optional name filterskipCount- page offset, default zeromaxItems- page size, default 100- Returns:
- the JSON page with continuation information
-
purgeTrashcanNode
@Tool(name="alfresco_purge_trashcan_node", description="Permanently deletes one document or folder from the Alfresco trashcan: it cannot be restored afterwards. Ask the user for confirmation before purging.") public String purgeTrashcanNode(@ToolParam(description="Node in the trashcan: an archived nodeRef (archive://SpacesStore/<id>) or its bare node id") String nodeRef) Permanently deletes one archived node under the configured user's permissions.- Parameters:
nodeRef- archive reference or supported archived-node ID- Returns:
- a purge confirmation
-
emptyTrashcan
@Tool(name="alfresco_empty_trashcan", description="Permanently deletes every node in the Alfresco trashcan that the configured user can see (all of them for an administrator): they cannot be restored afterwards. Ask the user for confirmation first.") public String emptyTrashcan()Permanently deletes the archive entries visible to the configured user.- Returns:
- a confirmation with the number of purged nodes
-