Using the JIRA Search Objects Activity
Use the Search Objects activity to fetch the records which matches search string for Issue, User, UsersOverMultiProject, AssignableUser and UsersWithPermissions from JIRA. Search activity for Issue will get custom fields data.
About this task
Use this task to Search objects in the JIRA instance by setting query parameters. The call to this activity is a synchronous call where the input data is sent to the activity for processing and the response is sent back to the orchestration.
Procedure
- In an active orchestration, open the Activities tab and expand the JIRA folder contents.
- Drag the Search Objects activity icon onto the orchestration. Select the activity. The JIRA Search Objects Checklist is displayed.
- In the checklist, click Summary.
- Review the contents of the Activity Name field, and make the required changes.
- In the checklist, click Pick Endpoint.
- Click Browse and use the Project Explorer dialog box to select the relevant JIRA endpoint.
- Optional: You can create the endpoint by clicking New and specifying the required connection details. Click OK to save and use the endpoint for this configuration.
- To make required changes to the selected endpoint configuration, click Edit to access the options in a separate window. Any changes you make globally affects all uses of the endpoint in active orchestrations.
- In the checklist, click Configure.
- Click Browse to select the object type. The Browse JIRA window is displayed.
- In Browse JIRA, you can select the object type from the object type list. Click OK.
- In the Checklist, click Retry. Review the default settings and make the
required changes. Note: For more information, see Specifying the Retry options for JIRA REST API activities.
- Select the Map Inputs in the Checklist. The XML Schemas generated from the selected object of the Retrieve Objects activity are displayed as nodes under the request input parameter in the To Activity panel.
- Create a map between the orchestration variables and the input parameter of the activity. Note: Values must be provided at run time for any mandatory elements of the input structure. A value can be provided by specifying a default value for element or by linking the element with an input node. During run time if no value is provided for a mandatory element, the activity throws an exception, which is reported by the Web Management Console. If a value is not provided at run time for an optional input parameter, no exception is thrown during run time.
- Select the Map Outputs in the Checklist. The XML Schema generated to hold the response of the activity is displayed as nodes under the response output parameter in the From Activity panel.
- Create a map between the output parameters and orchestration variables. Query Parameter
Below are the query parameters of the Search objects:
Table 1. Common Query parameters for all the Search Objects Field Name Description startAt The index of the first record to return (0-based) maxResults The maximum number of users to return (defaults to 50). The maximum allowed value is 1000. If you specify a value that is higher than this number, your search results will be truncated. Table 2. Query parameters for Issue Objects Field Name Description validateQuery This parameter is used to validate the JQL query responseFields The list of fields to return for each issue. By default, all navigable fields are returned. criteria field, operator, value and logicalOperator is definied in criteria. Multiple criteria can be specified by expanding occurrences for the criteria node. field The standard field name to be used in the criteria should be specified. operator The operator to be applied. (For Ex: The valid operators are =, !=, <, >, <=, >=, ~, !~, IN, NOT IN, IS and IS NOT) value The value of the field used in the search logicalOperator The logical operator to be applied (For Ex: Valid logical operators are AND, OR, NOT and ORDER BY) orderBy field and order is definied in orderBy. Multiple orderby can be specified by expanding occurrences for the orderBy node field The standard field name to be used to display the fields in order order The order are ASC and DESC Table 3. Common Query parameters for User Objects Field Name Description includeActive The parameter is used to include the active users includeInActive The parameter is used to include the inactive users Table 4. Common Query parameters for UserWithPermission Objects Field Name Description permissions comma separated list of permissions for project or issue returned users must have Note: Enumeration is not supported by connector so user has to enter the data in query parameters.
Results
Parent topic: JIRA Activities