Nhảy tới nội dung
Phiên bản: 2.3.0

Cập nhật quy trình xử lý

Ngày cập nhật: 16 tháng 09, 2026
Người cập nhật: VNPT eContract's team


Mục đích​

Cập nhật quy trình xử lý cho chứng từ đã được tạo tại mục 4.1 và cập nhật tại mục 4.2 (nếu có), bao gồm danh sách người tham gia xử lý, thứ tự thực hiện, quyền xử lý và thông tin vị trí ký tương ứng trên từng file thành phần (fileInfoId) của chứng từ.

  • Request URL: /v2/documents/update-process
  • HTTP method: POST
  • HTTP content-type: application/json
  • Authorize: Bearer token
  • Parameter:
KeyTypeBắt buộcDescription
idGUIDCóDocumentId của chứng từ cần cấu hình quy trình (lấy từ response API mục 4.1 hoặc 4.2)
processInOrderbooleanCóQuy trình xử lý tuần tự (true) hay song song (false)
processesarrayCóDanh sách bước xử lý - chi tiết bên dưới
processes[].orderNointCóThứ tự xử lý (nếu processInOrder = true)
processes[].processedByUserCodestring(50)CóMã người dùng được phân công xử lý
processes[].accessPermissionCodestring(50)CóMã quyền xử lý (ví dụ: "D" — Ký số; xem thêm danh mục quyền xử lý tại Phụ lục)
processes[].positionstringCóTọa độ vị trí đặt chữ ký trên file, định dạng "x1,y1,x2,y2"
processes[].pageSignintCóTrang cần ký trong file
processes[].fileInfoIdGUIDCóID file thành phần cần xử lý (lấy từ downloadFileUrls[].id của response mới nhất tại API mục 4.1 hoặc 4.2)

Mẫu request​

{
"id": "f5b0c112-d357-44ce-b8a8-7cb77d3d0b9e",
"processInOrder": true,
"processes": [
{
"orderNo": 1,
"processedByUserCode": "user001",
"accessPermissionCode": "D",
"position": "234,514,374,574",
"pageSign": 1,
"fileInfoId": "6865273c-90f5-49cd-403b-08defc11a479"
},
{
"orderNo": 2,
"processedByUserCode": "user002",
"accessPermissionCode": "D",
"position": "334,614,474,674",
"pageSign": 1,
"fileInfoId": "a940f960-213c-4a89-403c-08defc11a479"
}
]
}

Mẫu response body​

{
"data": {
"id": "f5b0c112-d357-44ce-b8a8-7cb77d3d0b9e",
"createdDate": "2026-08-13T17:55:40.8560899",
"lastModifiedDate": "2026-08-13T17:58:15.7799973+07:00",
"no": "DOCUMENT-MF-001",
"subject": "Chứng từ nhiều file DOCUMENT-MF-001 - Cập nhật",
"hasVerified": false,
"hasVerify": false,
"hasSeal": false,
"requireVerifiedUserSigning": false,
"status": {
"value": 1,
"description": "New"
},
"contractStatus": {
"value": 0,
"description": "Undefined"
},
"description": "Ví dụ cập nhật chứng từ DOCUMENT-MF-001",
"createdByUserId": 27938,
"processRecipientCount": 2,
"waitingProcesses": [
],
"processInOrder": true,
"isWaitToSignDraw": false,
"isWaitToSignDigital": false,
"isWaitToApprove": false,
"isWaitToFillData": false,
"isWaitToCoordinate": false,
"isWaitToESign": false,
"isWaitToEkyc": false,
"isFillable": false,
"type": {
"id": 8950,
"code": "DOCID",
"name": "Chứng từ thử nghiệm",
"documentCount": 1,
"enableVnptSeal": false,
"requireVerifiedUserSigning": false,
"children": [
]
},
"processes": [
{
"id": "bba867ee-09f9-41f6-6ddb-08def929c6d3",
"createdDate": "2026-08-13T17:58:15.7798094+07:00",
"comId": 7354,
"isOrder": true,
"orderNo": 1,
"pageSign": 1,
"position": "234,514,374,574",
"displayType": {
"value": 0,
"description": "0"
},
"accessPermission": {
"value": 4,
"description": "Sign digital"
},
"status": {
"value": 1,
"description": "Waiting"
},
"processedByUserId": 59407,
"documentId": "f5b0c112-d357-44ce-b8a8-7cb77d3d0b9e",
"fillingItems": [
],
"fileInfoId": "6865273c-90f5-49cd-403b-08defc11a479",
"attachments": [
]
},
{
"id": "129da2f9-85d4-4390-6ddc-08def929c6d3",
"createdDate": "2026-08-13T17:58:15.7799953+07:00",
"comId": 7354,
"isOrder": true,
"orderNo": 2,
"pageSign": 1,
"position": "334,614,474,674",
"displayType": {
"value": 0,
"description": "0"
},
"accessPermission": {
"value": 4,
"description": "Sign digital"
},
"status": {
"value": 1,
"description": "Waiting"
},
"processedByUserId": 27938,
"documentId": "f5b0c112-d357-44ce-b8a8-7cb77d3d0b9e",
"fillingItems": [
],
"fileInfoId": "a940f960-213c-4a89-403c-08defc11a479",
"attachments": [
]
}
],
"accessibleViewProcesses": [
],
"histories": [
{
"createdDate": "2026-08-13T17:58:15.7800305+07:00",
"requestType": {
"value": 0,
"description": "Web"
},
"ipAddress": "10.70.39.34",
"activity": {
"value": 2,
"description": "Update document"
}
}
],
"attachments": [],
"relatedDocuments": [],
"linkedDocuments": [],
"messages": [],
"fillingItems": [],
"sharedUsers": [],
"isMarkStar": false,
"downloadFileUrls": [
{
"id": "6865273c-90f5-49cd-403b-08defc11a479",
"fileName": "Tai-lieu-chinh-01.pdf",
"downloadUrl": "{HOST}/api/Download?token=...",
"downloadWatermarkMetadataUrl": "{HOST}/api/Download?token=...",
"orderNo": 1,
"size": 358043,
"fileType": {
"value": 0,
"description": "General"
},
"hasSeal": false
},
{
"id": "a940f960-213c-4a89-403c-08defc11a479",
"fileName": "Phu-luc-02.pdf",
"downloadUrl": "{HOST}/api/Download?token=...",
"downloadWatermarkMetadataUrl": "{HOST}/api/Download?token=...",
"orderNo": 2,
"size": 262757,
"fileType": {
"value": 0,
"description": "General"
},
"hasSeal": false
}
],
"zipDownloadUrl": "{HOST}/api/Download/MergeFilesZipDocument?token=...",
"zipDownloadOriginalUrl": "{HOST}/api/Download/MergeFilesZipDocument?token=...",
"zipDownloadWatermarkMetadataUrl": "{HOST}/api/Download/MergeFilesZipDocument?token=...",
"requiresSealSendConfirmation": false,
"fixedPosition": false,
"isLaborContractDocument": false
},
"success": true,
"code": 0,
"messages": [
"Update document success"
]
}

Mô tả Response Body​

KeyTypeDescription
successbooleanTrạng thái phản hồi của yêu cầu (true: Thành công, false: Thất bại)
codeintMã phản hồi từ hệ thống
messagesarrayDanh sách thông báo hoặc lỗi trả về từ hệ thống (Ví dụ: ["Update document success"])
dataobjectĐối tượng chứa thông tin chi tiết của chứng từ sau khi cập nhật quy trình xử lý (xem chi tiết bên dưới)

Chi tiết dữ liệu trong data:​

Các trường id, createdDate, lastModifiedDate, no, subject, description, status, contractStatus, type, downloadFileUrls, zipDownloadUrl, zipDownloadOriginalUrl, zipDownloadWatermarkMetadataUrl... có ý nghĩa giống API Tạo chứng từ nhiều file (mục 4.1). Bảng dưới đây chỉ mô tả các trường thay đổi giá trị hoặc phát sinh mới sau khi cập nhật quy trình cho chứng từ.

KeyTypeDescription
processRecipientCountintSố người tham gia xử lý quy trình vừa cấu hình
processInOrderbooleanQuy trình xử lý tuần tự (true) hay song song (false), lấy theo giá trị đã gửi ở request
processesarrayDanh sách bước xử lý vừa được cấu hình — chi tiết từng phần tử (xem bên dưới)

Chi tiết danh sách processes:​

Danh sách chứa các đối tượng bước xử lý trong quy trình chứng từ với các thuộc tính của 1 phần tử:

KeyTypeDescription
idGUIDId bước xử lý (process) do hệ thống sinh ra
createdDatedatetimeThời điểm tạo bước xử lý
comIdintId công ty của người xử lý
isOrderbooleanBước xử lý có thuộc quy trình tuần tự hay không
orderNointThứ tự xử lý
pageSignintSố trang cần ký trong file
positionstringTọa độ vị trí đặt chữ ký trên file, định dạng "x1,y1,x2,y2"
displayTypeobjectKiểu hiển thị chữ ký (xem danh mục Enum tại Phụ lục)
accessPermissionobjectQuyền xử lý được cấp cho bước này (ví dụ: Ký số - xem danh mục Enum tại Phụ lục)
statusobjectTrạng thái bước xử lý (ví dụ: Waiting - Chờ xử lý)
processedByUserIdintId người dùng được phân công xử lý bước này
documentIdstring (GUID)Id chứng từ chứa bước xử lý này
fillingItemsarrayDanh sách trường dữ liệu cần điền tại bước này (nếu có)
fileInfoIdstring (GUID)ID file thành phần cần xử lý ở bước này
attachmentsarrayTệp đính kèm phát sinh tại bước xử lý (nếu có)
Lưu ý

Response trả về lại toàn bộ thông tin chứng từ sau khi cập nhật quy trình: mảng processes thể hiện các bước xử lý vừa được cấu hình (trạng thái "Waiting" - Chờ xử lý), processRecipientCount thể hiện số người tham gia xử lý.