When making app requests on Facebook using the iOS SDK, the developers guide requires that developers clear the request when the app is opened.
Deleting Requests
When a user is directed to your app by clicking accepting a Request
you must delete the request after it has been accepted. Requests are
not automatically deleted once they have been clicked, thus it is the
developer’s responsibility to clear them once they have been accepted.
https://developers.facebook.com/docs/requests/#deleting
Is there a function to clear all notifications, or other helpers like that?
The following API will clear a specific app-request:
Substitute the request ID for REQUEST-ID and the Facebook user’s Id for USER-ID (the underline between the two is important). Change the
andDelegateandandParamsas needed, but don’t pass anilobject toandParamsotherwise it will completely fail.To delete all the requests, you need to iterate through all the requests passed in the url in :
which is probabaly implemented in your app delegate.
All of the user’s existing request-ids are comma-separated in the
request_idsparameter of thetarget_urlparamater in theurlNSURL. This only happens when a user clicks on an app-request notification in the iOS Facebook app and your facebook app hasiOS Native Deep Linkingenabled.