SetResponsible

[POST] .../v1/deal/setresponsible

Assigns the responsible user for a CRM deal. Use this workflow method instead of Deal/Edit when changing the user responsible for a CRM deal. The method validates the deal, responsible user and pipeline access, preserves the previous responsible user as a participant when needed, updates the assignment, synchronizes deal participants and chat staff participants, writes a chat system message, sends DealResponsibleSet webhook and assignment notifications and returns row_affected with the deal id. The request body is required; id and responsible_user_id must both be positive and responsible_user_id must resolve to an existing active user. The caller must have CRM deal responsible-set permission; missing body, invalid ids, missing deal, missing responsible user, denied access, pipeline ACL failures, storage errors are returned as HTTP 200 ErrorResult.

Request Parameters

Name Type Required Description
id Int64 Required Deal ID.
responsible_user_id Int64 Required New responsible user ID.

Request Example

{
  "id": 230,
  "responsible_user_id": 31
}

Response Parameters

Name Type Description
ok Boolean Indicates whether the request completed successfully.
result Update Update operation result.

Response Example

{
  "ok": true,
  "result": {
    "row_affected": 1,
    "ids": [
      230
    ]
  }
}