Jira Webhook
The Jira Webhook component acts as a bridge between your Jira Cloud account and the Nappai automation system. Its primary purpose is to receive notifications whenever specific events happen in Jira, such as a new ticket being created, a comment being added, or a sprint being closed.
Instead of constantly checking Jira for changes, this component waits for Jira to “tell” it when something happens. It then checks if the event is one you care about. If it is, it organizes the data so you can use it in other parts of your workflow. If not, it quietly stops the process to save resources.
How it Works
This component works by listening for incoming messages (webhooks) from Jira. When Jira detects a change, it sends a message to this component.
- Reception: The component receives raw data from Jira describing the event (e.g., “Ticket PROJ-123 was created”).
- Filtering: It looks at your settings to see which types of events you want to process (e.g., only “Issue Created”). If the incoming event doesn’t match your selection, the component ignores it.
- Structuring: If the event is relevant, it breaks down the complex data into a simple, organized format. It extracts key details like the ticket ID, summary, status, and who made the change.
- Output: It passes this clean, structured data to the next step in your automation workflow.
Note: This component does not have different “operations” to select from. It simply processes incoming data based on your filter settings.
Connection & Credentials
To connect with Jira, you must first set up a secure credential in Nappai. This ensures that your automation is authorized to receive data from your Jira account.
- Go to the Credentials section in your Nappai panel.
- Create a new credential of the type Jira API.
- You will need to enter your Jira Base URL (e.g.,
https://your-company.atlassian.net). - Enter your Jira Email associated with your Atlassian account.
- Enter your Jira API Token (generated in your Atlassian account settings).
- You will need to enter your Jira Base URL (e.g.,
- In your workflow, open the Jira Webhook component and select the saved credential from the Credential input field.
Inputs
Input Fields
The following fields are available to configure this component:
- Events: Select which types of Jira events you want this component to process. You can choose multiple options like “Issue Created,” “Comment Updated,” or “Sprint Closed.” If you leave this empty, it will process all event types.
Outputs
The component produces a single output called Data. This output contains two main parts:
- Summary Text: A human-readable summary, such as “ISSUE-123: Bug fix for login page.”
- Structured Data: A detailed list of information including the event type, the ticket key, status, priority, assignee, and any comments or changes made.
If an event is ignored because it wasn’t selected in your filters, the output will clearly indicate that it was ignored, preventing further steps in your workflow from running unnecessarily.
Output Data Example (JSON)
Below is an example of the structured data (Data output) when a new issue is created in Jira:
json
{
“text”: “ISSUE_CREATED: PROJ-123: Fix login error”,
“data”: {
“event_type”: “jira:issue_created”,
“category”: “issue”,
“operation”: “created”,
“issue_key”: “PROJ-123”,
“summary”: “Fix login error”,
“status”: “To Do”,
“priority”: “High”,
“assignee”: “john.doe”,
“reporter”: “jane.smith”,
“created_at”: “2023-10-27T10:00:00.000+0000”,
“user”: {
“name”: “jane.smith”,
“email”: “jane.smith@example.com”
},
“ignored”: false
}
}
Connectivity
This component is typically placed at the start of an automation workflow. It acts as a trigger node.
- Connects To: It should connect to other components that need to react to Jira changes, such as:
- Message Builders: To send notifications via email or chat (e.g., Slack, Teams) when a new ticket is created.
- Database Writers: To store ticket details in a custom database.
- AI Analyzers: To use an LLM to suggest next steps or summarize the ticket content.
By placing this component first, you ensure that subsequent steps only run when relevant events occur, keeping your automation efficient.
Usage Example
Scenario: You want to receive a Slack notification whenever a “High Priority” bug is created in Jira.
- Add the Jira Webhook component to your canvas.
- In the Events input, select “Issue Created”.
- Connect the Data output of the Jira Webhook to a Filter component or an AI Assistant that checks the “priority” field.
- If the condition is met, connect the next step to a Slack or Email component to send the notification.
When a user creates a new ticket in Jira, Jira sends a signal to this component. The component checks if it was an “Issue Created” event. If yes, it passes the ticket details to the next step, which then triggers the notification.
Tips and Best Practices
- Be Specific with Filters: In the Events input, only select the event types you actually need. For example, if you only care about new tickets, leave “Comment Updated” unchecked. This makes your workflow faster and easier to debug.
- Understand the Output: The Data output includes both a simple text summary and a complex object. When connecting to subsequent nodes, you can choose to use either the simple text for quick reading or the detailed object for accessing specific fields like
priorityorassignee. - Test with All Events First: When setting up a new webhook, you might leave the Events input empty to catch all data types. Once you verify it works, go back and select specific events to optimize performance.
Security Considerations
- Credential Management: Ensure your Jira API Token is kept secret. Do not share your credential file or screenshot the credential settings in public forums.
- Webhook Endpoint: The underlying system handles the security of the connection. However, ensure your Jira Cloud instance is configured to send webhooks only to your trusted Nappai endpoint.