This function restores an account's files.
Important:
When the File Storage role is disabled, the system also disables this function.
Note:
You must use the backup
parameter when you call this function in one of the following formats:
multipart/form-data
request body to upload and restore a backup file to the server. For more information about this structure, read Mozilla's POST Method documentation.The backup file to upload and restore.
Important:
Note:
To upload and restore multiple backup files, increment the parameter name. For example: backup-1
, backup-2
, and backup-3
.
uapi --input=json --output=jsonpretty \ --user=username \ Backup \ restore_files
{- "apiversion": 3,
- "func": "restore_files",
- "module": "Backup",
- "result": {
- "data": {
- "log_id": "2019-08-13T15:10:07Z.1",
- "log_path": "/home/cptest/.cpanel/logs/restorefiles/2019-08-13T15:10:07Z.1.log",
- "messages": [
- "The system successfully restored the directory /home/cpuser/point2 from the backup file backup-cpuser.tld-9-10-2019_1.tar.gz"
]
}, - "errors": null,
- "messages": null,
- "metadata": { },
- "status": 1,
- "warnings": null
}
}