Contents

Add Related Issue

Adds a related issue to the issue. targetIssueId must be an issue the requesting user can view. Up to 50 related issues can be added per issue. If the issue is already related, or the target issue is the same as the issue, no error is returned and the current issue information is returned as is.

Role

Administrator
Normal User
Reporter
Guest Reporter

Method

POST

URL

/api/v2/issues/:issueIdOrKey/relatedIssues

URL parameters

Parameter NameTypeDescription
issueIdOrKeyStringIssue ID or Issue key

Form parameters

Content-Type:application/x-www-form-urlencoded
Parameter NameTypeDescription
targetIssueId (Required)NumberID of the issue to relate

Response example

Status Line / Response Header

HTTP/1.1 200 OK
Content-Type:application/json;charset=utf-8

Response Body

{
    "id": 2,
    "projectId": 1,
    "issueKey": "BLG-2",
    "keyId": 2,
    "issueType": {
        "id": 2,
        "projectId": 1,
        "name": "Task",
        "color": "#7ea800",
        "displayOrder": 0
    },
    "summary": "second issue",
    "description": "",
    "resolution": null,
    "priority": {
        "id": 3,
        "name": "Normal"
    },
    "status": {
        "id": 1,
        "projectId": 1,
        "name": "Open",
        "color": "#ed8077",
        "displayOrder": 1000
    },
    "assignee": {
        "id": 2,
        "userId": "eguchi",
        "name": "eguchi",
        "roleType": 2,
        "lang": null,
        "nulabAccount": {
            "nulabId": "tSaVeJfRxLURSAkgfbNAfCbM7PqddYLJ3nG3BELjx6eSTbu8LD",
            "name": "eguchi",
            "uniqueId": "eguchi"
        },
        "mailAddress": "eguchi@nulab.example",
        "lastLoginTime": "2022-09-01T06:35:39Z"
    },
    "category": [],
    "versions": [],
    "milestone": [],
    "startDate": null,
    "dueDate": null,
    "estimatedHours": null,
    "actualHours": null,
    "parentIssueId": null,
    "createdUser": {
        "id": 1,
        "userId": "admin",
        "name": "admin",
        "roleType": 1,
        "lang": "ja",
        "nulabAccount": {
            "nulabId": "Prm9ZD9DQD5snNWcSYSwZiQoA9WFBUEa2ySznrSnSQRhdC2X8G",
            "name": "admin",
            "uniqueId": "admin"
        },
        "mailAddress": "eguchi@nulab.example",
        "lastLoginTime": "2022-09-01T06:35:39Z"
    },
    "created": "2012-07-23T06:10:15Z",
    "updatedUser": {
        "id": 1,
        "userId": "admin",
        "name": "admin",
        "roleType": 1,
        "lang": "ja",
        "nulabAccount": {
            "nulabId": "Prm9ZD9DQD5snNWcSYSwZiQoA9WFBUEa2ySznrSnSQRhdC2X8G",
            "name": "admin",
            "uniqueId": "admin"
        },
        "mailAddress": "eguchi@nulab.example",
        "lastLoginTime": "2022-09-01T06:35:39Z"
    },
    "updated": "2012-07-23T06:10:15Z",
    "customFields": [],
    "attachments": [],
    "sharedFiles": [],
    "externalFileLinks": [],
    "stars": [],
    "type": "RELATES"
}