deleteImagePermissions method
Deletes permissions for the specified private image. After you delete permissions for an image, AWS accounts to which you previously granted these permissions can no longer use the image.
May throw ResourceNotAvailableException. May throw ResourceNotFoundException.
Parameter name :
The name of the private image.
Parameter sharedAccountId :
The 12-digit identifier of the AWS account for which to delete image
permissions.
Implementation
Future<void> deleteImagePermissions({
required String name,
required String sharedAccountId,
}) async {
ArgumentError.checkNotNull(name, 'name');
ArgumentError.checkNotNull(sharedAccountId, 'sharedAccountId');
final headers = <String, String>{
'Content-Type': 'application/x-amz-json-1.1',
'X-Amz-Target': 'PhotonAdminProxyService.DeleteImagePermissions'
};
await _protocol.send(
method: 'POST',
requestUri: '/',
exceptionFnMap: _exceptionFns,
// TODO queryParams
headers: headers,
payload: {
'Name': name,
'SharedAccountId': sharedAccountId,
},
);
}