> For the complete documentation index, see [llms.txt](https://docs.octoxlabs.com/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.octoxlabs.com/adapters/j/jetbrains-users.md).

# JetBrains Users

JetBrains Users reads the user accounts of a YouTrack service. OctoXLabs adds them to the user inventory.

## Use cases

* **Find YouTrack users with no directory account.** How accounts are matched depends on your user merge settings.

```
Adapters = jetbrains-users AND NOT Adapters = active-directory
```

* **List YouTrack users by email domain.**

```
Adapters = jetbrains-users AND NOT Email ~ <your domain>
```

## Before you begin

### Network

| Source              | Destination                         | Port                                                           | Protocol                           |
| ------------------- | ----------------------------------- | -------------------------------------------------------------- | ---------------------------------- |
| OctoXLabs connector | YouTrack service (Domain parameter) | 443 (HTTPS) or 80 (HTTP), unless the Domain gives another port | HTTPS (HTTP when Is Secure is off) |

If a proxy is set, requests go through it.

### Required permissions

| Scope or role         | Permission | Needed for           |
| --------------------- | ---------- | -------------------- |
| Permanent token scope | YouTrack   | Calling `/api/users` |

The baseline says to include the **YouTrack** scope when you create the token. Which YouTrack role the token owner needs is not stated.

## Create credentials in YouTrack

{% stepper %}
{% step %}

### Open your profile

From the main menu, select your avatar and open **Profile**.
{% endstep %}

{% step %}

### Open Account Security

Select the **Account Security** tab.
{% endstep %}

{% step %}

### Create a token

In the **Tokens** section, click **New token**. Enter a name, select the access scope (include **YouTrack**) and click **Create token**.
{% endstep %}

{% step %}

### Copy the token

Click **Copy token** and store it securely. It is shown only once.
{% endstep %}
{% endstepper %}

## Connection parameters

| Parameter | Required | Type    | Default | Description                                                                                                                                                       |
| --------- | -------- | ------- | ------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| Domain    | Yes      | String  | None    | YouTrack service address without the scheme. Include the context path if the server uses one, for example `www.example.com/youtrack` or `company.youtrack.cloud`. |
| API Token | Yes      | String  | None    | Permanent token.                                                                                                                                                  |
| Is Secure | No       | Boolean | True    | Use HTTPS.                                                                                                                                                        |
| Proxy     | No       | String  | None    | Proxy address, used as `http://<value>` for HTTP and HTTPS.                                                                                                       |
| Timeout   | No       | Integer | 30      | Seconds to wait for an API response.                                                                                                                              |

## Troubleshooting

| Error message                  | Cause                       | Fix                        |
| ------------------------------ | --------------------------- | -------------------------- |
| Max retries exceeded for {url} | The API kept answering 429. | Run discovery again later. |

## Change history

{% hint style="info" %}
Available starting from version 6.7.2.
{% endhint %}
