Help Center/ CodeArts Req/ API Reference/ API/ IPD Work Item Management/ Querying Tree-shaped Work Items
Updated on 2026-10-13 GMT+08:00

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

Table 1 Path Parameters

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

Table 2 Query Parameters

Parameter

Mandatory

Type

Description

category

Yes

String

Definition

Work item type.

Constraints

2 to 32 characters, including letters, underscores (_), and commas (,).

Range

Multiple work item types are supported, which are separated by commas (,), for example, IR,SR,AR.

  • For system device projects, options include RR, SF, IR, SR, AR, Task, and Bug.

  • For standalone software projects, options include RR, SF, IR, US, Task, and Bug.

Default Value

N/A

Request Parameters

Table 3 Request header 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

Table 4 Request body parameters

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

Table 5 PlanFilterVO

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

Table 6 DateFilterVO

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

Table 7 Response body parameters

Parameter

Type

Description

result

IssueEntityPageResult object

Definition

Work item tree diagram API.

status

String

Definition

Response status.

Range

  • success: The response is successful.

  • error: The response fails.

message

String

Definition

Query failure cause.

Range

N/A

Table 8 IssueEntityPageResult

Parameter

Type

Description

issues

Array of IssueInfoVO objects

Definition

Work item list.

total

Integer

Definition

Total number of work items.

Range

N/A

Table 9 IssueInfoVO

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.

  • For system device projects, options include RR, SF, IR, SR, AR, Task, and Bug.

  • For standalone software projects, options include RR, SF, IR, US, Task, and Bug.

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

  • In use: work items that can be operated properly

  • Discarded: soft-deleted work items that can be restored from the recycle bin

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

  • yes: Breakdown is required.

  • no: Breakdown is not required.

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

  • null: not baselined

  • baselined

  • baseline-reviewing: baseline review in progress

priority

String

Definition

Work item priority. Some work items have this field.

Range

  • Low

  • Medium

  • High

related_network_security

String

Definition

Whether network security is involved.

Range

  • yes: Network security is involved.

  • no: Network security is not involved.

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

  • software

  • soft-hardware

  • hardware

  • Performance

  • Functions

  • O&M

  • Operations

  • User experience

  • Privacy protection

  • Compliance

  • Resilience (reliability/availability)

  • Resilience (hazard detection and recovery)

  • Transparent

  • Harmless

  • Security

  • API

  • Cost

  • Maintainability

  • Other DFX

  • Availability

  • others

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

Table 10 UserEntity

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

Table 11 LabelEntity

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

  • raw requirement

  • feature (system feature)

  • requirement (R&D requirement)

  • task

  • bug

color

String

Definition

Label RGB color.

Range

The available color codes and their descriptions are as follows:

  • #86CAFF: light sky blue

  • #6DDEBB: aquamarine

  • #A6DD82: light green

  • #FAC20A: golden yellow

  • #FA9841: sandy orange

  • #F66F6A: light coral

  • #F3689A: pink

  • #A97AF8: medium purple

  • #71757F: slate gray

  • #5E7CE0: soft blue

  • #207AB3: steel blue

  • #169E6C: sea green

  • #6CA83B: olive green

  • #B58200: dark golden yellow

  • #B54E04: burnt orange

  • #B02121: dark red

  • #AD215B: dark pink

  • #572DB3: deep violet

  • #4F4F4F: dark gray

  • #3C51A6: indigo blue

title

String

Definition

Label title.

Range

N/A

Table 12 FieldCodeValuePair

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

Table 13 Response body parameters

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.