/
REST API: Coverage

DATA CENTER AND SERVER | CLOUD

REST API: Coverage

 



REST API: Coverage#columnFilterJsonObject

Construct definition

POST

com.easesolutions.jira.plugins.coverage/1.0/data

Evaluates coverage data for view

GET

com.easesolutions.jira.plugins.coverage/1.0/displayFields

Get display fields available for coverage view

 

POST

com.easesolutions.jira.plugins.requirements/1.0/coverage/prjKey/createcoverageview

Trigger the creation of a coverage view (old implementation)

POST

com.easesolutions.jira.plugins.coverage/1.0/filter/saveFilter

Trigger the creation of a coverage view

PUT

com.easesolutions.jira.plugins.coverage/1.0/filter/renameFilter

Rename coverage view filter

PUT

com.easesolutions.jira.plugins.coverage/1.0/filter/updateFilter

Update coverage view filter columns

DELETE

com.easesolutions.jira.plugins.coverage/1.0/filter/deleteFilter

Delete coverage view filter

GET

com.easesolutions.jira.plugins.coverage/1.0/filter/getAllFilters

Get all public and personal coverage filters for application user

GET

com.easesolutions.jira.plugins.coverage/1.0/filter/getFilter

Get data for a specific coverage view filter

GET

com.easesolutions.jira.plugins.coverage/1.0/filter/getFilters

Get public and personal coverage filters for project

 

POST

com.easesolutions.jira.plugins.coverage/1.0/export/excel

Export the coverage view to an excel file

POST

com.easesolutions.jira.plugins.coverage/1.0/export/xml

Export the coverage view to an xml file

 

Definition of Request Data for columnFilterJsonObject

Defines possible JSON keys construct for columnFilterJsonObject.

columnFilterJsonObject

{ "columns":[ { "label":"Level 1", "jiraJql":"", "jiraFilterId":"", "linkTypes":[ { "id":"-1", "directions":{ "in":true, "out":true } } ], "currentIssueTypes":[ "-1" ], "projects":[ "10005,SP,Scrum Project" ], "fromLevel":-1 } ], "fields":[], "folderIssueKeys":[], "filterId":0, "folderId":0, "folderName":"", "projectId":10005, "fromColumn":0 }

 

columns - an array of objects compose of name, type ("filter", "jql", or "issue types"), filter, and link types that define each column

fields - an array of display field ids present in coverage view issue cells (if any)

folderIssueKeys - an array of of issue keys used to filter the column (if any)

filterId - Jira filter id used to filter column

folderId - project tree folder id; used to filter the column by only issues that belong to a certain project tree folder

folderName - name of project tree folder used as filter (if any)

projectId - the project id that the coverage view is under

fromColumn - index of column basis

com.easesolutions.jira.plugins.requirements/1.0/coverage/prjKey/createcoverageview

Trigger the creation of a coverage view

REQUEST
POST

/rest/com.easesolutions.jira.plugins.requirements/1.0/coverage/prjKey/createcoverageview?name&isPublic&columns

PARAMETERS

parameter

type

description

parameter

type

description

prjKey*

string

the project the view to be created

name

string

the name of the view

isPublic

boolean

the visibility of the view

columns

string

an array of objects compose of name, type ("filter", "jql", or "issue types"), filter, and link types

example:

[
{"name": "Column 1","type": "jql","filter": "issuetype in (bug, improvement)","linkTypes": []},
{"name": "Column 2","type": "filter","filter": "10000": ["relates to","trace to","duplicates"]},
{"name": "Column 2","type": "issue types","filter": ["task", "bug"],"linkTypes": []}
]

fieldsToDisplay

string

an array of field names (Note: name is case sensitive)

folderId

long

the tree folder id (Optional)

 


RESPONSES

STATUS 200 - Returned if a coverage view is created

Example Response JSON
View name has been successfully created

STATUS 400 - Returned if the project is invalid, name is invalid or already exist, columns is invalid or contains invalid values, or an error occurs while creating the coverage view

STATUS 401 - Returned if invalid user credentials, or the user has no permission to use Requirements for JIRA plugin

STATUS 403 - Returned if the license is invalid or has expired, incompatible JIRA version, the project is not configured for Requirements for JIRA, or no permission to create coverage view

STATUS 404 - Returned if project is not found

com.easesolutions.jira.plugins.coverage/1.0/filter/saveFilter

Trigger the creation of a coverage view

REQUEST
POST

/rest/com.easesolutions.jira.plugins.coverage/1.0/filter/saveFilter



Example Request JSON
{ "projectId": 10000, "isPublic": true, "name": "Coverage View", "addedFieldsJsonArray": ["issuetype","issuekey","status","priority","summary"], "columnFilterJsonObject": {<this object is defined elsewhere>} } Definition: projectId - the project the view to be created isPublic - the visibility of the view name - the name of the view addedFieldsJsonArray - an array of field names columnFilterJsonObject - an object containing column data relevant to the coverage view




RESPONSES

STATUS 200 - Returned if a coverage view is created

Example Response JSON
{ "id": 1, "name": "Coverage View" }

STATUS 400 - Returned if the project is invalid, name is invalid or already exist, columns is invalid or contains invalid values, or an error occurs while creating the coverage view

STATUS 401 - Returned if invalid user credentials, or the user has no permission to use Requirements for JIRA plugin

STATUS 403 - Returned if the license is invalid or has expired, incompatible JIRA version, the project is not configured for Requirements for JIRA, or no permission to create coverage view

STATUS 404 - Returned if project is not found

com.easesolutions.jira.plugins.coverage/1.0/data

Evaluates coverage data for view

REQUEST
POST

com.easesolutions.jira.plugins.coverage/1.0/data



Example Request JSON
{ "columns": [{ "label": "Level 1", "jiraJql": "", "jiraFilterId": "", "linkTypes": [{"id": "-1","directions": {"in": true,"out": true}}], "currentIssueTypes": ["-1"], "projects": ["10000,DEMO,DEMO"], "fromLevel": -1 }], "fields": [], "folderIssueKeys": [], "filterId": 0, "folderId": 0, "folderName": "", "projectId": 10000, "fromColumn": 0, "isFiltered": false }




RESPONSES

STATUS 201 - Returned if data successfully parsed

Example Response JSON
{ "headerList":[ { "label":"Level 1", "issueTypes":"<any>", "linkTypes":"<any>", "fromLevel":-1, "projects":"DEMO (DEMO)", "columnTotal":5 } ], "columns":{ "0":[ { "issues":[{...}], "pathid":"" } ] }, "fromColumn":0, "maxLimit":1000 }

STATUS 400 - Returned if the project is invalid, name is invalid or already exist, columns is invalid or contains invalid values, or an error occurs while creating the coverage view

STATUS 401 - Returned if invalid user credentials, or the user has no permission to use Requirements for JIRA plugin

STATUS 403 - Returned if the license is invalid or has expired, incompatible JIRA version, the project is not configured for Requirements for JIRA, or no permission to create coverage view

STATUS 404 - Returned if project is not found

com.easesolutions.jira.plugins.coverage/1.0/displayFields

Get display fields for coverage view

REQUEST
POST

com.easesolutions.jira.plugins.coverage/1.0/displayFields




RESPONSES

STATUS 201 - Returned if successful

Example Response JSON
[ { "id": "issuetype", "name": "Issue Type", "selected": true }, .... ]

STATUS 400 - Returned if the project is invalid, name is invalid or already exist, columns is invalid or contains invalid values, or an error occurs while creating the coverage view

STATUS 401 - Returned if invalid user credentials, or the user has no permission to use Requirements for JIRA plugin

STATUS 403 - Returned if the license is invalid or has expired, incompatible JIRA version, the project is not configured for Requirements for JIRA, or no permission to create coverage view

STATUS 404 - Returned if project is not found

com.easesolutions.jira.plugins.coverage/1.0/filter/renameFilter

Rename coverage filter

REQUEST
POST

com.easesolutions.jira.plugins.coverage/1.0/filter/renameFilter



Example Request JSON
{ "projectId": 10000, "name": "Filter C", "isPublic": false, "filterId": "3" }




RESPONSES

STATUS 200 - Returned if successful rename

Example Response JSON
{ "id": "3", "name": "Filter C" }

STATUS 400 - Returned if the project is invalid, name is invalid or already exist, columns is invalid or contains invalid values, or an error occurs while creating the coverage view

STATUS 401 - Returned if invalid user credentials, or the user has no permission to use Requirements for JIRA plugin

STATUS 403 - Returned if the license is invalid or has expired, incompatible JIRA version, the project is not configured for Requirements for JIRA, or no permission to create coverage view

STATUS 404 - Returned if project is not found

com.easesolutions.jira.plugins.coverage/1.0/filter/updateFilter

Update coverage filter columns

REQUEST
POST

com.easesolutions.jira.plugins.coverage/1.0/filter/updateFilter



Example Request JSON
{ "projectId": 10000, "filterId": "4", "isPublic": true, "columnFilterJsonObject": "{<this object is defined elsewhere>}", "addedFieldsJsonArray": ["issuetype","issuekey","status","priority","summary"] } Definition: projectId - the project the view to be created filterId - id of filter to update isPublic - the visibility of the view addedFieldsJsonArray - an array of field names columnFilterJsonObject - an object containing column data relevant to the coverage view




RESPONSES

STATUS 200 - Returned if successful update

Example Response JSON
{ "id": "4", "name": "C", "columnFilterJsonObject": "{....}", "addedFieldsJsonArray": "[....]" }

STATUS 400 - Returned if the project is invalid, name is invalid or already exist, columns is invalid or contains invalid values, or an error occurs while creating the coverage view

STATUS 401 - Returned if invalid user credentials, or the user has no permission to use Requirements for JIRA plugin

STATUS 403 - Returned if the license is invalid or has expired, incompatible JIRA version, the project is not configured for Requirements for JIRA, or no permission to create coverage view

STATUS 404 - Returned if project is not found

com.easesolutions.jira.plugins.coverage/1.0/filter/deleteFilter

Delete coverage filter

REQUEST
POST

com.easesolutions.jira.plugins.coverage/1.0/filter/deleteFilter



PARAMETERS

parameter

type

description

parameter

type

description

projectId

Long

project id of filter to be deleted

filterId

Long

filterId of filter to be deleted




RESPONSES

STATUS 200 - Returned if coverage is successfully deleted

STATUS 400 - Returned if the project is invalid, name is invalid or already exist, columns is invalid or contains invalid values, or an error occurs while creating the coverage view

STATUS 401 - Returned if invalid user credentials, or the user has no permission to use Requirements for JIRA plugin

STATUS 403 - Returned if the license is invalid or has expired, incompatible JIRA version, the project is not configured for Requirements for JIRA, or no permission to create coverage view

STATUS 404 - Returned if project is not found

com.easesolutions.jira.plugins.coverage/1.0/filter/getAllFilters

Get all public and personal coverage filters for user

REQUEST
GET

com.easesolutions.jira.plugins.coverage/1.0/filter/getAllFilters




RESPONSES

STATUS 201 - Returned if successful

Example Response JSON
{ "publicFilters":[ { "id":"1", "name":"Filter A", "projectId": 10000 }, { "id":"2", "name":"Filter B", "projectId": 10001 } ], "personalFilters":[ { "id":"3", "name":"Filter C", "projectId": 10000 } ] }

STATUS 400 - Returned if the project is invalid, name is invalid or already exist, columns is invalid or contains invalid values, or an error occurs while creating the coverage view

STATUS 401 - Returned if invalid user credentials, or the user has no permission to use Requirements for JIRA plugin

STATUS 403 - Returned if the license is invalid or has expired, incompatible JIRA version, the project is not configured for Requirements for JIRA, or no permission to create coverage view

STATUS 404 - Returned if project is not found

com.easesolutions.jira.plugins.coverage/1.0/filter/getFilter

Get specific coverage filter

REQUEST
GET

com.easesolutions.jira.plugins.coverage/1.0/filter/getFilter



PARAMETERS

parameter

type

description

parameter

type

description

projectId

Long

project id of filter to get

filterId

Long

filterId of filter to get




RESPONSES

STATUS 200 - Returned if successful

Example Response JSON
{ "id": "1", "name": "Filter A", "columnFilterJsonObject": "{....}", "addedFieldsJsonArray": "[....]" }

STATUS 400 - Returned if the project is invalid, name is invalid or already exist, columns is invalid or contains invalid values, or an error occurs while creating the coverage view

STATUS 401 - Returned if invalid user credentials, or the user has no permission to use Requirements for JIRA plugin

STATUS 403 - Returned if the license is invalid or has expired, incompatible JIRA version, the project is not configured for Requirements for JIRA, or no permission to create coverage view

STATUS 404 - Returned if project is not found

com.easesolutions.jira.plugins.coverage/1.0/filter/getFilters

Get public and personal coverage filters for project

REQUEST
GET

com.easesolutions.jira.plugins.coverage/1.0/filter/getFilters



PARAMETERS

parameter

type

description

parameter

type

description

projectId

Long

project id of filter to get




RESPONSES

STATUS 201 - Returned if successful

Example Response JSON
{ "publicFilters": [{"id": "1","name": "Filter A"}, {"id": "2","name": "Filter B"}], "personalFilters": [{"id": "3","name": "Filter C"}] }

STATUS 400 - Returned if the project is invalid, name is invalid or already exist, columns is invalid or contains invalid values, or an error occurs while creating the coverage view

STATUS 401 - Returned if invalid user credentials, or the user has no permission to use Requirements for JIRA plugin

STATUS 403 - Returned if the license is invalid or has expired, incompatible JIRA version, the project is not configured for Requirements for JIRA, or no permission to create coverage view

STATUS 404 - Returned if project is not found

com.easesolutions.jira.plugins.coverage/1.0/export/excel

Export the coverage view to an excel file

REQUEST
POST

com.easesolutions.jira.plugins.coverage/1.0/export/excel



Example Request JSON
{ "columns": [{ "label": "Level 1", "jiraJql": "", "jiraFilterId": "", "linkTypes": [{ "id": "-1", "directions": {"in": true,"out": true} }], "currentIssueTypes": ["-1"], "projects": ["10000,DEMO,DEMO"], "fromLevel": -1, "issueSize": 0, "coverageCompleteness": 0 }], "fields": [], "folderIssueKeys": [], "filterId": 0, "folderId": 0, "folderName": "", "projectId": 10000, "fromColumn": 0, "isFiltered": false }




RESPONSES

STATUS 200 - Returned if excel file creation is successful

Example Response JSON
EXCEL FILE

STATUS 400 - Returned if the project is invalid, name is invalid or already exist, columns is invalid or contains invalid values, or an error occurs while creating the coverage view

STATUS 401 - Returned if invalid user credentials, or the user has no permission to use Requirements for JIRA plugin

STATUS 403 - Returned if the license is invalid or has expired, incompatible JIRA version, the project is not configured for Requirements for JIRA, or no permission to create coverage view

STATUS 500 - Returned if project is not found

com.easesolutions.jira.plugins.coverage/1.0/export/xml

Export the coverage view to an xml file

REQUEST
POST

com.easesolutions.jira.plugins.coverage/1.0/export/xml 



Example Request JSON
{ "columns": [{ "label": "Level 1", "jiraJql": "", "jiraFilterId": "", "linkTypes": [{ "id": "-1", "directions": {"in": true,"out": true} }], "currentIssueTypes": ["-1"], "projects": ["10000,DEMO,DEMO"], "fromLevel": -1 }], "fields": [], "folderIssueKeys": [], "filterId": 0, "folderId": 0, "folderName": "", "projectId": 10000, "fromColumn": 0, "isFiltered": false }




RESPONSES

STATUS 201 - Returned if xml file creation is successful

Example Response JSON
XML FILE

STATUS 400 - Returned if the project is invalid, name is invalid or already exist, columns is invalid or contains invalid values, or an error occurs while creating the coverage view

STATUS 401 - Returned if invalid user credentials, or the user has no permission to use Requirements for JIRA plugin

STATUS 403 - Returned if the license is invalid or has expired, incompatible JIRA version, the project is not configured for Requirements for JIRA, or no permission to create coverage view

STATUS 404 - Returned if project is not found