By default, importing from other issue trackers to YouTrack is a per-project process, that is: You transfer all issues from a project to YouTrack at once. However, in some situations it can be useful to import a single issue, for example, from an internal YouTrack instance to a publicly available main tracker. We now provide you with a script allowing import issues from one YouTrack instance to another on per-issue basis.
Current implementation of the Python Client Library and scripts is compatible with YouTrack 3.x and 4.x REST API and Python 2.6. If you use YouTrack 2.x, please refer to YouTrack Release Downloads Archive for the YouTrack 2.x compatible versions of the library and scripts.
To import a single issue from one YouTrack instance to another:
- Download the latest version of YouTrack's Python Client Library and unzip it.
- Ensure that Python is installed in your system.
- Execute the following command:
The following command-line parameters should be provided:Parameter Description src_url An URL to the source YouTrack server you want to import issues from. src_login Username to log in to the source YouTrack server. src_password Password to log in to the source YouTrack server. trg_url An URL to a target YouTrack server you want to import issues to. trg_login Username to log into the target YouTrack server. trg_password Password to log in to the source YouTrack server. src_issueId An issueID for the issue you want to import to the target YouTrack instance. trg_projectId projectID of a project in a target YouTrack instance, you want to import the source issue to.
- A user account you use to log in to source YouTrack server should have enough permissions to read issues and all their attributes including custom fields for the project to be imported. A user account you use to log into target YouTrack server should have enough permissions to create new user accounts, and new issues in the specified target project.
- When a user account is imported, it will be created with the new randomly generated password. That is, when a user logs into the target YouTrack server with his username from the source server, on the Login page he should type his username and then use the Send password restore E-mail link to restore the password.
- Only those custom fields that are used in the target project will be imported from the source YouTrack server.