πŸ’¬ Build RAG-powered support agent for Jira issues using Pinecone and OpenAI

⚑ 477 views Β· πŸ’¬ Support Chatbots

Description

Load Jira open issues with comments into Pinecone + RAG Agent (Direct Tool or MCP)

Who’s it for

This workflow is designed for support teams, data engineers, and AI developers who want to centralize Jira issue data into a vector database.
It collects open issues and their associated comments, converts them into embeddings, and loads them into Pinecone for semantic search, retrieval-augmented generation (RAG), or AI-powered support bots.
It’s also published as an MCP tool, so external applications can query the indexed issues directly.

How it works

The workflow automates Jira issue extraction, comment processing, and vector storage in Pinecone. Importantly, the Pinecone index is recreated at every run so that it always reflects the current set of unresolved tickets.

  1. Trigger – A schedule trigger runs the workflow at defined times (e.g., 8, 11, 14, and 17 on weekdays).
  2. Issue extraction with pagination – Calls the Jira REST API to fetch open issues matching a JQL query (unresolved cases created in the last year).
    • Pagination is fully handled: issues are retrieved in batches of 25, and the workflow continues iterating until all open issues are loaded.
  3. Data transformation – Extracts key fields (issue ID, key, summary, description, product, customer, classification, status, registration date).
  4. Comments integration – Fetches all comments for each issue, filters out empty/irrelevant ones (images, dots, empty markdown), and merges them with the issue data.
  5. Text cleaning – Converts HTML descriptions into clean plain text for processing.
  6. Embedding generation – Uses the OpenAI Embeddings node to vectorize text.
  7. Vector storage with index recreation – Loads embeddings and metadata into Pinecone under the jira namespace and the openissues index. The namespace is cleared at every run to ensure the index contains only unresolved tickets.
  8. Document chunking – Splits long issue texts into smaller chunks (512 tokens, 50 overlap) for better embedding quality.
  9. MCP publishing – Exposes the Pinecone index as an MCP tool (openissues), enabling external systems to query Jira issues semantically.

How to set up

  1. Jira – Configure a Jira account and generate a token. Update the Jira node with credentials and adjust the JQL query if needed.
  2. OpenAI – Set up an OpenAI API key for embeddings. Configure embedding dimensions (default: 512).
  3. Pinecone – Create an index (e.g., openissues) with matching dimensions (512). Configure Pinecone API credentials and namespace (jira).
    • The index will be cleared automatically at every run before reloading unresolved issues.
  4. Schedule – Adjust the cron expression in the Schedule Trigger to fit your update frequency.
  5. Optional MCP – If you want to query Jira issues via MCP, configure the MCP trigger and tool nodes.

Requirements

How to customize the workflow


AI Chatbot for Jira open tickets with SLA insights

Who’s it for

This workflow is designed for commercial teams, customer support, and service managers who need quick, conversational access to unresolved Jira tickets.
It enables them to check whether a client has open issues, see related details, and understand SLA implications without manually browsing Jira.

How it works

Setup

  1. Configure Jira β†’ Pinecone index (openissues, 512 dimensions) already populated with unresolved tickets.
  2. Provide OpenAI API credentials.
  3. Ensure the SLA node includes the correct service-level definitions.
  4. Adjust chat branding (title, subtitle, CSS) if desired.

Requirements

How to customize

πŸ”— Nodes Used

HTTP Request, Schedule Trigger, AI Agent, Embeddings OpenAI, OpenAI Chat Model, Simple Memory

πŸ“₯ Import

Download workflow.json and import into n8n: Workflow menu β†’ Import from File

πŸ“– Importing guide Β· πŸ”‘ Credential setup