Description

This function starts a single WordPress® site backup.


You must install the WordPress Manager cPanel plugin to access this API function.


Examples 




https://hostname.example.com:2083/cpsess##########/execute/WordPressBackup/start?site=example.com



$cpanel = new CPANEL(); // Connect to cPanel - only do this once.
 
// Start the WordPress site backup.
 $instances = $cpanel->uapi(
    'WordPressBackup', 'start',
	array(	
		'site' => 'example.com'
	)
);



my $cpliveapi = Cpanel::LiveAPI->new(); # Connect to cPanel - only do this once.
 
# Start the WordPress site backup.
my $instances = $cpliveapi->uapi(
    'WordPressBackup', 'start',
	{
		'site' => 'example.com'
	}
);



<!-- Start the WordPress site backup. -->
[% data = execute( 'WordPressBackup', 'start', { 'site' => 'example.com' } ); %]



uapi --user=username WordPressBackup start site=example.com



{
	"data": {
		"sse_url": "/sse/WordPressBackup",
		"site": "example.com",
		"backup_id": "example.com__2018-10-10T10:53:31-0500"
	},
	"status": 1,
	"errors": null,
	"metadata": {},
	"warnings": null,
	"messages": null
}



Parameters

ParameterTypeDescriptionPossible valuesExample
sitestring

Required

The WordPress site's URL.

A URL without the protocol prefix.


example.com


example.com/wordpress


Returns

ReturnTypeDescriptionPossible valuesExample
sitestringThe WordPress site's URL.A URL without the protocol prefix.example.com
backup_idstringThe unique ID of the backup process.A valid string.

example.com__2018-10-10T10:53:31-0500

sse_url

stringThe SSE path that the system uses to monitor the backup progress.The path to the SSE service, without the protocol, hostname, or port./sse/WordPressBackup