Update a client
Request to update an existing client:
PUT /api/v2/clients/<client-id>.json
The request body contains the attributes of the client object to
change. Attributes that are not included keep their values. When contacts is included, it replaces
the whole list of contacts.
For example:
{
"client": {
"name": "New Client Name"
}
}
Response contains HTTP status code as shown in the following table.
| Response | Description |
|---|---|
| 200 OK | The client has been successfully updated. The response body contains the complete client object after the update |
| 400 Bad Request | The request cannot be completed because the supplied JSON object has invalid data. The response contains a detailed description of the error, like: |
| 403 Forbidden | The request cannot be completed because API user has no permission to edit clients |
| 404 Not Found | Client with such ID does not exist, or it is outside the access scope of the API user |