startAppAssessment method
Creates a new application assessment for an application.
May throw AccessDeniedException.
May throw ConflictException.
May throw InternalServerException.
May throw ResourceNotFoundException.
May throw ServiceQuotaExceededException.
May throw ThrottlingException.
May throw ValidationException.
Parameter appArn :
Amazon Resource Name (ARN) of the Resilience Hub application. The format
for this ARN is:
arn:partition:resiliencehub:region:account:app/app-id.
For more information about ARNs, see
Amazon Resource Names (ARNs) in the Amazon Web Services General
Reference guide.
Parameter appVersion :
The version of the application.
Parameter assessmentName :
The name for the assessment.
Parameter clientToken :
Used for an idempotency token. A client token is a unique, case-sensitive
string of up to 64 ASCII characters. You should not reuse the same client
token for other API requests.
Parameter tags :
Tags assigned to the resource. A tag is a label that you assign to an
Amazon Web Services resource. Each tag consists of a key/value pair.
Implementation
Future<StartAppAssessmentResponse> startAppAssessment({
required String appArn,
required String appVersion,
required String assessmentName,
String? clientToken,
Map<String, String>? tags,
}) async {
final $payload = <String, dynamic>{
'appArn': appArn,
'appVersion': appVersion,
'assessmentName': assessmentName,
'clientToken': clientToken ?? _s.generateIdempotencyToken(),
if (tags != null) 'tags': tags,
};
final response = await _protocol.send(
payload: $payload,
method: 'POST',
requestUri: '/start-app-assessment',
exceptionFnMap: _exceptionFns,
);
return StartAppAssessmentResponse.fromJson(response);
}