---
title: "Jira Service Desk"
canonical: "https://docs.getxporter.app/space/XPORTER/1409355/Jira%20Service%20Desk"
format: markdown
---
> Macro (rw-ui-expands-macro)
> 
> > Macro (rw-expand)
> 
> > Macro (toc)

## Introduction

[Xporter for Jira](https://marketplace.atlassian.com/apps/891368/xporter-export-issues-from-jira?tab=installation&hosting=datacenter) is now available on the [Jira Service Desk (JSD) Customer Portal](https://developer.atlassian.com/cloud/jira/service-desk/customer-portal/), which allows you to export a [Template](https://docs.getxporter.app/space/XPORTER/1409467) from it.

Prerequisites:

- [Jira Service Desk 3.2.0](https://confluence.atlassian.com/servicemanagement/jira-service-desk-documentation-408453917.html)
- Xporter 5.0.0

> ℹ️ Before you can export in the JSD Customer Portal using the Export menu, [configure the Xporter app first](https://docs.getxporter.app/space/XPORTER/20054584/Getting+Started).


Usage

### Integration Configuration

#### Configuring [Global Settings](https://docs.getxporter.app/space/XPORTER/1409516)

> Macro (rw-ui-steps-macro)
> 
> > Macro (rw-step)
> 
> Go to the Integration page on the Jira Administration section, and check the Jira Service Desk section (Figure 1 - 1).
> 
> ![Figure 1 - Settings](media://c6348cb3-f0b3-402b-a6f0-2c2faa07c9ee)
> 
> > Macro (rw-step)
> 
> Enable Xporter on Ticket Detail (Figure 2 - 1).
> 
> ![Figure 2 - Enable Xporter](media://dd5b49fc-35b4-485f-97a1-590d37899b85)
> 
> > Macro (rw-step)
> 
> Enable Xporter on my Requests (Figure 3 - 1).
> 
> ![Figure 3 - Requests](media://31e0b0af-c3cf-46b4-b153-fcb4f34f6f09)
> 
> > Macro (rw-step)
> 
> Enable Xporter on Jira Service Desk Queues (Figure 4 - 1).
> 
> ![Figure 4 - Enable Xporter](media://3e6c0cb7-1286-4e70-a9d8-232b6c174b70)

### Template Configuration

> Macro (rw-ui-steps-macro)
> 
> > Macro (rw-step)
> 
> [Add a Template](https://docs.getxporter.app/space/XPORTER/1409467/Templates) with the Jira Service Desk scope (Figure 5).
> 
> ![Figure 5 - Scope](media://8b0a46e6-ab2b-4742-8f9b-c28cd124e7e6)
> 
> > Macro (rw-step)
> 
> Please note that Xporter has two different scopes for Jira Service Desk:
> 
> - **JSD Request Detail**: Allows you to use the current template on the Service Desk request details (Figure 2).
> 
> - **JSD Request List**: Xporter allows you to use the current template on the Service Desk customer portal where all the requests are listed (Figure 3). Furthermore, Xporter also will be available on the approvals list (Figure 6).
> 
> ![Figure 6 - Approvals](media://4bf6ea1f-63f5-46fe-9252-edfb67020cb5)

### Permissions

[Permission Schemes](https://docs.getxporter.app/space/XPORTER/1409475/Permission+Schemes) allow administrators to define which Projects, Issue Types, User Roles, and Groups will be available to use Xporter, as well as manage the templates allowed to be used in each of those available Issue Types.

> Macro (rw-ui-steps-macro)
> 
> > Macro (rw-step)
> 
> On your Jira Data Center instance, [access Permission Schemes](https://docs.getxporter.app/space/XPORTER/1409475/Permission+Schemes#Access).
> 
> > Macro (rw-step)
> 
> On the desired Permission Scheme, click the gear icon (Figure 7 - 1) and then *Permissions* (Figure 7 - 2). A new screen will appear (Figure 8).
> 
> ![Figure 7 - Permissions](media://0191202b-7b0d-4b2c-b187-59c94cc3c7d8)
> 
> > Macro (rw-step)
> 
> Click the *Assign* button (Figure 8 - 1), next to *Roles allowed to use Xporter*. A modal will open (Figure 9).
> 
> ![Figure 8 - Roles](media://383113ae-88dd-498c-beab-ca9d594fe833)
> 
> > Macro (rw-step)
> 
> Select the *Service Desk Customers* option (Figure 9 - 1) and click *Assign* (Figure 9 - 2).
> 
> ![Figure 9 - Assign roles](media://fc143cf3-79b4-4f6e-a13b-c640d0135a8b)
> 
> > Macro (rw-step)
> 
> Return to the Permissions screen (Figure 10) and click the *Assign* button (Figure 8 - 2). A modal will open (Figure 10).
> 
> ![Figure 10 - Assign groups](media://5a444837-c07c-4400-bf4e-92fe31099baf)
> 
> > Macro (rw-step)
> 
> Select the *jira-servicedesk-users* option (Figure 10 - 1) and click *Assign* (Figure 10 - 2).

### Customer Portal

If you have access to the customer portal for a particular issue, you will be able to export the document.

![Figure 11 - Customer Portal](media://f3efa83e-9e8f-4e7a-a6db-ed607e3b9a8e)

### Getting the Value of the Service-Level Agreement (SLA)

You can extract the time of SLA data from the JSD.

#### Definition

Let's imagine that the SLA is the Time to Resolution custom field. The definition is: `${Time to Resolution}`

To export with friendly value, you must use the word "Formatted": `${Time to Resolution Formatted}`

No special configuration is required. The time is exported in milliseconds.

#### Example

Below there's the **Time to first response** and **Time to resolution** (Figure 12 and 13).

![Figure 12 - Time to first response](media://27e0a8ca-ca36-4155-b3a4-4354dd072e41)

![Figure 13 - Example](media://513138ae-e5b7-4351-8a27-79e8a16d7347)

This translates to a Word document template as resolved by Xporter for Jira (Figure 14):

![Figure 14 - Template](media://d214d521-0f02-489c-9212-2a6fda496354)

Furthermore, you are able to export more information related to SLA. Each SLA has information on when it started and stopped, and whether it breached the SLA goal. 

The notation is: `${<SLA custom field>.<Field>}`

| **SLA Fields** | **Description** |
| --- | --- |
| elapsedTime | The total time the SLA has been running |
| elaspedTime Formatted | The total time the SLA has been running formatted with friendly value |
| startTime | The date when the SLA started |
| stopTime | The date when the SLA stopped |
| goalDuration | The date with the SLA duration |
| goalDuration Formatted | The date with the SLA duration formatted with a friendly value |
| breached | Returns a boolean if the SLA is breached |
| paused | Returns a boolean if the SLA is paused |
| withinCalendarHours | Returns a boolean if the SLA is within calendar hours |

Let's imagine that the SLA is the *Time to Resolution* custom field:

```
Time to resolution: ${Time to resolution}
Time to resolution formatted: ${Time to resolution Formatted}
Elapsed Time: ${Time to resolution.elapsedTime}
Elapsed Time Formatted: ${Time to resolution.elapsedTime Formatted}
Start Time: ${Time to resolution.startTime}
Start Time Formatted: ${dateformat("yyyy-MM-dd"):Time to resolution.startTime}
Stop time: ${Time to resolution.stopTime}
Stop Time Formatted: ${dateformat("yyyy-MM-dd"):Time to resolution.stopTime}
Goal Duration: ${Time to resolution.goalDuration Formatted}
Goal Duration Formatted: ${Time to resolution.goalDuration Formatted}
Paused: ${Time to resolution.paused}
Within Calendar Hours: ${Time to resolution.withinCalendarHours}
```

> ℹ️ The *${Time to resolution}* field will be responsible for returning the remaining time of the SLA custom field.

### Exporting Internal Comments

**Xporter V5.3.0** and higher allows you to export the internal value of a comment.

This can also be used to filter the internal comments.

#### Definition

`#{for comments}`

`${Comments[n].Internal}`

`#{end}`

#### How to Use to Filter Comments

To return only the Internal Comments:

`#{if (%{${Comments[n].Internal}})} or #{if (%{'${Comments[n].Internal}'.equals('true')})}`

To retrieve only the public comments:

`#{if (%{!${Comments[n].Internal}})} or #{if (%{'${Comments[n].Internal}'.equals('false')})}`

#### Example

`#{for comments}`

`#{if (%{${Comments[n].Internal}})}`

Author: `${Comments[n].Author}`

Body: `${Comments[n].Body}`

`#{end}`

### Exporting Jira Service Desk Approvals

<span style="color: #172B4D">The Jira Service Desk allows you to add an approval step to a status in a workflow, in case approval is needed for issue types (and their associated request types).</span>

Xporter for Jira allows the exporting of Jira Service Desk Approvals and the relevant information about the approval and the respective approvers.

As it is not known in advance how many approvals exist for an Issue, you can iterate a section over all the approvals of an Issue and all the approvers and respective decision. This allows you to create a table that dynamically grows according to the number of existing approvals. The notation is:

| <span style="color: #000000">**Approvals Fields**</span> | **Description** |
| --- | --- |
| Name | The name of the approval |
| Final Decision | The decision about the approval (Approved, Declined, or Pending) |
| Can Answer Approval | This field returns True or False to know if the approval was closed or if it's still pending |
| `Created Date` | The date the approval was posted |
| `Completed Date` | The date the approval was completed with all users' answers |

  
To extract more information from Approvals, it is possible to get information from the approvers and the decision of each one:  

| <span style="color: #000000">**Users Approvals Field**</span> | **Description** |
| --- | --- |
| Approver Name | This field returns the name of the approver |
| Email Address | This field returns the email address of the approver |
| Approver Decision | The response of the approver about the approval |

Here's an example of an Xporter for Jira template to get all the approvals of an issue and the information about each approver:

![Figure 15 - Template](media://96ed1182-f51a-47fc-91df-a9e6ffe21c45)

```
#{for approvals}
	${Approvals[n].Name} 
	${Approvals[n].Final Decision} 
	${Approvals[n].Can Answer Approval}
	${Approvals[n].Created Date}
	${Approvals[n].Completed Date}
	
	Here, we are going to list all approvers data.
	#{for m=Approvals[n].UsersApprovalsCount}
		${Approvals[n].UsersApprovals[m].Approver Name}
		${Approvals[n].UsersApprovals[m].Email Address}
		${Approvals[n].UsersApprovals[m].Approver Decision}
	#{end}
#{end}
 
or
 
#{for <VariableName>=ApprovalsCount}
   Content and Issue Mappings. Example: ${Approvals[VariableName].Field}
#{end}
```

### Exporting Jira Service Desk Request Type

Xporter for Jira allows exporting Jira Service Desk Request Type (request a new account, get IT Help, report a system problem, etc.).

| <span style="color: #000000">**Field**</span> | **Description** |
| --- | --- |
| Request type | This field returns the Request type |

### Exporting Jira Service Desk Customer Status

Xporter for Jira allows the exporting of Jira Service Desk Customer Status

| <span style="color: #000000">**Field**</span> | **Description** |
| --- | --- |
| Customer status | This field returns the Customer Status |

### Exporting Requests from an Organization

<span style="color: #172B4D">Xporter is available on JIRA Service Desk </span>**organizations **directly from the Customer Portal.

Organizations are groups of customers and customers can be members of multiple organizations.

After raising a request and sharing the request with the organization, the user will be able to view and search the organization's requests from the **My Requests** page in the portal (Figure 17).

Xporter will allow users to:

- **Export** shared requests with the organization.
- Organization members will be able to **export** the requests.
- <span style="color: #172B4D">Requests that are</span><span style="color: #172B4D"> </span>**<span style="color: #172B4D">shared</span>**<span style="color: #172B4D"> </span><span style="color: #172B4D">with customers who belong to the same</span><span style="color: #172B4D"> </span>**<span style="color: #172B4D">organization.</span>**

![Figure 16 - Requests](media://4cab9da5-e91a-4736-8ba2-27c77d64b8a6)

> ℹ️ - A user that belongs to an organization can only export issues that were created after the user was added to the organization.
> ℹ️ - The user can export the displayed issues only if he has an open ticket also listed.


<details>
<summary>Support/Troubleshooting</summary>

If you have questions or technical issues, please [contact the Support team via the Customer Portal (Jira service management)](https://jira.getxray.app/servicedesk/customer/portal/2/user/login?destination=portal%2F2%2Fcreate%2F28) or [send us a message using the in-app chat](https://docs.getxporter.app/space/XPORTER/23102936).
</details>