为 Amazon Chime SDK 消息传递将移动设备端点注册为应用程序实例用户 - Amazon Chime SDK

为 Amazon Chime SDK 消息传递将移动设备端点注册为应用程序实例用户

要接收推送通知,应用程序实例用户必须首先使用 RegisterAppInstanceUserEndpoint API 注册一台移动设备。他们必须通过能够访问设备操作系统的设备令牌的移动应用程序进行注册。

为确保应用程序实例用户有权访问 ARN 中列出的 Amazon Pinpoint 应用程序,用户必须有权调用 Amazon Pinpoint ARN 上的 mobiletargeting:GetApp。否则,Amazon Chime SDK 在调用 RegisterAppInstanceUserEndpoint 时会引发 403 禁止错误。

此示例介绍了注册终端节点所需的策略。

{ "Version": "2012-10-17", "Statement": [ { "Sid": "PermissionToRegisterEndpoint", "Effect": "Allow", "Action": "chime:RegisterAppInstanceUserEndpoint", "Resource": "arn:aws:chime:region:aws_account_id:app-instance/app_instance_id/user/app_instance_user_id" }, { "Sid": "PermissionToGetAppOnPinpoint", "Effect": "Allow", "Action": "mobiletargeting:GetApp", "Resource": "arn:aws:mobiletargeting:region:aws_account_id:apps/project_id" } ] }
要注册终端节点