Chapter 60: Controller: /siteworx/backup Up Part III: SiteWorx API Spec Chapter 62: Controller: /siteworx/cron 

61 Controller: /siteworx/backup/schedule

Required Permissions "BACKUP"
Required Options Account Backup
Action: create
Added in version 4.8.0-393
Description Add a scheduled backup.
Input Parameters
Name Type Notes Required?
frequency string Example Values
weekly, monthly
Yes
type string Example Values
full, partial, structure
Yes
location string Example Values
siteworx, local, ftp, scp
Yes
email_address string Example Default Value
user@example.com
No*
rotate integer Help Entry
Indicates the maximum number of backups to keep before removing old backups.
Example Default Value
4
No*
hour integer Example Values
0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23
Example Default Value
0
No*
day_of_week integer Example Values
0, 1, 2, 3, 4, 5, 6
Yes
* indicates that it’s actually required, but probably already has a valid default value
Action: delete
Added in version 4.8.0-393
Description Deletes the scheduled backup.
Input Parameters
Name Type Notes Required?
scheduled struct (integer) Example Values
133
Yes
Action: edit
Added in version 5.0.14-579
Description Edit a scheduled backup.
Input Parameters
Name Type Notes Required?
id integer Yes
frequency string Example Values
daily, weekly, monthly
Yes
type string Example Values
full, partial, structure
Yes
location string Example Values
siteworx, local, ftp, scp
Yes
email_address string Example Default Value
user@example.com
No*
rotate integer Help Entry
Indicates the maximum number of backups to keep before removing old backups.
Example Default Value
2
No*
hour integer Example Values
0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23
Example Default Value
1
No*
* indicates that it’s actually required, but probably already has a valid default value
Action: listScheduled
Added in version 4.8.0-393
Description Lists all the scheduled backups for the current SiteWorx user.
Sample output
array (
’status’ => 0,
’payload’ =>
array (
0 =>
array (
’id’ => ’133’,
’siteworx_id’ => ’278’,
’email_address’ => ’user@example.com’,
’rotate’ => ’2’,
’frequency’ => ’daily’,
’hour’ => ’1’,
’day_of_month’ => ’*’,
’day_of_week’ => ’*’,
’type’ => ’structure’,
’backup_dbs’ => ’0’,
’backup_web’ => ’0’,
’backup_mail’ => ’0’,
’location’ => ’siteworx’,
’location_data’ => ’[]’,
),
),
)
Action: queryEdit
Added in version 5.1.0-838
Description Displays the information available to the action "edit".
Input Parameters
Name Type Notes Required?
id integer Yes
frequency string Example Values
daily, weekly, monthly
Yes
type string Example Values
full, partial, structure
Yes
location string Example Values
siteworx, local, ftp, scp
Yes
Sample output
array (
’status’ => 0,
’payload’ =>
array (
’siteworx_id’ => ’278’,
’email_address’ => ’user@example.com’,
’type_copy’ => ’full’,
’location_copy’ => ’siteworx’,
’rotate’ => ’2’,
’frequency_copy’ => ’daily’,
’hour’ => ’1’,
’day_of_week’ => ’*’,
’day_of_month’ => ’*’,
’id’ => ’133’,
’frequency’ => ’daily’,
’type’ => ’full’,
’location’ => ’siteworx’,
),
)
 Chapter 60: Controller: /siteworx/backup Up Part III: SiteWorx API Spec Chapter 62: Controller: /siteworx/cron 

(C) 2017 by InterWorx LLC