getBot method

Future<GetBotResponse> getBot({
  1. required String name,
  2. required String versionOrAlias,
})

Returns metadata information for a specific bot. You must provide the bot name and the bot version or alias.

This operation requires permissions for the lex:GetBot action.

May throw BadRequestException. May throw InternalFailureException. May throw LimitExceededException. May throw NotFoundException.

Parameter name : The name of the bot. The name is case sensitive.

Parameter versionOrAlias : The version or alias of the bot.

Implementation

Future<GetBotResponse> getBot({
  required String name,
  required String versionOrAlias,
}) async {
  final response = await _protocol.send(
    payload: null,
    method: 'GET',
    requestUri:
        '/bots/${Uri.encodeComponent(name)}/versions/${Uri.encodeComponent(versionOrAlias)}',
    exceptionFnMap: _exceptionFns,
  );
  return GetBotResponse.fromJson(response);
}