createEnvironmentAction method
Creates an action for the environment, for example, creates a console link for an analytics tool that is available in this environment.
May throw AccessDeniedException.
May throw ConflictException.
May throw InternalServerException.
May throw ResourceNotFoundException.
May throw ThrottlingException.
May throw ValidationException.
Parameter domainIdentifier :
The ID of the Amazon DataZone domain in which the environment action is
created.
Parameter environmentIdentifier :
The ID of the environment in which the environment action is created.
Parameter name :
The name of the environment action.
Parameter parameters :
The parameters of the environment action.
Parameter description :
The description of the environment action that is being created in the
environment.
Implementation
Future<CreateEnvironmentActionOutput> createEnvironmentAction({
required String domainIdentifier,
required String environmentIdentifier,
required String name,
required ActionParameters parameters,
String? description,
}) async {
final $payload = <String, dynamic>{
'name': name,
'parameters': parameters,
if (description != null) 'description': description,
};
final response = await _protocol.send(
payload: $payload,
method: 'POST',
requestUri:
'/v2/domains/${Uri.encodeComponent(domainIdentifier)}/environments/${Uri.encodeComponent(environmentIdentifier)}/actions',
exceptionFnMap: _exceptionFns,
);
return CreateEnvironmentActionOutput.fromJson(response);
}