Searching forms remotely

Forms Manager provides a REST-based search API that web developers can use to query Forms Manager and to retrieve a set of forms that meets their search criteria. It supports search for forms based on various property filters. The response contains various form attributes and properties, including their render end points.

To search forms using the REST API, send a POST request to Forms Manager server at https://[server]:[port]/lc/libs/formsmanager/manage.json with the query parameters described below.

Query parameters

Attribute
Attribute name
Description
Function Name
func
The name of the function to invoke
Value = searchForms
This is a mandatory parameter.
Application Path
appPath

Use this, if there is a need to look up forms residing under a particular application. Else, appPath points to the root node containing all applications.

Multiple application paths are supported, to search forms across more than one applications using a single search query.

Cutpoints
cutPoints
A pipe-separated string indicating the properties to fetch with the assets.

Format = propertyName1|propertyName2|propertyName3

This setpoint string fetches propertyName1, propertyName2, and propertyName3 properties for the search result assets.
Using * fetches all properties.
Relation
relation
Whether to fetch related assets along with the search results.

NO_RELATION: Do not fetch related assets.
IMMEDIATE: Fetch only assets that are immediately related to the search results.
ALL: Fetch all related assets.
Maximum Size maxSize The maximum number of results to fetch.
Offset offset Number of results to skip from the start.
Search Count returnCount Whether to return the total number of search results matching the given criteria.
Statements statements

List of statements based on which the query is to be executed in {"name":"property_name","value":"property_value","operator":"operator_type"} json format.Name - The property name that is to be compared/looked up.

Value: The comparison/lookup value.
Operator: Comparison/Lookup operator. The following operators are allowed:

  • EQ- Equal To
  • NEQ- Not Equal To
  • GT - Greater Than
  • LT - Less Than
  • GTEQ- Greater Than or Equal To
  • LTEQ- Less Than or Equal To
  • CONTAINS - A contains B if B is a part of A
  • FULLTEXT - For full text search
  • STARTSWITH - A starts with B if B is the beginning part of A
  • ENDSWITH - A ends with B if B is the ending part of A
  • LIKE - Implements the LIKE operator

GT, LT, GTEQ, and LTEQ operators are applicable for properties of linear type such as LONG, DOUBLE, and DATE.
Multiple statements can be combined using the logical AND operator.

Orderings
orderings

Defines ordering criteria for search results in {"name":“property_name“:”order”:”order_type”} json format.
Name: The property name based on which to order.
Order: ASC or DES. Mul

Multiple orderings are supported to sort on more than one field. The fields are sorted in the order they appear in the query.

Fetch the XDP or not
includeXdp Specifies whether to retrieve the binary content or not. This is applicable for assets of type FORM, PDFFORM, and PRINTFORM.
Type of an asset assetType Specifies asset types to retrieve from all the published assets. Multiple asset types can be specified using the pipe character as a separator. Valid asset types are FORM, PDFFORM, PRINTFORM, RESOURCE, and GUIDE.

Sample request

func : searchForms
appPath : /content/dam/lcapplications/MyApplication23
cutPoints : title|description|author|status|creationDate|lastModifiedDate|formUrl|pdfUrl
relation : NO_RELATION
includeXdp : false
maxSize : 10
offset : 0
returnCount : true
statements: [{"name":"name","value":"*Claim.xdp","operator":"CONTAINS"},
                {"name":"","value":"Expense","operator":"FULLTEXT"},
                {"name":"description","value":"ABCD*","operator":"CONTAINS"},
                {"name":"status","value":"false","operator":"EQ"},
                {"name":"lastModifiedDate","value":"01/09/2013","operator":"GTEQ"},
                {"name":"lastModifiedDate","value":"01/18/2013","operator":"LTEQ"}]
orderings:[{"name" :“lastModifiedDate“:”order”:”ASC”}]

Sample response

[
{"resultCount":2},
    {"assetType":"FORM","name":"ExpenseClaim.xdp","id":"509fa2d5-e3c9-407b-b8dc-fa0ba08eb0ce",
       "path":"/content/dam/lcapplications/MyApplication23/1.0/ExpenseClaim.xdp",
       "title":"Expense Report","description":"ABCDEFGIJK","author":"Frank Bowman",
       "tags":[],"formUrl":"/content/dam/lcapplications/MyApplication23/1.0/ExpenseClaim.xdp/jcr:content",
       "pdfUrl":"/content/dam/lcapplications/MyApplication23/1.0/ExpenseClaim.xdp/jcr:content?type=pdf",
       "references":[],"images":[{"assetType":"resource","name":"Image.gif","id":"5477a127-8bbf-4cec-8f81-2689e5cb4a15",
       "path":"/content/dam/lcapplications/MyApplication23/1.0/Image.gif","resourceSize":0}],
       "status":false,"creationDate":1358429845623,"lastModifiedDate":1358429846771},
{"assetType":"FORM","name":"ExpenseClaim.xdp","id":"4312239b-b666-4d36-95bc-641b3a39ddd4",
       "path":"/content/dam/lcapplications/MyApplication23/ExpenseClaim.xdp",
       "title":"Expense Report","description":"ABCDefghijklm","author":"Frank Bowman",
       "tags":[],"formUrl":"/content/dam/lcapplications/MyApplication23/ExpenseClaim.xdp/jcr:content",
       "pdfUrl":"/content/dam/lcapplications/MyApplication23/ExpenseClaim.xdp/jcr:content?type=pdf",
       "references":[],"images":[{"assetType":"resource","name":"Image.gif","id":"118a2e3f-7097-4d8c-85d1-651306de284a",
       "path":"/content/dam/lcapplications/MyApplication23/Image.gif","resourceSize":0}],"status":false,
       "creationDate":1358429856690,"lastModifiedDate":1358430109023}
]

 Adobe

Get help faster and easier

New user?

Adobe MAX 2024

Adobe MAX
The Creativity Conference

Oct 14–16 Miami Beach and online

Adobe MAX

The Creativity Conference

Oct 14–16 Miami Beach and online

Adobe MAX 2024

Adobe MAX
The Creativity Conference

Oct 14–16 Miami Beach and online

Adobe MAX

The Creativity Conference

Oct 14–16 Miami Beach and online