

本文属于机器翻译版本。若本译文内容与英语原文存在差异，则一律以英文原文为准。

# 向 AppInstanceBot 适用于 Amazon 的 Chime 软件开发工具包消息发送消息
<a name="message-appinstancebot"></a>

您可以使用 [https://docs.aws.amazon.com/chime-sdk/latest/APIReference/API_messaging-chime_SendChannelMessage.html](https://docs.aws.amazon.com/chime-sdk/latest/APIReference/API_messaging-chime_SendChannelMessage.html)API 向发送消息 AppInstanceBot。您将消息发送到该 AppInstanceBot 成员所在的频道。如果[自然语言理解模型](https://docs.aws.amazon.com/lexv2/latest/dg/what-is.html)识别出消息内容并引发 Amazon Lex 意图，则会使用频道消息进行 AppInstanceBot 响应并启动对话。

您还可以向频道成员发送目标消息，该成员可以是 AppInstanceUser 或 AppInstanceBot。只有目标和发件人可以查看定向消息。只有能够看到定向消息的用户才能对其采取行动。但是，管理员可以删除他们看不到的定向消息。

以下示例说明如何使用 AWS CLI 发送频道消息。

```
aws chime-sdk-messaging send-channel-message \
--chime-bearer caller_app_instance_user_arn \
--channel-arn channel_arn \
--content content \
--type STANDARD \
--persistence PERSISTENT
```