REST API: Project Tree Old

DATA CENTER AND SERVER | CLOUD

REST API: Project Tree Old

This content is archived.

com.easesolutions.jira.plugins.requirements/1.0/tree/prjKey/foldertree/id

GET

com.easesolutions.jira.plugins.requirement1s/1.0/search/prjKey

Search for project tree folders and retrieve detailed information for the found elements.

GET

com.easesolutions.jira.plugins.requirements/1.0/tree/prjKey

Get the complete project tree structure for a given project.

POST

com.easesolutions.jira.plugins.requirements/1.0/tree/reuse

Trigger a requirements reuse. Source and target may be in different projects.

POST

com.easesolutions.jira.plugins.requirements/1.0/tree/prjKey/createscheduledjob

Allows the creation of jobs for the scheduled adding of existing issues.

GET

com.easesolutions.jira.plugins.requirements/1.0/tree/totalItemCount/prjKey

4.2.0 Returns total item count of project tree. 

 

GET

com.easesolutions.jira.plugins.requirements/1.0/tree/prjKey/folders

Get complete tree structure of project.

GET

com.easesolutions.jira.plugins.requirements/1.0/tree/prjKey/foldertree/id

Get complete tree structure with or without issues for certain project tree folder.

POST

com.easesolutions.jira.plugins.requirements/1.0/tree/prjKey/folder

Create a new project tree folder below the root folder of a given project.

POST

com.easesolutions.jira.plugins.requirements/1.0/tree/prjKey/folder/id

Create a new project tree folder below a specified folder of a given project.

PUT

com.easesolutions.jira.plugins.requirements/1.0/tree/prjKey/folder/id

Rename a folder using project key.

DELETE

com.easesolutions.jira.plugins.requirements/1.0/tree/prjKey/folder/id

Delete a project tree folder from a given project.

 

POST

com.easesolutions.jira.plugins.requirements/1.0/tree/prjKey/rootissue

Add an existing issue to the root folder of a given project.

DELETE

com.easesolutions.jira.plugins.requirements/1.0/tree/prjKey/rootissue

Remove an issue from the root folder of a given project.

POST

com.easesolutions.jira.plugins.requirements/1.0/tree/prjKey/folderissue/id

Add an existing issue to a specified tree folder of a given project.

DELETE

com.easesolutions.jira.plugins.requirements/1.0/tree/prjKey/folderissue/id

Remove an issue from a specified tree folder of a given project.

POST

com.easesolutions.jira.plugins.requirements/1.0/tree/prjKey/moveissue

Move an issue from one tree folder to another one of the same project.

 

GET

com.easesolutions.jira.plugins.requirements/1.0/child-req/prjKey/parentKey

Get all child requirements for a given issue in a specific project.

POST

com.easesolutions.jira.plugins.requirements/1.0/child-req/prjKey/parentKey

Add a child requirement to an issue in the project tree a given project.

DELETE

com.easesolutions.jira.plugins.requirements/1.0/child-req/prjKey/parentKey

Remove a child requirement from an issue in the project tree of a given project.

 

com.easesolutions.jira.plugins.requirements/1.0/search/prjKey

Search for project tree folders and retrieve detailed information for the found elements.  

 Click here for details...
REQUEST
GET

/rest/com.easesolutions.jira.plugins.requirements/1.0/search/prjKey?type&pathSep&path



PARAMETERS
parametertypedescription
prjKey*stringthe project key
typestringitemtype to search for (should be "folder")
pathSepstringseperator chars used in path (default "/")
pathstringthe path to search in



RESPONSES

STATUS 200 - Returned if tree element is found

Example response
{
  	"folders": [
    	{
      		"name": "First",
      		"id": 9,
      		"name_display":"First",
      		"parent": -1,
      		"folders": [
        		{
          			"name": "Second",
          			"id": 14,
          			"name_display":"Second",
          			"parent": 9,
          			"folders": [],
          			"issues": [],
          			"position": 2
        		},
      		],
      		"issues": [],
      		"position": 3
    	}
  	],
  	"issues": []
}

STATUS 400 - Returned if the project is invalid, type is invalid, the path separator is invalid or path is invalid

STATUS 401 - Returned if invalid user credentials, or the user has no permission

STATUS 403 - Returned if the license is invalid or has expired, or incompatible JIRA version

 

com.easesolutions.jira.plugins.requirements/1.0/tree/prjKey

Get the complete project tree structure for a given project.

 Click here for details...
REQUEST
GET

/rest/com.easesolutions.jira.plugins.requirements/1.0/tree/prjKey?n



PARAMETERS
parametertypedescription
prjKey*stringthe project key
nstringtoggles structure numbering prefix for folder names (0 = disabled (default), 1 = enabled)



RESPONSES

STATUS 200 - Returned if tree structure of an existing project is found

Example response
{
  	"id": -1,
  	"folders": [
		{
      		"name": "First",
      		"id": 56,
      		"name_display": "First",
      		"parent": -1,
      		"folders": [
        		{
          			"name": "Third",
          			"id": 69,
          			"name_display": "Third",
          			"parent": 56,
          			"folders": [],
          			"issues": [
            			{
              				"id": 132,
              				"issueId": 10157,
              				"key": "AN-4",
              				"url": "http://<server-name>/browse/AN-4",
              				"summary": "Second",
              				"description": "Issue number 61",
              				"icon_url": "http://<server-name>/images/icons/issuetypes/newfeature.png",
              				"issueType": "New Feature",
              				"position": 1
            			},
            			{
              				"id": 131,
              				"issueId": 10155,
              				"key": "AN-2",
              				"url": "http://<server-name>/browse/AN-2",
              				"summary": "Second",
              				"description": "Second",
              				"icon_url": "http://<server-name>/images/icons/issuetypes/newfeature.png",
              				"issueType": "New Feature",
              				"position": 2
            			}
          			],
         			"position": 1
        		}
			],
    		"issues": [],
    		"position": 1
		},
		{
			"name": "Test",
			"id": 67,
			"name_display": "Test",
			"parent": -1,
			"folders": [
				{
					"name": "Second",
					"id": 68,
					"name_display": "Second",
					"parent": 67,
					"folders": [],
					"issues": [
						{
							"id": 127,
							"issueId": 10155,
							"key": "AN-2",
							"url": "http://<server-name>/browse/AN-2",
							"summary": "Second",
							"description": "Second",
							"icon_url": "http://<server-name>/images/icons/issuetypes/newfeature.png",
							"issueType": "New Feature",
							"position": 1
						},
						{
							"id": 118,
							"issueId": 10154,
							"key": "AN-1",
							"url": "http://<server-name>/browse/AN-1",
							"summary": "First",
							"description": "First issue textasd",
							"icon_url": "http://<server-name>/images/icons/issuetypes/newfeature.png",
							"issueType": "New Feature",
							"position": 2
						}
					],
					"position": 1
				}
			],
			"issues": [],
			"position": 2
		},
		{
			"name": "Root",
			"id": 75,
			"name_display": "Root",
			"parent": -1,
			"folders": [],
			"issues": [],
			"position": 3
		},
		{
			"name": "Test",
			"id": 70,
			"name_display": "Test",
			"parent": -1,
			"folders": [],
			"issues": [],
			"position": 4
		}
	],
	"issues": []
} 

STATUS 400 - Returned if the project is invalid

STATUS 401 - Returned if invalid user credentials, or the user has no permission

STATUS 403 - Returned if the license is invalid or has expired, or incompatible JIRA version

 

com.easesolutions.jira.plugins.requirements/1.0/tree/reuse

Trigger a requirements reuse. Source and target may be in different projects.

 Click here for details...
com.easesolutions.jira.plugins.requirements/1.0/tree/reuse
REQUEST
POST

/rest/com.easesolutions.jira.plugins.requirements/1.0/tree/reuse?source&target&ruleName



PARAMETERS
parametertypedescription
sourcestringthe source folder for reuse (e.g. Requirements Plugin/Implementation)
targetstringthe target folder for the reuse (e.g. Requirements Plugin/Features/Baseline/Permissions)
ruleNamestringthe name of a reuse rule (e.g. "rule 27")



RESPONSES

STATUS 200 - Returned if requirement is successfully reused

Example Response
Reuse Success

STATUS 400 - Returned if source folder is invalid, source project is invalid, target folder is invalid, target project is invalid, the reuse rule name is invalid or an error occurs while processing reuse

STATUS 401 - Returned if invalid user credentials, or the user has no permission

STATUS 403 - Returned if the license is invalid or has expired, or incompatible JIRA version

 

com.easesolutions.jira.plugins.requirements/1.0/tree/prjKey/createscheduledjob

Allows the creation of jobs for the scheduled adding of existing issues.

 Click here for details...
REQUEST
POST

/rest/com.easesolutions.jira.plugins.requirements/1.0/tree/prjKey/createscheduledjob?name&folderId&filter&interval



PARAMETERS
parametertypedescription
prjKey*stringthe project key of the project
namestringthe name of the scheduled job
folderIdlongthe folder id of the tree folder
filterstringthe JQL, JIRA filter, or if null will default to add all issues from the project that have not added to the project tree
intervallongthe time interval in minutes. Enter 0 as value to set execution interval to Manual.



RESPONSES

STATUS 201 - Returned if jobs for the scheduled adding of existing issues is succesfully created

Example Response
Rule Home Page UI req has been successfully created

STATUS 400 - Returned if the project is invalid, the name is invalid or already exists, the folder is invalid, the filter is invalid or interval is less than zero

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

STATUS 403 - Returned if the license is invalid or has expired, incompatible JIRA version, or no permission to create jobs for the scheduled adding of existing issues

STATUS 404 - Returned if folder is not found

com.easesolutions.jira.plugins.requirements/1.0/tree/prjKey/folders

Returns all tree folders and subfolders in project.

 Click here for details...
REQUEST
GET

/rest/com.easesolutions.jira.plugins.requirements/1.0/tree/prjKey/folders



PARAMETERS
parametertypedescription
prjKey*stringproject key of folders to be return



RESPONSES

STATUS 200 - Returned if tree structure if an existing project is found

Example response
[
  {
    "folders": [
      {
        "folders": [],
        "name": "Folder 1.1",
        "id": 10
      },
      {
        "folders": [],
        "name": "Folder 1.2",
        "id": 11
      }
    ],
    "name": "Folder 1",
    "id": 5
  },
  {
    "folders": [],
    "name": "Folder 2",
    "id": 6
  },
  {
    "folders": [
      {
        "folders": [],
        "name": "Folder 3.1",
        "id": 8
      },
      {
        "folders": [],
        "name": "Folder 3.2",
        "id": 9
      }
    ],
    "name": "Folder 3",
    "id": 7
  }
]

STATUS 400 - Returned if the project is invalid

STATUS 401 - Returned if invalid user credentials, or the user has no permission

STATUS 403 - Returned if the license is invalid or has expired, or incompatible JIRA version

 

com.easesolutions.jira.plugins.requirements/1.0/tree/prjKey/foldertree/id

Get complete tree structure with or without issues for certain project tree folder.

 Click here for details...
REQUEST
GET

/rest/com.easesolutions.jira.plugins.requirements/1.0/tree/prjKey/foldertree/id?folderOnly&n



PARAMETERS
parametertypedescription
prjKey*stringthe project key
id*stringthe folder id
folderOnlystringtoggles include issues in folder (0 = disabled (default), 1 = enabled)
nstringtoggles structure numbering prefix for folder names (0 = disabled (default), 1 = enabled)



RESPONSES

STATUS 200 - Returned if tree structure if an existing project is found

Example response
{
  	"id": 1,
  	"folders": [
		{
      		"name": "First",
      		"id": 56,
      		"name_display": "First",
      		"parent": -1,
      		"folders": [
        		{
          			"name": "Third",
          			"id": 69,
          			"name_display": "Third",
          			"parent": 56,
          			"folders": [],
          			"issues": [
            			{
              				"id": 132,
              				"issueId": 10157,
              				"key": "AN-4",
              				"url": "http://<server-name>/browse/AN-4",
              				"summary": "Second",
              				"description": "Issue number 61",
              				"icon_url": "http://<server-name>/images/icons/issuetypes/newfeature.png",
              				"issueType": "New Feature",
              				"position": 1
            			},
            			{
              				"id": 131,
              				"issueId": 10155,
              				"key": "AN-2",
              				"url": "http://<server-name>/browse/AN-2",
              				"summary": "Second",
              				"description": "Second",
              				"icon_url": "http://<server-name>/images/icons/issuetypes/newfeature.png",
              				"issueType": "New Feature",
              				"position": 2
            			}
          			],
         			"position": 1
        		}
			],
    		"issues": [],
    		"position": 1
		},
		{
			"name": "Test",
			"id": 67,
			"name_display": "Test",
			"parent": -1,
			"folders": [
				{
					"name": "Second",
					"id": 68,
					"name_display": "Second",
					"parent": 67,
					"folders": [],
					"issues": [
						{
							"id": 127,
							"issueId": 10155,
							"key": "AN-2",
							"url": "http://<server-name>/browse/AN-2",
							"summary": "Second",
							"description": "Second",
							"icon_url": "http://<server-name>/images/icons/issuetypes/newfeature.png",
							"issueType": "New Feature",
							"position": 1
						},
						{
							"id": 118,
							"issueId": 10154,
							"key": "AN-1",
							"url": "http://<server-name>/browse/AN-1",
							"summary": "First",
							"description": "First issue textasd",
							"icon_url": "http://<server-name>/images/icons/issuetypes/newfeature.png",
							"issueType": "New Feature",
							"position": 2
						}
					],
					"position": 1
				}
			],
			"issues": [],
			"position": 2
		},
		{
			"name": "Root",
			"id": 75,
			"name_display": "Root",
			"parent": -1,
			"folders": [],
			"issues": [],
			"position": 3
		},
		{
			"name": "Test",
			"id": 70,
			"name_display": "Test",
			"parent": -1,
			"folders": [],
			"issues": [],
			"position": 4
		}
	],
	"issues": []
} 

STATUS 400 - Returned if the project is invalid

STATUS 401 - Returned if invalid user credentials, or the user has no permission

STATUS 403 - Returned if the license is invalid or has expired, or incompatible JIRA version

 

 

com.easesolutions.jira.plugins.requirements/1.0/tree/prjKey/folder

Create a new project tree folder below the root folder of a given project.

Returns information about the new folder in case of success. 


 Click here for details...
REQUEST
POST

/rest/com.easesolutions.jira.plugins.requirements/1.0/tree/prjKey/folder?name&description



PARAMETERS
parametertypedescription
prjKey*stringthe project key
namestringthe name of the new folder
descriptionstringoptional description of the new folder



RESPONSES

STATUS 200 - Returned if the folder is successfully created

Example Response
{
  "name": "Test",
  "id": 76,
  "parent": -1,
  "folders": [],
  "issues": [],
  "position": 0
} 

STATUS 400 - Returned if the project is invalid, name is invalid or already exists, or an error occurs in folder creation

STATUS 401 - Returned if invalid user credentials, or the user has no permission

STATUS 403 - Returned if the license is invalid or has expired, or incompatible JIRA version