All URIs are relative to http://localhost
| Method | HTTP request | Description |
|---|---|---|
| GetSnapshot | Get /v1/projects/{projectId}/snapshots/{id} | Get Snapshot |
| HoldSnapshot | Patch /v1/projects/{projectId}/snapshots/{id}/hold | Hold Snapshot |
| ListResourceSnapshots | Post /v1/projects/{projectId}/resources/{id}/snapshots | List Resource Snapshots |
| RemoveSnapshotHold | Patch /v1/projects/{projectId}/snapshots/{id}/remove-hold | Remove Snapshot Hold |
| RestoreAzureDisk | Post /v1/projects/{projectId}/resources/{id}/snapshots/{snapshotId}/restore-azure-disk | Restore Azure Disk |
| RestoreAzureSqlDatabase | Post /v1/projects/{projectId}/resources/{id}/snapshots/{snapshotId}/restore-azure-sql-database | Restore Azure SQL Database |
| RestoreAzureVmInstance | Post /v1/projects/{projectId}/resources/{id}/snapshots/{snapshotId}/restore-azure-vm-instance | Restore Azure VM Instance |
| RestoreBigQueryDataset | Post /v1/projects/{projectId}/resources/{id}/snapshots/{snapshotId}/restore-bigquery-dataset | Restore BigQuery Dataset |
| RestoreBucket | Post /v1/projects/{projectId}/resources/{id}/snapshots/{snapshotId}/restore-bucket | Restore Bucket |
| RestoreDatabase | Post /v1/projects/{projectId}/resources/{id}/snapshots/{snapshotId}/restore-rds-instance | Restore RDS Instance |
| RestoreDynamoDBTable | Post /v1/projects/{projectId}/resources/{id}/snapshots/{snapshotId}/restore-dynamo-db-table | Restore DynamoDB Table |
| RestoreEbsVolume | Post /v1/projects/{projectId}/resources/{id}/snapshots/{snapshotId}/restore-ec2-ebs-volume | Restore EBS Volume |
| RestoreEc2Instance | Post /v1/projects/{projectId}/resources/{id}/snapshots/{snapshotId}/restore-ec2-instance | Restore EC2 Instance |
| RestoreFiles | Post /v1/projects/{projectId}/resources/{id}/snapshots/{snapshotId}/restore-files | Restore Files |
| RestoreGcpCloudSql | Post /v1/projects/{projectId}/resources/{id}/snapshots/{snapshotId}/restore-gcp-cloudsql | Restore GCP Cloud SQL Instance |
| RestoreGcpDisk | Post /v1/projects/{projectId}/resources/{id}/snapshots/{snapshotId}/restore-gcp-disk | Restore GCP Disk |
| RestoreGcpVmInstance | Post /v1/projects/{projectId}/resources/{id}/snapshots/{snapshotId}/restore-gcp-vm-instance | Restore GCP VM Instance |
| RestoreToEbsSnapshot | Post /v1/projects/{projectId}/resources/{id}/snapshots/{snapshotId}/convert-ec2-ebs-snapshot | Restore to EBS Snapshot |
GetSnapshotResponse GetSnapshot(ctx, projectId, id).Execute()
Get Snapshot
package main
import (
"context"
"fmt"
"os"
openapiclient "github.com/eon-io/eon-service/services/frontend/api-gateway/sdk/external-go"
)
func main() {
projectId := "1ee34dc5-0a7c-4e56-a820-917371e05c8d" // string | ID of the project the snapshot is in. You can get your project ID from the [API Credentials](https://console.eon.io/global-management/api-credentials) page in your global management console.
id := "043090df-9fe5-4f89-9859-45db589c2936" // string | ID of the Eon snapshot to retrieve.
configuration := openapiclient.NewConfiguration()
apiClient := openapiclient.NewAPIClient(configuration)
resp, r, err := apiClient.SnapshotsAPI.GetSnapshot(context.Background(), projectId, id).Execute()
if err != nil {
fmt.Fprintf(os.Stderr, "Error when calling `SnapshotsAPI.GetSnapshot``: %v\n", err)
fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r)
}
// response from `GetSnapshot`: GetSnapshotResponse
fmt.Fprintf(os.Stdout, "Response from `SnapshotsAPI.GetSnapshot`: %v\n", resp)
}| Name | Type | Description | Notes |
|---|---|---|---|
| ctx | context.Context | context for authentication, logging, cancellation, deadlines, tracing, etc. | |
| projectId | string | ID of the project the snapshot is in. You can get your project ID from the API Credentials page in your global management console. | |
| id | string | ID of the Eon snapshot to retrieve. |
Other parameters are passed through a pointer to a apiGetSnapshotRequest struct via the builder pattern
| Name | Type | Description | Notes |
|---|
- Content-Type: Not defined
- Accept: application/json
[Back to top] [Back to API list] [Back to Model list] [Back to README]
map[string]interface{} HoldSnapshot(ctx, projectId, id).HoldSnapshotRequest(holdSnapshotRequest).Execute()
Hold Snapshot
package main
import (
"context"
"fmt"
"os"
openapiclient "github.com/eon-io/eon-service/services/frontend/api-gateway/sdk/external-go"
)
func main() {
projectId := "1ee34dc5-0a7c-4e56-a820-917371e05c8d" // string | ID of the project the snapshot is in. You can get your project ID from the [API Credentials](https://console.eon.io/global-management/api-credentials) page in your global management console.
id := "043090df-9fe5-4f89-9859-45db589c2936" // string | ID of the Eon snapshot.
holdSnapshotRequest := *openapiclient.NewHoldSnapshotRequest() // HoldSnapshotRequest | (optional)
configuration := openapiclient.NewConfiguration()
apiClient := openapiclient.NewAPIClient(configuration)
resp, r, err := apiClient.SnapshotsAPI.HoldSnapshot(context.Background(), projectId, id).HoldSnapshotRequest(holdSnapshotRequest).Execute()
if err != nil {
fmt.Fprintf(os.Stderr, "Error when calling `SnapshotsAPI.HoldSnapshot``: %v\n", err)
fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r)
}
// response from `HoldSnapshot`: map[string]interface{}
fmt.Fprintf(os.Stdout, "Response from `SnapshotsAPI.HoldSnapshot`: %v\n", resp)
}| Name | Type | Description | Notes |
|---|---|---|---|
| ctx | context.Context | context for authentication, logging, cancellation, deadlines, tracing, etc. | |
| projectId | string | ID of the project the snapshot is in. You can get your project ID from the API Credentials page in your global management console. | |
| id | string | ID of the Eon snapshot. |
Other parameters are passed through a pointer to a apiHoldSnapshotRequest struct via the builder pattern
| Name | Type | Description | Notes |
|---|
holdSnapshotRequest | HoldSnapshotRequest | |
map[string]interface{}
- Content-Type: application/json
- Accept: application/json
[Back to top] [Back to API list] [Back to Model list] [Back to README]
ListInventorySnapshotsResponse ListResourceSnapshots(ctx, projectId, id).PageToken(pageToken).PageSize(pageSize).ListInventorySnapshotsRequest(listInventorySnapshotsRequest).Execute()
List Resource Snapshots
package main
import (
"context"
"fmt"
"os"
openapiclient "github.com/eon-io/eon-service/services/frontend/api-gateway/sdk/external-go"
)
func main() {
projectId := "1ee34dc5-0a7c-4e56-a820-917371e05c8d" // string | ID of the project the resource is in. You can get your project ID from the [API Credentials](https://console.eon.io/global-management/api-credentials) page in your global management console.
id := "043090df-9fe5-4f89-9859-45db589c2936" // string | Eon-assigned ID of the resource whose Eon snapshots you want to retrieve.
pageToken := "OGRjZmRkNjYtZjJiMy00MmQ3LWIyMjMtNzU2M2NmMThiYWM2fDE=" // string | Cursor that points to the first record of the next page of results. Get this value from the previous response. To preserve the results in the same order, use the same sorting and filters in the first request as all subsequent requests. (optional)
pageSize := int32(10) // int32 | Maximum number of items to return in the response. (optional) (default to 50)
listInventorySnapshotsRequest := *openapiclient.NewListInventorySnapshotsRequest() // ListInventorySnapshotsRequest | (optional)
configuration := openapiclient.NewConfiguration()
apiClient := openapiclient.NewAPIClient(configuration)
resp, r, err := apiClient.SnapshotsAPI.ListResourceSnapshots(context.Background(), projectId, id).PageToken(pageToken).PageSize(pageSize).ListInventorySnapshotsRequest(listInventorySnapshotsRequest).Execute()
if err != nil {
fmt.Fprintf(os.Stderr, "Error when calling `SnapshotsAPI.ListResourceSnapshots``: %v\n", err)
fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r)
}
// response from `ListResourceSnapshots`: ListInventorySnapshotsResponse
fmt.Fprintf(os.Stdout, "Response from `SnapshotsAPI.ListResourceSnapshots`: %v\n", resp)
}| Name | Type | Description | Notes |
|---|---|---|---|
| ctx | context.Context | context for authentication, logging, cancellation, deadlines, tracing, etc. | |
| projectId | string | ID of the project the resource is in. You can get your project ID from the API Credentials page in your global management console. | |
| id | string | Eon-assigned ID of the resource whose Eon snapshots you want to retrieve. |
Other parameters are passed through a pointer to a apiListResourceSnapshotsRequest struct via the builder pattern
| Name | Type | Description | Notes |
|---|
pageToken | string | Cursor that points to the first record of the next page of results. Get this value from the previous response. To preserve the results in the same order, use the same sorting and filters in the first request as all subsequent requests. | pageSize | int32 | Maximum number of items to return in the response. | [default to 50] listInventorySnapshotsRequest | ListInventorySnapshotsRequest | |
ListInventorySnapshotsResponse
- Content-Type: application/json
- Accept: application/json
[Back to top] [Back to API list] [Back to Model list] [Back to README]
map[string]interface{} RemoveSnapshotHold(ctx, projectId, id).XActionApprovalRequestId(xActionApprovalRequestId).Execute()
Remove Snapshot Hold
package main
import (
"context"
"fmt"
"os"
openapiclient "github.com/eon-io/eon-service/services/frontend/api-gateway/sdk/external-go"
)
func main() {
projectId := "1ee34dc5-0a7c-4e56-a820-917371e05c8d" // string | ID of the project the snapshot is in. You can get your project ID from the [API Credentials](https://console.eon.io/global-management/api-credentials) page in your global management console.
id := "043090df-9fe5-4f89-9859-45db589c2936" // string | ID of the Eon snapshot.
xActionApprovalRequestId := "38400000-8cf0-11bd-b23e-10b96e4ef00d" // string | ID of an approved action request. Applicable only when the method is protected by an action approval policy and the action request has been approved. When used, the current API request must match the original request parameters. The approved action request can be executed only by the original requester. (optional)
configuration := openapiclient.NewConfiguration()
apiClient := openapiclient.NewAPIClient(configuration)
resp, r, err := apiClient.SnapshotsAPI.RemoveSnapshotHold(context.Background(), projectId, id).XActionApprovalRequestId(xActionApprovalRequestId).Execute()
if err != nil {
fmt.Fprintf(os.Stderr, "Error when calling `SnapshotsAPI.RemoveSnapshotHold``: %v\n", err)
fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r)
}
// response from `RemoveSnapshotHold`: map[string]interface{}
fmt.Fprintf(os.Stdout, "Response from `SnapshotsAPI.RemoveSnapshotHold`: %v\n", resp)
}| Name | Type | Description | Notes |
|---|---|---|---|
| ctx | context.Context | context for authentication, logging, cancellation, deadlines, tracing, etc. | |
| projectId | string | ID of the project the snapshot is in. You can get your project ID from the API Credentials page in your global management console. | |
| id | string | ID of the Eon snapshot. |
Other parameters are passed through a pointer to a apiRemoveSnapshotHoldRequest struct via the builder pattern
| Name | Type | Description | Notes |
|---|
xActionApprovalRequestId | string | ID of an approved action request. Applicable only when the method is protected by an action approval policy and the action request has been approved. When used, the current API request must match the original request parameters. The approved action request can be executed only by the original requester. |
map[string]interface{}
- Content-Type: Not defined
- Accept: application/json
[Back to top] [Back to API list] [Back to Model list] [Back to README]
RestoreJobInitiationResponse RestoreAzureDisk(ctx, projectId, id, snapshotId).RestoreAzureDiskRequest(restoreAzureDiskRequest).XActionApprovalRequestId(xActionApprovalRequestId).Execute()
Restore Azure Disk
package main
import (
"context"
"fmt"
"os"
openapiclient "github.com/eon-io/eon-service/services/frontend/api-gateway/sdk/external-go"
)
func main() {
projectId := "1ee34dc5-0a7c-4e56-a820-917371e05c8d" // string | ID of the project the snapshot is in. You can get your project ID from the [API Credentials](https://console.eon.io/global-management/api-credentials) page in your global management console.
id := "043090df-9fe5-4f89-9859-45db589c2936" // string | Eon-assigned resource ID.
snapshotId := "c11d3c11-7be5-4ee4-9eb8-2024d9c04904" // string | ID of the Eon [snapshot](/api/api-reference/backup-management/snapshots/list-resource-snapshots) to restore.
restoreAzureDiskRequest := *openapiclient.NewRestoreAzureDiskRequest("/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/my-resource-group-12345/providers/Microsoft.Compute/disks/my-disk-12345", "1ee34dc5-0a7c-4e56-a820-917371e05c8d", *openapiclient.NewAzureDiskRestoreDestination()) // RestoreAzureDiskRequest |
xActionApprovalRequestId := "38400000-8cf0-11bd-b23e-10b96e4ef00d" // string | ID of an approved action request. Applicable only when the method is protected by an action approval policy and the action request has been approved. When used, the current API request must match the original request parameters. The approved action request can be executed only by the original requester. (optional)
configuration := openapiclient.NewConfiguration()
apiClient := openapiclient.NewAPIClient(configuration)
resp, r, err := apiClient.SnapshotsAPI.RestoreAzureDisk(context.Background(), projectId, id, snapshotId).RestoreAzureDiskRequest(restoreAzureDiskRequest).XActionApprovalRequestId(xActionApprovalRequestId).Execute()
if err != nil {
fmt.Fprintf(os.Stderr, "Error when calling `SnapshotsAPI.RestoreAzureDisk``: %v\n", err)
fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r)
}
// response from `RestoreAzureDisk`: RestoreJobInitiationResponse
fmt.Fprintf(os.Stdout, "Response from `SnapshotsAPI.RestoreAzureDisk`: %v\n", resp)
}| Name | Type | Description | Notes |
|---|---|---|---|
| ctx | context.Context | context for authentication, logging, cancellation, deadlines, tracing, etc. | |
| projectId | string | ID of the project the snapshot is in. You can get your project ID from the API Credentials page in your global management console. | |
| id | string | Eon-assigned resource ID. | |
| snapshotId | string | ID of the Eon snapshot to restore. |
Other parameters are passed through a pointer to a apiRestoreAzureDiskRequest struct via the builder pattern
| Name | Type | Description | Notes |
|---|
restoreAzureDiskRequest | RestoreAzureDiskRequest | | xActionApprovalRequestId | string | ID of an approved action request. Applicable only when the method is protected by an action approval policy and the action request has been approved. When used, the current API request must match the original request parameters. The approved action request can be executed only by the original requester. |
- Content-Type: application/json
- Accept: application/json
[Back to top] [Back to API list] [Back to Model list] [Back to README]
RestoreJobInitiationResponse RestoreAzureSqlDatabase(ctx, projectId, id, snapshotId).RestoreAzureSqlDatabaseRequest(restoreAzureSqlDatabaseRequest).XActionApprovalRequestId(xActionApprovalRequestId).Execute()
Restore Azure SQL Database
package main
import (
"context"
"fmt"
"os"
openapiclient "github.com/eon-io/eon-service/services/frontend/api-gateway/sdk/external-go"
)
func main() {
projectId := "1ee34dc5-0a7c-4e56-a820-917371e05c8d" // string | ID of the project the snapshot is in. You can get your project ID from the [API Credentials](https://console.eon.io/global-management/api-credentials) page in your global management console.
id := "fb806ce1-1cd3-5034-928a-33a87be714da" // string | Eon-assigned resource ID.
snapshotId := "3dc6c0c6-f94d-5e85-a174-4b981a4bb262" // string | ID of the Eon [snapshot](/api/api-reference/backup-management/snapshots/list-resource-snapshots) to restore.
restoreAzureSqlDatabaseRequest := *openapiclient.NewRestoreAzureSqlDatabaseRequest("RestoreAccountId_example", *openapiclient.NewAzureSqlDatabaseRestoreDestination()) // RestoreAzureSqlDatabaseRequest |
xActionApprovalRequestId := "38400000-8cf0-11bd-b23e-10b96e4ef00d" // string | ID of an approved action request. Applicable only when the method is protected by an action approval policy and the action request has been approved. When used, the current API request must match the original request parameters. The approved action request can be executed only by the original requester. (optional)
configuration := openapiclient.NewConfiguration()
apiClient := openapiclient.NewAPIClient(configuration)
resp, r, err := apiClient.SnapshotsAPI.RestoreAzureSqlDatabase(context.Background(), projectId, id, snapshotId).RestoreAzureSqlDatabaseRequest(restoreAzureSqlDatabaseRequest).XActionApprovalRequestId(xActionApprovalRequestId).Execute()
if err != nil {
fmt.Fprintf(os.Stderr, "Error when calling `SnapshotsAPI.RestoreAzureSqlDatabase``: %v\n", err)
fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r)
}
// response from `RestoreAzureSqlDatabase`: RestoreJobInitiationResponse
fmt.Fprintf(os.Stdout, "Response from `SnapshotsAPI.RestoreAzureSqlDatabase`: %v\n", resp)
}| Name | Type | Description | Notes |
|---|---|---|---|
| ctx | context.Context | context for authentication, logging, cancellation, deadlines, tracing, etc. | |
| projectId | string | ID of the project the snapshot is in. You can get your project ID from the API Credentials page in your global management console. | |
| id | string | Eon-assigned resource ID. | |
| snapshotId | string | ID of the Eon snapshot to restore. |
Other parameters are passed through a pointer to a apiRestoreAzureSqlDatabaseRequest struct via the builder pattern
| Name | Type | Description | Notes |
|---|
restoreAzureSqlDatabaseRequest | RestoreAzureSqlDatabaseRequest | | xActionApprovalRequestId | string | ID of an approved action request. Applicable only when the method is protected by an action approval policy and the action request has been approved. When used, the current API request must match the original request parameters. The approved action request can be executed only by the original requester. |
- Content-Type: application/json
- Accept: application/json
[Back to top] [Back to API list] [Back to Model list] [Back to README]
RestoreJobInitiationResponse RestoreAzureVmInstance(ctx, projectId, id, snapshotId).RestoreAzureVmInstanceRequest(restoreAzureVmInstanceRequest).XActionApprovalRequestId(xActionApprovalRequestId).Execute()
Restore Azure VM Instance
package main
import (
"context"
"fmt"
"os"
openapiclient "github.com/eon-io/eon-service/services/frontend/api-gateway/sdk/external-go"
)
func main() {
projectId := "1ee34dc5-0a7c-4e56-a820-917371e05c8d" // string | ID of the project the snapshot is in. You can get your project ID from the [API Credentials](https://console.eon.io/global-management/api-credentials) page in your global management console.
id := "fb806ce1-1cd3-5034-928a-33a87be714da" // string | Eon-assigned resource ID.
snapshotId := "3dc6c0c6-f94d-5e85-a174-4b981a4bb262" // string | ID of the Eon [snapshot](/api/api-reference/backup-management/snapshots/list-resource-snapshots) to restore.
restoreAzureVmInstanceRequest := *openapiclient.NewRestoreAzureVmInstanceRequest("1ee34dc5-0a7c-4e56-a820-917371e05c8d", *openapiclient.NewAzureVmInstanceRestoreDestination()) // RestoreAzureVmInstanceRequest |
xActionApprovalRequestId := "38400000-8cf0-11bd-b23e-10b96e4ef00d" // string | ID of an approved action request. Applicable only when the method is protected by an action approval policy and the action request has been approved. When used, the current API request must match the original request parameters. The approved action request can be executed only by the original requester. (optional)
configuration := openapiclient.NewConfiguration()
apiClient := openapiclient.NewAPIClient(configuration)
resp, r, err := apiClient.SnapshotsAPI.RestoreAzureVmInstance(context.Background(), projectId, id, snapshotId).RestoreAzureVmInstanceRequest(restoreAzureVmInstanceRequest).XActionApprovalRequestId(xActionApprovalRequestId).Execute()
if err != nil {
fmt.Fprintf(os.Stderr, "Error when calling `SnapshotsAPI.RestoreAzureVmInstance``: %v\n", err)
fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r)
}
// response from `RestoreAzureVmInstance`: RestoreJobInitiationResponse
fmt.Fprintf(os.Stdout, "Response from `SnapshotsAPI.RestoreAzureVmInstance`: %v\n", resp)
}| Name | Type | Description | Notes |
|---|---|---|---|
| ctx | context.Context | context for authentication, logging, cancellation, deadlines, tracing, etc. | |
| projectId | string | ID of the project the snapshot is in. You can get your project ID from the API Credentials page in your global management console. | |
| id | string | Eon-assigned resource ID. | |
| snapshotId | string | ID of the Eon snapshot to restore. |
Other parameters are passed through a pointer to a apiRestoreAzureVmInstanceRequest struct via the builder pattern
| Name | Type | Description | Notes |
|---|
restoreAzureVmInstanceRequest | RestoreAzureVmInstanceRequest | | xActionApprovalRequestId | string | ID of an approved action request. Applicable only when the method is protected by an action approval policy and the action request has been approved. When used, the current API request must match the original request parameters. The approved action request can be executed only by the original requester. |
- Content-Type: application/json
- Accept: application/json
[Back to top] [Back to API list] [Back to Model list] [Back to README]
RestoreJobInitiationResponse RestoreBigQueryDataset(ctx, projectId, id, snapshotId).RestoreBigQueryDatasetRequest(restoreBigQueryDatasetRequest).XActionApprovalRequestId(xActionApprovalRequestId).Execute()
Restore BigQuery Dataset
package main
import (
"context"
"fmt"
"os"
openapiclient "github.com/eon-io/eon-service/services/frontend/api-gateway/sdk/external-go"
)
func main() {
projectId := "1ee34dc5-0a7c-4e56-a820-917371e05c8d" // string | ID of the project the snapshot is in. You can get your project ID from the [API Credentials](https://console.eon.io/global-management/api-credentials) page in your global management console.
id := "043090df-9fe5-4f89-9859-45db589c2936" // string | Eon-assigned resource ID.
snapshotId := "c11d3c11-7be5-4ee4-9eb8-2024d9c04904" // string | ID of the Eon [snapshot](/api/api-reference/backup-management/snapshots/list-resource-snapshots) to restore.
restoreBigQueryDatasetRequest := *openapiclient.NewRestoreBigQueryDatasetRequest("1ee34dc5-0a7c-4e56-a820-917371e05c8d", *openapiclient.NewBigQueryDatasetDestination("restored_dataset")) // RestoreBigQueryDatasetRequest |
xActionApprovalRequestId := "38400000-8cf0-11bd-b23e-10b96e4ef00d" // string | ID of an approved action request. Applicable only when the method is protected by an action approval policy and the action request has been approved. When used, the current API request must match the original request parameters. The approved action request can be executed only by the original requester. (optional)
configuration := openapiclient.NewConfiguration()
apiClient := openapiclient.NewAPIClient(configuration)
resp, r, err := apiClient.SnapshotsAPI.RestoreBigQueryDataset(context.Background(), projectId, id, snapshotId).RestoreBigQueryDatasetRequest(restoreBigQueryDatasetRequest).XActionApprovalRequestId(xActionApprovalRequestId).Execute()
if err != nil {
fmt.Fprintf(os.Stderr, "Error when calling `SnapshotsAPI.RestoreBigQueryDataset``: %v\n", err)
fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r)
}
// response from `RestoreBigQueryDataset`: RestoreJobInitiationResponse
fmt.Fprintf(os.Stdout, "Response from `SnapshotsAPI.RestoreBigQueryDataset`: %v\n", resp)
}| Name | Type | Description | Notes |
|---|---|---|---|
| ctx | context.Context | context for authentication, logging, cancellation, deadlines, tracing, etc. | |
| projectId | string | ID of the project the snapshot is in. You can get your project ID from the API Credentials page in your global management console. | |
| id | string | Eon-assigned resource ID. | |
| snapshotId | string | ID of the Eon snapshot to restore. |
Other parameters are passed through a pointer to a apiRestoreBigQueryDatasetRequest struct via the builder pattern
| Name | Type | Description | Notes |
|---|
restoreBigQueryDatasetRequest | RestoreBigQueryDatasetRequest | | xActionApprovalRequestId | string | ID of an approved action request. Applicable only when the method is protected by an action approval policy and the action request has been approved. When used, the current API request must match the original request parameters. The approved action request can be executed only by the original requester. |
- Content-Type: application/json
- Accept: application/json
[Back to top] [Back to API list] [Back to Model list] [Back to README]
RestoreJobInitiationResponse RestoreBucket(ctx, projectId, id, snapshotId).RestoreBucketRequest(restoreBucketRequest).XActionApprovalRequestId(xActionApprovalRequestId).Execute()
Restore Bucket
package main
import (
"context"
"fmt"
"os"
openapiclient "github.com/eon-io/eon-service/services/frontend/api-gateway/sdk/external-go"
)
func main() {
projectId := "1ee34dc5-0a7c-4e56-a820-917371e05c8d" // string | ID of the project the snapshot is in. You can get your project ID from the [API Credentials](https://console.eon.io/global-management/api-credentials) page in your global management console.
id := "043090df-9fe5-4f89-9859-45db589c2936" // string | Eon-assigned resource ID.
snapshotId := "c11d3c11-7be5-4ee4-9eb8-2024d9c04904" // string | ID of the Eon [snapshot](/api/api-reference/backup-management/snapshots/list-resource-snapshots) to restore.
restoreBucketRequest := *openapiclient.NewRestoreBucketRequest(*openapiclient.NewObjectStorageDestination(), "1ee34dc5-0a7c-4e56-a820-917371e05c8d") // RestoreBucketRequest |
xActionApprovalRequestId := "38400000-8cf0-11bd-b23e-10b96e4ef00d" // string | ID of an approved action request. Applicable only when the method is protected by an action approval policy and the action request has been approved. When used, the current API request must match the original request parameters. The approved action request can be executed only by the original requester. (optional)
configuration := openapiclient.NewConfiguration()
apiClient := openapiclient.NewAPIClient(configuration)
resp, r, err := apiClient.SnapshotsAPI.RestoreBucket(context.Background(), projectId, id, snapshotId).RestoreBucketRequest(restoreBucketRequest).XActionApprovalRequestId(xActionApprovalRequestId).Execute()
if err != nil {
fmt.Fprintf(os.Stderr, "Error when calling `SnapshotsAPI.RestoreBucket``: %v\n", err)
fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r)
}
// response from `RestoreBucket`: RestoreJobInitiationResponse
fmt.Fprintf(os.Stdout, "Response from `SnapshotsAPI.RestoreBucket`: %v\n", resp)
}| Name | Type | Description | Notes |
|---|---|---|---|
| ctx | context.Context | context for authentication, logging, cancellation, deadlines, tracing, etc. | |
| projectId | string | ID of the project the snapshot is in. You can get your project ID from the API Credentials page in your global management console. | |
| id | string | Eon-assigned resource ID. | |
| snapshotId | string | ID of the Eon snapshot to restore. |
Other parameters are passed through a pointer to a apiRestoreBucketRequest struct via the builder pattern
| Name | Type | Description | Notes |
|---|
restoreBucketRequest | RestoreBucketRequest | | xActionApprovalRequestId | string | ID of an approved action request. Applicable only when the method is protected by an action approval policy and the action request has been approved. When used, the current API request must match the original request parameters. The approved action request can be executed only by the original requester. |
- Content-Type: application/json
- Accept: application/json
[Back to top] [Back to API list] [Back to Model list] [Back to README]
RestoreJobInitiationResponse RestoreDatabase(ctx, projectId, id, snapshotId).RestoreDbToRdsInstanceRequest(restoreDbToRdsInstanceRequest).XActionApprovalRequestId(xActionApprovalRequestId).Execute()
Restore RDS Instance
package main
import (
"context"
"fmt"
"os"
openapiclient "github.com/eon-io/eon-service/services/frontend/api-gateway/sdk/external-go"
)
func main() {
projectId := "1ee34dc5-0a7c-4e56-a820-917371e05c8d" // string | ID of the project the snapshot is in. You can get your project ID from the [API Credentials](https://console.eon.io/global-management/api-credentials) page in your global management console.
id := "043090df-9fe5-4f89-9859-45db589c2936" // string | Eon-assigned resource ID.
snapshotId := "c11d3c11-7be5-4ee4-9eb8-2024d9c04904" // string | ID of the Eon [snapshot](/api/api-reference/backup-management/snapshots/list-resource-snapshots) to restore.
restoreDbToRdsInstanceRequest := *openapiclient.NewRestoreDbToRdsInstanceRequest("1ee34dc5-0a7c-4e56-a820-917371e05c8d", *openapiclient.NewDatabaseDestination()) // RestoreDbToRdsInstanceRequest |
xActionApprovalRequestId := "38400000-8cf0-11bd-b23e-10b96e4ef00d" // string | ID of an approved action request. Applicable only when the method is protected by an action approval policy and the action request has been approved. When used, the current API request must match the original request parameters. The approved action request can be executed only by the original requester. (optional)
configuration := openapiclient.NewConfiguration()
apiClient := openapiclient.NewAPIClient(configuration)
resp, r, err := apiClient.SnapshotsAPI.RestoreDatabase(context.Background(), projectId, id, snapshotId).RestoreDbToRdsInstanceRequest(restoreDbToRdsInstanceRequest).XActionApprovalRequestId(xActionApprovalRequestId).Execute()
if err != nil {
fmt.Fprintf(os.Stderr, "Error when calling `SnapshotsAPI.RestoreDatabase``: %v\n", err)
fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r)
}
// response from `RestoreDatabase`: RestoreJobInitiationResponse
fmt.Fprintf(os.Stdout, "Response from `SnapshotsAPI.RestoreDatabase`: %v\n", resp)
}| Name | Type | Description | Notes |
|---|---|---|---|
| ctx | context.Context | context for authentication, logging, cancellation, deadlines, tracing, etc. | |
| projectId | string | ID of the project the snapshot is in. You can get your project ID from the API Credentials page in your global management console. | |
| id | string | Eon-assigned resource ID. | |
| snapshotId | string | ID of the Eon snapshot to restore. |
Other parameters are passed through a pointer to a apiRestoreDatabaseRequest struct via the builder pattern
| Name | Type | Description | Notes |
|---|
restoreDbToRdsInstanceRequest | RestoreDbToRdsInstanceRequest | | xActionApprovalRequestId | string | ID of an approved action request. Applicable only when the method is protected by an action approval policy and the action request has been approved. When used, the current API request must match the original request parameters. The approved action request can be executed only by the original requester. |
- Content-Type: application/json
- Accept: application/json
[Back to top] [Back to API list] [Back to Model list] [Back to README]
RestoreJobInitiationResponse RestoreDynamoDBTable(ctx, projectId, id, snapshotId).RestoreDynamoDBTableRequest(restoreDynamoDBTableRequest).XActionApprovalRequestId(xActionApprovalRequestId).Execute()
Restore DynamoDB Table
package main
import (
"context"
"fmt"
"os"
openapiclient "github.com/eon-io/eon-service/services/frontend/api-gateway/sdk/external-go"
)
func main() {
projectId := "1ee34dc5-0a7c-4e56-a820-917371e05c8d" // string | ID of the project the snapshot is in. You can get your project ID from the [API Credentials](https://console.eon.io/global-management/api-credentials) page in your global management console.
id := "2f97ca76-6a78-55d8-94d3-66c2f2cfff23" // string | Eon-assigned resource ID.
snapshotId := "ac3014c2-9ab3-5d7f-ab4c-73412d6b9ef5" // string | ID of the Eon [snapshot](/api/api-reference/backup-management/snapshots/list-resource-snapshots) to restore.
restoreDynamoDBTableRequest := *openapiclient.NewRestoreDynamoDBTableRequest("1ee34dc5-0a7c-4e56-a820-917371e05c8d", *openapiclient.NewDynamodbTableRestoreDestination()) // RestoreDynamoDBTableRequest |
xActionApprovalRequestId := "38400000-8cf0-11bd-b23e-10b96e4ef00d" // string | ID of an approved action request. Applicable only when the method is protected by an action approval policy and the action request has been approved. When used, the current API request must match the original request parameters. The approved action request can be executed only by the original requester. (optional)
configuration := openapiclient.NewConfiguration()
apiClient := openapiclient.NewAPIClient(configuration)
resp, r, err := apiClient.SnapshotsAPI.RestoreDynamoDBTable(context.Background(), projectId, id, snapshotId).RestoreDynamoDBTableRequest(restoreDynamoDBTableRequest).XActionApprovalRequestId(xActionApprovalRequestId).Execute()
if err != nil {
fmt.Fprintf(os.Stderr, "Error when calling `SnapshotsAPI.RestoreDynamoDBTable``: %v\n", err)
fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r)
}
// response from `RestoreDynamoDBTable`: RestoreJobInitiationResponse
fmt.Fprintf(os.Stdout, "Response from `SnapshotsAPI.RestoreDynamoDBTable`: %v\n", resp)
}| Name | Type | Description | Notes |
|---|---|---|---|
| ctx | context.Context | context for authentication, logging, cancellation, deadlines, tracing, etc. | |
| projectId | string | ID of the project the snapshot is in. You can get your project ID from the API Credentials page in your global management console. | |
| id | string | Eon-assigned resource ID. | |
| snapshotId | string | ID of the Eon snapshot to restore. |
Other parameters are passed through a pointer to a apiRestoreDynamoDBTableRequest struct via the builder pattern
| Name | Type | Description | Notes |
|---|
restoreDynamoDBTableRequest | RestoreDynamoDBTableRequest | | xActionApprovalRequestId | string | ID of an approved action request. Applicable only when the method is protected by an action approval policy and the action request has been approved. When used, the current API request must match the original request parameters. The approved action request can be executed only by the original requester. |
- Content-Type: application/json
- Accept: application/json
[Back to top] [Back to API list] [Back to Model list] [Back to README]
RestoreJobInitiationResponse RestoreEbsVolume(ctx, projectId, id, snapshotId).RestoreVolumeToEbsRequest(restoreVolumeToEbsRequest).XActionApprovalRequestId(xActionApprovalRequestId).Execute()
Restore EBS Volume
package main
import (
"context"
"fmt"
"os"
openapiclient "github.com/eon-io/eon-service/services/frontend/api-gateway/sdk/external-go"
)
func main() {
projectId := "1ee34dc5-0a7c-4e56-a820-917371e05c8d" // string | ID of the project the snapshot is in. You can get your project ID from the [API Credentials](https://console.eon.io/global-management/api-credentials) page in your global management console.
id := "043090df-9fe5-4f89-9859-45db589c2936" // string | Eon-assigned resource ID.
snapshotId := "c11d3c11-7be5-4ee4-9eb8-2024d9c04904" // string | ID of the Eon [snapshot](/api/api-reference/backup-management/snapshots/list-resource-snapshots) to restore.
restoreVolumeToEbsRequest := *openapiclient.NewRestoreVolumeToEbsRequest("vol-01a29e3ba811d4613", "1ee34dc5-0a7c-4e56-a820-917371e05c8d", *openapiclient.NewEbsRestoreDestination()) // RestoreVolumeToEbsRequest |
xActionApprovalRequestId := "38400000-8cf0-11bd-b23e-10b96e4ef00d" // string | ID of an approved action request. Applicable only when the method is protected by an action approval policy and the action request has been approved. When used, the current API request must match the original request parameters. The approved action request can be executed only by the original requester. (optional)
configuration := openapiclient.NewConfiguration()
apiClient := openapiclient.NewAPIClient(configuration)
resp, r, err := apiClient.SnapshotsAPI.RestoreEbsVolume(context.Background(), projectId, id, snapshotId).RestoreVolumeToEbsRequest(restoreVolumeToEbsRequest).XActionApprovalRequestId(xActionApprovalRequestId).Execute()
if err != nil {
fmt.Fprintf(os.Stderr, "Error when calling `SnapshotsAPI.RestoreEbsVolume``: %v\n", err)
fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r)
}
// response from `RestoreEbsVolume`: RestoreJobInitiationResponse
fmt.Fprintf(os.Stdout, "Response from `SnapshotsAPI.RestoreEbsVolume`: %v\n", resp)
}| Name | Type | Description | Notes |
|---|---|---|---|
| ctx | context.Context | context for authentication, logging, cancellation, deadlines, tracing, etc. | |
| projectId | string | ID of the project the snapshot is in. You can get your project ID from the API Credentials page in your global management console. | |
| id | string | Eon-assigned resource ID. | |
| snapshotId | string | ID of the Eon snapshot to restore. |
Other parameters are passed through a pointer to a apiRestoreEbsVolumeRequest struct via the builder pattern
| Name | Type | Description | Notes |
|---|
restoreVolumeToEbsRequest | RestoreVolumeToEbsRequest | | xActionApprovalRequestId | string | ID of an approved action request. Applicable only when the method is protected by an action approval policy and the action request has been approved. When used, the current API request must match the original request parameters. The approved action request can be executed only by the original requester. |
- Content-Type: application/json
- Accept: application/json
[Back to top] [Back to API list] [Back to Model list] [Back to README]
RestoreJobInitiationResponse RestoreEc2Instance(ctx, projectId, id, snapshotId).RestoreAwsEc2InstanceRequest(restoreAwsEc2InstanceRequest).XActionApprovalRequestId(xActionApprovalRequestId).Execute()
Restore EC2 Instance
package main
import (
"context"
"fmt"
"os"
openapiclient "github.com/eon-io/eon-service/services/frontend/api-gateway/sdk/external-go"
)
func main() {
projectId := "1ee34dc5-0a7c-4e56-a820-917371e05c8d" // string | ID of the project the snapshot is in. You can get your project ID from the [API Credentials](https://console.eon.io/global-management/api-credentials) page in your global management console.
id := "fb806ce1-1cd3-5034-928a-33a87be714da" // string | Eon-assigned resource ID.
snapshotId := "3dc6c0c6-f94d-5e85-a174-4b981a4bb262" // string | ID of the Eon [snapshot](/api/api-reference/backup-management/snapshots/list-resource-snapshots) to restore.
restoreAwsEc2InstanceRequest := *openapiclient.NewRestoreAwsEc2InstanceRequest("1ee34dc5-0a7c-4e56-a820-917371e05c8d", *openapiclient.NewAwsEc2InstanceRestoreDestination()) // RestoreAwsEc2InstanceRequest |
xActionApprovalRequestId := "38400000-8cf0-11bd-b23e-10b96e4ef00d" // string | ID of an approved action request. Applicable only when the method is protected by an action approval policy and the action request has been approved. When used, the current API request must match the original request parameters. The approved action request can be executed only by the original requester. (optional)
configuration := openapiclient.NewConfiguration()
apiClient := openapiclient.NewAPIClient(configuration)
resp, r, err := apiClient.SnapshotsAPI.RestoreEc2Instance(context.Background(), projectId, id, snapshotId).RestoreAwsEc2InstanceRequest(restoreAwsEc2InstanceRequest).XActionApprovalRequestId(xActionApprovalRequestId).Execute()
if err != nil {
fmt.Fprintf(os.Stderr, "Error when calling `SnapshotsAPI.RestoreEc2Instance``: %v\n", err)
fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r)
}
// response from `RestoreEc2Instance`: RestoreJobInitiationResponse
fmt.Fprintf(os.Stdout, "Response from `SnapshotsAPI.RestoreEc2Instance`: %v\n", resp)
}| Name | Type | Description | Notes |
|---|---|---|---|
| ctx | context.Context | context for authentication, logging, cancellation, deadlines, tracing, etc. | |
| projectId | string | ID of the project the snapshot is in. You can get your project ID from the API Credentials page in your global management console. | |
| id | string | Eon-assigned resource ID. | |
| snapshotId | string | ID of the Eon snapshot to restore. |
Other parameters are passed through a pointer to a apiRestoreEc2InstanceRequest struct via the builder pattern
| Name | Type | Description | Notes |
|---|
restoreAwsEc2InstanceRequest | RestoreAwsEc2InstanceRequest | | xActionApprovalRequestId | string | ID of an approved action request. Applicable only when the method is protected by an action approval policy and the action request has been approved. When used, the current API request must match the original request parameters. The approved action request can be executed only by the original requester. |
- Content-Type: application/json
- Accept: application/json
[Back to top] [Back to API list] [Back to Model list] [Back to README]
RestoreJobInitiationResponse RestoreFiles(ctx, projectId, id, snapshotId).RestoreFilesRequest(restoreFilesRequest).Execute()
Restore Files
package main
import (
"context"
"fmt"
"os"
openapiclient "github.com/eon-io/eon-service/services/frontend/api-gateway/sdk/external-go"
)
func main() {
projectId := "1ee34dc5-0a7c-4e56-a820-917371e05c8d" // string | ID of the project the snapshot is in. You can get your project ID from the [API Credentials](https://console.eon.io/global-management/api-credentials) page in your global management console.
id := "043090df-9fe5-4f89-9859-45db589c2936" // string | Eon-assigned resource ID.
snapshotId := "c11d3c11-7be5-4ee4-9eb8-2024d9c04904" // string | ID of the Eon [snapshot](/api/api-reference/backup-management/snapshots/list-resource-snapshots) to restore.
restoreFilesRequest := *openapiclient.NewRestoreFilesRequest(*openapiclient.NewObjectStorageDestination(), []openapiclient.FilePath{*openapiclient.NewFilePath("Path_example", false)}, "1ee34dc5-0a7c-4e56-a820-917371e05c8d") // RestoreFilesRequest |
configuration := openapiclient.NewConfiguration()
apiClient := openapiclient.NewAPIClient(configuration)
resp, r, err := apiClient.SnapshotsAPI.RestoreFiles(context.Background(), projectId, id, snapshotId).RestoreFilesRequest(restoreFilesRequest).Execute()
if err != nil {
fmt.Fprintf(os.Stderr, "Error when calling `SnapshotsAPI.RestoreFiles``: %v\n", err)
fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r)
}
// response from `RestoreFiles`: RestoreJobInitiationResponse
fmt.Fprintf(os.Stdout, "Response from `SnapshotsAPI.RestoreFiles`: %v\n", resp)
}| Name | Type | Description | Notes |
|---|---|---|---|
| ctx | context.Context | context for authentication, logging, cancellation, deadlines, tracing, etc. | |
| projectId | string | ID of the project the snapshot is in. You can get your project ID from the API Credentials page in your global management console. | |
| id | string | Eon-assigned resource ID. | |
| snapshotId | string | ID of the Eon snapshot to restore. |
Other parameters are passed through a pointer to a apiRestoreFilesRequest struct via the builder pattern
| Name | Type | Description | Notes |
|---|
restoreFilesRequest | RestoreFilesRequest | |
- Content-Type: application/json
- Accept: application/json
[Back to top] [Back to API list] [Back to Model list] [Back to README]
RestoreJobInitiationResponse RestoreGcpCloudSql(ctx, projectId, id, snapshotId).RestoreGcpCloudSqlRequest(restoreGcpCloudSqlRequest).XActionApprovalRequestId(xActionApprovalRequestId).Execute()
Restore GCP Cloud SQL Instance
package main
import (
"context"
"fmt"
"os"
openapiclient "github.com/eon-io/eon-service/services/frontend/api-gateway/sdk/external-go"
)
func main() {
projectId := "1ee34dc5-0a7c-4e56-a820-917371e05c8d" // string | ID of the project the snapshot is in. You can get your project ID from the [API Credentials](https://console.eon.io/global-management/api-credentials) page in your global management console.
id := "fb806ce1-1cd3-5034-928a-33a87be714da" // string | Eon-assigned resource ID.
snapshotId := "3dc6c0c6-f94d-5e85-a174-4b981a4bb262" // string | ID of the Eon [snapshot](/api/api-reference/backup-management/snapshots/list-resource-snapshots) to restore.
restoreGcpCloudSqlRequest := *openapiclient.NewRestoreGcpCloudSqlRequest("1ee34dc5-0a7c-4e56-a820-917371e05c8d", *openapiclient.NewGcpCloudSqlRestoreDestination()) // RestoreGcpCloudSqlRequest |
xActionApprovalRequestId := "38400000-8cf0-11bd-b23e-10b96e4ef00d" // string | ID of an approved action request. Applicable only when the method is protected by an action approval policy and the action request has been approved. When used, the current API request must match the original request parameters. The approved action request can be executed only by the original requester. (optional)
configuration := openapiclient.NewConfiguration()
apiClient := openapiclient.NewAPIClient(configuration)
resp, r, err := apiClient.SnapshotsAPI.RestoreGcpCloudSql(context.Background(), projectId, id, snapshotId).RestoreGcpCloudSqlRequest(restoreGcpCloudSqlRequest).XActionApprovalRequestId(xActionApprovalRequestId).Execute()
if err != nil {
fmt.Fprintf(os.Stderr, "Error when calling `SnapshotsAPI.RestoreGcpCloudSql``: %v\n", err)
fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r)
}
// response from `RestoreGcpCloudSql`: RestoreJobInitiationResponse
fmt.Fprintf(os.Stdout, "Response from `SnapshotsAPI.RestoreGcpCloudSql`: %v\n", resp)
}| Name | Type | Description | Notes |
|---|---|---|---|
| ctx | context.Context | context for authentication, logging, cancellation, deadlines, tracing, etc. | |
| projectId | string | ID of the project the snapshot is in. You can get your project ID from the API Credentials page in your global management console. | |
| id | string | Eon-assigned resource ID. | |
| snapshotId | string | ID of the Eon snapshot to restore. |
Other parameters are passed through a pointer to a apiRestoreGcpCloudSqlRequest struct via the builder pattern
| Name | Type | Description | Notes |
|---|
restoreGcpCloudSqlRequest | RestoreGcpCloudSqlRequest | | xActionApprovalRequestId | string | ID of an approved action request. Applicable only when the method is protected by an action approval policy and the action request has been approved. When used, the current API request must match the original request parameters. The approved action request can be executed only by the original requester. |
- Content-Type: application/json
- Accept: application/json
[Back to top] [Back to API list] [Back to Model list] [Back to README]
RestoreJobInitiationResponse RestoreGcpDisk(ctx, projectId, id, snapshotId).RestoreGcpDiskRequest(restoreGcpDiskRequest).XActionApprovalRequestId(xActionApprovalRequestId).Execute()
Restore GCP Disk
package main
import (
"context"
"fmt"
"os"
openapiclient "github.com/eon-io/eon-service/services/frontend/api-gateway/sdk/external-go"
)
func main() {
projectId := "1ee34dc5-0a7c-4e56-a820-917371e05c8d" // string | ID of the project the snapshot is in. You can get your project ID from the [API Credentials](https://console.eon.io/global-management/api-credentials) page in your global management console.
id := "fb806ce1-1cd3-5034-928a-33a87be714da" // string | Eon-assigned resource ID.
snapshotId := "3dc6c0c6-f94d-5e85-a174-4b981a4bb262" // string | ID of the Eon [snapshot](/api/api-reference/backup-management/snapshots/list-resource-snapshots) to restore.
restoreGcpDiskRequest := *openapiclient.NewRestoreGcpDiskRequest("5178361631409150158", "1ee34dc5-0a7c-4e56-a820-917371e05c8d", *openapiclient.NewGcpDiskRestoreDestination()) // RestoreGcpDiskRequest |
xActionApprovalRequestId := "38400000-8cf0-11bd-b23e-10b96e4ef00d" // string | ID of an approved action request. Applicable only when the method is protected by an action approval policy and the action request has been approved. When used, the current API request must match the original request parameters. The approved action request can be executed only by the original requester. (optional)
configuration := openapiclient.NewConfiguration()
apiClient := openapiclient.NewAPIClient(configuration)
resp, r, err := apiClient.SnapshotsAPI.RestoreGcpDisk(context.Background(), projectId, id, snapshotId).RestoreGcpDiskRequest(restoreGcpDiskRequest).XActionApprovalRequestId(xActionApprovalRequestId).Execute()
if err != nil {
fmt.Fprintf(os.Stderr, "Error when calling `SnapshotsAPI.RestoreGcpDisk``: %v\n", err)
fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r)
}
// response from `RestoreGcpDisk`: RestoreJobInitiationResponse
fmt.Fprintf(os.Stdout, "Response from `SnapshotsAPI.RestoreGcpDisk`: %v\n", resp)
}| Name | Type | Description | Notes |
|---|---|---|---|
| ctx | context.Context | context for authentication, logging, cancellation, deadlines, tracing, etc. | |
| projectId | string | ID of the project the snapshot is in. You can get your project ID from the API Credentials page in your global management console. | |
| id | string | Eon-assigned resource ID. | |
| snapshotId | string | ID of the Eon snapshot to restore. |
Other parameters are passed through a pointer to a apiRestoreGcpDiskRequest struct via the builder pattern
| Name | Type | Description | Notes |
|---|
restoreGcpDiskRequest | RestoreGcpDiskRequest | | xActionApprovalRequestId | string | ID of an approved action request. Applicable only when the method is protected by an action approval policy and the action request has been approved. When used, the current API request must match the original request parameters. The approved action request can be executed only by the original requester. |
- Content-Type: application/json
- Accept: application/json
[Back to top] [Back to API list] [Back to Model list] [Back to README]
RestoreJobInitiationResponse RestoreGcpVmInstance(ctx, projectId, id, snapshotId).RestoreGcpVmInstanceRequest(restoreGcpVmInstanceRequest).XActionApprovalRequestId(xActionApprovalRequestId).Execute()
Restore GCP VM Instance
package main
import (
"context"
"fmt"
"os"
openapiclient "github.com/eon-io/eon-service/services/frontend/api-gateway/sdk/external-go"
)
func main() {
projectId := "1ee34dc5-0a7c-4e56-a820-917371e05c8d" // string | ID of the project the snapshot is in. You can get your project ID from the [API Credentials](https://console.eon.io/global-management/api-credentials) page in your global management console.
id := "fb806ce1-1cd3-5034-928a-33a87be714da" // string | Eon-assigned resource ID.
snapshotId := "3dc6c0c6-f94d-5e85-a174-4b981a4bb262" // string | ID of the Eon [snapshot](/api/api-reference/backup-management/snapshots/list-resource-snapshots) to restore.
restoreGcpVmInstanceRequest := *openapiclient.NewRestoreGcpVmInstanceRequest("1ee34dc5-0a7c-4e56-a820-917371e05c8d", *openapiclient.NewGcpVmInstanceRestoreDestination()) // RestoreGcpVmInstanceRequest |
xActionApprovalRequestId := "38400000-8cf0-11bd-b23e-10b96e4ef00d" // string | ID of an approved action request. Applicable only when the method is protected by an action approval policy and the action request has been approved. When used, the current API request must match the original request parameters. The approved action request can be executed only by the original requester. (optional)
configuration := openapiclient.NewConfiguration()
apiClient := openapiclient.NewAPIClient(configuration)
resp, r, err := apiClient.SnapshotsAPI.RestoreGcpVmInstance(context.Background(), projectId, id, snapshotId).RestoreGcpVmInstanceRequest(restoreGcpVmInstanceRequest).XActionApprovalRequestId(xActionApprovalRequestId).Execute()
if err != nil {
fmt.Fprintf(os.Stderr, "Error when calling `SnapshotsAPI.RestoreGcpVmInstance``: %v\n", err)
fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r)
}
// response from `RestoreGcpVmInstance`: RestoreJobInitiationResponse
fmt.Fprintf(os.Stdout, "Response from `SnapshotsAPI.RestoreGcpVmInstance`: %v\n", resp)
}| Name | Type | Description | Notes |
|---|---|---|---|
| ctx | context.Context | context for authentication, logging, cancellation, deadlines, tracing, etc. | |
| projectId | string | ID of the project the snapshot is in. You can get your project ID from the API Credentials page in your global management console. | |
| id | string | Eon-assigned resource ID. | |
| snapshotId | string | ID of the Eon snapshot to restore. |
Other parameters are passed through a pointer to a apiRestoreGcpVmInstanceRequest struct via the builder pattern
| Name | Type | Description | Notes |
|---|
restoreGcpVmInstanceRequest | RestoreGcpVmInstanceRequest | | xActionApprovalRequestId | string | ID of an approved action request. Applicable only when the method is protected by an action approval policy and the action request has been approved. When used, the current API request must match the original request parameters. The approved action request can be executed only by the original requester. |
- Content-Type: application/json
- Accept: application/json
[Back to top] [Back to API list] [Back to Model list] [Back to README]
RestoreJobInitiationResponse RestoreToEbsSnapshot(ctx, projectId, id, snapshotId).RestoreVolumeToEbsSnapshotRequest(restoreVolumeToEbsSnapshotRequest).XActionApprovalRequestId(xActionApprovalRequestId).Execute()
Restore to EBS Snapshot
package main
import (
"context"
"fmt"
"os"
openapiclient "github.com/eon-io/eon-service/services/frontend/api-gateway/sdk/external-go"
)
func main() {
projectId := "1ee34dc5-0a7c-4e56-a820-917371e05c8d" // string | ID of the project the snapshot is in. You can get your project ID from the [API Credentials](https://console.eon.io/global-management/api-credentials) page in your global management console.
id := "043090df-9fe5-4f89-9859-45db589c2936" // string | Eon-assigned resource ID.
snapshotId := "c11d3c11-7be5-4ee4-9eb8-2024d9c04904" // string | ID of the Eon [snapshot](/api/api-reference/backup-management/snapshots/list-resource-snapshots) to restore.
restoreVolumeToEbsSnapshotRequest := *openapiclient.NewRestoreVolumeToEbsSnapshotRequest("vol-01a29e3ba811d4613", "1ee34dc5-0a7c-4e56-a820-917371e05c8d", *openapiclient.NewEbsSnapshotRestoreDestination()) // RestoreVolumeToEbsSnapshotRequest |
xActionApprovalRequestId := "38400000-8cf0-11bd-b23e-10b96e4ef00d" // string | ID of an approved action request. Applicable only when the method is protected by an action approval policy and the action request has been approved. When used, the current API request must match the original request parameters. The approved action request can be executed only by the original requester. (optional)
configuration := openapiclient.NewConfiguration()
apiClient := openapiclient.NewAPIClient(configuration)
resp, r, err := apiClient.SnapshotsAPI.RestoreToEbsSnapshot(context.Background(), projectId, id, snapshotId).RestoreVolumeToEbsSnapshotRequest(restoreVolumeToEbsSnapshotRequest).XActionApprovalRequestId(xActionApprovalRequestId).Execute()
if err != nil {
fmt.Fprintf(os.Stderr, "Error when calling `SnapshotsAPI.RestoreToEbsSnapshot``: %v\n", err)
fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r)
}
// response from `RestoreToEbsSnapshot`: RestoreJobInitiationResponse
fmt.Fprintf(os.Stdout, "Response from `SnapshotsAPI.RestoreToEbsSnapshot`: %v\n", resp)
}| Name | Type | Description | Notes |
|---|---|---|---|
| ctx | context.Context | context for authentication, logging, cancellation, deadlines, tracing, etc. | |
| projectId | string | ID of the project the snapshot is in. You can get your project ID from the API Credentials page in your global management console. | |
| id | string | Eon-assigned resource ID. | |
| snapshotId | string | ID of the Eon snapshot to restore. |
Other parameters are passed through a pointer to a apiRestoreToEbsSnapshotRequest struct via the builder pattern
| Name | Type | Description | Notes |
|---|
restoreVolumeToEbsSnapshotRequest | RestoreVolumeToEbsSnapshotRequest | | xActionApprovalRequestId | string | ID of an approved action request. Applicable only when the method is protected by an action approval policy and the action request has been approved. When used, the current API request must match the original request parameters. The approved action request can be executed only by the original requester. |
- Content-Type: application/json
- Accept: application/json
[Back to top] [Back to API list] [Back to Model list] [Back to README]