關於極光推送訊息提醒並且播放指定鈴聲
阿新 • • 發佈:2019-01-06
private static PushPayload PushPayload_all(string[] all, string conetent, string Url, string sound) { PushPayload pushPayload = new PushPayload(); pushPayload.platform = Platform.all(); ; pushPayload.audience = Audience.all(); var notification = new Notification(); notification.IosNotification = new IosNotification().setAlert(conetent).setSound("callu.caf"); notification.AndroidNotification = new AndroidNotification().setAlert(conetent); pushPayload.notification = notification; pushPayload.options.apns_production = true; pushPayload.message = Message.content(conetent).AddExtras("Act", "OpenWeb").AddExtras("Url", "/" + Url).AddExtras("Sound", sound); return pushPayload; }