Class: AgileEpicClient

AgileEpicClient(jiraClient)

new AgileEpicClient(jiraClient)

Used to access Jira REST endpoints in '/rest/agile/1.0/epic'

Parameters:
Name Type Description
jiraClient JiraClient
Source:

Methods

(static) getEpic(opts, callbackopt) → {Promise}

Returns the epic for a given epic ID. This epic will only be returned if the user has permission to view it.

Parameters:
Name Type Attributes Description
opts

The request options to send to the Jira API

Properties
Name Type Description
epicId number | string
callback function <optional>

Called when the dashboards have been retrieved.

Source:
Returns:

Resolved when the dashboards have been retrieved.

Type
Promise

(static) getIssuesForEpic(opts, callbackopt) → {Promise}

Get a list of all issues associated with an agile epic

Parameters:
Name Type Attributes Description
opts

The request options to send to the Jira API

Properties
Name Type Attributes Description
epicId string | number

epic id or epic key

startAt number <optional>

The index of the first dashboard to return (0-based). must be 0 or a multiple of maxResults

maxResults number <optional>

A hint as to the the maximum number of dashboards to return in each call. Note that the JIRA server reserves the right to impose a maxResults limit that is lower than the value that a client provides, dues to lack or resources or any other condition. When this happens, your results will be truncated. Callers should always check the returned maxResults to determine the value that is effectively being used.

jql string <optional>
validateQuery boolean <optional>
fields Array.<string> <optional>
expand string <optional>
callback function <optional>

Called when the dashboards have been retrieved.

Source:
Returns:

Resolved when the dashboards have been retrieved.

Type
Promise

(static) getIssuesWithoutEpic(optsopt, callbackopt) → {Promise}

Returns all issues that do not belong to any epic. This only includes issues that the user has permission to view. Issues returned from this resource include Agile fields, like sprint, closedSprints, flagged, and epic. By default, the returned issues are ordered by rank.

Parameters:
Name Type Attributes Description
opts Object <optional>

The request options to send to the Jira API

Properties
Name Type Attributes Description
startAt number <optional>

The index of the first dashboard to return (0-based). must be 0 or a multiple of maxResults

maxResults number <optional>

A hint as to the the maximum number of dashboards to return in each call. Note that the JIRA server reserves the right to impose a maxResults limit that is lower than the value that a client provides, dues to lack or resources or any other condition. When this happens, your results will be truncated. Callers should always check the returned maxResults to determine the value that is effectively being used.

jql string <optional>
validateQuery boolean <optional>
fields Array.<string> <optional>
expand string <optional>
callback function <optional>

Called when the dashboards have been retrieved.

Source:
Returns:

Resolved when the dashboards have been retrieved.

Type
Promise

(static) moveIssuesToEpic(opts, callbackopt) → {Promise}

Moves issues to an epic, for a given epic id. Issues can be only in a single epic at the same time. That means that already assigned issues to an epic, will not be assigned to the previous epic anymore. The user needs to have the edit issue permission for all issue they want to move and to the epic. The maximum number of issues that can be moved in one operation is 50.

Parameters:
Name Type Attributes Description
opts

The request options to send to the Jira API

Properties
Name Type Attributes Description
epicId number | string
issues Array.<string> <optional>
callback function <optional>

Called when the dashboards have been retrieved.

Source:
Returns:

Resolved when the dashboards have been retrieved.

Type
Promise

(static) partiallyUpdateEpic(opts, callbackopt) → {Promise}

Performs a partial update of the epic. A partial update means that fields not present in the request JSON will not be updated. Valid values for color are color_1 to color_9.

Parameters:
Name Type Attributes Description
opts

The request options to send to the Jira API

Properties
Name Type Attributes Description
epicId number | string
name string <optional>
summary string <optional>
color any <optional>
done boolean <optional>
callback function <optional>

Called when the dashboards have been retrieved.

Source:
Returns:

Resolved when the dashboards have been retrieved.

Type
Promise

(static) rankEpics(opts, callbackopt) → {Promise}

Moves (ranks) an epic before or after a given epic.

If rankCustomFieldId is not defined, the default rank field will be used.

Parameters:
Name Type Attributes Description
opts

The request options to send to the Jira API

Properties
Name Type Attributes Description
epicId number | string
rankBeforeEpic string <optional>
rankAfterEpic string <optional>
rankCustomFieldId number <optional>
callback function <optional>

Called when the dashboards have been retrieved.

Source:
Returns:

Resolved when the dashboards have been retrieved.

Type
Promise

(static) removeIssuesFromEpic(opts, callbackopt) → {Promise}

Removes issues from epics. The user needs to have the edit issue permission for all issue they want to remove from epics. The maximum number of issues that can be moved in one operation is 50.

Parameters:
Name Type Attributes Description
opts

The request options to send to the Jira API

Properties
Name Type Attributes Description
issues Array.<string> <optional>
callback function <optional>

Called when the dashboards have been retrieved.

Source:
Returns:

Resolved when the dashboards have been retrieved.

Type
Promise