# Jira

## Overview

Purify allows you to create Jira tickets.&#x20;

In addition, Purify will track changes in created tickets, and if tickets will be resolved, Purify will also close them.&#x20;

## Configuration

First, you need to get Atlassian API token. Go [here](https://id.atlassian.com/manage/api-tokens) to create them.

Second, do the following:

```bash
http POST https://purifyhost/api/settings/jira \
    "apikey: your-api-token" \
    username="myemail@domain.com" \
    host="mycompany.atlassian.net" \
    api_key="xxxxxxx"
```

If there are no errors, then everything is fine.

## Action

In the issue view you can see pretty straightforward button:

![](https://88240658-files.gitbook.io/~/files/v0/b/gitbook-legacy-files/o/assets%2F-M3I4ZhftILe_kBZUamw%2F-M44q7TZKm5c27ThalCW%2F-M44tjw9wtJEr93A5xu6%2FScreenshot%202020-04-04%20at%2018.54.54.png?alt=media\&token=0ddd9968-4d5e-403c-86d3-f06e4388e23c)

If you click on it, Purify will convert the issue into Markdown and give you the ability to edit its content:

![Basic Markdown editor](https://88240658-files.gitbook.io/~/files/v0/b/gitbook-legacy-files/o/assets%2F-M3I4ZhftILe_kBZUamw%2F-M44q7TZKm5c27ThalCW%2F-M44xeUpjCh-G06LcL_D%2FScreenshot%202020-04-04%20at%2019.12.01.png?alt=media\&token=fd6e28fe-2dd2-4637-a215-f3de20ff4348)

{% hint style="warning" %}
Jira does not support markdown **\<details>** feature, so it will not the same as on the preview below. Consider refactoring it.
{% endhint %}

![](https://88240658-files.gitbook.io/~/files/v0/b/gitbook-legacy-files/o/assets%2F-M3I4ZhftILe_kBZUamw%2F-M44q7TZKm5c27ThalCW%2F-M44yWVVURoEchAZbR7J%2FScreenshot%202020-04-04%20at%2019.15.46.png?alt=media\&token=c880e4df-d8ca-4854-a744-1b2ea77c6103)

When you're done with refactoring, click on **Next** and complete ticket

{% hint style="warning" %}
Currently, when Purify creates a Jira ticket, it sets **Unassigned** as the assignee.
{% endhint %}

![](https://88240658-files.gitbook.io/~/files/v0/b/gitbook-legacy-files/o/assets%2F-M3I4ZhftILe_kBZUamw%2F-M44q7TZKm5c27ThalCW%2F-M44z_IIpoA3GNqU7vau%2FScreenshot%202020-04-04%20at%2019.19.52.png?alt=media\&token=3a795293-4312-416f-8568-0b8d56167d9e)

{% hint style="info" %}
Purify will convert markdown, into Jira compatible markdown, so your issue will look exactly like the preview.
{% endhint %}

## Extras

> In addition, Purify will track changes in created tickets, and if tickets will be resolved, Purify will also close them.&#x20;

When it happens, Purify will add the following comment to the issue:

![](https://88240658-files.gitbook.io/~/files/v0/b/gitbook-legacy-files/o/assets%2F-M3I4ZhftILe_kBZUamw%2F-M40ro9SltmpCkDFs-Qd%2F-M40s7rpj6TiAZw888Pq%2FScreenshot%202020-03-27%20at%2000.31.19.png?alt=media\&token=96792356-e325-4e63-a3d2-c50cab9a0fe7)
