How to export issues from Jira Server plugin to Excel or Pdf?

I want to create a plugin which can export issues from Jira Server to excel or pdf. I am using the Issue interface for fetching the details of issues.(Issue (Atlassian JIRA 7.1.4 API))

How can I export the results obtained from it in excel or pdf ?

Hi Shubhangi,

Threre is a Jira plugin which provides simple API to export Jira data to excel file: Java/Groovy API - Better Excel Exporter for Jira | Midori
I believe it’s one of the simplest way to create excel file.

If you don’t want to use other plugin you can export on your own with apache poi library https://poi.apache.org/
You have to add new dependency into your project

<dependency>
    <groupId>org.apache.poi</groupId>
    <artifactId>poi-ooxml</artifactId>
</dependency>

and follow tutorial How to Write Excel Files in Java using Apache POI

Hopefully it will help you.
Josef Pavelec, Morosystems