OpenSearchServiceServerless / Client / list_lifecycle_policies
list_lifecycle_policies#
- OpenSearchServiceServerless.Client.list_lifecycle_policies(**kwargs)#
Returns a list of OpenSearch Serverless lifecycle policies. For more information, see Viewing data lifecycle policies.
See also: AWS API Documentation
Request Syntax
response = client.list_lifecycle_policies( type='retention', resources=[ 'string', ], nextToken='string', maxResults=123 )
- Parameters:
type (string) –
[REQUIRED]
The type of lifecycle policy.
resources (list) –
Resource filters that policies can apply to. Currently, the only supported resource type is
index
.(string) –
nextToken (string) – If your initial
ListLifecyclePolicies
operation returns anextToken
, you can include the returnednextToken
in subsequentListLifecyclePolicies
operations, which returns results in the next page.maxResults (integer) – An optional parameter that specifies the maximum number of results to return. You can use use
nextToken
to get the next page of results. The default is 10.
- Return type:
dict
- Returns:
Response Syntax
{ 'lifecyclePolicySummaries': [ { 'type': 'retention', 'name': 'string', 'policyVersion': 'string', 'description': 'string', 'createdDate': 123, 'lastModifiedDate': 123 }, ], 'nextToken': 'string' }
Response Structure
(dict) –
lifecyclePolicySummaries (list) –
Details about the requested lifecycle policies.
(dict) –
A summary of the lifecycle policy.
type (string) –
The type of lifecycle policy.
name (string) –
The name of the lifecycle policy.
policyVersion (string) –
The version of the lifecycle policy.
description (string) –
The description of the lifecycle policy.
createdDate (integer) –
The Epoch time when the lifecycle policy was created.
lastModifiedDate (integer) –
The date and time when the lifecycle policy was last modified.
nextToken (string) –
When
nextToken
is returned, there are more results available. The value ofnextToken
is a unique pagination token for each page. Make the call again using the returned token to retrieve the next page.
Exceptions
OpenSearchServiceServerless.Client.exceptions.InternalServerException
OpenSearchServiceServerless.Client.exceptions.ValidationException