REST API - queryProcessInstancesAlt

The table summarizes the REST API - queryProcessInstancesAlt.

Request

Format
GET <baseurl>/process/query/instancealt/<select>/<where>/<orderby>/<pagesize>
Path parameters
  • select: Attributes to be selected for each process instance in the result set.
  • where: Filter criteria to be used in the query.
  • orderby: Sorting/grouping criteria to be used in the query.

    For information about valid SQL syntax, see Sorting and Filtering Lists of Process Templates and Instances .

  • pagesize: Page size to be used to return the list of process instances. One of the following values:
    • 0: Return the entire result set in a single, non-paged list.
    • -1: Return the result set in a paged list, using the default page size.
    • positive integer: return the result set in a paged list, with the specified number of items on each page.

      If you specify a paged result (pageSize = -1 or a number greater than 0), use the queryFirstPage , queryLastPage , queryNextPage , and queryPreviousPage operations to navigate the paged list, and queryDone to clear resources when you are finished with the paged list. (Note that the result limit for non-paginated queries (pageSize=0) is 500.)

Query parameters
  • name=string (0..n): Name of the template attribute.
  • type=string (0..n): Data type of the template attribute.

    If a user-defined attribute is used in the select parameter of a paginated query, that attribute and its type should be included in the query parameters, otherwise a database query must be made to get the type of the user-defined attribute, making the request less efficient

Response

JSON Returns a JSON representation of the content of the queryProcessInstancesOutput element.
XML Returns the content of the queryProcessInstancesOutput element (from the ProcessManagement schema).

Example

Request
get <baseurl>/process/query/instancealt/ContactName/INSTANCE.STATUS='ACTIVE'/INSTANCE.START_DATE/0?name=ContactName&type=String
Response
{

  "xml-fragment": {

    "proc:processInstances": {

      "@xmlns:proc": "http://www.tibco.com/bx/2009/management/processManagerType",

      "proc:processInstance": [

        {

          "proc:customAttributes": {

            "proc:customAttribute": {

              "proc:name": "ContactName",

              "proc:value": "Bob Wilson"

            }

          }

        },

        {

          "proc:customAttributes": {

            "proc:customAttribute": {

              "proc:name": "ContactName",

              "proc:value": "Nancy Small"

            }

          }

        },

                     .

                     .

                     .

{

          "proc:customAttributes": {

            "proc:customAttribute": {

              "proc:name": "ContactName",

              "proc:value": "Bob Campanella"

            }

          }

        }

      ]

    },

    "proc:pagingID": {

      "@xmlns:proc": "http://www.tibco.com/bx/2009/management/processManagerType",

      "#text": "0"

    }

  }

}