YouTrack Integration with n8n
YouTrack integrates with n8n workflow automation software using the Webhook Triggers app. This setup lets you start automated workflows in n8n when events occur in YouTrack and perform YouTrack operations from n8n workflows.
Integration Overview
The integration consists of two parts:
The Webhook Triggers app in YouTrack sends event notifications.
The YouTrack integration in n8n receives events notifications and performs API operations.
When an event occurs in YouTrack, the Webhook Triggers app sends a POST request to an n8n webhook endpoint. The n8n workflow then processes the event and can perform additional actions.
Prerequisites
Access to a YouTrack instance
Administrative permission to manage YouTrack apps
Access to an n8n instance
Permission to create workflows and credentials in n8n
Set Up the Webhook Triggers App in YouTrack
For information on how to set up the Webhook Triggers app, see Webhook Triggers.
This is a two-part installation:
In administration settings for YouTrack apps, select the YouTrack projects for the app.
In project settings for apps, add your generated webhook token, HTTP header, and the webhook URLs from n8n.
Webhook URLs are found in n8n after setting up the YouTrack integration.
Set Up n8n with YouTrack Integration Credentials
Install and configure n8n with YouTrack API and webhook credentials so workflows can securely connect to and interact with your YouTrack instance.
Install the YouTrack Integration in n8n
Install the YouTrack integration in n8n using the Community Nodes feature.
To install the YouTrack integration in n8n:
Open n8n and select Settings from the navigation menu.
Select Community nodes.
Click Install a community node and enter
n8n-nodes-youtrack.Click Install.
For more information, see n8n documentation for installing community nodes.
Create a Permanent Token in YouTrack for API Authentication
Generate a permanent YouTrack API token to enable authenticated access for integrations and automation.
To create a permanent token for API authentication:
Log in to YouTrack.
From the main navigation menu, click your user icon and select Profile.
Open the Account Security tab and click the New Token button.
Enter a name for the token, select the token scope, and click Create.
Copy or save the token in a safe location as it cannot be accessed again.
For more information, see Manage Permanent Tokens.
Configure Credentials in n8n
Credentials to store in n8n:
A YouTrack permanent token used to authenticate connections to your YouTrack instance through the REST API.
A webhook token added as a header parameter.
To add YouTrack permanent token credentials in n8n:
Open n8n to the Overview homepage.
Open the Credentials tab and click Create credential.
Select YouTrack API.
Click Continue.
Enter the YouTrack URL for your YouTrack instance.
Example:
https://your-instance.youtrack.cloudfor YouTrack Cloud instances.Enter the base URL without
/apiat the end
Enter your Permanent Token that you created in YouTrack in the procedure above.
Click Save.
To configure webhook token credentials in n8n:
Open n8n to the Overview homepage.
Open the Credentials tab and click Create credential.
Select YouTrack Webhook Trigger App API.
Click Continue.
Select Header Auth for the authentication method.
Enter your header name.
The header name is configurable (default X-YouTrack-Token).
The header name must match the header value in the Webhook Triggers app.
Enter your webhook token that you created for the Webhook Triggers app in the Webhook Token field.
To learn more about creating a webhook token, see Webhook Triggers Configuration.
Click Save.
Add a YouTrack Trigger to an n8n Workflow
In n8n, a trigger workflow is a workflow that starts automatically when a specific event happens. You can set up trigger workflows from YouTrack trigger events.
To add YouTrack trigger nodes to an n8n workflow:
Open n8n and click Create workflow or open an existing workflow.
Add a YouTrack trigger node to the workflow.
In n8n's Search nodes... field, enter YouTrack for a full list of YouTrack trigger nodes.
After selecting a YouTrack trigger, the trigger node Parameters are displayed.
Copy the Webhook URL and paste it into the corresponding trigger field in the YouTrack Webhook Triggers app.
Select your permanent YouTrack token for the Credentials to Connect to YouTrack field.
Select your webhook token for the Authenticate Incoming Webhook field.
Supported YouTrack Events
The integration supports the following YouTrack events:
Issue: created, updated, and deleted
Comment: added, updated, and deleted
Work item: added, updated, and deleted
Attachment: added and deleted
Using YouTrack Actions in n8n
In addition to triggers, the YouTrack integration provides nodes for performing actions using the YouTrack REST API.
These actions include creating and updating issues, executing commands, managing comments, work items, tags, projects, and users.
API operations use the permissions of the user associated with the permanent token.
Security Considerations
Use HTTPS for all webhook URLs.
Keep your tokens secure and rotate them periodically.
Troubleshooting
If you experience problems using the Webhook Triggers app, see if any of the following conditions apply.
Condition — 401/403 unauthorized or refused authentication error.
Cause | Solution |
|---|---|
YouTrack is unable to authenticate because either the header name or the token is incorrect. |
|
Condition — A webhook is not triggering.
Cause | Solution |
|---|---|
The webhook request is not sent when the configured event occurs in YouTrack. |
|
Condition — Multiple webhook URLs are not firing.
Cause | Solution |
|---|---|
One or more webhook URLs that have been entered in the Webhook Triggers app are incorrect or formatted incorrectly. |
|