getBotChannelAssociation method

Future<GetBotChannelAssociationResponse> getBotChannelAssociation({
  1. required String botAlias,
  2. required String botName,
  3. required String name,
})

Returns information about the association between an Amazon Lex bot and a messaging platform.

This operation requires permissions for the lex:GetBotChannelAssociation action.

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

Parameter botAlias : An alias pointing to the specific version of the Amazon Lex bot to which this association is being made.

Parameter botName : The name of the Amazon Lex bot.

Parameter name : The name of the association between the bot and the channel. The name is case sensitive.

Implementation

Future<GetBotChannelAssociationResponse> getBotChannelAssociation({
  required String botAlias,
  required String botName,
  required String name,
}) async {
  ArgumentError.checkNotNull(botAlias, 'botAlias');
  _s.validateStringLength(
    'botAlias',
    botAlias,
    1,
    100,
    isRequired: true,
  );
  ArgumentError.checkNotNull(botName, 'botName');
  _s.validateStringLength(
    'botName',
    botName,
    2,
    50,
    isRequired: true,
  );
  ArgumentError.checkNotNull(name, 'name');
  _s.validateStringLength(
    'name',
    name,
    1,
    100,
    isRequired: true,
  );
  final response = await _protocol.send(
    payload: null,
    method: 'GET',
    requestUri:
        '/bots/${Uri.encodeComponent(botName)}/aliases/${Uri.encodeComponent(botAlias)}/channels/${Uri.encodeComponent(name)}',
    exceptionFnMap: _exceptionFns,
  );
  return GetBotChannelAssociationResponse.fromJson(response);
}