UpdateWorkitemField
Updates the fields of a work item and supports batch updates for multiple fields.
Operation description
Updates work item fields in batches. Only work item context fields and custom fields are supported. The properties of the work item itself, such as the description, title, and status, cannot be updated. To update these properties, use the operation for updating work item property fields.
Try it now
Test
RAM authorization
Request syntax
POST /organization/{organizationId}/workitems/updateWorkitemField HTTP/1.1
Path Parameters
|
Parameter |
Type |
Required |
Description |
Example |
| organizationId |
string |
Yes |
The enterprise ID. |
60ee8a814690c27532d412f8 |
Request parameters
|
Parameter |
Type |
Required |
Description |
Example |
| body |
object |
No |
The request body. |
|
| workitemIdentifier |
string |
Yes |
The unique identifier of the work item, which is the same as the work item ID. |
9144ef6b72d8exxxxx9e61a4d0 |
| updateWorkitemPropertyRequest |
array<object> |
Yes |
The request to update work item properties, in array format. |
|
|
object |
No |
The entity property. |
||
| fieldIdentifier |
string |
Yes |
The ID of the work item field to be updated. You can obtain the corresponding data from the API operation that retrieves all fields of a work item. |
tag |
| fieldValue |
string |
Yes |
The property value of the field to be updated. Note: 1. If the value is of the personnel type, you must specify the aliyunPK. 2. If the field contains candidate values, specify the ID of the corresponding candidate value. 3. If there are multiple values, separate them with commas (,) and concatenate them into a single string. |
Personal attribute |
Response elements
|
Element |
Type |
Description |
Example |
|
object |
|||
| requestId |
string |
The request ID, which is unique for each request and facilitates subsequent troubleshooting. |
ASSDS-ASSASX-XSAXSA-XSAXSAXS |
| errorMsg |
string |
The error message. |
error |
| errorCode |
string |
The error code. |
Openapi.RequestError |
| success |
boolean |
Indicates whether the request is successful. |
true |
| workitem |
object |
The work item information. |
|
| identifier |
string |
The unique identifier of the work item. |
e8bxxxxxxxxxxxxxxxx23 |
| subject |
string |
The title of the work item. |
Test work item |
| document |
string |
The content of the work item. |
HTML format |
| assignedTo |
string |
The assignee. |
19xx7043xxxxxxx914 |
| status |
string |
The name of the status. |
Pending |
| statusStageIdentifier |
string |
The ID of the status stage. |
1 |
| spaceIdentifier |
string |
The ID of the project to which the work item belongs. |
e8b26xxxxx6e76aa20xxxxx23 |
| spaceName |
string |
The name of the project to which the work item belongs. |
Requirement project |
| spaceType |
string |
The type of the project. |
Project |
| logicalStatus |
string |
The logical status. |
NORMAL |
| categoryIdentifier |
string |
The category ID of the work item. |
Req |
| parentIdentifier |
string |
The ID of the parent work item. |
e8bxxxxxxxxxxxxxxxx24 |
| workitemTypeIdentifier |
string |
The type ID of the work item. |
9uxxxxxxre573f5xxxxxx0 |
| updateStatusAt |
integer |
The time when the status was updated. |
1640850328000 |
| serialNumber |
string |
The serial number. |
1 |
| gmtCreate |
integer |
The time when the work item was created. |
1640850318000 |
| gmtModified |
integer |
The time when the work item was modified. |
1640850318000 |
| creator |
string |
The creator. |
19xx7043xxxxxxx914 |
| modifier |
string |
The modifier. |
19xx7043xxxxxxx914 |
| statusIdentifier |
string |
The unique identifier of the status. |
28 |
| sprintIdentifier |
string |
The ID of the sprint. |
75528f17703e92e5a568...... |
Examples
Success response
JSON format
{
"requestId": "ASSDS-ASSASX-XSAXSA-XSAXSAXS",
"errorMsg": "error",
"errorCode": "Openapi.RequestError",
"success": true,
"workitem": {
"identifier": "e8bxxxxxxxxxxxxxxxx23",
"subject": "测试工作项",
"document": "html格式",
"assignedTo": "19xx7043xxxxxxx914",
"status": "待处理",
"statusStageIdentifier": "1",
"spaceIdentifier": "e8b26xxxxx6e76aa20xxxxx23",
"spaceName": "需求项目",
"spaceType": "Project",
"logicalStatus": "NORMAL",
"categoryIdentifier": "Req",
"parentIdentifier": "e8bxxxxxxxxxxxxxxxx24",
"workitemTypeIdentifier": "9uxxxxxxre573f5xxxxxx0",
"updateStatusAt": 1640850328000,
"serialNumber": "1",
"gmtCreate": 1640850318000,
"gmtModified": 1640850318000,
"creator": "19xx7043xxxxxxx914",
"modifier": "19xx7043xxxxxxx914",
"statusIdentifier": "28",
"sprintIdentifier": "75528f17703e92e5a568......"
}
}
Error codes
|
HTTP status code |
Error code |
Error message |
Description |
|---|---|---|---|
| 400 | Openapi.RequestError | request error | |
| 403 | Operate.NoPermission | NoPermission | You are not authorized to perform this operation. |
See Error Codes for a complete list.
Release notes
See Release Notes for a complete list.