Querying Tree-shaped Work Items
Function
This API is used to query tree-shaped work items.
Calling Method
For details, see Calling APIs.
Authorization Information
No identity policy-based permission required for calling this API.
URI
POST /v1/ipdprojectservice/projects/{project_id}/issues/tree
| Parameter | Mandatory | Type | Description |
|---|---|---|---|
| project_id | Yes | String | Definition 32-character ID of a project, which must be unique. Obtain the value by calling the API for querying the IPD project list. The value of id in the response message body is the project ID. Constraints N/A Range A string of 32 characters consisting of letters and digits. Default Value N/A |
Request Parameters
| Parameter | Mandatory | Type | Description |
|---|---|---|---|
| X-Auth-Token | Yes | String | Definition User token. Obtain a token by calling the IAM API for obtaining a user token. The value of X-Subject-Token in the response header is the user token. Constraints N/A Range 10 to 32,768 characters Default Value N/A |
| Parameter | Mandatory | Type | Description |
|---|---|---|---|
| keyword | No | String | Definition Keyword. Fuzzy search by title and exact search by number are supported. Constraints N/A Range N/A Default Value N/A |
| number | No | Array of strings | Definition Query by number. If number is specified, keyword does not take effect. You can obtain the value from the Querying Tree-shaped Work Items API. The value is number in the response body. Constraints N/A |
| plan | No | Array of PlanFilterVO objects | Definition Filter by release and sprint plan criteria. The parameters are the release and sprint plan IDs. The sprint and release plan IDs are subordinate to each other. The value –2 indicates that no content is set. Constraints N/A |
| offset | No | Integer | Definition Start page number. The value starts from 0 and is an integer multiple of limit. Constraints N/A Range N/A Default Value N/A |
| limit | No | Integer | Definition Number of records on each page (pagination parameter). Constraints N/A Range N/A Default Value 20 |
| modified_date | No | DateFilterVO object | Definition Last modification time of a work item. Constraints N/A |
| Parameter | Mandatory | Type | Description |
|---|---|---|---|
| plan_pi | No | String | Definition Release plan ID. The value –2 indicates that no content is set. You can query the release plan ID by calling the API for querying the release/sprint plan list. The id in PlanVO in the returned parameters is the release plan ID. Constraints A string of 18 to 19 digits, or -2. Range N/A Default Value N/A |
| plan_iteration | No | Array of strings | Definition Sprint plan ID of the release plan. The value –2 indicates that no sprint is set. ID of the sprint plan when the statistics are collected by sprint plan. You can query the release plan ID by calling the API for querying the release/sprint plan list. The id in children in the returned parameters is the release sprint ID. Constraints N/A |
| Parameter | Mandatory | Type | Description |
|---|---|---|---|
| start_date | No | String | Definition Start timestamp of the time filter, for example, 1711036800000. Constraints -2 indicates that no content is set. Range N/A Default Value N/A |
| end_date | No | String | Definition End timestamp of the time filter, for example, 1711036899999. Constraints -2 indicates that no content is set. Range N/A Default Value N/A |
Response Parameters
Status code: 200
| Parameter | Type | Description |
|---|---|---|
| result | IssueEntityPageResult object | Definition Work item tree diagram API. |
| status | String | Definition Response status. Range |
| message | String | Definition Query failure cause. Range N/A |
| Parameter | Type | Description |
|---|---|---|
| issues | Array of IssueInfoVO objects | Definition Work item list. |
| total | Integer | Definition Total number of work items. Range N/A |
| Parameter | Type | Description |
|---|---|---|
| id | String | Definition ID of the work item to be updated. Range N/A |
| title | String | Definition Work item title. Range N/A |
| description | String | Definition Work item description field. Range N/A |
| type | String | Definition Broad category of a work item. Range requirement (R&D requirement), bug, task, feature, and raw_requirement. |
| number | String | Definition Work item ID. Range N/A |
| category | String | Definition Work item type. Range Multiple values are supported. Use commas (,) to separate them. |
| parent_id | String | Definition Parent work item ID. Range N/A |
| project_id | String | Definition 32-character UUID of a project, which must be unique. Range N/A |
| status | String | Definition Work item status code. Range Start: initial Analyse: to be analyzed Develop: being developed Test: testing Finish: completed |
| state | String | Definition Work item lifecycle. Range |
| assignee | UserEntity object | Definition Work item owner. |
| assigned_cc | Array of UserEntity objects | Definition Cc recipient of a work item. Multiple Cc recipients are supported. A work item can be copied to a maximum of 50 recipients. |
| created_by | UserEntity object | Definition Work item creator. |
| created_time | String | Definition Work item creation time, which is a Unix timestamp (unit: millisecond). Range N/A |
| modified_by | UserEntity object | Definition Latest updater of a work item. |
| modified_time | String | Definition Last update time of the work item, which is a Unix timestamp (unit: millisecond). Range N/A |
| plan_end_date | String | Definition Planned end date of a work item, which is a Unix timestamp (unit: millisecond). Range N/A |
| close_time | String | Definition Work item closure time, which is a Unix timestamp (unit: millisecond). Range N/A |
| workload | String | Definition Planned workloads of a work item. One decimal place is reserved. The value ranges from 0 to 999999999.9. Range 0-999999999.9 |
| workload_sum | String | Definition Actual workloads of a work item. Range 0-999999999.9 |
| tenant_id | String | Definition ID of the tenant to which the work item belongs. Obtain the value from the Querying Tree-shaped Work Items API. The value is tenant_id in the response body. Range N/A |
| link | String | Definition IDs of associated items of a work item. Range N/A |
| suspended | Boolean | Definition Whether a work item is suspended. Range true and false |
| status_modified_time | String | Definition Time when the work item status changes, which can be used to calculate the number of days that the work item stays in the current status. The value is a Unix timestamp, in milliseconds. Range N/A |
| labels | Array of LabelEntity objects | Definition Work item label. |
| custom_fields | Array of FieldCodeValuePair objects | Definition Custom field mapping of a work item. System fields added by users are also in this column. { "code":"field code", "value":"field value" }. |
| children | Array of IssueInfoVO objects | Definition Child work item set of a work item. |
| path | String | Definition Path of a child work item. Range N/A |
| ir2feature | String | Definition Association field of IRs and SFs. |
| need_break | String | Definition Whether a work item needs to be broken down. Range |
| break_status | String | Definition Breakdown status. decomposed: broken down undecomposed: not broken down --: N/A Range decomposed, undecomposed, and -- |
| baseline | String | Definition Work item baseline status. Range |
| priority | String | Definition Work item priority. Some work items have this field. Range |
| related_network_security | String | Definition Whether network security is involved. Range |
| collaboratives | String | Definition R&D requirement collaboration task ID. Obtain the value from the Querying Tree-shaped Work Items API. The value is collaboratives in the response body. Range N/A |
| business_domain | String | Definition Domain field. Range |
| plan_pi | String | Definition Work item release plan ID. Range N/A |
| plan_iteration | String | Definition ID of the sprint plan in which the work item is completed. The field is the fixing sprint plan ID for bugs. Range N/A |
| change_status | String | Definition Work item change status. change-reviewing: being reviewed changed: changed unchange or null: not changed Range change-reviewing, changed, unchange, and null |
| no_break_reason | String | Definition Reason for no breakdown required. need_break is no. Range 0 to 512 characters. |
| submitted_by | Array of UserEntity objects | Definition Work item proposer. |
| ir2rr | String | Definition ID of the RR associated with the IR. Use commas (,) to separate multiple IDs. Range N/A |
| feature_set | String | Definition Feature set ID. Range N/A |
| expected_repair_date | String | Definition Expected fixing time. This field is available only for bugs. The value is a Unix timestamp, in milliseconds. Range N/A |
| found_pi | String | Definition ID of the release plan where a bug is found. This field is available only for bugs. Range N/A |
| found_iteration | String | Definition ID of the sprint plan where a bug is found. This field is available only for bugs. Range N/A |
| reason_analysis | String | Definition Reason analysis. Range 0 to 50,000 characters. |
| repair_solution | String | Definition Fix solution. This field is available only for bugs. Range N/A |
| test_report | String | Definition Test report. This field is available only for bugs. Range N/A |
| sys_no_repair_reason | String | Definition Reason why rectification is not required. This field is available only for bugs. Range N/A |
| sys_activation_reason | String | Definition Activation reason. This field is available only for bugs. Range N/A |
| sys_return_reason | String | Definition Reason for return. This field is available only for bugs. Range N/A |
| test_failures_times | Integer | Definition Number of times that regression failed. This field is available only for bugs. Range N/A |
| close_type | String | Definition Closure type. This field is available only for bugs. The options are problem_solved, problem_to_requirement, duplicate_problem, and not_a_problem, which mean that the bug was fixed and closed, the bug was converted into a requirement and closed, the bug was closed as a duplicate, the bug was closed because it was not a valid issue, respectively. Range problem_solved, problem_to_requirement, duplicate_problem, and not_a_problem |
| Parameter | Type | Description |
|---|---|---|
| id | String | Definition User ID. Obtain it by calling the API for querying project members. The value of id in the response message body is the user ID. Range N/A |
| name | String | Definition Username. Range 2 to 64 characters. |
| nick_name | String | Definition User alias. Range 2 to 30 characters |
| Parameter | Type | Description |
|---|---|---|
| id | String | Definition Label ID, which is the value of id in the response body returned by calling the API for querying the label list. Range A string of 18 to 19 digits. |
| category_types | Array of strings | Definition Code of the work item type to which a label belongs. |
| label_type | String | Definition Type of the work item to which the label belongs, corresponding to the type field of the work item. The options are as follows. Range |
| color | String | Definition Label RGB color. Range The available color codes and their descriptions are as follows: |
| title | String | Definition Label title. Range N/A |
| Parameter | Type | Description |
|---|---|---|
| code | String | Definition Code of a custom field of a work item. Obtain the value from the Querying Field Templates API. The value is code in the response body. Range N/A |
| value | String | Definition Custom field value of a work item. Range N/A |
Status code: 400
| Parameter | Type | Description |
|---|---|---|
| error_code | String | Definition Error code. Range N/A |
| error_msg | String | Definition Error description, which is a supplement to error_code. Range N/A |
Example Requests
POST https://{endpoint}/v1/ipdprojectservice/projects/8e70d806a8f04d018ea6af6b6ffe7b96/issues/tree?category=IR,US
{
"keyword" : "IR-",
"plan" : [ {
"plan_pi" : "966380919792246785",
"plan_iteration" : [ "967014561020424192", "-2" ]
} ],
"number" : [ "IR20240218102026" ],
"limit" : 10,
"offset" : 0
} Example Responses
Status code: 200
{
"status" : "success",
"message" : null,
"result" : {
"issues" : [ {
"category" : "IR",
"id" : "961308804339843073",
"title" : "IR-16-Breakdown",
"type" : "requirement",
"number" : "IR20240205000401",
"project_id" : "8e70d806a8f04d018ea6af6b6ffe7b96",
"status" : "Start",
"state" : "Working",
"assignee" : {
"id" : "a360371833bf4c558f796fd707b44daf",
"name" : "devcloud_devcloud_01",
"nick_name" : "Test account"
},
"assigned_cc" : [ {
"id" : "a360371833bf4c558f796fd707b44daf",
"name" : "devcloud_devcloud_01",
"nick_name" : "Test account"
} ],
"created_by" : {
"id" : "a360371833bf4c558f796fd707b44daf",
"name" : "devcloud_devcloud_01",
"nick_name" : "Test account"
},
"created_time" : "1707123479000",
"modified_by" : {
"id" : "a360371833bf4c558f796fd707b44daf",
"name" : "devcloud_devcloud_01",
"nick_name" : "Test account"
},
"modified_time" : "1707123480000",
"workload" : "20.00",
"tenant_id" : "4e919d73499648e3b0292cd3cbef806a",
"link" : "",
"status_modified_time" : "1707123480000",
"custom_fields" : [ {
"code" : "c7073388365101674496",
"value" : "881467547473321986"
}, {
"code" : "c7148512434669625344",
"value" : "956591616891461634"
} ],
"children" : [ ],
"ir2feature" : "",
"need_break" : "yes",
"break_status" : "undecomposed",
"priority" : "Medium",
"related_network_security" : "no",
"business_domain" : "software",
"submitted_by" : [ {
"id" : "a360371833bf4c558f796fd707b44daf",
"name" : "devcloud_devcloud_01",
"nick_name" : "Test account"
} ],
"ir2rr" : "956559072707911681"
} ],
"total" : 1
}
} Status code: 400
{
"error_code" : "PM.PM.02176813",
"error_msg" : "No permission."
} Status Codes
| Status Code | Description |
|---|---|
| 200 | OK |
| 400 | Error message. |
Error Codes
See Error Codes.
What is your overall rating for this page?
Thank you very much for your feedback. We will continue working to improve the documentation.See the reply and handling status in My Cloud VOC.
For any further questions, feel free to contact us through the chatbot.
Chatbot