Update an existing device in one of your OneSignal apps

🚧

Warning - Android SDK Data Synchronization

The OneSignal Android SDKs leverage cacheing on external_user_id and Data Tags.

external_user_id or tags added client-side through the Android SDK are cached. They can be changed server-side, but will not be changed back to the original client-side values if tried to set again through the SDK.

For example, if calling the SDK method sendTag("key", "value1") then update the tag value to "value2" with this API endpoint. You will not be able to set the value back to "value1" through the SDK. You will need to set a new value client side or reset the value server side.

Recommendations if using this Endpoint on Android Mobile Apps:
1 - Do not use the same tag keys for SDK and API updates
2 - If you want to use the same key for both SDK and API updates, call the SDK getTags method first to update the device's tags.

This is only applicable on the Android Mobile App SDKs.

📘

Deleting Tags

To delete a tag, include its key and set its value null. Omitting a key/value will not delete it.

For example, if I wanted to delete two existing tags rank and category while simultaneously adding a new tag class, the tags JSON would look like the following:

"tags": {
           "rank": null,
           "category": null,
           "class": "my_new_value"
        }

🚧

Data Latency

A successful response means our database has received the request. This may take additional time for the data to be available on the user.

If using Message Personalization, please allow 60+ seconds before sending your messages.

Language