Edits user
Updates user information by its ID.
HTTP Request
PATCH https://courier.yandex.ru/api/v1/companies/{company_id}/users/{user_id}
Path Parameters
company_id * | integer The ID of the company that is used in requests to the Track & Trace API. |
user_id * | integer The ID of the user that is used in requests to the Track & Trace API. |
* Required parameter
Request Body
{ "login": string, "role": string }
Copied to clipboard
Representation
Fields
login | string User's login. |
role | string Role of this user. Possible values: admin, manager, dispatcher, app. |
login | string User's login. |
role | string Role of this user. Possible values: admin, manager, dispatcher, app. |
* Required parameter
Responses
Code 200
Returns the updated object.
{ "id": integer, "login": string, "role": string }
Copied to clipboard
Representation
Fields
id | integer User ID. |
login | string User's login. |
role | string Role of this user. Possible values: admin, manager, dispatcher, app. |
id | integer User ID. |
login | string User's login. |
role | string Role of this user. Possible values: admin, manager, dispatcher, app. |
* Required parameter
Code 401
Authorization failed. Send the correct OAuth token in the authorization header.
Code 403
You do not have access to this object.
Code 404
No object found.
Code 422
Incorrect input.