Products: Managed Backup (Agent)
Article ID: m0707Last Modified: 20-Mar-2025

POST API/Computers/{hid}/authorization

Creates/updates authorization for endpoints which are currently online by specified HID.

POST /mbsapi/api/Computers/01d469cb-326e-444f-a9b0-XXXXXXXXXXX/authorization

Body

{
  "UserId": "10ce439b-7bec-4208-a116-XXXXXXXXXXX"
}

Request Information

URI Parameters

Name Description Type Additional Information
hid HID of the computer (endpoint) string Required

Body Parameters

Name Description Type Additional Information
UserID User GUID string Optional, but at least one parameter must be provided for authorization
UserID Company ID string Optional, but at least one parameter must be provided for authorization

Authorization follows the same logic as the Authorize button on the Computers page:

  • If only UserID is specified, this user will be authorized on the computer.
  • If only CompanyId is specified,a new user will be created for this computer.
  • If both UserID and CompanyId are specified, the system will verify the user and company before authorization. Then, the existing user from the specified company will be authorized on the computer.

Response Information

Response Formats

application/json

Successful authorization:

{
  "ResultCode": 0,
  "ErrorMessage": ""
}

Failed authorization:

{
  "ErrorCode": -6,
  "Message": "Object \"10ce439b-7bec-4208-a116-4e0236085f87\" not found"
}
 {
  "ResultCode": 0,
  "ErrorMessage": ""
}
 
https://git.cloudberrylab.com/egor.m/doc-help-mbs.git
Production