All URIs are relative to http://localhost
| Method | HTTP request | Description |
|---|---|---|
| ProtectionGroupSnapshotsDelete | Delete /api/2.48/protection-group-snapshots | Delete a protection group snapshot |
| ProtectionGroupSnapshotsGet | Get /api/2.48/protection-group-snapshots | List protection group snapshots |
| ProtectionGroupSnapshotsPatch | Patch /api/2.48/protection-group-snapshots | Modify a protection group snapshot |
| ProtectionGroupSnapshotsPost | Post /api/2.48/protection-group-snapshots | Create a protection group snapshot and create tags. |
| ProtectionGroupSnapshotsReplicaPost | Post /api/2.48/protection-group-snapshots/replica | Create an action to send protection group snapshots |
| ProtectionGroupSnapshotsTagsBatchPut | Put /api/2.48/protection-group-snapshots/tags/batch | Update tags |
| ProtectionGroupSnapshotsTagsDelete | Delete /api/2.48/protection-group-snapshots/tags | Delete tags |
| ProtectionGroupSnapshotsTagsGet | Get /api/2.48/protection-group-snapshots/tags | List tags |
| ProtectionGroupSnapshotsTestPost | Post /api/2.48/protection-group-snapshots/test | Create an attempt to take protection group snapshot |
| ProtectionGroupSnapshotsTransferGet | Get /api/2.48/protection-group-snapshots/transfer | List protection group snapshots with transfer statistics |
ProtectionGroupSnapshotsDelete(ctx).Authorization(authorization).XRequestID(xRequestID).ContextNames(contextNames).Ids(ids).Names(names).Execute()
Delete a protection group snapshot
package main
import (
"context"
"fmt"
"os"
openapiclient "github.com/PureStorage-OpenConnect/go-pure-client/flasharray/FA_2_48"
)
func main() {
configuration, err := openapiclient.NewConfigurationBuilder(server.URL).
APIToken(apiToken).
Build()
if err != nil {
fmt.Fprintf(os.Stderr, "Error when creating api client configuration: %v\n", err)
}
apiClient, err := openapiclient.NewClient(configuration)
if err != nil {
fmt.Fprintf(os.Stderr, "Error when creating api client: %v\n", err)
}
req := apiClient.ProtectionGroupSnapshotsAPI.ProtectionGroupSnapshotsDelete(context.Background())
// Set request parameters ...
resp, r, err := req.Execute()
if err != nil {
fmt.Fprintf(os.Stderr, "Error when calling `ProtectionGroupSnapshotsAPI.ProtectionGroupSnapshotsDelete``: %v\n", err)
fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r)
}
}Other parameters are passed through a pointer to a apiProtectionGroupSnapshotsDeleteRequest struct via the builder pattern
| Name | Type | Description | Notes |
|---|---|---|---|
| authorization | string | Access token (in JWT format) required to use any API endpoint (except `/oauth2`, `/login`, and `/logout`) | |
| xRequestID | string | Supplied by client during request or generated by server. | |
| contextNames | []string | Performs the operation on the context specified. If specified, the context names must be an array of size 1, and the single element must be the name of an array in the same fleet. If not specified, the context will default to the array that received this request. Other parameters provided with the request, such as names of volumes or snapshots, are resolved relative to the provided `context`. | |
| ids | []string | Performs the operation on the unique resource IDs specified. Enter multiple resource IDs in comma-separated format. The `ids` or `names` parameter is required, but they cannot be set together. | |
| names | []string | Performs the operation on the unique name specified. Enter multiple names in comma-separated format. For example, `name01,name02`. |
(empty response body)
Authorization is handled by the Authenticator specified in the configuration and data are filled automatically. Use param authorization only when you need to override this behaviour.
- Content-Type: Not defined
- Accept: Not defined
[Back to top] [Back to API list] [Back to Model list] [Back to README]
ProtectionGroupSnapshotGetResponse ProtectionGroupSnapshotsGet(ctx).Authorization(authorization).XRequestID(xRequestID).AllowErrors(allowErrors).ContextNames(contextNames).ContinuationToken(continuationToken).Destroyed(destroyed).Filter(filter).Ids(ids).Limit(limit).Names(names).Offset(offset).Sort(sort).SourceIds(sourceIds).SourceNames(sourceNames).TotalItemCount(totalItemCount).TotalOnly(totalOnly).Execute()
List protection group snapshots
package main
import (
"context"
"fmt"
"os"
openapiclient "github.com/PureStorage-OpenConnect/go-pure-client/flasharray/FA_2_48"
)
func main() {
configuration, err := openapiclient.NewConfigurationBuilder(server.URL).
APIToken(apiToken).
Build()
if err != nil {
fmt.Fprintf(os.Stderr, "Error when creating api client configuration: %v\n", err)
}
apiClient, err := openapiclient.NewClient(configuration)
if err != nil {
fmt.Fprintf(os.Stderr, "Error when creating api client: %v\n", err)
}
req := apiClient.ProtectionGroupSnapshotsAPI.ProtectionGroupSnapshotsGet(context.Background())
// Set request parameters ...
resp, r, err := req.Execute()
if err != nil {
fmt.Fprintf(os.Stderr, "Error when calling `ProtectionGroupSnapshotsAPI.ProtectionGroupSnapshotsGet``: %v\n", err)
fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r)
}
// response from `ProtectionGroupSnapshotsGet`: ProtectionGroupSnapshotGetResponse
fmt.Fprintf(os.Stdout, "Response from `ProtectionGroupSnapshotsAPI.ProtectionGroupSnapshotsGet`: %v\n", resp)
}Other parameters are passed through a pointer to a apiProtectionGroupSnapshotsGetRequest struct via the builder pattern
| Name | Type | Description | Notes |
|---|---|---|---|
| authorization | string | Access token (in JWT format) required to use any API endpoint (except `/oauth2`, `/login`, and `/logout`) | |
| xRequestID | string | Supplied by client during request or generated by server. | |
| allowErrors | bool | If set to `true`, the API will allow the operation to continue even if there are errors. Any errors will be returned in the `errors` field of the response. If set to `false`, the operation will fail if there are any errors. | [default to false] |
| contextNames | []string | Performs the operation on the unique contexts specified. If specified, each context name must be the name of an array in the same fleet. If not specified, the context will default to the array that received this request. Other parameters provided with the request, such as names of volumes or snapshots, are resolved relative to the provided `context`. Enter multiple names in comma-separated format. For example, `name01,name02`. | |
| continuationToken | string | A token used to retrieve the next page of data with some consistency guaranteed. The token is a Base64 encoded value. Set `continuation_token` to the system-generated token taken from the `x-next-token` header field of the response. A query has reached its last page when the response does not include a token. Pagination requires the `limit` and `continuation_token` query parameters. | |
| destroyed | bool | If set to `true`, lists only destroyed objects that are in the eradication pending state. If set to `false`, lists only objects that are not destroyed. If not set, lists both objects that are destroyed and those that are not destroyed. For destroyed objects, the time remaining is displayed in milliseconds. If object name(s) or id(s) are specified, then each object referenced must exist. If `destroyed` is set to `true`, then each object referenced must also be destroyed. If `destroyed` is set to `false`, then each object referenced must also not be destroyed. An error is returned if any of these conditions are not met. | |
| filter | string | Narrows down the results to only the response objects that satisfy the filter criteria. | |
| ids | []string | Performs the operation on the unique resource IDs specified. Enter multiple resource IDs in comma-separated format. The `ids` or `names` parameter is required, but they cannot be set together. | |
| limit | int32 | Limits the size of the response to the specified number of objects on each page. To return the total number of resources, set `limit=0`. The total number of resources is returned as a `total_item_count` value. If the page size requested is larger than the system maximum limit, the server returns the maximum limit, disregarding the requested page size. | |
| names | []string | Performs the operation on the unique name specified. Enter multiple names in comma-separated format. For example, `name01,name02`. | |
| offset | int32 | The starting position based on the results of the query in relation to the full set of response objects returned. | |
| sort | []string | Returns the response objects in the order specified. Set `sort` to the name in the response by which to sort. Sorting can be performed on any of the names in the response, and the objects can be sorted in ascending or descending order. By default, the response objects are sorted in ascending order. To sort in descending order, append the minus sign (`-`) to the name. A single request can be sorted on multiple objects. For example, you can sort all volumes from largest to smallest volume size, and then sort volumes of the same size in ascending order by volume name. To sort on multiple names, list the names as comma-separated values. | |
| sourceIds | []string | Performs the operation on the source ID specified. Enter multiple source IDs in comma-separated format. | |
| sourceNames | []string | Performs the operation on the source name specified. Enter multiple source names in comma-separated format. For example, `name01,name02`. | |
| totalItemCount | bool | If set to `true`, the `total_item_count` matching the specified query parameters is calculated and returned in the response. If set to `false`, the `total_item_count` is `null` in the response. This may speed up queries where the `total_item_count` is large. If not specified, defaults to `false`. | |
| totalOnly | bool | If set to `true`, returns the aggregate value of all items after filtering. Where it makes more sense, the average value is displayed instead. The values are displayed for each name where meaningful. If `total_only=true`, the `items` list will be empty. |
ProtectionGroupSnapshotGetResponse
Authorization is handled by the Authenticator specified in the configuration and data are filled automatically. Use param authorization only when you need to override this behaviour.
- Content-Type: Not defined
- Accept: application/json
[Back to top] [Back to API list] [Back to Model list] [Back to README]
ProtectionGroupSnapshotResponse ProtectionGroupSnapshotsPatch(ctx).ProtectionGroupSnapshot(protectionGroupSnapshot).Authorization(authorization).XRequestID(xRequestID).ContextNames(contextNames).Ids(ids).Names(names).Execute()
Modify a protection group snapshot
package main
import (
"context"
"fmt"
"os"
openapiclient "github.com/PureStorage-OpenConnect/go-pure-client/flasharray/FA_2_48"
)
func main() {
configuration, err := openapiclient.NewConfigurationBuilder(server.URL).
APIToken(apiToken).
Build()
if err != nil {
fmt.Fprintf(os.Stderr, "Error when creating api client configuration: %v\n", err)
}
apiClient, err := openapiclient.NewClient(configuration)
if err != nil {
fmt.Fprintf(os.Stderr, "Error when creating api client: %v\n", err)
}
req := apiClient.ProtectionGroupSnapshotsAPI.ProtectionGroupSnapshotsPatch(context.Background())
// Set request parameters ...
resp, r, err := req.Execute()
if err != nil {
fmt.Fprintf(os.Stderr, "Error when calling `ProtectionGroupSnapshotsAPI.ProtectionGroupSnapshotsPatch``: %v\n", err)
fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r)
}
// response from `ProtectionGroupSnapshotsPatch`: ProtectionGroupSnapshotResponse
fmt.Fprintf(os.Stdout, "Response from `ProtectionGroupSnapshotsAPI.ProtectionGroupSnapshotsPatch`: %v\n", resp)
}Other parameters are passed through a pointer to a apiProtectionGroupSnapshotsPatchRequest struct via the builder pattern
| Name | Type | Description | Notes |
|---|---|---|---|
| protectionGroupSnapshot | ProtectionGroupSnapshotPatch | ||
| authorization | string | Access token (in JWT format) required to use any API endpoint (except `/oauth2`, `/login`, and `/logout`) | |
| xRequestID | string | Supplied by client during request or generated by server. | |
| contextNames | []string | Performs the operation on the context specified. If specified, the context names must be an array of size 1, and the single element must be the name of an array in the same fleet. If not specified, the context will default to the array that received this request. Other parameters provided with the request, such as names of volumes or snapshots, are resolved relative to the provided `context`. | |
| ids | []string | Performs the operation on the unique resource IDs specified. Enter multiple resource IDs in comma-separated format. The `ids` or `names` parameter is required, but they cannot be set together. | |
| names | []string | Performs the operation on the unique name specified. Enter multiple names in comma-separated format. For example, `name01,name02`. |
ProtectionGroupSnapshotResponse
Authorization is handled by the Authenticator specified in the configuration and data are filled automatically. Use param authorization only when you need to override this behaviour.
- Content-Type: application/json
- Accept: application/json
[Back to top] [Back to API list] [Back to Model list] [Back to README]
ProtectionGroupSnapshotResponse ProtectionGroupSnapshotsPost(ctx).Authorization(authorization).XRequestID(xRequestID).AllowThrottle(allowThrottle).ApplyRetention(applyRetention).ContextNames(contextNames).ForReplication(forReplication).Replicate(replicate).ReplicateNow(replicateNow).SourceIds(sourceIds).SourceNames(sourceNames).ProtectionGroupSnapshot(protectionGroupSnapshot).Execute()
Create a protection group snapshot and create tags.
package main
import (
"context"
"fmt"
"os"
openapiclient "github.com/PureStorage-OpenConnect/go-pure-client/flasharray/FA_2_48"
)
func main() {
configuration, err := openapiclient.NewConfigurationBuilder(server.URL).
APIToken(apiToken).
Build()
if err != nil {
fmt.Fprintf(os.Stderr, "Error when creating api client configuration: %v\n", err)
}
apiClient, err := openapiclient.NewClient(configuration)
if err != nil {
fmt.Fprintf(os.Stderr, "Error when creating api client: %v\n", err)
}
req := apiClient.ProtectionGroupSnapshotsAPI.ProtectionGroupSnapshotsPost(context.Background())
// Set request parameters ...
resp, r, err := req.Execute()
if err != nil {
fmt.Fprintf(os.Stderr, "Error when calling `ProtectionGroupSnapshotsAPI.ProtectionGroupSnapshotsPost``: %v\n", err)
fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r)
}
// response from `ProtectionGroupSnapshotsPost`: ProtectionGroupSnapshotResponse
fmt.Fprintf(os.Stdout, "Response from `ProtectionGroupSnapshotsAPI.ProtectionGroupSnapshotsPost`: %v\n", resp)
}Other parameters are passed through a pointer to a apiProtectionGroupSnapshotsPostRequest struct via the builder pattern
| Name | Type | Description | Notes |
|---|---|---|---|
| authorization | string | Access token (in JWT format) required to use any API endpoint (except `/oauth2`, `/login`, and `/logout`) | |
| xRequestID | string | Supplied by client during request or generated by server. | |
| allowThrottle | bool | If set to `true`, allows snapshot to fail if array health is not optimal. | |
| applyRetention | bool | If `true`, applies the local and remote retention policy to the snapshots. | |
| contextNames | []string | Performs the operation on the context specified. If specified, the context names must be an array of size 1, and the single element must be the name of an array in the same fleet. If not specified, the context will default to the array that received this request. Other parameters provided with the request, such as names of volumes or snapshots, are resolved relative to the provided `context`. | |
| forReplication | bool | If `true`, destroys and eradicates the snapshot after 1 hour. | |
| replicate | bool | If set to `true`, queues up and begins replicating to each allowed target after all earlier replication sessions for the same protection group have been completed to that target. The `replicate` and `replicate_now` parameters cannot be used together. | |
| replicateNow | bool | If set to `true`, replicates the snapshots to each allowed target. The `replicate` and `replicate_now` parameters cannot be used together. | |
| sourceIds | []string | Performs the operation on the source ID specified. Enter multiple source IDs in comma-separated format. | |
| sourceNames | []string | Performs the operation on the source name specified. Enter multiple source names in comma-separated format. For example, `name01,name02`. | |
| protectionGroupSnapshot | ProtectionGroupSnapshotPost |
ProtectionGroupSnapshotResponse
Authorization is handled by the Authenticator specified in the configuration and data are filled automatically. Use param authorization only when you need to override this behaviour.
- Content-Type: application/json
- Accept: application/json
[Back to top] [Back to API list] [Back to Model list] [Back to README]
ProtectionGroupSnapshotReplicaResponse ProtectionGroupSnapshotsReplicaPost(ctx).Authorization(authorization).XRequestID(xRequestID).ContextNames(contextNames).ConvertSourceToBaseline(convertSourceToBaseline).Ids(ids).Names(names).On(on).Execute()
Create an action to send protection group snapshots
package main
import (
"context"
"fmt"
"os"
openapiclient "github.com/PureStorage-OpenConnect/go-pure-client/flasharray/FA_2_48"
)
func main() {
configuration, err := openapiclient.NewConfigurationBuilder(server.URL).
APIToken(apiToken).
Build()
if err != nil {
fmt.Fprintf(os.Stderr, "Error when creating api client configuration: %v\n", err)
}
apiClient, err := openapiclient.NewClient(configuration)
if err != nil {
fmt.Fprintf(os.Stderr, "Error when creating api client: %v\n", err)
}
req := apiClient.ProtectionGroupSnapshotsAPI.ProtectionGroupSnapshotsReplicaPost(context.Background())
// Set request parameters ...
resp, r, err := req.Execute()
if err != nil {
fmt.Fprintf(os.Stderr, "Error when calling `ProtectionGroupSnapshotsAPI.ProtectionGroupSnapshotsReplicaPost``: %v\n", err)
fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r)
}
// response from `ProtectionGroupSnapshotsReplicaPost`: ProtectionGroupSnapshotReplicaResponse
fmt.Fprintf(os.Stdout, "Response from `ProtectionGroupSnapshotsAPI.ProtectionGroupSnapshotsReplicaPost`: %v\n", resp)
}Other parameters are passed through a pointer to a apiProtectionGroupSnapshotsReplicaPostRequest struct via the builder pattern
| Name | Type | Description | Notes |
|---|---|---|---|
| authorization | string | Access token (in JWT format) required to use any API endpoint (except `/oauth2`, `/login`, and `/logout`) | |
| xRequestID | string | Supplied by client during request or generated by server. | |
| contextNames | []string | Performs the operation on the context specified. If specified, the context names must be an array of size 1, and the single element must be the name of an array in the same fleet. If not specified, the context will default to the array that received this request. Other parameters provided with the request, such as names of volumes or snapshots, are resolved relative to the provided `context`. | |
| convertSourceToBaseline | bool | Set to `true` to have the snapshot be eradicated when it is no longer baseline on source. | |
| ids | []string | Performs the operation on the unique resource IDs specified. Enter multiple resource IDs in comma-separated format. The `ids` or `names` parameter is required, but they cannot be set together. | |
| names | []string | Performs the operation on the unique name specified. Enter multiple names in comma-separated format. For example, `name01,name02`. | |
| on | []string | Performs the operation locally with the target names specified as the destinations of the operation. Enter multiple target names in comma-separated format. For example, `targetName01,targetName02`. |
ProtectionGroupSnapshotReplicaResponse
Authorization is handled by the Authenticator specified in the configuration and data are filled automatically. Use param authorization only when you need to override this behaviour.
- Content-Type: Not defined
- Accept: application/json
[Back to top] [Back to API list] [Back to Model list] [Back to README]
TagResponse ProtectionGroupSnapshotsTagsBatchPut(ctx).Tag(tag).Authorization(authorization).XRequestID(xRequestID).ContextNames(contextNames).ResourceIds(resourceIds).ResourceNames(resourceNames).Execute()
Update tags
package main
import (
"context"
"fmt"
"os"
openapiclient "github.com/PureStorage-OpenConnect/go-pure-client/flasharray/FA_2_48"
)
func main() {
configuration, err := openapiclient.NewConfigurationBuilder(server.URL).
APIToken(apiToken).
Build()
if err != nil {
fmt.Fprintf(os.Stderr, "Error when creating api client configuration: %v\n", err)
}
apiClient, err := openapiclient.NewClient(configuration)
if err != nil {
fmt.Fprintf(os.Stderr, "Error when creating api client: %v\n", err)
}
req := apiClient.ProtectionGroupSnapshotsAPI.ProtectionGroupSnapshotsTagsBatchPut(context.Background())
// Set request parameters ...
resp, r, err := req.Execute()
if err != nil {
fmt.Fprintf(os.Stderr, "Error when calling `ProtectionGroupSnapshotsAPI.ProtectionGroupSnapshotsTagsBatchPut``: %v\n", err)
fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r)
}
// response from `ProtectionGroupSnapshotsTagsBatchPut`: TagResponse
fmt.Fprintf(os.Stdout, "Response from `ProtectionGroupSnapshotsAPI.ProtectionGroupSnapshotsTagsBatchPut`: %v\n", resp)
}Other parameters are passed through a pointer to a apiProtectionGroupSnapshotsTagsBatchPutRequest struct via the builder pattern
| Name | Type | Description | Notes |
|---|---|---|---|
| tag | []TagBatch | A list of tags to be created or, if already existing, updated. | |
| authorization | string | Access token (in JWT format) required to use any API endpoint (except `/oauth2`, `/login`, and `/logout`) | |
| xRequestID | string | Supplied by client during request or generated by server. | |
| contextNames | []string | Performs the operation on the context specified. If specified, the context names must be an array of size 1, and the single element must be the name of an array in the same fleet. If not specified, the context will default to the array that received this request. Other parameters provided with the request, such as names of volumes or snapshots, are resolved relative to the provided `context`. | |
| resourceIds | []string | A comma-separated list of resource IDs. The `resource_ids` or `resource_names` parameter is required, but they cannot be set together. | |
| resourceNames | []string | A comma-separated list of resource names. The `resource_ids` or `resource_names` parameter is required, but they cannot be set together. |
Authorization is handled by the Authenticator specified in the configuration and data are filled automatically. Use param authorization only when you need to override this behaviour.
- Content-Type: application/json
- Accept: application/json
[Back to top] [Back to API list] [Back to Model list] [Back to README]
ProtectionGroupSnapshotsTagsDelete(ctx).Authorization(authorization).XRequestID(xRequestID).ContextNames(contextNames).Keys(keys).Namespaces(namespaces).ResourceIds(resourceIds).ResourceNames(resourceNames).Execute()
Delete tags
package main
import (
"context"
"fmt"
"os"
openapiclient "github.com/PureStorage-OpenConnect/go-pure-client/flasharray/FA_2_48"
)
func main() {
configuration, err := openapiclient.NewConfigurationBuilder(server.URL).
APIToken(apiToken).
Build()
if err != nil {
fmt.Fprintf(os.Stderr, "Error when creating api client configuration: %v\n", err)
}
apiClient, err := openapiclient.NewClient(configuration)
if err != nil {
fmt.Fprintf(os.Stderr, "Error when creating api client: %v\n", err)
}
req := apiClient.ProtectionGroupSnapshotsAPI.ProtectionGroupSnapshotsTagsDelete(context.Background())
// Set request parameters ...
resp, r, err := req.Execute()
if err != nil {
fmt.Fprintf(os.Stderr, "Error when calling `ProtectionGroupSnapshotsAPI.ProtectionGroupSnapshotsTagsDelete``: %v\n", err)
fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r)
}
}Other parameters are passed through a pointer to a apiProtectionGroupSnapshotsTagsDeleteRequest struct via the builder pattern
| Name | Type | Description | Notes |
|---|---|---|---|
| authorization | string | Access token (in JWT format) required to use any API endpoint (except `/oauth2`, `/login`, and `/logout`) | |
| xRequestID | string | Supplied by client during request or generated by server. | |
| contextNames | []string | Performs the operation on the context specified. If specified, the context names must be an array of size 1, and the single element must be the name of an array in the same fleet. If not specified, the context will default to the array that received this request. Other parameters provided with the request, such as names of volumes or snapshots, are resolved relative to the provided `context`. | |
| keys | []string | A comma-separated list of tag keys. | |
| namespaces | []string | A comma-separated list of namespaces. Only one namespace is allowed per delete request. | |
| resourceIds | []string | A comma-separated list of resource IDs. The `resource_ids` or `resource_names` parameter is required, but they cannot be set together. | |
| resourceNames | []string | A comma-separated list of resource names. The `resource_ids` or `resource_names` parameter is required, but they cannot be set together. |
(empty response body)
Authorization is handled by the Authenticator specified in the configuration and data are filled automatically. Use param authorization only when you need to override this behaviour.
- Content-Type: Not defined
- Accept: Not defined
[Back to top] [Back to API list] [Back to Model list] [Back to README]
TagGetResponse ProtectionGroupSnapshotsTagsGet(ctx).Authorization(authorization).XRequestID(xRequestID).AllowErrors(allowErrors).ContextNames(contextNames).ContinuationToken(continuationToken).Filter(filter).Limit(limit).Namespaces(namespaces).Offset(offset).ResourceDestroyed(resourceDestroyed).ResourceIds(resourceIds).ResourceNames(resourceNames).Sort(sort).TotalItemCount(totalItemCount).Execute()
List tags
package main
import (
"context"
"fmt"
"os"
openapiclient "github.com/PureStorage-OpenConnect/go-pure-client/flasharray/FA_2_48"
)
func main() {
configuration, err := openapiclient.NewConfigurationBuilder(server.URL).
APIToken(apiToken).
Build()
if err != nil {
fmt.Fprintf(os.Stderr, "Error when creating api client configuration: %v\n", err)
}
apiClient, err := openapiclient.NewClient(configuration)
if err != nil {
fmt.Fprintf(os.Stderr, "Error when creating api client: %v\n", err)
}
req := apiClient.ProtectionGroupSnapshotsAPI.ProtectionGroupSnapshotsTagsGet(context.Background())
// Set request parameters ...
resp, r, err := req.Execute()
if err != nil {
fmt.Fprintf(os.Stderr, "Error when calling `ProtectionGroupSnapshotsAPI.ProtectionGroupSnapshotsTagsGet``: %v\n", err)
fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r)
}
// response from `ProtectionGroupSnapshotsTagsGet`: TagGetResponse
fmt.Fprintf(os.Stdout, "Response from `ProtectionGroupSnapshotsAPI.ProtectionGroupSnapshotsTagsGet`: %v\n", resp)
}Other parameters are passed through a pointer to a apiProtectionGroupSnapshotsTagsGetRequest struct via the builder pattern
| Name | Type | Description | Notes |
|---|---|---|---|
| authorization | string | Access token (in JWT format) required to use any API endpoint (except `/oauth2`, `/login`, and `/logout`) | |
| xRequestID | string | Supplied by client during request or generated by server. | |
| allowErrors | bool | If set to `true`, the API will allow the operation to continue even if there are errors. Any errors will be returned in the `errors` field of the response. If set to `false`, the operation will fail if there are any errors. | [default to false] |
| contextNames | []string | Performs the operation on the unique contexts specified. If specified, each context name must be the name of an array in the same fleet. If not specified, the context will default to the array that received this request. Other parameters provided with the request, such as names of volumes or snapshots, are resolved relative to the provided `context`. Enter multiple names in comma-separated format. For example, `name01,name02`. | |
| continuationToken | string | A token used to retrieve the next page of data with some consistency guaranteed. The token is a Base64 encoded value. Set `continuation_token` to the system-generated token taken from the `x-next-token` header field of the response. A query has reached its last page when the response does not include a token. Pagination requires the `limit` and `continuation_token` query parameters. | |
| filter | string | Narrows down the results to only the response objects that satisfy the filter criteria. | |
| limit | int32 | Limits the size of the response to the specified number of objects on each page. To return the total number of resources, set `limit=0`. The total number of resources is returned as a `total_item_count` value. If the page size requested is larger than the system maximum limit, the server returns the maximum limit, disregarding the requested page size. | |
| namespaces | []string | A comma-separated list of namespaces. | |
| offset | int32 | The starting position based on the results of the query in relation to the full set of response objects returned. | |
| resourceDestroyed | bool | If set to `true`, returns only objects from destroyed resources. Returns an error if the name of a live resource is specified in the `resource_names` query parameter. If set to `false`, returns only objects from live resources. Returns an error if the name of a destroyed resource is specified in the `resource_names` query parameter. | |
| resourceIds | []string | A comma-separated list of resource IDs. The `resource_ids` or `resource_names` parameter is required, but they cannot be set together. | |
| resourceNames | []string | A comma-separated list of resource names. The `resource_ids` or `resource_names` parameter is required, but they cannot be set together. | |
| sort | []string | Returns the response objects in the order specified. Set `sort` to the name in the response by which to sort. Sorting can be performed on any of the names in the response, and the objects can be sorted in ascending or descending order. By default, the response objects are sorted in ascending order. To sort in descending order, append the minus sign (`-`) to the name. A single request can be sorted on multiple objects. For example, you can sort all volumes from largest to smallest volume size, and then sort volumes of the same size in ascending order by volume name. To sort on multiple names, list the names as comma-separated values. | |
| totalItemCount | bool | If set to `true`, the `total_item_count` matching the specified query parameters is calculated and returned in the response. If set to `false`, the `total_item_count` is `null` in the response. This may speed up queries where the `total_item_count` is large. If not specified, defaults to `false`. |
Authorization is handled by the Authenticator specified in the configuration and data are filled automatically. Use param authorization only when you need to override this behaviour.
- Content-Type: Not defined
- Accept: application/json
[Back to top] [Back to API list] [Back to Model list] [Back to README]
TestResultWithResourceWithIdPostResponse ProtectionGroupSnapshotsTestPost(ctx).Authorization(authorization).XRequestID(xRequestID).AllowThrottle(allowThrottle).ApplyRetention(applyRetention).ContextNames(contextNames).ForReplication(forReplication).Replicate(replicate).ReplicateNow(replicateNow).SourceIds(sourceIds).SourceNames(sourceNames).ProtectionGroupSnapshot(protectionGroupSnapshot).Execute()
Create an attempt to take protection group snapshot
package main
import (
"context"
"fmt"
"os"
openapiclient "github.com/PureStorage-OpenConnect/go-pure-client/flasharray/FA_2_48"
)
func main() {
configuration, err := openapiclient.NewConfigurationBuilder(server.URL).
APIToken(apiToken).
Build()
if err != nil {
fmt.Fprintf(os.Stderr, "Error when creating api client configuration: %v\n", err)
}
apiClient, err := openapiclient.NewClient(configuration)
if err != nil {
fmt.Fprintf(os.Stderr, "Error when creating api client: %v\n", err)
}
req := apiClient.ProtectionGroupSnapshotsAPI.ProtectionGroupSnapshotsTestPost(context.Background())
// Set request parameters ...
resp, r, err := req.Execute()
if err != nil {
fmt.Fprintf(os.Stderr, "Error when calling `ProtectionGroupSnapshotsAPI.ProtectionGroupSnapshotsTestPost``: %v\n", err)
fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r)
}
// response from `ProtectionGroupSnapshotsTestPost`: TestResultWithResourceWithIdPostResponse
fmt.Fprintf(os.Stdout, "Response from `ProtectionGroupSnapshotsAPI.ProtectionGroupSnapshotsTestPost`: %v\n", resp)
}Other parameters are passed through a pointer to a apiProtectionGroupSnapshotsTestPostRequest struct via the builder pattern
| Name | Type | Description | Notes |
|---|---|---|---|
| authorization | string | Access token (in JWT format) required to use any API endpoint (except `/oauth2`, `/login`, and `/logout`) | |
| xRequestID | string | Supplied by client during request or generated by server. | |
| allowThrottle | bool | If set to `true`, allows snapshot to fail if array health is not optimal. | |
| applyRetention | bool | If `true`, applies the local and remote retention policy to the snapshots. | |
| contextNames | []string | Performs the operation on the context specified. If specified, the context names must be an array of size 1, and the single element must be the name of an array in the same fleet. If not specified, the context will default to the array that received this request. Other parameters provided with the request, such as names of volumes or snapshots, are resolved relative to the provided `context`. | |
| forReplication | bool | If `true`, destroys and eradicates the snapshot after 1 hour. | |
| replicate | bool | If set to `true`, queues up and begins replicating to each allowed target after all earlier replication sessions for the same protection group have been completed to that target. The `replicate` and `replicate_now` parameters cannot be used together. | |
| replicateNow | bool | If set to `true`, replicates the snapshots to each allowed target. The `replicate` and `replicate_now` parameters cannot be used together. | |
| sourceIds | []string | Performs the operation on the source ID specified. Enter multiple source IDs in comma-separated format. | |
| sourceNames | []string | Performs the operation on the source name specified. Enter multiple source names in comma-separated format. For example, `name01,name02`. | |
| protectionGroupSnapshot | ProtectionGroupSnapshotPost |
TestResultWithResourceWithIdPostResponse
Authorization is handled by the Authenticator specified in the configuration and data are filled automatically. Use param authorization only when you need to override this behaviour.
- Content-Type: application/json
- Accept: application/json
[Back to top] [Back to API list] [Back to Model list] [Back to README]
ProtectionGroupSnapshotTransferGetResponse ProtectionGroupSnapshotsTransferGet(ctx).Authorization(authorization).XRequestID(xRequestID).AllowErrors(allowErrors).ContextNames(contextNames).ContinuationToken(continuationToken).Destroyed(destroyed).Filter(filter).Ids(ids).Limit(limit).Names(names).Offset(offset).Sort(sort).SourceIds(sourceIds).SourceNames(sourceNames).TotalItemCount(totalItemCount).TotalOnly(totalOnly).Execute()
List protection group snapshots with transfer statistics
package main
import (
"context"
"fmt"
"os"
openapiclient "github.com/PureStorage-OpenConnect/go-pure-client/flasharray/FA_2_48"
)
func main() {
configuration, err := openapiclient.NewConfigurationBuilder(server.URL).
APIToken(apiToken).
Build()
if err != nil {
fmt.Fprintf(os.Stderr, "Error when creating api client configuration: %v\n", err)
}
apiClient, err := openapiclient.NewClient(configuration)
if err != nil {
fmt.Fprintf(os.Stderr, "Error when creating api client: %v\n", err)
}
req := apiClient.ProtectionGroupSnapshotsAPI.ProtectionGroupSnapshotsTransferGet(context.Background())
// Set request parameters ...
resp, r, err := req.Execute()
if err != nil {
fmt.Fprintf(os.Stderr, "Error when calling `ProtectionGroupSnapshotsAPI.ProtectionGroupSnapshotsTransferGet``: %v\n", err)
fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r)
}
// response from `ProtectionGroupSnapshotsTransferGet`: ProtectionGroupSnapshotTransferGetResponse
fmt.Fprintf(os.Stdout, "Response from `ProtectionGroupSnapshotsAPI.ProtectionGroupSnapshotsTransferGet`: %v\n", resp)
}Other parameters are passed through a pointer to a apiProtectionGroupSnapshotsTransferGetRequest struct via the builder pattern
| Name | Type | Description | Notes |
|---|---|---|---|
| authorization | string | Access token (in JWT format) required to use any API endpoint (except `/oauth2`, `/login`, and `/logout`) | |
| xRequestID | string | Supplied by client during request or generated by server. | |
| allowErrors | bool | If set to `true`, the API will allow the operation to continue even if there are errors. Any errors will be returned in the `errors` field of the response. If set to `false`, the operation will fail if there are any errors. | [default to false] |
| contextNames | []string | Performs the operation on the unique contexts specified. If specified, each context name must be the name of an array in the same fleet. If not specified, the context will default to the array that received this request. Other parameters provided with the request, such as names of volumes or snapshots, are resolved relative to the provided `context`. Enter multiple names in comma-separated format. For example, `name01,name02`. | |
| continuationToken | string | A token used to retrieve the next page of data with some consistency guaranteed. The token is a Base64 encoded value. Set `continuation_token` to the system-generated token taken from the `x-next-token` header field of the response. A query has reached its last page when the response does not include a token. Pagination requires the `limit` and `continuation_token` query parameters. | |
| destroyed | bool | If set to `true`, lists only destroyed objects that are in the eradication pending state. If set to `false`, lists only objects that are not destroyed. If not set, lists both objects that are destroyed and those that are not destroyed. For destroyed objects, the time remaining is displayed in milliseconds. If object name(s) or id(s) are specified, then each object referenced must exist. If `destroyed` is set to `true`, then each object referenced must also be destroyed. If `destroyed` is set to `false`, then each object referenced must also not be destroyed. An error is returned if any of these conditions are not met. | |
| filter | string | Narrows down the results to only the response objects that satisfy the filter criteria. | |
| ids | []string | Performs the operation on the unique resource IDs specified. Enter multiple resource IDs in comma-separated format. The `ids` or `names` parameter is required, but they cannot be set together. | |
| limit | int32 | Limits the size of the response to the specified number of objects on each page. To return the total number of resources, set `limit=0`. The total number of resources is returned as a `total_item_count` value. If the page size requested is larger than the system maximum limit, the server returns the maximum limit, disregarding the requested page size. | |
| names | []string | Performs the operation on the unique name specified. Enter multiple names in comma-separated format. For example, `name01,name02`. | |
| offset | int32 | The starting position based on the results of the query in relation to the full set of response objects returned. | |
| sort | []string | Returns the response objects in the order specified. Set `sort` to the name in the response by which to sort. Sorting can be performed on any of the names in the response, and the objects can be sorted in ascending or descending order. By default, the response objects are sorted in ascending order. To sort in descending order, append the minus sign (`-`) to the name. A single request can be sorted on multiple objects. For example, you can sort all volumes from largest to smallest volume size, and then sort volumes of the same size in ascending order by volume name. To sort on multiple names, list the names as comma-separated values. | |
| sourceIds | []string | Performs the operation on the source ID specified. Enter multiple source IDs in comma-separated format. | |
| sourceNames | []string | Performs the operation on the source name specified. Enter multiple source names in comma-separated format. For example, `name01,name02`. | |
| totalItemCount | bool | If set to `true`, the `total_item_count` matching the specified query parameters is calculated and returned in the response. If set to `false`, the `total_item_count` is `null` in the response. This may speed up queries where the `total_item_count` is large. If not specified, defaults to `false`. | |
| totalOnly | bool | If set to `true`, returns the aggregate value of all items after filtering. Where it makes more sense, the average value is displayed instead. The values are displayed for each name where meaningful. If `total_only=true`, the `items` list will be empty. |
ProtectionGroupSnapshotTransferGetResponse
Authorization is handled by the Authenticator specified in the configuration and data are filled automatically. Use param authorization only when you need to override this behaviour.
- Content-Type: Not defined
- Accept: application/json
[Back to top] [Back to API list] [Back to Model list] [Back to README]