Jira Actions
Let an assistant perform actions in Jira, like reading and writing issues.
Prerequisites
This guide helps you to set up an assistant action for Jira. Before proceeding, we recommend reading the following guide: Assistant actions.
Jira is a ticket and project management tool by Atlassian. You can search and read issues from Jira in Langdock or create and update issues, tasks and assign the to other users in your assistant.
Before you get started, make sure that you have access and permissions to create an application in the Atlassian Developer Console. Also, you need your Jira Domain: https://YOUR_SUBDOMAIN.atlassian.net/jira
You can find the Application API Documentation of Jira here and the Application OAuth 2.0 Documentation here.
Setup
1. Assistant instructions
Create a new assistant. If you are new to creating assistants, you can read more about how to create assistants and write instructions in our assistant guide and our prompt engineering guide. Paste the following instructions into the according field.
2. OpenAPI Schema
Scroll to the bottom of the assistant configuration and click on New Action. Here you can configure actions and API requests to other tools. Copy the text below into the field OpenAPI Schema. You can also try out action assistant to write the OpenAPI schema.
Authentication
3. Create a Jira Application
-
Go to the Atlassian Developer Console. Click on Create and select OAuth 2.0 integration
-
Enter the name of the integration and click Create.
-
Go to the Permissions menu in the left sidebar.
-
Click on Add in the Jira API. Then click Configure.
-
Under Jira platform REST API click on Edit Scopes.
-
Grant the following scopes: read:jira-work write:jira-work read:jira-user
If you want to use other permissions than in our example, you need to set this here and in the OpenAPI Schema above.
-
Click Save.
-
Go to Authorization in the left sidebar and click on Add next to OAuth 2.0 (3LO)
-
Enter a placeholder callback URL and click Save Changes. We will replace this later by the correct callback URL from the action.
-
Go to Settings in the left sidebar and scroll down to Authentication Details. Save the Client ID and the Secret securely. We will need them to authenticate the access from Langdock.
4. OAuth Configuration in Langdock
- Go to the Authentication section at the top of the action settings. Select OAuth. Enter the according information from your Jira Application:
-
Client ID: Enter the Client Key from above
-
Client Secret: Enter the Secret from before
-
Authorization URL: https://auth.atlassian.com/authorize
-
Token URL: https://auth.atlassian.com/oauth/token
-
Scopes: read:jira-work write:jira-work read:jira-user offline_access
-
Token: Default
Specifying the scope offline_access
allows us to automatically refresh access tokens for signed-in users.
5. Paste the redirect URL into Jira application
-
Copy the redirect URL from the OAuth section in the action.
-
Go to your Jira app
-
Navigate back to the Authorization section in the left sidebar.
-
Next to OAuth 2.0 (3LO) click on Configure and replace the placeholder from before with the correct callback URL.
Was this page helpful?