Import website from archive
Imports an Agency Plan website from an already-uploaded archive.
Imports an Agency Plan website from an already-uploaded archive.
Upload the archive to the website's root directory via file browser first, then provide its filename in this request. Website contents are overwritten by the archive contents. Supported archive types: .zip, .tar, .tar.gz, .tgz.
Authorizations
AuthorizationstringRequired
API Token authentication
Path parameters
website_uidstringRequiredExample:
Agency Plan website UID
zpwlGlp19Body
Import a website from an already-uploaded archive
archive_namestringRequiredExample:
Archive filename (e.g., archive.zip). The file must already be uploaded to the website's .h5g/ directory.
archive.zipResponses
200
Success empty response
application/json
messagestringOptionalExample:
Request accepted401
Unauthenticated response
application/json
422
Validation error response
application/json
500
Error response
application/json
post/api/agency-hosting/v1/websites/{website_uid}/files/import-archive
POST /api/agency-hosting/v1/websites/{website_uid}/files/import-archive HTTP/1.1
Host: developers.hostinger.com
Authorization: Bearer YOUR_SECRET_TOKEN
Content-Type: application/json
Accept: */*
Content-Length: 30
{
"archive_name": "archive.zip"
}{
"message": "Request accepted"
}Last updated
Was this helpful?