iOS CallKit Directory Extension Tips

Tips:

  1. The label text that you see will have the following format: Caller ID:  You can change the app name part of the label by changing app’s Bundle Name.
  2. You must provide a full country code and area code with the phone number.
  3. -reloadExtensionWithIdentifier:completionHandler:, which requests to have your app extension’s data reloaded by the system. Call this whenever you have new blocking or identification data to provide to the system.
  4. -getEnabledStatusForExtensionWithIdentifier:completionHandler:, which allows your app to query whether its extension has been enabled in Settings. Call this from within your app before requesting to reload data, and perhaps prompt the user to first enable your extension in Settings in order to begin loading data.
  5. The array of phone numbers must be a sorted list of int64’s. From smallest to largest. The list will be rejected with an “entries out of order” error otherwise.
  6. Store all the contacts to directory every time, because directory is getting recreated (loosing the previous contacts). Checked in iOS 11.
  7. Make sure the phone numbers are of type NSNumber instead of NSString.
Advertisements

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Google+ photo

You are commenting using your Google+ account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s

%d bloggers like this: