---
title: "YouTrack"
description: "Connect YouTrack with a permanent token so Baz reviews each pull request against its issue."
canonical: "https://baz.ai/docs/integrations/ticketing/youtrack"
---

# YouTrack

Connect YouTrack with a permanent token so Baz reviews each pull request against its issue.

Connect YouTrack to give Baz the intent behind a change. When a pull request references a YouTrack issue, Baz fetches it and passes its title, description, state and comments to the review agents and the Verification Agent.

## Connect YouTrack

<Steps>
  <Step title="Create a permanent token">
    In YouTrack, create a permanent access token for an account that can read your projects. Give it the `YouTrack` scope.
  </Step>
  <Step title="Open the YouTrack integration">
    In Baz, go to **Settings → Integrations**, select **Ticketing System**, then **YouTrack**, and select **Configure**.
  </Step>
  <Step title="Enter the token and domain">
    In **Add YouTrack Integration**, paste the token into **Permanent Access Token** (it starts with `perm:`) and enter your **Domain** as an HTTPS URL, for example `https://yourcompany.youtrack.cloud`. Select **Add Integration**.
  </Step>
</Steps>

## Link a pull request to an issue

Baz looks for an issue ID that starts with one of your YouTrack project short names, such as `PROJ-123`, in the pull request title or source branch.

## Troubleshooting

<Accordion>
  <AccordionItem title="Validation error when saving">
    Both fields are required, and the domain must be a valid HTTPS URL.
  </AccordionItem>
  <AccordionItem title="No ticket context on my pull request">
    Confirm the issue ID uses a project short name the token can read.
  </AccordionItem>
</Accordion>

## Related

<CardGroup cols={2}>
  <Card title="Verification Agent" href="/docs/agents/deploy/verification-agent" icon="check-check">
    Checks each change against the issue's requirements.
  </Card>
  <Card title="Integrations" href="/docs/integrations" icon="plug">
    Every integration and what it adds.
  </Card>
</CardGroup>
