Skip to navigation

Chuyển giai đoạn vòng đời khách hàng

Scope yêu cầu: customer:write. Agent cần quyền sửa (crm.customer → edit) và khách hàng phải nằm trong phạm vi sửa của agent. Đổi field lifecycleStages (xem Cấu hình khách hàng → Hành trình). Mỗi tenant tự cấu hình danh sách giai đoạn và có thể thêm/sửa/xoá; mẫu mặc định khi khởi tạo gồm: | Giai đoạn | lifecycleStage | | --- | --- | | Đăng ký (mặc định) | subscriber | | Tiềm năng | lead | | Đủ điều kiện | qualifiedLead | | Cơ hội bán hàng | opportunity | | Chính thức | official | | Trung thành | evangelist | | Khác | other |

Headers

X-Api-KeystringRequired

Request

This endpoint expects an object.
customerIdstringRequiredformat: "^[0-9A-Z]{11}$"

customerId do API trả về (11 ký tự [0-9A-Z]). Gửi id nội bộ (UUID) sẽ bị từ chối.

lifecycleStagestringRequired

Mã giai đoạn hành trình. Mẫu mặc định: subscriber, lead, qualifiedLead, opportunity, official, evangelist, other.

reasonstringOptional<=2000 characters

Response

Đã cập nhật — {customerId, success}.

customerIdstringOptional
successbooleanOptional

Errors

400
Bad Request Error
401
Unauthorized Error
403
Forbidden Error
404
Not Found Error
429
Too Many Requests Error
502
Bad Gateway Error
503
Service Unavailable Error