createAppInstanceBot method
Creates a bot under an Amazon Chime AppInstance. The request
consists of a unique Configuration and Name for
that bot.
May throw BadRequestException.
May throw ConflictException.
May throw ForbiddenException.
May throw ResourceLimitExceededException.
May throw ServiceFailureException.
May throw ServiceUnavailableException.
May throw ThrottledClientException.
May throw UnauthorizedClientException.
Parameter appInstanceArn :
The ARN of the AppInstance request.
Parameter configuration :
Configuration information about the Amazon Lex V2 V2 bot.
Parameter clientRequestToken :
The unique ID for the client making the request. Use different tokens for
different AppInstanceBots.
Parameter metadata :
The request metadata. Limited to a 1KB string in UTF-8.
Parameter name :
The user's name.
Parameter tags :
The tags assigned to the AppInstanceBot.
Implementation
Future<CreateAppInstanceBotResponse> createAppInstanceBot({
required String appInstanceArn,
required Configuration configuration,
String? clientRequestToken,
String? metadata,
String? name,
List<Tag>? tags,
}) async {
final $payload = <String, dynamic>{
'AppInstanceArn': appInstanceArn,
'Configuration': configuration,
'ClientRequestToken': clientRequestToken ?? _s.generateIdempotencyToken(),
if (metadata != null) 'Metadata': metadata,
if (name != null) 'Name': name,
if (tags != null) 'Tags': tags,
};
final response = await _protocol.send(
payload: $payload,
method: 'POST',
requestUri: '/app-instance-bots',
exceptionFnMap: _exceptionFns,
);
return CreateAppInstanceBotResponse.fromJson(response);
}