Search code examples
iosappstore-approvaliphone-privateapi

Apple rejected an app that for use on non public api where there aren't any non pulic apis


This is the message I got from Apple for rejecting my app:

Your app uses or references the following non-public APIs:

didDetermineState:forRegion:
didEnterRegion:
didExitRegion:

The use of non-public APIs is not permitted on the App Store because it can lead to a poor user experience should these APIs change.

I really don't know what to do as there api are clearly public. Anyone got some advise? It would really help.


Solution

  • I think the public apis you are mentioning about are those in CLLocationManagerDelegate. If it is the case, take didEnterRegion:, for example, the api is actually locationManager:didEnterRegion:. However, Apple mentions didEnterRegion: only. That probably means somewhere in your app, you have declared a method with that exact signature, and it happens to have the same signature with a private api method.

    My suggestion is to do a search on your whole project for such methods and rename them.