Pushwoosh / pushwoosh-phonegap-plugin

Pushwoosh PhoneGap Build Plugin
Other
109 stars 139 forks source link

Suggested document update #241

Closed rwillett closed 7 years ago

rwillett commented 7 years ago

Hi,

We've been experimenting with expanding our use of the content-available flag and passing data along with it.

We were hoping that we could pass quite a large data set but it turns out that Apple limits the data payload to 4K (https://developer.apple.com/library/content/documentation/NetworkingInternet/Conceptual/RemoteNotificationsPG/CreatingtheNotificationPayload.html) which is annoying but understandable.

It took us a long time, over an hour!, :) to

a) Work out exactly how to pass user data in with the content-available=1 flag

b) There was a data size limit.

It might be worth expanding your doc to show how to pass data

e.g. your current docs say:

"ios_root_params" : {"aps":{"content-available": "1"}}, // Optional — root level parameters to the aps dictionary

They could be expanded to say

"ios_root_params" : {"aps":{"content-available": "1"} , "data": << User supplied data, max of 4KB>> }, // Optional — root level parameters to the aps dictionary

or something.

Might save somebody else a massive 60 mins :)

Thanks

Rob

viridanti commented 7 years ago

Hi,

Thanks for your suggestion! We've updated our Remote API guide already:)

Regards, Andrey