public void RedshiftAuthorizeSnapshotAccess() { #region to-authorize-an-aws-account-to-restore-from-snapshot-1482368189016 var response = client.AuthorizeSnapshotAccess(new AuthorizeSnapshotAccessRequest { AccountWithRestoreAccess = "444455556666", SnapshotIdentifier = "my-snapshot-id" }); #endregion }
private Amazon.Redshift.Model.AuthorizeSnapshotAccessResponse CallAWSServiceOperation(IAmazonRedshift client, Amazon.Redshift.Model.AuthorizeSnapshotAccessRequest request) { Utils.Common.WriteVerboseEndpointMessage(this, client.Config, "Amazon Redshift", "AuthorizeSnapshotAccess"); try { #if DESKTOP return(client.AuthorizeSnapshotAccess(request)); #elif CORECLR return(client.AuthorizeSnapshotAccessAsync(request).GetAwaiter().GetResult()); #else #error "Unknown build edition" #endif } catch (AmazonServiceException exc) { var webException = exc.InnerException as System.Net.WebException; if (webException != null) { throw new Exception(Utils.Common.FormatNameResolutionFailureMessage(client.Config, webException.Message), webException); } throw; } }