Start a Backup Operation
/paas/api/v1.1/instancemgmt/{identityDomainId}/services/MySQLCS/instances/{serviceId}/backups
Request
- application/json
-
identityDomainId: string
Name of the identity domain for the MySQL Cloud Service account.
-
serviceId: string
The user-defined name of the Oracle MySQL Cloud Service instance.
-
X-ID-TENANT-NAME: string
Name of the identity domain for the MySQL Cloud Service account.
object
-
keepForever(optional):
boolean
Flag that specifies whether to keep the backup forever. Otherwise, full on-demand backups are retained for the default retention period defined in the backup configuration.
-
notes(optional):
string
Free-form text to provide additional information about the backup.
Response
- application/json
202 Response
object
Response Body
-
job_id(optional):
string
Job ID for the operation.
-
operationName(optional):
string
Name of the operation. For example:
start-backup
,restore-backup
, ordelete-backup
. -
target_uri(optional):
string
Target URI. Poll the URI to get the target information or status of the operation.
Examples
The following example shows how to start a backup operation by submitting a POST request on the REST endpoint using cURL.
Note: The command in this example uses the URL structure https://rest_server_url/resource-path
, where rest_server_url
is the Oracle Public Cloud or Oracle Cloud Machine REST server to contact for your identity domain or tenant name. See Send Requests for the appropriate URL structure to use on Oracle Public Cloud or Oracle Cloud Machine.
Note: Backups must be configured (enabled) for this operation to function.
Note: Sending a request body is always required, but it may be empty as demonstrated in this example by passing in an empty JSON object using curl's -d (--data) parameter.
cURL Command
curl -i -X POST \ -u "username:password" \ -H "X-ID-TENANT-NAME: ExampleIdentityDomain" \ -H "Accept: application/json" \ -H "Content-Type: application/json" \ -d '{}' \ https://rest_server_url/paas/api/v1.1/instancemgmt/ExampleIdentityDomain/services/MySQLCS/instances/MyTestInstance/backups
Example of Response Header
The following shows an example of the response header.
HTTP/1.1 202 Accepted
Server: Oracle-Application-Server-11g
Location: https://rest_server_url:443/paas/api/v1.1/activitylog/exampleidentitydomain/job/2223717
Content-Language: en
Access-Control-Allow-Headers: Content-Type, api_key, Authorization
Access-Control-Allow-Methods: GET, POST, DELETE, PUT, OPTIONS, HEAD
X-ORACLE-DMS-ECID: Ggo0RHV050R000u76o0dp503uF6EVi3SU0
X-ORACLE-DMS-ECID: Ggo0RHV050R000u76o0dp503uF6EVi3SU0
Access-Control-Allow-Origin: *
X-Frame-Options: DENY
Content-Type: application/json
Vary: user-agent
Date: Thu, 15 Dec 2016 00:51:45 GMT
Connection: close
Example of Response Body
The following shows an example of the response body in JSON format.
{ "operationName": "start-backup", "target_uri": "https:\/\/rest_surver_url:443\/paas\/api\/v1.1\/instancemgmt\/exampleidentitydomain\/services\/MySQLCS\/instances\/MyTestInstance\/backups\/302248b3-1240-474b-8022-bcb1e7907f74", "job_id": "2223717" }