# JIRA server (self-hosted)

### How to setup JIRA server?

To setup, we need 3 things -

1. Base URL - the url where your server is currently hosted such as `jira.mydomain.com`
2. Client ID
3. Client Secret

We will need to generate Client ID and Client Secret. Let's get started

1. On your JIRA server, go to **settings -> applications**
2. Click on **Application Links**
3. and then click **Create Link**

<figure><img src="https://1743514643-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F-Ln3jS1bJTTsE3yoEcOu%2Fuploads%2Fgit-blob-82b728df9a57b6ca6d90a3e3a1f9b5714a456735%2Fimage.png?alt=media" alt=""><figcaption></figcaption></figure>

4. On the modal for Create Link, select **External application** and I**ncoming**

<figure><img src="https://1743514643-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F-Ln3jS1bJTTsE3yoEcOu%2Fuploads%2Fgit-blob-d13355a3959642e87910ae68393a757b0fe7cca5%2Fjira-server-spike-2.png?alt=media" alt=""><figcaption></figcaption></figure>

5. On the next page, in the details, make sure to
   1. add a name i.e. **Spike.sh**
   2. this callback url -> `https://app.spike.sh/task-management/jira/self-hosted/auth/callback`
   3. Select **Write permission**
   4. **Hit save**

<figure><img src="https://1743514643-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F-Ln3jS1bJTTsE3yoEcOu%2Fuploads%2Fgit-blob-44a2c0d317ee99fa2179d261692e42abd9bd5e23%2Fjira-server-integration-form.png?alt=media" alt=""><figcaption></figcaption></figure>

6. This will generate you Client Id and Client Secret. Copy these.
7. Your Base URL is the subdomain or domain where JIRA is hosted. In our case, it's `https://jira.spike.sh` with no trailing forward slashes.

<figure><img src="https://1743514643-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F-Ln3jS1bJTTsE3yoEcOu%2Fuploads%2Fgit-blob-f2594fbe4aeb8c6a8478f05c3a2fa29d91d6e8bf%2Fjira-integration-final-step.png?alt=media" alt=""><figcaption></figcaption></figure>

So far, we have prepped our JIRA server to accept requests from Spike.sh. In the next step, let's configure Spike.sh.

### How to configure setup for final connection?

Visit the Task management section under [Settings > Organisation](https://app.spike.sh/settings/general/organisation#org--task-management) and select JIRA server. Enter the Base URL, Client ID, and Client Secret and hit Connect.

<figure><img src="https://1743514643-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F-Ln3jS1bJTTsE3yoEcOu%2Fuploads%2Fgit-blob-514fb64e15d3cb70128e4d652d29c28cfdf1d905%2Fimage%20(1).png?alt=media" alt=""><figcaption></figcaption></figure>

This will take you to your JIRA setup for validation. It's all done once permissions are granted on the next step.
