JIRA Cloud
Setup connector
Jira is a project management tool that helps teams plan, track, and manage work. It can be used for a variety of purposes, including:
- Software development: Planning and launching campaigns, tracking bugs, and supporting releases
- Marketing: Managing and tracking requests
- IT: Building workflows
- Design: Creating custom processes
- Operations: Planning and organizing tasks
Overview
Leena AI integrates with Jira using Jira Rest API v3.
The Jira Cloud connector supports two types of authentication:
- Basic Authentication
- Connect App (supports User Impersonation)
Prerequisites
Before setting up the Jira Cloud connector, ensure you have:
- Administrator access to your Jira Cloud instance
- Ability to create API tokens in Atlassian
- Access to your Leena AI workspace with connector management permissions
Setting up the Jira Cloud Connector
Option 1: Basic Authentication
Basic Authentication is the simpler method using API tokens.
Step 1: Generate API Token in Atlassian
- Go to https://id.atlassian.com/manage-profile/security/api-tokens and login using the service account credentials
- Click on Create API Token
- Provide a Label for the token
- Copy the token generated
Step 2: Configure Basic Authentication in Leena AI
- Give an ID and Name to your connection. ID is used to identify the connector in workflow
- Select Auth Type as Basic Auth
- Enter the following details:
| Parameter | Description | Example |
|---|---|---|
| Site URL | This is the initial part of your Jira URL | https://leena-ai.atlassian.net |
| User Email | This is the service account Email that would be used for the integration | [email protected] |
| API Token | This is the user specific token used for the integration | Generated token from Atlassian |
- Click Save to store the connector configuration
Option 2: Connect App (supports User Impersonation)
Connect App authentication provides user impersonation capabilities, which is required for certain actions like adding comments with 'Created by' information.
Note: This is the most commonly used authentication type for most of the actions. Actions such as 'Adding Comment' requires 'Created by' (createdBy) information, which can only be fetched if this authentication type is used.
Step 1: Create Basic Authentication Connection
- First, create a basic authentication connection following the steps in Option 1
- This connection is required to fetch the list of users required in various actions
Step 2: Configure Connect App in Leena AI
- Select the authentication type as Connect App Auth in Leena AI
- Enter the Site URL (e.g., https://leena-ai.atlassian.net)
- Enter the Connection ID of the Basic Authentication connection created in Step 1
- Copy the Descriptor URL shown
- Click Submit
Step 3: Install App in Jira
- Go to https://leena-ai.atlassian.net/plugins/servlet/upm
- Click on Upload App
- Enter the Descriptor URL from Step 2
- Click Upload
Step 4: Complete Setup
- After the app is installed successfully, come back to Leena AI connector
- The OAuth Client ID and Shared Secret should have values fetched automatically from Jira App
- The connector is now ready for use
Authentication Comparison
| Feature | Basic Auth | Connect App |
|---|---|---|
| Setup Complexity | Simple | Advanced |
| User Impersonation | Not supported | Supported |
| Use Case | Basic operations | Advanced operations with user context |
| Required For | Standard actions | Actions requiring 'Created by' information |
| Recommended For | Simple workflows | Full-featured integrations |
Supported Actions
Leena AI Jira Cloud connector supports the following actions:
| Action Name | Description |
|---|---|
| Add Attachment | Adds a new attachment to Jira Issue |
| Add comment | Adds a new comment to Jira Issue |
| Assign Issue | Assign an issue to a user |
| Create issue | Creates a new issue in a project |
| Create Project | Creates a new project |
| Create Users | Create/onboard a new user in Jira |
| Delete Project | Delete a project |
| Delete Users | Deletes a user in Jira |
| Edit issue | Edit properties of an Issue like status, etc. |
| Get Attachment | Fetches all attachments of an issue |
| Get comments | Fetches all comments of an issue |
| Get edit issue metadata | Fetches edit history of an issue |
| Get issue | Fetches details of an issue |
| Get Project By ProjectId | Fetches details of a project |
| Get Projects Paginated | Fetches all list of projects in a paginated manner |
| Get User By AccountId | Fetches details of user based on account id |
| Get Users | Fetches all the users from Jira in a paginated manner |
| Search for issues using JQL | Fetches all issues based on a JQL query |
Use Cases
Some of the use cases that you can achieve using Jira connector are below:
-
Create, Update and Get status of issue raised via Leena AI Assistant - This connector allows you to setup workflows which enables user to create, add comments or get status of their tickets via natural language using Leena AI assistant.
-
Provision or De-provision users at the time of onboarding / off-boarding - Provision of accounts for new users at the time of onboarding can be automated. Similarly deletion/deactivation of account at the time of off-boarding can also be automated.
-
Automate creation of new projects on client onboarding - Integrate with your CRM to automatically create a new project as soon as a new client onboards.
Security Best Practices
- API Token Security: Store API tokens securely and rotate them regularly
- Service Account: Use dedicated service accounts for integration rather than personal accounts
- Principle of Least Privilege: Only grant necessary permissions to the service account
- Access Monitoring: Monitor API usage through Jira admin panels
- Regular Audits: Review connector permissions and access logs periodically
The connector is now ready to be used by your Leena AI Agents for automated project management and issue tracking workflows.
Create Issue
Helps create a ticket for a user on Jira.
Input Fields
| Field | Description | Type |
|---|---|---|
| Update History | Whether the project in which the issue is created is added to the user's Recently viewed project list, as shown under Projects in Jira. When provided, the issue type and request type are added to the user's history for a project. These values are then used to provide defaults on the issue create screen. | Boolean |
| Fields | List of issue screen fields to update, specifying the sub-field to update and its value for each field | Object |
| History Metadata | History details of the issue | Object |
| Properties | Details of issue properties to be add or update | Object |
| Additional Properties | Extra properties of any type | Object |
Example Usage
Basic Issue Creation
{
"fields": {
"project": {
"key": "PROJ"
},
"summary": "Bug in login functionality",
"description": "Users are unable to login with valid credentials",
"issuetype": {
"name": "Bug"
}
}
}Issue with Additional Fields
{
"updateHistory": true,
"fields": {
"project": {
"key": "PROJ"
},
"summary": "Implement new feature",
"description": "Add support for multi-factor authentication",
"issuetype": {
"name": "Story"
},
"priority": {
"name": "High"
},
"assignee": {
"accountId": "5b10a2844c20165700ede21g"
}
}
}Issue with Custom Properties
{
"fields": {
"project": {
"key": "PROJ"
},
"summary": "Database performance issue",
"description": "Query execution time is significantly slow",
"issuetype": {
"name": "Bug"
}
},
"properties": [
{
"key": "severity",
"value": "critical"
}
]
}Response
Upon successful creation, the action returns:
- Issue ID
- Issue Key
- Issue URL
- Creation timestamp
Common Use Cases
- Bug Reporting: Automatically create bug tickets from user reports
- Feature Requests: Generate feature request tickets from feedback
- Service Requests: Create IT service tickets from employee requests
- Incident Management: Automatically log incidents as Jira issues
- Task Creation: Generate tasks from workflow triggers
- Customer Support: Create support tickets from customer inquiries
Edit Issue
Action to allow user to update or edit issue.
Input Fields
| Field | Description | Type |
|---|---|---|
| Issue id or key | Issue id that needs to be updated | String |
| Notify user | Whether to notify user or not | Boolean |
| Override Screen Security | Whether screen security is overridden to enable hidden fields to be edited | Boolean |
| Override Editable Flag | Whether screen security is overridden to enable uneditable fields to be edited | Boolean |
| Return Issue | Whether the response should contain the issue with fields edited in this request | Boolean |
| Expand | The expand parameters to use in conjunction to return issue flag | String |
| Fields | List of issue screen fields to update, specifying the sub-field to update and its value for each field | Object |
| History Metadata | History details of the issue | Object |
| Properties | Details of issue properties to be updated | Object |
| Additional Properties | Extra properties of any type | Object |
| Transition | Details of a transition. Required when performing a transition, optional when editing an issue | Object |
Example Usage
Update Issue Summary and Description
{
"issueIdOrKey": "PROJ-123",
"notifyUsers": true,
"fields": {
"summary": "Updated: Bug in login functionality",
"description": "Users are unable to login with valid credentials. Issue occurs on mobile devices."
}
}Update Issue Status (Transition)
{
"issueIdOrKey": "PROJ-123",
"notifyUsers": true,
"transition": {
"id": "31"
}
}Update Multiple Fields
{
"issueIdOrKey": "PROJ-123",
"notifyUsers": true,
"returnIssue": true,
"fields": {
"priority": {
"name": "Critical"
},
"assignee": {
"accountId": "5b10a2844c20165700ede21g"
},
"labels": ["urgent", "customer-impact"]
}
}Update with Override Flags
{
"issueIdOrKey": "PROJ-123",
"notifyUsers": false,
"overrideScreenSecurity": true,
"overrideEditableFlag": true,
"fields": {
"customfield_10001": "Updated custom field value"
}
}Response
Upon successful update, the action returns:
- Updated issue ID
- Updated fields
- New status (if transition was performed)
- Update timestamp
Common Use Cases
- Status Updates: Change issue status through workflow transitions
- Assignment Changes: Reassign issues to different team members
- Priority Updates: Adjust issue priority based on business needs
- Field Updates: Update custom fields and standard fields
- Bulk Updates: Update multiple fields in a single operation
- Automated Workflows: Trigger updates based on external events
Add comment
This action is used to add comment to an existing Issue.
Input Fields
| Field Name | Description | Type |
|---|---|---|
| Issue Id or Key | Issue ID on which comment needs to be added. Ex: IT-91 | String |
| Expand | Use expand to include additional information about comments in the response | String |
| Body | Comment text in the Atlassian format | String |
| Properties | A list of comment properties | Array |
| Visibility | The group or role to which this comment is visible. Optional on create and update | Object |
| Additional Properties | Extra properties of any type may be provided to this object | Object |
Example Usage
Basic Comment
{
"issueIdOrKey": "IT-91",
"body": "This issue has been reviewed and assigned to the development team."
}Comment with Visibility Restriction
{
"issueIdOrKey": "IT-91",
"body": "Internal note: This requires urgent attention from senior developers.",
"visibility": {
"type": "role",
"value": "Administrators"
}
}Comment with Properties
{
"issueIdOrKey": "IT-91",
"body": "Update: Bug has been fixed and is ready for testing.",
"properties": [
{
"key": "status",
"value": "fixed"
}
]
}Comment with Expand
{
"issueIdOrKey": "IT-91",
"expand": "renderedBody",
"body": "Please review the attached documentation for more details."
}Response
Upon successful creation, the action returns:
- Comment ID
- Comment body
- Author details
- Creation timestamp
- Visibility settings
Common Use Cases
- Status Updates: Provide updates on issue progress
- Internal Notes: Add internal comments visible only to specific roles
- User Communication: Communicate with issue reporters
- Collaboration: Enable team collaboration on issues
- Audit Trail: Document actions taken on issues
- Automated Updates: Add system-generated comments based on workflows
Get Comments
This action is used to get comments about an existing Issue.
Input Fields
| Field Name | Description | Type |
|---|---|---|
| Issue Id or Key | Issue ID on which comment needs to be added. Ex: IT-91 | String |
| Expand | Use expand to include additional information about comments in the response | String |
| Start At | Index to start at | Integer |
| Max Results | Maximum number of results returned | Integer |
| Order By | Sorting to be applied | String |
Example Usage
Get All Comments
{
"issueIdOrKey": "IT-91"
}Get Comments with Pagination
{
"issueIdOrKey": "IT-91",
"startAt": 0,
"maxResults": 50
}Get Comments with Sorting
{
"issueIdOrKey": "IT-91",
"orderBy": "created",
"maxResults": 100
}Get Comments with Expanded Information
{
"issueIdOrKey": "IT-91",
"expand": "renderedBody,properties",
"startAt": 0,
"maxResults": 25
}Response
The action returns a list of comments, each containing:
- Comment ID
- Comment body
- Author information
- Creation timestamp
- Update timestamp
- Visibility settings
- Properties (if expanded)
Common Use Cases
- Comment History: Retrieve complete comment history of an issue
- Communication Review: Review all communications on a ticket
- Audit Trail: Track all updates and discussions
- Reporting: Generate reports on issue communications
- Search: Find specific comments or discussions
- Integration: Sync comments with external systems
Add Attachment
This action is used to add attachment to an Issue. This can be used in conjunction Add comment or Create Issue to allow users to add attachment as well.
Input Fields
| Field Name | Description | Type |
|---|---|---|
| Issue ID or Key | Issue ID on which attachment needs to be added. Ex: IT-91 | String |
| File Name | Name of the attachment file | String |
| File Data | Public URL of the attachment or base 64 encoded attachment data | String |
Example Usage
Add Attachment from URL
{
"issueIdOrKey": "IT-91",
"fileName": "screenshot.png",
"fileData": "https://example.com/files/screenshot.png"
}Add Attachment from Base64
{
"issueIdOrKey": "IT-91",
"fileName": "error-log.txt",
"fileData": "data:text/plain;base64,VGhpcyBpcyBhIHNhbXBsZSBlcnJvciBsb2c="
}Add Multiple Attachments
{
"issueIdOrKey": "IT-91",
"fileName": "documentation.pdf",
"fileData": "https://example.com/files/documentation.pdf"
}Response
Upon successful upload, the action returns:
- Attachment ID
- File name
- File size
- Upload timestamp
- Download URL
Common Use Cases
- Bug Reports: Attach screenshots of errors or bugs
- Documentation: Upload relevant documentation files
- Logs: Attach error logs or system logs
- Evidence: Upload supporting evidence for issues
- Design Files: Attach design mockups or wireframes
- Test Results: Upload test results or reports
Create Project
This action can be used to create a new project in Jira automatically.
Input Fields
| Field | Description | Type |
|---|---|---|
| Assignee Type | Who would be the default assignee of the ticket | String |
| Project Category | Category of the project | String |
| Description | Project description | String |
| Issue Security Scheme | The ID of the issue security scheme for the project, which enables you to control who can and cannot view issues | String |
| Field Configuration Scheme | The ID of the field configuration scheme for the project | String |
| Issue Type Scheme | The ID of the issue type scheme for the project | String |
| Issue Type Screen Scheme | The ID of the issue type screen scheme for the project | String |
| Project Key | Project keys must be unique and start with an uppercase letter followed by one or more uppercase alphanumeric characters. The maximum length is 10 characters | String |
| Project Name | The name of the project | String |
Example Usage
Basic Project Creation
{
"projectKey": "NEWPROJ",
"projectName": "New Project",
"description": "This is a new project for Q4 initiatives",
"assigneeType": "PROJECT_LEAD"
}Project with Category
{
"projectKey": "MARKETING",
"projectName": "Marketing Campaigns",
"description": "Project to manage all marketing campaigns",
"assigneeType": "UNASSIGNED",
"projectCategory": "Marketing"
}Project with Schemes
{
"projectKey": "SECURE",
"projectName": "Secure Project",
"description": "High-security project with custom configurations",
"assigneeType": "PROJECT_LEAD",
"issueSecurityScheme": "10001",
"fieldConfigurationScheme": "10002",
"issueTypeScheme": "10003",
"issueTypeScreenScheme": "10004"
}Response
Upon successful creation, the action returns:
- Project ID
- Project Key
- Project URL
- Creation timestamp
- Project settings
Common Use Cases
- Client Onboarding: Automatically create projects for new clients
- Department Setup: Create projects for new departments or teams
- Campaign Management: Set up projects for marketing campaigns
- Product Development: Create projects for new product initiatives
- Event Management: Set up projects for events or launches
- Service Management: Create projects for service delivery teams
Create Users
This action enables you to create new users in Jira via any request or automatically at the time of employee onboarding.
Input Fields
| Field | Description | Type |
|---|---|---|
| Email Address | List of email addresses to create | Array |
| Products | The list of products the user should be given access to | Array |
Example Usage
Create Single User
{
"emailAddress": ["[email protected]"],
"products": ["jira-software"]
}Create Multiple Users
{
"emailAddress": [
"[email protected]",
"[email protected]",
"[email protected]"
],
"products": ["jira-software", "jira-servicedesk"]
}Create User with Multiple Products
{
"emailAddress": ["[email protected]"],
"products": ["jira-software", "jira-servicedesk", "jira-core"]
}Response
Upon successful creation, the action returns:
- User account ID
- Email address
- User status
- Product access granted
- Creation timestamp
Common Use Cases
- Employee Onboarding: Automatically create Jira accounts for new employees
- Bulk User Creation: Create multiple users during team expansion
- Contractor Access: Provision access for contractors or temporary staff
- Department Setup: Create users for new department members
- Project Team Setup: Provision users for new project teams
- Integration Workflows: Automatically create users from HR systems
Error Handling
Common error scenarios:
- Duplicate Email: User with email already exists
- Invalid Email: Email format is invalid
- Product Access: Specified product is not available
- License Limit: Organization has reached user license limit
- Permission Denied: Insufficient permissions to create users
Updated about 19 hours ago
