Class: LabelsClient

LabelsClient(jiraClient)

new LabelsClient(jiraClient)

Used to access Jira REST endpoints in '/rest/api/1.0/labels' and '/rest/api/2/label'

Parameters:
Name Type Description
jiraClient JiraClient
Source:

Methods

getAllLabels(optsopt, callbackopt) → {Promise}

Returns a paginated list of labels.

Parameters:
Name Type Attributes Description
opts Object <optional>
Properties
Name Type Attributes Description
startAt number <optional>

The index of the first item to return in a page of results (page offset).

maxResults number <optional>

The maximum number of items to return per page.

callback callback <optional>

Called when labels are retrieved

Source:
Returns:

Resolved when labels are retrieved

Type
Promise

getLabels(opts, callbackopt) → {Promise}

Use this method to retrieve all the available labels e.g if you create an issue and you have to fill the labels field, use this method to get all the available values

Parameters:
Name Type Attributes Description
opts Object

The request options sent to the Jira API.

Properties
Name Type Description
query string

Used for filter labels

callback callback <optional>

Called when labels are retrieved

Source:
Returns:

Resolved when labels are retrieved

Type
Promise