OneSignal / OneSignal-iOS-SDK

OneSignal is a free push notification service for mobile apps. This plugin makes it easy to integrate your native iOS app with OneSignal. https://onesignal.com
Other
494 stars 262 forks source link

Question: WatchOS 6 independent app #556

Closed lechuckcaptain closed 4 years ago

lechuckcaptain commented 4 years ago

Description: It's not 100% clear from the documentation if the SDK support also WatchOS 6 independent app (without a companion iOS app).

A similar question has been raised also on #159 but closed due to inactivity. With the introduction of independent app I think the topic has increased its importance.

rgomezp commented 4 years ago

As mentioned in that issue, there is no Watch-specific methods or settings currently

lechuckcaptain commented 4 years ago

@rgomezp does this mean that it's possible to use the OneSignal-iOS-SDK with complete functionalities into a Watch OS independent app without any iOS companion app?

rgomezp commented 4 years ago

Correct @lechuckcaptain

jkasten2 commented 4 years ago

@rgomezp watchOS 6 standalone apps have it's own registerForRemoteNotifications method on WKExtension vs iOS apps call this on UIApplication. Also watchOS has its own delegate for when the token is available via WKExtensionDelegate. https://developer.apple.com/documentation/watchkit/wkextension?language=objc

@lechuckcaptain The OneSignal-iOS-SDK does not support watchOS 6 independent apps currently. However if the user installs your iOS app and accepts notifications there by default all notifications shown on the iPhone will also show on the watch. The user does not have to install the your watchOS app if mirroring notifications to watch from the iPhone is all you need.

lechuckcaptain commented 4 years ago

Unfortunately what I need is an explicit support of WatchOS independent app, without any iOS installation.

Based on @jkasten2 answer, is there any available workaround (maybe doing some manual works) in order to use OneSignal for sending notification to WatchOS independent apps?

jkasten2 commented 4 years ago

@lechuckcaptain Since it isn't built into this SDK you could call WKExtension registerForRemoteNotifications from your app and setup the WKExtensionDelegate noted above to get the APNs token from the watch. Then make a player create REST API POST call to https://onesignal.com/api/v1/players to register the device with OneSignal. Once the device is registered you can send push notifications from OneSignal to watch directly.

owenzhao commented 4 years ago

An independent Apple Watch app means that the app must still work without iOS companion app.

That means SDK should allow register device on watchOS extension side, which doesn't support on current OneSignal SDK.

I asked a question on this in today's Zoom meeting by OneSignal. The answer is no. But OneSignal will provide it if developers want it badly.

So provide your needs here. 😉😉😉😉😉😉😉😉

rgomezp commented 4 years ago

Thanks for the question. Will close the issue for now. Let us know if you have further questions or concerns

GeylanKalafMohe commented 3 years ago

Any update ?

NathaSuleSM commented 1 year ago

Any Update on Independent watch app Push notification?

ramakrishnantag commented 1 year ago

Any Update on Independent watch app Push notification?

dwburns commented 1 year ago

+1 request to add standalone watch support

valeriolg commented 12 months ago

+1