AmplifyGen3 / Client / restore_branch
restore_branch¶
- AmplifyGen3.Client.restore_branch(**kwargs)¶
Restores the data of the production branch to a point in time in a new branch of the Production environment. The production branch isn’t changed, and no deployment uses the new branch. The name of the new branch is production- followed by the restore time in seconds since the epoch. The restore runs asynchronously. To connect to the new branch, call GetBranch with the returned branch ARN until it returns a DatabaseConnection. When you no longer need the branch, delete it with DeleteBranch. A request to restore to the same time as an earlier request returns the branch that the earlier request created.
See also: AWS API Documentation
Request Syntax
response = client.restore_branch( BranchArn='string', RestoreToTime=datetime(2015, 1, 1) )
- Parameters:
BranchArn (string) –
[REQUIRED]
The Amazon Resource Name (ARN) of the production branch of the Production environment. Other branches can’t be restored.
RestoreToTime (datetime) –
[REQUIRED]
The point in time to restore the production branch to. The time must be within the window that GetRestoreWindow returns and can’t be in the future. Fractions of a second are ignored.
- Return type:
dict
- Returns:
Response Syntax
{ 'BranchArn': 'string' }
Response Structure
(dict) –
BranchArn (string) –
The Amazon Resource Name (ARN) of the new branch that contains the restored data.
Exceptions