updatePackage method
Updates a package for use with Amazon ES domains.
May throw AccessDeniedException.
May throw BaseException.
May throw InternalException.
May throw LimitExceededException.
May throw ResourceNotFoundException.
May throw ValidationException.
Parameter packageID :
Unique identifier for the package.
Parameter commitMessage :
An info message for the new version which will be shown as part of
GetPackageVersionHistoryResponse.
Parameter packageDescription :
New description of the package.
Implementation
Future<UpdatePackageResponse> updatePackage({
required String packageID,
required PackageSource packageSource,
String? commitMessage,
String? packageDescription,
}) async {
final $payload = <String, dynamic>{
'PackageID': packageID,
'PackageSource': packageSource,
if (commitMessage != null) 'CommitMessage': commitMessage,
if (packageDescription != null) 'PackageDescription': packageDescription,
};
final response = await _protocol.send(
payload: $payload,
method: 'POST',
requestUri: '/2015-01-01/packages/update',
exceptionFnMap: _exceptionFns,
);
return UpdatePackageResponse.fromJson(response);
}