Register a new device to one of your OneSignal apps
Limitations with importing Push Tokens
If importing Push Tokens, this API endpoint is designed to be used from our open source Mobile and Web Push SDKs. If you use this method instead of our SDKs, many OneSignal features such as conversion tracking, timezone tracking, language detection, and rich-push won't work out of the box. It will also make it harder to identify possible setup issues.
This method is used to register a new device with OneSignal.
If a device is already registered with the specified identifier, then this will update the existing device record instead of creating a new one.
The returned ID is for the OneSignal Device Channel Record. If you set device_type = 11
the returned ID is for the Email Channel associated with the device. device_type = 14
is the SMS Channel. All other device_type
correspond to the Push Channel. It is recommended to include an external_user_id
to associate all Device Channel Records with your own User ID.