Jira Cloud

Description

The Jira Cloud Component is designed to connect to the Atlassian Jira Cloud platform.

API version

The current release of components tested on API v3.

Credentials

Before building any integration flow, configure the app from the Atlassian developer console.

  1. Create an OAuth 2.0 integration app or select an existing one.

  2. Go to the Authorization section and click the Configure button - near OAuth 2.0 (3LO).

  3. Add the authorized callback URL as https://app.connect.squiz.cloud/callback/oauth2

  4. Click the Save changes.

  5. Select Permissions in the left menu.

  6. Click the Add button next to Jira API.

  7. Click Configure.

  8. Provide the required scopes.

For more information, visit the Atlassian Developer OAuth page.

You can now create new credentials for the component.

Type

A required drop-down. Select OAuth2.

Choose auth client

A required drop-down. Select either Created before or Add New Auth Client.

Name

A required string. There are no restrictions on this field.

Client ID

A required string. Enter the Client ID in the Settings section of the Atlassian developer console.

Client secret

A required string. Enter the Secret from the same page.

Authorization endpoint

A required string. The Atlassian authorization endpoint is https://auth.atlassian.com/authorize.

Token endpoint

A required string. Atlassian refresh token endpoint https://auth.atlassian.com/oauth/token.

Name your credential

A required string. Provide a name for the credential.

Scopes (space-separated list)

A required string. Enter the following scopes to view your Jira:

offline_access read:jira-user read:jira-work write:jira-work

For more information, read the documentation in the Atlassian documentation.

Additional parameters (comma-separated list)

A required string. Set it as prompt:consent to make the component work properly.

Number of retries

An optional integer. The maximum is 10. The default is 5. The number of times the component should retry a request.

Delay between retries

An optional integer in milliseconds. The maximum is 10000, and the default is 3000. This sets how long the system waits until the new attempt. The Retry-After header will be honored when included a response.

Triggers

Get new and updated objects polling

Retrieve all the updated or created objects within a given time range. Only the Issues object type is supported.

Configuration fields

Select cloud

A required drop-down. This will retrieve the sites that have scopes granted by the token.

Object type

A required string. Object type on which to lookup. For example, Issues.

Timestamp field to poll on

An optional string. It can be either Last Modified or Created dates (updated or new objects). Defaults to Last Modified.

Emit behavior

A required drop-down. Defines how result objects will be emitted, one of Emit all, Emit page, or Emit individually.

Start time

An optional string. The timestamp to start polling from (inclusive). The format is YYYY-MM-DD hh:mm and should include the timezone. The default value is the beginning of the Unix Epoch (January 1, 1970, at 00:00).

End time

An optional string. The timestamp to stop polling (exclusive). It is formatted as YYYY-MM-DD hh:mm and should include the timezone. The default value is execution time.

Input metadata

There is no input metadata in this component.

Output metadata

For Emit Page mode

An object with key results with an array as its value.

For Emit Individually mode

Each object will fill the entire message.

Known limitations

Retrieve sample

Limited to 10 records.

Actions

Delete object

Deletes an object. Only the Issues object type is supported.

Configuration fields

Select cloud

A required drop-down. This will retrieve the sites that have scopes granted by the token.

Object type

A required drop-down. Object-type to delete. Only the Issues object type is supported.

Emit strategy when no object found

An optional drop-down. This specifies the output when no object is found by the provided criteria (for example, ID).

Choose one of the following:

Emit nothing

Skips an execution.

If this option is selected, retrieving a sample, you will see an error with the text No object found.
Execution stopped

This error is only applicable to the Retrieve sample field. Flow executions will be skipped instead of throwing an error.

This is fine

Suppresses any error from the flow execution.

Emit an empty object

Emits an empty object. For example, {}.

Throw an error (default)

Throw an error with the text:

No object found by provided ID

This is the default option if nothing else is selected.

Input metadata

Issue ID or Key

A required string. An ID or a key of an issue to delete. Example:

{
  "issueIdOrKey": "SP-60"
}

Output metadata

Issue ID or key

An optional string. An ID or a key of a deleted issue.

Lookup objects (plural)

This action Looks up a set of objects by defined criteria. The Users and Issues object types are supported.

Configuration fields

Select cloud

A required drop-down. This will retrieve the sites that have scopes granted by the token.

Object type

A required drop-down. Object type on which to look up. For example, 'Users'.

Emit behavior

A required drop-down. Defines the way results will be emitted;

  • One of Emit all.

  • Emit page.

  • Emit individually.

Number of search terms

An optional integer. Specify the number of search terms (not applicable to Users). The maximum is 99.

Input metadata

Issues object type
Field name

A required string. The object field name to filter (a list of allowed values is available).

Condition

A required string. Condition to compare the selected field with a value. https://support.atlassian.com/jira-software-cloud/docs/advanced-search-reference-jql-operators/ more info

Field value

An optional string. The value of the selected field. Be aware of the syntax used in the value: If the value contains spaces, it should be quoted. The condition should be formatted differently depending on the content:

  • If the condition is = and the value does not contain spaces, it can be simple text: John.

  • If the condition is = and the value contains spaces, it should be quoted: "John Smith".

  • If the condition is IN and the value does not contain spaces, it should be enclosed in parentheses: (Jack,Jill).

  • If the condition is IN and the value contains spaces, it should be quoted and enclosed in parentheses: ("Jack Smith", "Jill Smith").

Logical operator

You can use either and or or to combine multiple search terms.

   {
      "sTerm_1": {
        "fieldName": "summary",
        "condition": "~",
        "fieldValue": "Fail"
      },
      "link_1_2": "and",
      "sTerm_2": {
        "fieldName": "assignee",
        "condition": "=",
        "fieldValue": "null"
      }
    }
Users object type
Query

An optional string. Find users by query. You can enter a string that is then matched against user attributes displayName and emailAddress (or use statements).

Read the Atlassian documentation for more information.

If Emit behavior equals Emit page, additional fields will be added:

Page number

An integer that defaults to 0. This indicates the index of the page to be fetched.

Page size

An integer that defaults to 100. This is the maximum value. The number of objects per page.

Output metadata

Emit all

An object with key results that has an array as its value.

Emit page

An object with key results with an array as its value (if Page Size > 0).

Key totalCountOfMatchingResults contains the total number of results (not just on the page) that match the search criteria (not available with Users Object Type).

Emit individually

Each object fills the entire message.

Known limitations

Emit all

Avoid using this setting if you expect a large number of result records.

Number of search terms

This field does not apply to the Users object type.

Users

The maximum results with a provided Query is restricted to 1000. Leave the query empty to allow more results.

Retrieve sample

Limited to 10 records.

Lookup object (at most one)

Lookup a single object by a selected field that uniquely identifies it.

Configuration fields

Select cloud

A required drop-down. This will retrieve the sites that have scopes granted by the token.

Object type

A required string. Object type on which to look up. For example, Users.

Allow criteria to be omitted

An optional boolean. This field becomes optional if the Lookup criteria value is selected.

Allow zero results

An optional boolean. When selected, if the object is not found, an empty object will be returned instead of throwing an error.

Input metadata

Lookup criteria value

A required string (unless Allow criteria to be omitted is selected). Value for unique search criteria in the Lookup criteria configuration field.

Output metadata

Object with the result of lookup as value.

Upsert object

Updates an object (if record found) or creates a new object.

Configuration fields

Select cloud

A required drop-down. This will retrieve the sites that have scopes granted by the token.

Object type

A required drop-down. Object type to upsert. For example, Issues.

Input metadata

ID or Key

An optional string. Id Or Key of the object to upsert. Dynamically generated fields according to the object type chosen.

Output metadata

If an object is created, there will be an ID and a key. Otherwise depends on the input.

ID

An optional string. ID Or Key of the object to upsert.

Key

An optional string. ID Or Key of the object to upsert.

Make raw request

Executes a custom request.

Configuration fields

Select cloud

A required drop-down. This will retrieve the sites that have scopes granted by the token.

Do not throw error on 404 response

An optional boolean. Does not treat 404 HTTP responses as errors. This defaults to false.

Input metadata

URL

A required string. Path of the resource relative to the base URL https://api.atlassian.com/ex/jira/{cloudid}/rest/api/3/

Method

A required string. HTTP verb to use in the request, one of GET, POST, PUT, PATCH, DELETE.

Request body

An optional object. Body of the request to send.

Output metadata

Status code

A required number. HTTP status code of the response.

HTTP headers

A required object. HTTP headers of the response.

Response body

An optional object. HTTP response body.