c# – 如何获得发送到移动设备的短信回复?
发布时间:2020-12-16 02:00:25 所属栏目:百科 来源:网络整理
导读:我正在尝试使用此示例代码来使用SNS API发送消息 – BasicAWSCredentials cr = new BasicAWSCredentials("MYACCESSKEYS","mySecretKeys");AmazonSimpleNotificationService sns = new AmazonSimpleNotificationServiceClient(cr);string topicArn = sns.Crea
我正在尝试使用此示例代码来使用SNS API发送消息 –
BasicAWSCredentials cr = new BasicAWSCredentials("MYACCESSKEYS","mySecretKeys"); AmazonSimpleNotificationService sns = new AmazonSimpleNotificationServiceClient(cr); string topicArn = sns.CreateTopic(new CreateTopicRequest { Name = "ses-bounces-topic",}).CreateTopicResult.TopicArn; sns.SetTopicAttributes(new SetTopicAttributesRequest { TopicArn = topicArn,AttributeName = "MyName",AttributeValue = "Sample Notifications" }); sns.Subscribe(new SubscribeRequest { TopicArn = topicArn,Protocol = "SMS",Endpoint = "my-mobile-number" }); ListSubscriptionsByTopicResult ls = sns.ListSubscriptionsByTopic(new ListSubscriptionsByTopicRequest { TopicArn = topicArn }).ListSubscriptionsByTopicResult; sns.Publish(new PublishRequest { TopicArn=topicArn,Subject="MySms",Message="Testing Message" }); 此代码工作正常,可以将消息发送到我的手机.我成功地将消息发送到启用SMS的设备移动设备. 如果他/她回来了,有没有办法得到用户的回复?如果我们能够获得使用任何API请求发回的用户的回复,请引导我. 提前致谢!! 解决方法
您目前无法收到使用Amazon SNS回复短信的回复.我们希望提供扩展的SMS支持(更多AWS区域,更多地理覆盖范围,更多功能),但遗憾的是没有时间分享.
(编辑:李大同) 【声明】本站内容均来自网络,其相关言论仅代表作者个人观点,不代表本站立场。若无意侵犯到您的权利,请及时与联系站长删除相关内容! |