Help Center/ CodeArts Req/ API Reference/ API/ IPD Work Item Management/ Updating Work Items in Batches
Updated on 2025-09-10 GMT+08:00

Updating Work Items in Batches

Function

This API is used to update work items in batches.

Calling Method

For details, see Calling APIs.

URI

PUT /v1/ipdprojectservice/projects/{project_id}/issues/batch

Table 1 Path Parameters

Parameter

Mandatory

Type

Description

project_id

Yes

String

Definition:

32-character UUID of a project, which uniquely identifies a project. Obtain the value of this parameter from the project_id field in the response body of the Querying the Project List API.

Constraints:

Regular expression: ^[A-Za-z0-9]{32}$

Options:

N/A

Default value:

N/A

Request Parameters

Table 2 Request header parameters

Parameter

Mandatory

Type

Description

X-Auth-Token

No

String

Definition:

User token. Obtain the token by calling theObtaining a User TokenIAM API. In the returned response header, X-Subject-Token is the desired user token.

Constraints:

Mandatory.

Range:

Minimum length: 10 character. Maximum length: 32,768 characters.

Default value:

N/A

Table 3 Request body parameters

Parameter

Mandatory

Type

Description

id

Yes

Array of strings

Definition:

Array of IDs of the work items to be updated. Performing Advanced Query of Work Items API. The value of the id field in the response message body is the work item ID.

Constraints:

Regular expression: ^([0-9]{18,19})$

Options:

Minimum length: 18 characters. Maximum length: 19 characters.

Default value:

N/A

attribute

Yes

IssueEntity object

Definition:

Work item updates.

Table 4 IssueEntity

Parameter

Mandatory

Type

Description

id

No

String

Definition:

ID of the work item to be updated. You can obtain the value from the Querying Tree-shaped Work Items API. The value is id in the response body.

Constraints:

Regular expression: ^([0-9]{18,19})$

Options:

N/A

Default value:

N/A

title

No

String

Definition:

Work item title. You can obtain the value from the Querying Tree-shaped Work Items API. The value is title in the response body.

Constraints:

Minimum length: 1 character. Maximum length: 256 characters.

Options:

N/A

Default value:

N/A

description

No

String

Definition:

Work item description. You can obtain the value from the Querying Tree-shaped Work Items API. The value is description in the response body.

Constraints:

Minimum length: 1 character. Maximum length: 50,000 characters.

Options:

N/A

Default value:

N/A

type

No

String

Definition:

Broad category of work item. This field is not available when you create or edit a work item. It is used only for display. You can obtain the value of this field from the type field in the response body of the Querying Tree-shaped Work Items API.

Constraints:

Minimum length: 0 characters. Maximum length: 128 characters.

Options:

requirement (R&D requirement), bug, task, feature, and raw_requirement.

Default value:

N/A

number

No

String

Definition:

Work item ID. You can obtain the value from the Querying Tree-shaped Work Items API. The value is number in the response body.

Constraints:

Minimum length: 0 characters. Maximum length: 128 characters.

Options:

N/A

Default value:

N/A

category

Yes

String

Definition:

Subcategory of work item. You can obtain the value from the Querying Tree-shaped Work Items API. The value is category in the response body.

Constraints:

N/A

Options:

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.

For cloud service projects, options include RR, Epic, FE, US, Task, and Bug.

Default value:

N/A

parent_id

No

String

Definition:

Parent work item ID. You can obtain the value from the Querying Tree-shaped Work Items API. The value is parent_id in the response body.

Constraints:

Regular expression: ^([0-9]{18,19})$

Options:

N/A

Default value:

N/A

project_id

No

String

Definition:

32-character UUID of a project, which uniquely identifies a project. Obtain the value of this parameter from the project_id field in the response body of the Querying the Project List API.

Constraints:

Regular expression: [A-Za-z0-9]{32}

Options:

N/A

Default value:

N/A

status

No

String

Definition:

Work item status code. You can obtain the value from the Querying Tree-shaped Work Items API. The value is status in the response body.

Constraints:

Minimum length: 2 characters. Maximum length: 32 characters.

Options:

N/A

Default value:

N/A

assignee

No

UserEntity object

Definition:

Work item owner.

assigned_cc

No

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

No

UserEntity object

Definition:

Work item creator.

created_time

No

String

Definition:

Work item creation time, which is a Unix timestamp (unit: millisecond).

Constraints:

N/A

Options:

N/A

Default value:

N/A

modified_by

No

UserEntity object

Definition:

Late updater of a work item.

modified_time

No

String

Definition:

Last update time of the work item, which is a Unix timestamp (unit: millisecond).

Constraints:

N/A

Options:

N/A

Default value:

N/A

plan_end_date

No

String

Definition:

Planned end date of a work item, which is a Unix timestamp (unit: millisecond).

Constraints:

N/A

Options:

N/A

Default value:

N/A

close_time

No

String

Definition:

Work item closure time, which is a Unix timestamp (unit: millisecond).

Constraints:

N/A

Options:

N/A

Default value:

N/A

workload

No

String

Definition:

Planned workloads of a work item. One decimal place is reserved. The value ranges from 0 to 999,999,999.9.

Constraints:

N/A

Options:

0–999,999,999.9

Default value:

N/A

link

No

String

Definition:

IDs of associated items of a work item. Separate multiple associated items by commas (,). A work item can have a maximum of 50 associated items. You can obtain the value from the Querying Tree-shaped Work Items API. The value is link in the response body.

Constraints:

Minimum length: 0 characters. Maximum length: 2,048 characters.

Options:

N/A

Default value:

N/A

suspended

No

Boolean

Definition:

Whether a work item is suspended.

Constraints:

N/A

Options:

true and false

Default value:

N/A

status_modified_time

No

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.

Constraints:

N/A

Options:

N/A

Default value:

N/A

labels

No

Array of LabelEntity objects

Definition:

Work item tag.

custom_fields

No

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

No

Array of IssueEntity objects

Definition:

Child work item set of a work item.

ir2feature

No

String

Definition:

Associated field between IR and FE. This field is available when the work item type is IR.

Constraints:

N/A

Options:

N/A

Default value:

N/A

need_break

No

String

Definition:

Whether a work item needs to be broke down. This field is available only for work item types that can be broke down.

Constraints:

N/A

Options:

N/A

Default value:

N/A

break_status

No

String

Definition:

Breakdown status. The options are:

decomposed: broken down

undecomposed: not broken down

--: N/A

Constraints:

N/A

Options:

decomposed, undecomposed, and --.

Default value:

N/A

baseline

No

String

Definition:

Work item baseline status. The options are:

null: unbaselined

baselined: baselined

baseline-reviewing: being reviewed

Constraints:

N/A

Options:

null, baselined, and baseline-reviewing

Default value:

N/A

priority

No

String

Definition:

Work item priority. Some work items have this field.

Constraints:

N/A

Options:

N/A

Default value:

N/A

related_network_security

No

String

Definition:

Whether network security is involved. This field is available only for R&D requirements.

Constraints:

N/A

Options:

N/A

Default value:

N/A

collaboratives

No

String

Definition:

R&D requirement collaboration task ID. You can obtain the value from the Querying Tree-shaped Work Items API. The value is collaboratives in the response body.

Constraints:

Minimum length: 0 characters. Maximum length: 256 characters.

Options:

N/A

Default value:

N/A

business_domain

No

String

Definition:

Domain field.

Constraints:

N/A

Options:

N/A

Default value:

N/A

plan_pi

No

String

Definition:

Work item release plan ID. You can obtain the value from the Querying Tree-shaped Work Items API. The value is plan_pi in the response body.

Constraints:

Regular expression: ^([0-9]{18,19})$

Options:

N/A

Default value:

N/A

plan_iteration

No

String

Definition:

ID of the sprint plan in which the work item is completed. For bugs, the value is the ID of the fix sprint plan. You can obtain the value from the Querying Tree-shaped Work Items API. The value is plan_iteration in the response body.

Constraints:

Regular expression: ^([0-9]{18,19})$

Options:

N/A

Default value:

N/A

change_status

No

String

Definition:

Work item change status. The options are:

change-reviewing: being reviewed

changed: changed

unchange or null: unchanged

Constraints:

Minimum length: 0 characters. Maximum length: 32 characters.

Options:

change-reviewing, changed, unchange, and null

Default value:

N/A

no_break_reason

No

String

Definition:

Reason for breakdown nonnecessity. This field is available when need_break is set to no.

Constraints:

Minimum length: 0 characters. Maximum length: 512 characters.

Options:

N/A

Default value:

N/A

submitted_by

No

Array of UserEntity objects

Definition:

Work item proposer.

ir2rr

No

String

Definition:

ID of the RR associated with the IR. Use commas (,) to separate multiple IDs.

Constraints:

N/A

Options:

N/A

Default value:

N/A

feature_set

No

String

Definition:

Feature set ID. You can obtain the value from the Querying Tree-shaped Work Items API. The value is feature_set in the response body.

Constraints:

Regular expression: ^([0-9]{18,19})$

Options:

N/A

Default value:

N/A

expected_repair_date

No

String

Definition:

Expected fixing time. This field is available only for bugs. The value is a Unix timestamp, in milliseconds.

Constraints:

N/A

Options:

N/A

Default value:

N/A

found_pi

No

String

Definition:

ID of the release plan where the bug is found. This field is available only for bugs. You can obtain the value from the Querying Tree-shaped Work Items API. The value is found_pi in the response body.

Constraints:

Regular expression: ^([0-9]{18,19})$

Options:

N/A

Default value:

N/A

found_iteration

No

String

Definition:

ID of the sprint plan where the bug is found. This field is available only for bugs. You can obtain the value from the Querying Tree-shaped Work Items API. The value is found_iteration in the response body.

Constraints:

Regular expression: ^([0-9]{18,19})$

Options:

N/A

Default value:

N/A

reason_analysis

No

String

Definition:

Cause analysis. This field is available only for bugs.

Constraints:

N/A

Options:

N/A

Default value:

N/A

repair_solution

No

String

Definition:

Rectification solution. This field is available only for bugs.

Constraints:

Minimum length: 0 characters. Maximum length: 50,000 characters.

Options:

N/A

Default value:

N/A

test_report

No

String

Definition:

Test report. This field is available only for bugs.

Constraints:

N/A

Options:

N/A

Default value:

N/A

sys_no_repair_reason

No

String

Definition:

Reason why rectification is not required. This field is available only for bugs.

Constraints:

N/A

Options:

N/A

Default value:

N/A

sys_activation_reason

No

String

Definition:

Activation reason. This field is available only for bugs.

Constraints:

N/A

Options:

N/A

Default value:

N/A

sys_return_reason

No

String

Definition:

Reason for return. This field is available only for bugs.

Constraints:

N/A

Options:

N/A

Default value:

N/A

test_failures_times

No

Integer

Definition:

Number of times that regression failed. This field is available only for bugs.

Constraints:

N/A

Options:

N/A

Default value:

N/A

close_type

No

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.

Constraints:

N/A

Options:

problem_solved, problem_to_requirement, duplicate_problem, and not_a_problem

Default value:

N/A

plan_owner

No

UserEntity object

Definition:

Work item planning owner.

doing_owner

No

UserEntity object

Definition:

Work item implementation owner.

delivered_owner

No

UserEntity object

Definition:

Work item delivery owner.

checking_owner

No

UserEntity object

Definition:

Work item acceptance owner.

test_owner

No

UserEntity object

Definition:

Work item testing owner.

develop_owner

No

UserEntity object

Definition:

Work item development owner.

processing_owner

No

UserEntity object

Definition:

Work item processing owner.

fixed_owner

No

UserEntity object

Definition:

Work item fixing owner.

researchanddevelop_owner

No

UserEntity object

Definition:

Work item R&D owner.

analyse_owner

No

UserEntity object

Definition:

Work item analysis owner.

Table 5 LabelEntity

Parameter

Mandatory

Type

Description

id

No

String

Definition:

Tag ID, which is the value of id in the response body returned by calling the Querying the Tag List API.

Constraints:

Regular expression: ^([0-9]{18,19})$

Options:

N/A

Default value:

N/A

label_type

No

String

Definition:

Type of the work item to which the label belongs, corresponding to the type field of the work item.

Constraints:

Minimum length: 0 characters. Maximum length: 32 characters.

Options:

N/A

Default value:

N/A

color

No

String

Definition:

Tag RGB color.

Constraints:

Minimum length: 0 characters. Maximum length: 16 characters.

Options:

N/A

Default value:

N/A

title

No

String

Definition:

Tag title.

Constraints:

Minimum length: 2 characters. Maximum length: 256 characters.

Options:

N/A

Default value:

N/A

Table 6 FieldCodeValuePair

Parameter

Mandatory

Type

Description

code

No

String

Definition:

Work item field code.

Constraints:

Minimum length: 0 characters. Maximum length: 32 characters.

Options:

N/A

Default value:

N/A

value

No

String

Definition:

Custom field value of a work item. Use commas (,) to separate multiple values.

Constraints:

Minimum length: 0 characters. Maximum length: 10,000 characters.

Options:

N/A

Default value:

N/A

Table 7 UserEntity

Parameter

Mandatory

Type

Description

id

No

String

Definition:

User ID. You can obtain the value using the Obtaining the Current User Information API. The value of id in the response message body is the user ID.

Constraints:

N/A

Options:

N/A

Default value:

N/A

name

No

String

Definition:

Username.

Constraints:

Minimum length: 2 characters. Maximum length: 64 characters.

Options:

N/A

Default value:

N/A

nick_name

No

String

Definition:

User alias.

Constraints:

Minimum length: 2 characters. Maximum length: 30 characters.

Options:

N/A

Default value:

N/A

Response Parameters

Status code: 200

Table 8 Response body parameters

Parameter

Type

Description

result

Array of IssueBatchOperateEntitiesResult objects

Definition:

Result of batch editing.

status

String

Definition:

Operation status.

Options:

N/A

message

String

Definition:

Operation failure cause.

Options:

N/A

Table 9 IssueBatchOperateEntitiesResult

Parameter

Type

Description

success

Array of IssueOperateResult objects

Definition:

Success result.

failed

Array of IssueOperateResult objects

Definition:

Failure result.

Table 10 IssueOperateResult

Parameter

Type

Description

id

String

Definition:

ID of the changed work item.

Options:

N/A

operator

String

Definition:

ID of the person who changes the work item.

Options:

N/A

state

String

Definition:

Lifecycle status after the work item changes.

Options:

N/A

operate_time

String

Definition:

Work item change time.

Options:

N/A

Status code: 400

Table 11 Response body parameters

Parameter

Type

Description

error_code

String

Error code.

error_msg

String

Error message.

Example Requests

Updating R&D Requirements in Batches

PUT https://{endpoint}/v1/ipdprojectservice/projects/8e70d806a8f04d018ea6af6b6ffe7b96/issues/batch

{
  "id" : [ "957294446158852096", "957315051394478080" ],
  "attribute" : {
    "category" : "IR",
    "priority" : "Low",
    "submitted_by" : [ {
      "id" : "a360371833bf4c558f796fd707b44daf"
    } ],
    "labels" : [ {
      "id" : "956308025419804673"
    }, {
      "id" : "956308025419804673"
    } ],
    "custom_fields" : [ {
      "code" : "c7073388365101674496",
      "value" : "881467547473321986,881467547473321987"
    }, {
      "code" : "c7148504958125613056",
      "value" : "Custom field of a project."
    }, {
      "code" : "module",
      "value" : "956584293264568320"
    }, {
      "code" : "c7148512434669625344",
      "value" : "956591616891461634"
    } ]
  }
}

Example Responses

Status code: 200

OK

{
  "status" : "success",
  "result" : [ {
    "success" : [ {
      "id" : "957294446158852096",
      "operator" : "a360371833bf4c558f796fd707b44daf",
      "operate_time" : "2024-01-29T21:26:11Z"
    }, {
      "id" : "957315051394478080",
      "operator" : "a360371833bf4c558f796fd707b44daf",
      "operate_time" : "2024-01-29T21:26:11Z"
    } ],
    "failed" : [ ]
  } ]
}

Status code: 400

Error cause.

{
  "error_code" : "PM.02175000",
  "error_msg" : "System busy. Try again later."
}

Status Codes

Status Code

Description

200

OK

400

Error cause.

Error Codes

See Error Codes.