watchOS & Wear OS Support
Setup OneSignal within standalone Apple and Android Watch Apps
Apple watchOS Setup
If the iOS Mobile App is synced to the watchOS App, notifications sent to the device will also pop-up on the watch. Also, if you have a standalone watchOS app, you can implement push notifications independently. OneSignal doesn't currently have an SDK for standalone watchOS apps, but you can set this up within OneSignal as follows:
Implement the Apple WatchKit WKExtension
with the registerForRemoteNotifications
method. This will get the APNs push token for the watch device.
Setup the WKExtensionDelegate
to get the APNs push token within the didRegisterForRemoteNotificationsWithDeviceToken
method from the watch.
Create the subscription within OneSignal using the Add a device API using the following properties:
identifier
: the APNs push token generated within the Watchdevice_type
:0
for iOSexternal_user_id
: to identify the user in which this subscription belongstest_type
only if testing on a development or ad-hoc build- Any other properties are optional
Once the device is registered you can send push notifications from OneSignal to watch directly.
Android Wear OS Setup
The OneSignal Android Native SDK will work on your Android Wear OS App.
You can build custom notification layouts and wearable-only actions following the Android Developer Notifications on Wear OS docs.
Updated over 1 year ago