Loading...

REST API - POST Authorize for Restore (Company Level)

A tenant administrator can use this operation to enable or disable authorized users (who have entered the correct passkey) to browse and restore backup files for 30 minutes.

Request

Syntax

Send the request using either XML or JSON.

  • XML

    POST <webservice>/Company/{CompanyId}/Passkey
    Host: <host name>
    Accept: {application/xml}
    Content-type: application/xml
    <App_AuthorizeForRestoreRequest passkey="">
    <passkeySettings enableAuthorizeForRestore="">
    <passkeyExpirationInterval toTime=""/>
    </passkeySettings>
    </App_AuthorizeForRestoreRequest>

  • JSON

    POST <webservice>/Company/{CompanyId}/Passkey
    Host: <host name>
    Accept: {application/json}
    Content-type: application/json
    {
    "passkeySettings": {
    "passkeyExpirationInterval": {
    "_toTime": "
    },
    "_enableAuthorizeForRestore": ""
    },
    "_passkey": ""
    }

where <webservice> is the root path used to route the API requests to the Web Server.

For more information, see Available Web Services for REST API.

Request Parameters

Name

Description

Required

companyId

The organization ID for the company.

If the organization ID is not known, use the REST API - GET Organization to retrieve it.

Yes

Request Headers

Name

Description

Host

The host name of the Web Server or Web Console used in the API request.

Accept

The format of the response.

Valid values are: application/xml or application/json.

Content-type

The media type that is contained in the request body.

Valid values are: application/xml or application/json.

Request Body

An XML element or a JSON message is required. See Syntax. The following table displays the parameters for the request body.

Note: All XML requests interpret the input as a plain text passkey, and all JSON requests interpret the input as a Base64-encoded passkey.

Parameter

Description

Elements

passkey

The existing passkey for restricting backup restores.

App_AuthorizeForRestoreRequest

enableAuthorizeForRestore

The type of authorize for restore operation. Valid value is:

  • 0: Disables authorize for restore.
  • 1: Enables authorize for restore.

passkeySettings

toTime

The duration for which a user can continue browsing and restoring backup data without being prompted to enter the passkey, again.

passkeyExpirationInterval

Response

Response Parameters

Parameter

Description

Elements

name

The API processing result. Valid value is exitval.

attributes

value

The number for the API processing result.

Valid values are:

  • 0: Successful completion
  • a specific error code.

attributes

errorMessage

The description of the error code. Not all error codes have an error message.

error

errorCode

The possible error codes.

error

Examples

Sample Request to Enable Authorize for Restore

POST <webservice>/ClientGroup HTTP/1.1
Host: client.mydomain.com
Accept: application/xml
Authtoken: QSDK 38568012f4d1e8ee1841d283a47aa3ba78e124ea58354b5fc60f4dab8a63347d05cf5552484dafda3bfa4c5db84e580b1cb37bcf8e65b39f7f8549a443e6f78a2c7be3f31b3d845e24776c835e498e8e883bb40c46bd15af4f40ca94e823acedcdd4e9659e74b34a07a85c4586cd2ed914b6dce015874783ef768fda78183a4208930954a377f66eb56c8b92cexampl4s437a19317ca6ce7f3233d5a01aca35dbad93468b833f2cf71010809006a937670adce711ca8be46638e8
Content-type: application/xml
<?xml version="1.0" encoding="UTF-8"?>
<App_AuthorizeForRestoreRequest passkey="Passkey!123">
<passkeySettings enableAuthorizeForRestore="1">
<passkeyExpirationInterval toTime="1800"/>
</passkeySettings>
</App_AuthorizeForRestoreRequest

Sample Request to Disable Authorize for Restore

POST <webservice>/ClientGroup HTTP/1.1
Host: client.mydomain.com
Accept: application/xml
Authtoken: QSDK 38568012f4d1e8ee1841d283a47aa3ba78e124ea58354b5fc60f4dab8a63347d05cf5552484dafda3bfa4c5db84e580b1cb37bcf8e65b39f7f8549a443e6f78a2c7be3f31b3d845e24776c835e498e8e883bb40c46bd15af4f40ca94e823acedcdd4e9659e74b34a07a85c4586cd2ed914b6dce015874783ef768fda78183a4208930954a377f66eb56c8b92cexampl4s437a19317ca6ce7f3233d5a01aca35dbad93468b833f2cf71010809006a937670adce711ca8be46638e8
Content-type: application/xml
<?xml version="1.0" encoding="UTF-8"?>
<App_AuthorizeForRestoreRequest>
<passkeySettings enableAuthorizeForRestore="0">
<passkeyExpirationInterval/>
</passkeySettings>
</App_AuthorizeForRestoreRequest

Sample Response When Authorize for Restore Is Enabled or Disabled Successfully

<?xml version="1.0" encoding="UTF-8"?>
<App_AuthorizeForRestoreResponse>
<processinginstructioninfo>
<attributes name="exitval" value="0"/>
</processinginstructioninfo>
<error errorCode="0"/>
</App_AuthorizeForRestoreResponse>

Sample Response When Passkey is Incorrect

<?xml version="1.0" encoding="UTF-8"?>
<App_AuthorizeForRestoreResponse>
<processinginstructioninfo>
<attributes name="exitval" value="587206528"/>
</processinginstructioninfo>
<error errorMessage="Passkey is incorrect. Please provide valid passkey to continue with the operation." errorCode="587206528"/>
</App_AuthorizeForRestoreResponse>

Last modified: 2/4/2021 4:58:09 PM