Suppressing notifications irrespective of iOS version

Hello friends, We are building a driving assistant app that gives description of the customer’s car details like fuel efficiency, battery health etc. We also send to notification to our users when they drive their car like harsh acceleration, over riding etc. One the most requested feature for our app is “Suppressing the notifications when the user is driving automatically”. So our customers will toggle a new feature called - Intelligent Alerts, which will automatically suppress the notifications of the app when the user is driving.

This is our progress -

  1. We know about com.apple.developer.usernotifications.filtering entitlement and its ability to suppress notifications but want something that works for iOS 12 and iOS 13 also (This only works for iOS 13.3 plus)
  2. We want to compare the car location to user location at all time if it matches then the user is driving and we suppress the notifications

My Question : - 

  1. How can we suppress notifications irrespective of the state of app like foreground, background or killed
  2. How can we access the location of the user at all time irrespective of the state of app like foreground, background or killed