Function getIssuesByJQL

  • Get field value by field name.

    Parameters

    • jql: string

      The JQL that defines the search.
      Note: If no JQL expression is provided, all issues are returned.
      username and userkey cannot be used as search terms due to privacy reasons. Use accountId instead.
      If a user has hidden their email address in their user profile, partial matches of the email address will not find the user. An exact match is required.

    • Optional fields: string

      A list of fields to return for each issue, use it to retrieve a subset of fields. This parameter accepts a comma-separated list. Expand options include:

      • all Returns all fields.
      • navigable Returns navigable fields.

      Any issue field, prefixed with a minus to exclude.

    • Optional expand: string

      A comma-separated list of the parameters to expand.
      Use ‘changelog’ to get issues change history.

    Returns Promise<JiraIssue[]>

    Remarks

    Different fields usage example:

    • “summary,comment” - Returns only the summary and comments fields.
    • “-description” - Returns all navigable (default) fields except description.
    • “*all,- comment” - Returns all fields except comments.

    Example

    await SR.jira.getIssuesByJQL('assignee = currentUser()', 'summary,comment')
    

    Example

    await SR.jira.getIssuesByJQL('assignee=currentUser()', 'worklog', 'changelog');