Content Tools

Overview

These functions extend Appian content and offer document/folder search, directory listing, and the ability to get/set the searchable attribute of a folder.

Functions are designed for and only work on Appian content, not the local filesystem. All search functions assume the root folder and all subfolders are searchable. Search functions will not return results contained within non-searchable objects.

All functions use the serviceContext of the user account executing the expression at runtime.

Key Features & Functionality

Data Types

  • contentSecurityRoleMap: CDT that backs the returnContentRoleMap function

Smart Services

  • Copy Document (Change Extension)
  • Delete Document Version
  • Delete Folder Contents
  • Delete Files Older Than
  • Delete Files Created Before
  • Delete Multiple Documents
  • Remove Member From Folder Security
  • Inherit Security From Parent for Folder
  • Inherit Security from Parent for Document
  • Remove Member From KC Security
  • Delete Rule/Constant Versions
  • Set Folder Security
  • Create Document Version
  • Create expression rule
  • Update expression rule expression
  • Update expression rule parameters

Functions

  • getfoldersrequiringchangesapproval
  • getsubfoldersfromfolder
  • getdocumentsfromfolder
  • getdocumentinternalidsfromfolder
  • getfilesolderthandate: Get files older than a particular date
  • getfileslargerthansize: Get files larger than a particular size
  • finddocumentsbyname
  • getconstantorruleuuidbyname
  • findcontentbyattribute
  • getcontentdetailsbyuuid
  • getcontentdetailsbyinternalname
  • getcontentobjectdetailsbyid
  • getcontentobjectswithnumofversions: function to find rules or constants with a given number of versions. Useful to find out objects that can increase memory usage in the collaboration engine. See https://forum.appian.com/suite/help/16.3/kb/kb-1226.html
  • getcontentobjectrevisionhistorydetails: Retrieves the revision history of a content object formatted as "[version id, date created, date updated, size, author]"
  • getconstantsfromfolder
  • getconstantsbyname
  • setfoldersearchability
  • getfoldersearchability
  • getdownloadersfromgroup
  • returncontentrolemap
  • getprocessmodeldetailsbyuuid
  • getrulereferencebyname
  • generateuuid
Anonymous
  • v1.9.0 Release Notes
    • Adding function to update expression rule parameters
  • Hi, I'm trying to add and deploy this plugin, but I get this error: "HTTP Code: 500 APNX-1-4198-019 An Error Has Occurred Expression evaluation error [evaluation ID = e1688:2495d] : An error occurred while executing a save: java.util.UnknownFormatConversionException: Conversion = 'D'"

    Any suggestions on how I can deploy and use the plugin functions?

  • Having the same issue described in this unsolved post - https://community.appian.com/discussions/f/user-interface/19110/error-document-does-not-exist-or-has-been-deleted-however-the-database-record-does-not-show-the-same 

    A document has suddenly 'disappeared' from our environment causing an error in the interface calling the document ID (taken from the DB) in the document() function:

    Expression evaluation error at function 'document' [line 112]: Document Does Not Exist or has been Deleted (APNX-1-4198-000)

    I can no longer find the document object anywhere in Appian Designer even after searching by it's UUID. However, the getcontentobjectdetailsbyid() function is still returning the following content. Note: deleted documents usually return 'No object with this ID has been found'.

    Content Object [Name: 20220427_141126.jpg, UUID: _a-0000e849-afa9-8000-9be1-011c48011c48_4780488, Parent: Temporary Documents Knowledge Center, Parent Id: 7, Type: Document, Created by: G01386130, Created on: 2022-06-29 16:16:16.0, Last updated by: G01386130, Last updated on: 2022-06-29 16:16:17.0, Latest version: 1, State: Invactive Published, Internal file name: N/A]

    The odd thing is the document can't be located in our environment, having seemingly been deleted but the function is returning content with the state 'Inactive Published' and in the 'Temporary Documents KC' which is not where the document was originally saved to.

    Any suggestions/advice on what happened to this document and how/why it was made inactive?

  • Hi, we had the same error. It was caused by installing another plug-in, 'constantProperties', which is incompatible.

  • if getcontentdetailsbyuuid() is called with an invalid uuid by me (with the developer role but no longer sys admin role, i believe) viewing an interface, it returns "No object with this UUID has been found" but a basic user gets an error. Whom can I reach out to for support on this?

  • In what version did the `Delete Rule/Constant Versions` smart service get added?

  • v1.8.1 Release Notes
    • Bug fixes: Adding parameter to generateuuid so that it can be used in loops
  • Release Notes - v1.8.0
    • New function: generateuuid
  • Hi, with the 1.7.3 update it seems like we are no longer able to do partial text search using "FindDocumentsByName".

    Before, entering something like "en" would return a document with the name "Document_en", but now only entering the full name works. Is this expected behavior?

    Thanks

  • Hi All
    I am using function getprocessmodeldetailsbyuuid. I am using this function in an expression rule which is getting called from the interface.
    I am getting the error 'user does not have sufficient privileges to perform action'
    I have given viewer access to the user to expression rule, interface, process model of which I am trying to fetch details.
    I even tried giving admin access to the process but still getting same error.

    But when I add the user to designer group, it is working fine.
    Is being a member of the Designers group a requirement to leverage getprocessmodeldetailsbyuuid function to get the desired results?

    Any help would be appreciated!

    Thanks!