Requirement link type mappings
This chapter focuses on requirement link type mappings.
Get requirement link type mapping
A GET
to /projects/{projectId}/requirement-link-type-mappings/{id}
returns the requirement link type mapping for the requirement link type with the given id.
Path parameters
Parameter | Description |
---|---|
|
the id of the project |
|
the id of the requirement link type |
HTTP request
GET /api/rest/latest/projects/31/requirement-link-type-mappings/4 HTTP/1.1
Accept: application/json
Host: localhost:8080
HTTP response
HTTP/1.1 200 OK
Content-Type: application/json
Content-Length: 273
{
"_type" : "requirement-link-type-mapping",
"id" : 4,
"squash_field" : "Blocked by",
"jira_field" : "Issue is blocked by",
"_links" : {
"self" : {
"href" : "http://localhost:8080/api/rest/latest/projects/31/requirement-link-type-mappings/4"
}
}
}
Response fields
Path | Type | Description |
---|---|---|
|
|
the type of the entity |
|
|
id of the requirement link type |
|
|
the name of the requirement link type in squash |
|
|
the name of the requirement link type in jira |
|
|
related links |
Links
Relation | Description |
---|---|
|
link to this requirement link type mapping |
Get all requirement link type mappings
A GET
to /projects/{id}/requirement-link-type-mappings
returns all the requirement link type mappings for the given project.
HTTP request
GET /api/rest/latest/projects/7/requirement-link-type-mappings HTTP/1.1
Accept: application/json
Host: localhost:8080
HTTP response
HTTP/1.1 200 OK
Content-Type: application/json
Content-Length: 1225
{
"_embedded" : {
"requirement-link-type-mappings" : [ {
"_type" : "requirement-link-type-mapping",
"id" : 1,
"squash_field" : "Related",
"jira_field" : "Issue related to",
"_links" : {
"self" : {
"href" : "http://localhost:8080/api/rest/latest/projects/7/requirement-link-type-mappings/1"
}
}
}, {
"_type" : "requirement-link-type-mapping",
"id" : 2,
"squash_field" : "Parent",
"jira_field" : "Issue parent of",
"_links" : {
"self" : {
"href" : "http://localhost:8080/api/rest/latest/projects/7/requirement-link-type-mappings/2"
}
}
}, {
"_type" : "requirement-link-type-mapping",
"id" : 3,
"squash_field" : "Blocked",
"jira_field" : "Issue blocked by",
"_links" : {
"self" : {
"href" : "http://localhost:8080/api/rest/latest/projects/7/requirement-link-type-mappings/3"
}
}
} ]
},
"_links" : {
"self" : {
"href" : "http://localhost:8080/api/rest/latest/projects/7/requirement-link-type-mappings"
}
},
"page" : {
"size" : 3,
"totalElements" : 3,
"totalPages" : 1,
"number" : 0
}
}
Response fields
Path | Type | Description |
---|---|---|
|
|
the list of elements for that page |
|
|
the page size for that query |
|
|
total number of elements the client is allowed to read |
|
|
how many pages can be browsed |
|
|
the page number |
|
|
related links |
Links
Relation | Description |
---|---|
|
link to the first page (optional) |
|
link to the previous page (optional) |
|
link to this page |
|
link to the next page (optional) |
|
link to the last page (optional) |
Modify requirement link type mapping
A PATCH
to /projects/{projectId}/requirement-link-type-mappings/{id}
modifies the requirement link type mapping for the requirement link type with the given id.
Path parameters
Parameter | Description |
---|---|
|
the id of the project |
|
the id of the requirement link type in squash |
HTTP request
PATCH /api/rest/latest/projects/5/requirement-link-type-mappings/2 HTTP/1.1
Content-Type: application/json
Accept: application/json
Content-Length: 83
Host: localhost:8080
{
"_type" : "requirement-link-type-mapping",
"jira_field" : "Issue parent of"
}
HTTP response
HTTP/1.1 200 OK
Content-Type: application/json
Content-Length: 267
{
"_type" : "requirement-link-type-mapping",
"id" : 2,
"squash_field" : "Parent of",
"jira_field" : "Issue parent of",
"_links" : {
"self" : {
"href" : "http://localhost:8080/api/rest/latest/projects/5/requirement-link-type-mappings/2"
}
}
}
Response fields
Path | Type | Description |
---|---|---|
|
|
the type of the entity |
|
|
the id of the requirement link type in squash |
|
|
the name of the requirement link type in squash |
|
|
the name of the requirement link type in jira |
|
|
related links |
Links
Relation | Description |
---|---|
|
link to this requirement link type mapping |