Retrieving Remote Storage Settings

Use the get-remote-storage-settings operation to retrieve settings of a remote backups FTP storage.

In this chapter:

Request Packet Structure

Response Packet Structure

Samples

 

Request Packet Structure

A request XML packet retrieving remote storage settings includes the get-remote-storage-settings operation node:

<packet>
<backup-manager>
   <get-remote-storage-settings>
...
   </get-remote-storage-settings>
</backup-manager>
</packet>

 

The get-remote-storage-settings node is presented by type BackupGetRemoteStorageSettingsInput (backup.xsd), and its graphical representation is as follows:

  • The webspace-id node is optional. It specifies a webspace ID. Data type: integer.
  • The webspace-name node is optional. It specifies a webspace name. Data type: string.
  • The customer-id node is optional. It specifies a customer ID. Data type: integer.
  • The customer-login node is optional. It specifies a customer login. Data type: string.
  • The reseller-id node is optional. It specifies the reseller ID. Data type: integer.
  • The reseller-login node is optional. It specifies a reseller login. Data type: string.
  • The server node is optional. It instructs Plesk to create a server-level backup. Data type: none.
  • The protocol node is required. It specifies a protocol for which the settings are retrieved. Data type: string. Allowed values: ftp.

Note: If you do not define a target Plesk user, the operation will use packet sender identifier.

Important: When creating request packets, put nodes and elements in the order they follow in the packet structure.

 

Response Packet Structure

The get-remote-storage-settings node of the output XML packet is presented by type BackupGetRemoteStorageSettingsOutput (backup.xsd) and structured as follows:

  • The result node is required. It wraps the response retrieved from the server. Data type: resultType (common.xsd).
  • The status node is required. It specifies the execution status of the operation. Data type: string. Allowed values: ok | error.
  • The errcode node is optional. Is returns the error code if the operation fails. Data type: integer.
  • The errtext node is optional. It returns the error message if the operation fails. Data type: string.
  • The settings node is optional. It specifies settings of a remote storage if the operation succeeds. Data type: BackupRemoteStorage (backup.xsd). For details on the node, refer to the Remote Storage Settings section.

 

 

Samples

Retrieving remote storage settings for a customer account

This request packet retrieves remote storage settings for the customer account with ID 17.

<packet>
<backup-manager>
   <get-remote-storage-settings>
      <customer-id>17</customer-id>
      <protocol>ftp</protocol>
   </get-remote-storage-settings>
</backup-manager>
</packet>

 Response:

<packet version="1.6.7.0">
<backup-manager>
   <get-remote-storage-settings>
      <result>
            <status>ok</status>
            <settings>
               <protocol>ftp</protocol>
               <host>ftp.example.com</host>
               <port>113</port>
               <directory>/backups/</protocol>
               <login>myftplogin</login>
               <password>myftppassword</password>
               <passive-mode>false</passive-mode>
            </settings>
      </result>
   </get-remote-storage-settings>
</backup-manager>
</packet>

 

If the settings haven't been specified, the response from the server is as follows:

<packet version="1.6.7.0">
  <backup-manager>
    <get-remote-storage-settings>
      <result>
        <status>ok</status>
        <settings>
          <protocol>ftp</protocol>
          <host>false</host>
          <port>21</port>
          <directory>false</directory>
          <login>false</login>
          <password>false</password>
          <passive-mode>false</passive-mode>
        </settings>
      </result>
    </get-remote-storage-settings>
  </backup-manager>
</packet>

 

A negative response from the server can look as follows:

<packet version="1.6.7.0">
  <backup-manager>
    <get-remote-storage-settings>
      <result>
        <status>error</status>
        <errcode>1013</errcode>
        <errtext>client does not exist</errtext>
      </result>
    </get-remote-storage-settings>
  </backup-manager>
</packet>

 

 

Leave your comments on this page

Leave your feedback or question on this documentation topic below. For technical assistance, contact your hosting service provider or submit a request to Plesk support. Suggest new features for Plesk here. Discuss general questions on the Plesk forum. All offtopic comments will be removed.