createUserJourney method
Creates a user journey within a system.
May throw AccessDeniedException.
May throw ConflictException.
May throw InternalServerException.
May throw ResourceNotFoundException.
May throw ServiceQuotaExceededException.
May throw ValidationException.
Implementation
Future<CreateUserJourneyResponse> createUserJourney({
required String name,
required String systemArn,
String? clientToken,
String? description,
String? policyArn,
}) async {
final $payload = <String, dynamic>{
'name': name,
'systemArn': systemArn,
'clientToken': clientToken ?? _s.generateIdempotencyToken(),
if (description != null) 'description': description,
if (policyArn != null) 'policyArn': policyArn,
};
final response = await _protocol.send(
payload: $payload,
method: 'POST',
requestUri: '/v2/create-user-journey',
exceptionFnMap: _exceptionFns,
);
return CreateUserJourneyResponse.fromJson(response);
}