Skip to content

Backup and Restore ​

13 operations. Call any of them with omada_call_operation (or, in full tool mode, as a tool named by its operationId).

OperationMethodSummary
backupFileServerPOSTBackup controller config to file server
getSelfServerFileListGETGet controller backup file list in self server
getBackupResultGETGet controller backup result
backupSelfServerPOSTBackup controller config to cloud server
restoreFileServerPOSTRestore controller config from file server
getRestoreResultGETGet controller restore result
restoreSelfServerPOSTRestore controller config from cloud server
getSiteBackupResultGETGet site backup result
getSelfServerSiteFileListGETGet site backup file list in self server
backupSitesFileServerPOSTBackup multi sites config to file server
backupSitesSelfServerPOSTBackup multi sites config to self server
restoreSitesFileServerPOSTRestore multi sites config from file server
restoreSitesSelfServerPOSTRestore multi sites config from self server

backupFileServer ​

POST /openapi/v1/{omadacId}/maintenance/backup/file-server

Backup controller config to file server

ParameterInTypeRequiredDescription
omadacIdpathstringautoOmada ID (filled in automatically)

Request body — application/json (required) — schema FileServerGlobalBackupVO

FieldTypeRequiredDescription
serverConfigFileServerOpenApiVOyes(FileServerOpenApiVO not expanded; call omada_get_schema "FileServerOpenApiVO")
filePathstringyesSaving directory path for backup file. Parameter [filePath] should be 1 - 128 ASCII characters.
retainUserbooleannoWhether need retain user info.
retainAuthRecordbooleannoWhether need retain auth record.
retainFirmwareLogbooleannoWhether need retain firmware log.
retentionintegernoBackup data retention, values are as follows: 0 :no limit others:7,30,60,90,180,365.
json
// omada_call_operation
{
  "operationId": "backupFileServer",
  "body": "{...}"
}
Details, permissions and error codes

Backup controller config to file server.
The interface requires one of the permissions:
Global Other Setting Modify
The possible error code for the interface in the returned body is one of the following error codes (non generic error codes):
-30028 - Operation failed because other operations (backuping, site copying, customer copying, etc.) are being performed on this organization. Please wait and try again later.
-30301 - Backing up...
-30304 - Restoring...
-30309 - Failed to back up the configurations.
-30320 - Failed to connect to the file server. The file server may not exist or it is temporarily unavailable. Please check the information and your network connection, and try again.

getSelfServerFileList ​

GET /openapi/v1/{omadacId}/maintenance/backup/files

Get controller backup file list in self server

ParameterInTypeRequiredDescription
omadacIdpathstringautoOmada ID (filled in automatically)
json
// omada_call_operation
{
  "operationId": "getSelfServerFileList"
}
Details, permissions and error codes

Get controller backup file list in self server.
The interface requires one of the permissions:
Global Other Setting Modify
The possible error code for the interface in the returned body is one of the following error codes (non generic error codes):
-30028 - Operation failed because other operations (backuping, site copying, customer copying, etc.) are being performed on this organization. Please wait and try again later.

getBackupResult ​

GET /openapi/v1/{omadacId}/maintenance/backup/result

Get controller backup result

ParameterInTypeRequiredDescription
omadacIdpathstringautoOmada ID (filled in automatically)
json
// omada_call_operation
{
  "operationId": "getBackupResult"
}
Details, permissions and error codes

Get controller backup result.
The interface requires one of the permissions:
Global Other Setting Modify
The possible error code for the interface in the returned body is one of the following error codes (non generic error codes):
-30028 - Operation failed because other operations (backuping, site copying, customer copying, etc.) are being performed on this organization. Please wait and try again later.
-30309 - Failed to back up the configurations.

backupSelfServer ​

POST /openapi/v1/{omadacId}/maintenance/backup/self-server

Backup controller config to cloud server

ParameterInTypeRequiredDescription
omadacIdpathstringautoOmada ID (filled in automatically)

Request body — application/json (required) — schema SelfGlobalBackupVO

FieldTypeRequiredDescription
retainUserbooleanyesWhether saving user info.
json
// omada_call_operation
{
  "operationId": "backupSelfServer",
  "body": "{...}"
}
Details, permissions and error codes

Backup controller config to cloud server.
The interface requires one of the permissions:
Global Other Setting Modify
The possible error code for the interface in the returned body is one of the following error codes (non generic error codes):
-30028 - Operation failed because other operations (backuping, site copying, customer copying, etc.) are being performed on this organization. Please wait and try again later.
-30301 - Backing up...
-30304 - Restoring...
-30309 - Failed to back up the configurations.

restoreFileServer ​

POST /openapi/v1/{omadacId}/maintenance/restore/file-server

Restore controller config from file server

ParameterInTypeRequiredDescription
omadacIdpathstringautoOmada ID (filled in automatically)

Request body — application/json (required) — schema FileServerGlobalRestoreVO

FieldTypeRequiredDescription
serverConfigFileServerOpenApiVOyes(FileServerOpenApiVO not expanded; call omada_get_schema "FileServerOpenApiVO")
filePathstringyesSaving directory path for backup file. Parameter [filePath] should be 1 - 128 ASCII characters.
skipDevicebooleanyesWhether skip import devices.
json
// omada_call_operation
{
  "operationId": "restoreFileServer",
  "body": "{...}"
}
Details, permissions and error codes

Restore controller config from file server.
The interface requires one of the permissions:
Global Other Setting Modify
The possible error code for the interface in the returned body is one of the following error codes (non generic error codes):
-30028 - Operation failed because other operations (backuping, site copying, customer copying, etc.) are being performed on this organization. Please wait and try again later.
-30304 - Restoring...
-30305 - Failed to restore because of unexpected errors. Please try again later.
-30320 - Failed to connect to the file server. The file server may not exist or it is temporarily unavailable. Please check the information and your network connection, and try again.

getRestoreResult ​

GET /openapi/v1/{omadacId}/maintenance/restore/result

Get controller restore result

ParameterInTypeRequiredDescription
omadacIdpathstringautoOmada ID (filled in automatically)
json
// omada_call_operation
{
  "operationId": "getRestoreResult"
}
Details, permissions and error codes

Get controller restore result.
The interface requires one of the permissions:
Global Other Setting Modify
Maintenance Page Modify
The possible error code for the interface in the returned body is one of the following error codes (non generic error codes):
-30028 - Operation failed because other operations (backuping, site copying, customer copying, etc.) are being performed on this organization. Please wait and try again later.
-30303 - Failed to restore because the file is incompatible.
-30305 - Failed to restore because of unexpected errors. Please try again later.
-30307 - Invalid configuration file. Please select the configuration file of the same integrated gateway model.
-30317 - Cannot restore a site-level backup file into the controller. Please go to global Dashboard > Site List to import
-30318 - Invalid file. To restore controller data, please go to Settings > Maintenance > Backup & Restore.
-30319 - Failed to restore due to database anomaly, please try again later.
-30326 - The devices in the customer configuration file are duplicate with the adopted devices and cannot be imported.

restoreSelfServer ​

POST /openapi/v1/{omadacId}/maintenance/restore/self-server

Restore controller config from cloud server

ParameterInTypeRequiredDescription
omadacIdpathstringautoOmada ID (filled in automatically)

Request body — application/json (required) — schema SelfGlobalRestoreVO

FieldTypeRequiredDescription
fileNamestringyesSite backup file name. Parameter [fileName] should be 1 - 128 ASCII characters.
json
// omada_call_operation
{
  "operationId": "restoreSelfServer",
  "body": "{...}"
}
Details, permissions and error codes

Restore controller config from cloud server.
The interface requires one of the permissions:
Global Other Setting Modify
The possible error code for the interface in the returned body is one of the following error codes (non generic error codes):
-30028 - Operation failed because other operations (backuping, site copying, customer copying, etc.) are being performed on this organization. Please wait and try again later.
-30304 - Restoring...
-30305 - Failed to restore because of unexpected errors. Please try again later.

getSiteBackupResult ​

GET /openapi/v1/{omadacId}/sites/{siteId}/backup/result

Get site backup result

ParameterInTypeRequiredDescription
omadacIdpathstringautoOmada ID (filled in automatically)
siteIdpathstringyesSite ID (site ID or site name)
json
// omada_call_operation
{
  "operationId": "getSiteBackupResult",
  "params": {
    "siteId": "<siteId>"
  }
}
Details, permissions and error codes

Get site backup result.
The interface requires one of the permissions:
Maintenance Page Modify
The possible error code for the interface in the returned body is one of the following error codes (non generic error codes):
-30028 - Operation failed because other operations (backuping, site copying, customer copying, etc.) are being performed on this organization. Please wait and try again later.
-30309 - Failed to back up the configurations.

getSelfServerSiteFileList ​

GET /openapi/v1/{omadacId}/sites/{siteId}/maintenance/backup/files

Get site backup file list in self server

ParameterInTypeRequiredDescription
omadacIdpathstringautoOmada ID (filled in automatically)
siteIdpathstringyesSite ID (site ID or site name)
json
// omada_call_operation
{
  "operationId": "getSelfServerSiteFileList",
  "params": {
    "siteId": "<siteId>"
  }
}
Details, permissions and error codes

Get site backup file list in self server.
The interface requires one of the permissions:
Maintenance Page Modify
The possible error code for the interface in the returned body is one of the following error codes (non generic error codes):
-30028 - Operation failed because other operations (backuping, site copying, customer copying, etc.) are being performed on this organization. Please wait and try again later.

backupSitesFileServer ​

POST /openapi/v1/{omadacId}/sites/maintenance/multi-backup/file-server

Backup multi sites config to file server

ParameterInTypeRequiredDescription
omadacIdpathstringautoOmada ID (filled in automatically)

Request body — application/json (required) — schema FileServerSiteBackupVO

FieldTypeRequiredDescription
serverConfigFileServerOpenApiVOyes(FileServerOpenApiVO not expanded; call omada_get_schema "FileServerOpenApiVO")
filePathstringyesSaving path of directory for all backup config files, example: /backup. Parameter [filePath] should be 1 - 128 ASCII characters.
siteIdsarray<string>yesSite ID list to backup, up to 300 entries are allowed for the site ID list.
json
// omada_call_operation
{
  "operationId": "backupSitesFileServer",
  "body": "{...}"
}
Details, permissions and error codes

Backup multi sites config to file server. At most 300 sites can backup.
The interface requires one of the permissions:
Maintenance Page Modify
The possible error code for the interface in the returned body is one of the following error codes (non generic error codes):
-30028 - Operation failed because other operations (backuping, site copying, customer copying, etc.) are being performed on this organization. Please wait and try again later.
-30301 - Backing up...
-30304 - Restoring...
-30309 - Failed to back up the configurations.
-30320 - Failed to connect to the file server. The file server may not exist or it is temporarily unavailable. Please check the information and your network connection, and try again.

backupSitesSelfServer ​

POST /openapi/v1/{omadacId}/sites/maintenance/multi-backup/self-server

Backup multi sites config to self server

ParameterInTypeRequiredDescription
omadacIdpathstringautoOmada ID (filled in automatically)

Request body — application/json (required) — schema BatchSiteBackupVO

FieldTypeRequiredDescription
siteIdsarray<string>yesSite ID list to backup, at least one site, max 300 sites.
json
// omada_call_operation
{
  "operationId": "backupSitesSelfServer",
  "body": "{...}"
}
Details, permissions and error codes

Backup multi sites config to self server. At most 300 sites can backup.
The interface requires one of the permissions:
Maintenance Page Modify
The possible error code for the interface in the returned body is one of the following error codes (non generic error codes):
-30028 - Operation failed because other operations (backuping, site copying, customer copying, etc.) are being performed on this organization. Please wait and try again later.
-30301 - Backing up...
-30304 - Restoring...
-30309 - Failed to back up the configurations.

restoreSitesFileServer ​

POST /openapi/v1/{omadacId}/sites/maintenance/multi-restore/file-server

Restore multi sites config from file server

ParameterInTypeRequiredDescription
omadacIdpathstringautoOmada ID (filled in automatically)

Request body — application/json (required) — schema BatchSiteFileServerRestoreVO

FieldTypeRequiredDescription
serverConfigFileServerOpenApiVOyes(FileServerOpenApiVO not expanded; call omada_get_schema "FileServerOpenApiVO")
siteInfosarray<FileServerSiteRestoreVO>yesSites to restore.
json
// omada_call_operation
{
  "operationId": "restoreSitesFileServer",
  "body": "{...}"
}
Details, permissions and error codes

Restore multi sites config from file server. At most 300 sites can be restored.
The interface requires one of the permissions:
Maintenance Page Modify
The possible error code for the interface in the returned body is one of the following error codes (non generic error codes):
-30028 - Operation failed because other operations (backuping, site copying, customer copying, etc.) are being performed on this organization. Please wait and try again later.
-30304 - Restoring...
-30305 - Failed to restore because of unexpected errors. Please try again later.
-30320 - Failed to connect to the file server. The file server may not exist or it is temporarily unavailable. Please check the information and your network connection, and try again.

restoreSitesSelfServer ​

POST /openapi/v1/{omadacId}/sites/maintenance/multi-restore/self-server

Restore multi sites config from self server

ParameterInTypeRequiredDescription
omadacIdpathstringautoOmada ID (filled in automatically)

Request body — application/json (required) — schema BatchSiteSelfRestoreVO

FieldTypeRequiredDescription
siteRestoreInfosarray<SelfSiteRestoreVO>yesSite restore info list to restore. Up to 300 entries are allowed for the site restore info list.
json
// omada_call_operation
{
  "operationId": "restoreSitesSelfServer",
  "body": "{...}"
}
Details, permissions and error codes

Restore multi sites config from self server. At most 300 sites can be restored.
The interface requires one of the permissions:
Maintenance Page Modify
The possible error code for the interface in the returned body is one of the following error codes (non generic error codes):
-30028 - Operation failed because other operations (backuping, site copying, customer copying, etc.) are being performed on this organization. Please wait and try again later.
-30304 - Restoring...
-30305 - Failed to restore because of unexpected errors. Please try again later.

Released under the MIT License. Not affiliated with or endorsed by TP-Link.