Backup / Client / list_legal_holds
list_legal_holds#
- Backup.Client.list_legal_holds(**kwargs)#
This action returns metadata about active and previous legal holds.
See also: AWS API Documentation
Request Syntax
response = client.list_legal_holds( NextToken='string', MaxResults=123 )
- Parameters:
NextToken (string) – The next item following a partial list of returned resources. For example, if a request is made to return
maxResults
number of resources,NextToken
allows you to return more items in your list starting at the location pointed to by the next token.MaxResults (integer) – The maximum number of resource list items to be returned.
- Return type:
dict
- Returns:
Response Syntax
{ 'NextToken': 'string', 'LegalHolds': [ { 'Title': 'string', 'Status': 'CREATING'|'ACTIVE'|'CANCELING'|'CANCELED', 'Description': 'string', 'LegalHoldId': 'string', 'LegalHoldArn': 'string', 'CreationDate': datetime(2015, 1, 1), 'CancellationDate': datetime(2015, 1, 1) }, ] }
Response Structure
(dict) –
NextToken (string) –
The next item following a partial list of returned resources. For example, if a request is made to return
maxResults
number of resources,NextToken
allows you to return more items in your list starting at the location pointed to by the next token.LegalHolds (list) –
This is an array of returned legal holds, both active and previous.
(dict) –
A legal hold is an administrative tool that helps prevent backups from being deleted while under a hold. While the hold is in place, backups under a hold cannot be deleted and lifecycle policies that would alter the backup status (such as transition to cold storage) are delayed until the legal hold is removed. A backup can have more than one legal hold. Legal holds are applied to one or more backups (also known as recovery points). These backups can be filtered by resource types and by resource IDs.
Title (string) –
This is the title of a legal hold.
Status (string) –
This is the status of the legal hold. Statuses can be
ACTIVE
,CREATING
,CANCELED
, andCANCELING
.Description (string) –
This is the description of a legal hold.
LegalHoldId (string) –
ID of specific legal hold on one or more recovery points.
LegalHoldArn (string) –
This is an Amazon Resource Number (ARN) that uniquely identifies the legal hold; for example,
arn:aws:backup:us-east-1:123456789012:recovery-point:1EB3B5E7-9EB0-435A-A80B-108B488B0D45
.CreationDate (datetime) –
This is the time in number format when legal hold was created.
CancellationDate (datetime) –
This is the time in number format when legal hold was cancelled.
Exceptions
Backup.Client.exceptions.InvalidParameterValueException
Backup.Client.exceptions.ServiceUnavailableException