applyEnvironmentManagedAction method
Applies a scheduled managed action immediately. A managed action can be
applied only if its status is Scheduled
. Get the status and
action ID of a managed action with
DescribeEnvironmentManagedActions.
May throw ElasticBeanstalkServiceException. May throw ManagedActionInvalidStateException.
Parameter actionId
:
The action ID of the scheduled managed action to execute.
Parameter environmentId
:
The environment ID of the target environment.
Parameter environmentName
:
The name of the target environment.
Implementation
Future<ApplyEnvironmentManagedActionResult> applyEnvironmentManagedAction({
required String actionId,
String? environmentId,
String? environmentName,
}) async {
ArgumentError.checkNotNull(actionId, 'actionId');
final $request = <String, dynamic>{};
$request['ActionId'] = actionId;
environmentId?.also((arg) => $request['EnvironmentId'] = arg);
environmentName?.also((arg) => $request['EnvironmentName'] = arg);
final $result = await _protocol.send(
$request,
action: 'ApplyEnvironmentManagedAction',
version: '2010-12-01',
method: 'POST',
requestUri: '/',
exceptionFnMap: _exceptionFns,
shape: shapes['ApplyEnvironmentManagedActionRequest'],
shapes: shapes,
resultWrapper: 'ApplyEnvironmentManagedActionResult',
);
return ApplyEnvironmentManagedActionResult.fromXml($result);
}