I have Implemented push notification in xamarin.forms android using this but it sends the notification to all the device.I want to send notification to the specific users only.How can I achieve it ?
可以将文章内容翻译成中文,广告屏蔽插件可能会导致该功能失效(如失效,请关闭广告屏蔽插件后再试):
问题:
回答1:
We use tags for this. Each user has a user Id and so when the device registers with azure, you add their user Id as a tag to the registration.
protected override void OnRegistered(Context context, string registrationId) {
...
var tags = new List<string>() { "userId4" }; // Your UserId here
...
}