Developer Portal for YouTrack and Hub Help

Operations with Specific IssueLink

This resource lets you read links of the issue.

Resource

/api/issues/{issueID}/links/{linkID}

Returned entity

IssueLink. For the description of the entity attributes, see Supported Fields section.

Supported methods

Represents issue links of a particular link type (for example, 'relates to').

Related Resources

Below you can find the list of resources that let you work with this entity.

Attributes

This table describes attributes of the IssueLink entity.

  • To receive an attribute in the response from the server, specify it explicitly in the fields request parameter.

  • To update an attribute, provide it in the body of a POST request.

Field

Type

Description

id

String

The ID of the issue link. Read-only.

direction

Enumeration

Link direction. Supported values are OUTWARD, INWARD, and BOTH. Read-only.

linkType

IssueLinkType

Link type. Read-only. Can be null.

issues

Array of Issues

List of issues that are linked with this type.

trimmedIssues

Array of Issues

The trimmed list of issues. This property can be used to avoid performance problems for issues that have many links. Use $topLinks and $skipLinks parameters to request a particular part of the whole list. Read-only.

Get the data for specific link of the issue.

Request syntax

GET /api/issues/{issueID}/links/{linkID}?{fields}

{linkID}

The database ID of the issue link.

Request parameters

Parameter

Type

Description

fields

String

A list of IssueLink attributes that should be returned in the response. If no field is specified, only the entityID is returned.

Sample request

https://example.youtrack.cloud/api/issues/2-33/links/80-2s?fields=id,direction,linkType(name,localizedName,sourceToTarget,targetToSource,directed,aggregation),issues(id,idReadable,summary)

Sample response body

{ "direction": "OUTWARD", "linkType": { "sourceToTarget": "is duplicated by", "directed": true, "aggregation": true, "targetToSource": "duplicates", "localizedName": null, "name": "Duplicate", "$type": "IssueLinkType" }, "issues": [ { "summary": "Issue from REST #1", "idReadable": "SP-42", "id": "2-47", "$type": "Issue" }, { "summary": "Sample for api/admin/projects/:id/issues endpoint", "idReadable": "RP-4", "id": "2-72", "$type": "Issue" } ], "id": "80-2s", "$type": "IssueLink" }
Last modified: 23 April 2024