How to use com.apple.developer.usernotifications.filtering entitlement

Question based on the https://developer.apple.com/forums/thread/649172

What is the mechanics of using this entitlement?
What should be done in the UNNotificationServiceExtension in order to prevent the display of a notification for the user?
Just pass an empty UNNotificationContent object to contentHandler or something else?
Answered by Engineer in 635761022
When you apply for this entitlement at https://developer.apple.com/contact/request/notification-service if you are subsequently granted the entitlement, you will receive the necessary documentation on how to filter the incoming notifications.
Accepted Answer
When you apply for this entitlement at https://developer.apple.com/contact/request/notification-service if you are subsequently granted the entitlement, you will receive the necessary documentation on how to filter the incoming notifications.

When you apply for this entitlement at https://developer.apple.com/contact/request/notification-service if you are subsequently granted the entitlement, you will receive the necessary documentation on how to filter the incoming notifications.

Hi!
I haven't received this documentation (
If you receive this documentation please share with me!
Here's what information I got in response to the request:

Hi, 
I've received confirmation that this has been processed. 

You'll need to switch to manually generating provisioning profiles, as this is a special entitlement. 
When you create a Development or Distribution provisioning profile for your Bundle ID, you'll be prompted to select additional entitlements. Click Profiles on the sidebar, then click the Add button (+) in the upper-left corner. Choose a provisioning profile type and follow the prompts until you see “Additional Entitlements.” Select “NSE Filtering” from the dropdown to include the Notifications Service Extension Filtering entitlement in your new profile. Click Continue to finish the process.

Once your profile has been created, you'll need to configure your Xcode project for manual code signing. If your Xcode project doesn't already have an entitlements file, create a new property list file and change its extension from .plist to .entitlements. Add the keys and values of the entitlements used in your project to the .entitlements file, then follow the rest of the Xcode manual signing process. (Note that the unrestricted-voip entitlement applies to the NSE target, not the app target.)

For troubleshooting, see Technote 2415 “Entitlements Troubleshooting” and Debugging Entitlement Issues. If you need additional support, visit the Apple Developer Forums or submit a Technical Support Incident.


Hi @vitosik,
I'm the author of question in your link, I don't receive any documentation after granted by Apple too, but it's very easy to use it. In case you still didn't know how to use it, please follow these step:
  • Edit your provision file on apple developer site: add NSE filtering iOS entitlement to your provision (Notification Service Extension provision, not your main app provision).

  • Add <key>com.apple.developer.usernotifications.filtering</key><true/> to your entitlement file, if you don't have it, create one and config it in project setting, at Code Signing Entitlements (and of course, select your Notification Service Extension target, not main app).

  • Call contentHandler with empty UNNotificationContent to silent origin notification.

If it's not clear enough, please see Signal project for more information
How to use com.apple.developer.usernotifications.filtering entitlement
 
 
Q