Yes, all parameters in the Pushwoosh API, including devices, are case-sensitive and must be in lowercase. Using an incorrect casing, such as Devices, will cause the parameter to be ignored by our system.
If the devices parameter is ignored and no other targeting options (like users or filters) are specified, the API call may result in a broadcast push to all subscribed users in your application. This can be misleading during testing, as it appears to work while not targeting the intended devices.
The "Unknown Devices" error specifically means that the identifiers (such as push tokens or Hardware IDs) you provided in the devices array are invalid, expired, or do not exist for your application.
How to Fix This Issue
Push tokens, which are provided by services like APNs and FCM, can change frequently (e.g., when a user reinstalls the app). Targeting them directly can be unreliable.
For more reliable device targeting, we strongly recommend using more stable identifiers:
- HWID (Hardware ID): A unique ID generated by the Pushwoosh SDK for each device. Target these using the
devicesparameter. - UserID: Your own internal user identifier, which is the most reliable method for targeting specific users across their devices. Target these using the
usersparameter.
To resolve the error, ensure you are:
1. Using the devices parameter in all lowercase.
2. Targeting valid and current HWIDs or UserIDs instead of potentially outdated push tokens.
Comments
0 comments
Please sign in to leave a comment.