OAuth with wrong server issue

I built an app that is used DOMAIN as the mobile server and using dns to point to the IP ADDRESS. App got accepted but the OAuth doesn’t work because the app is trying to login in with DOMAIN but its trying to return the OAuth to IP ADDRESS. So it doesn’t work on the app, but when I login directly from the IP ADDRESS it works flawlessly.

My root url is the IP address but the mobile build was the domain.

How can I keep the domain as the mobile-server but have the OAuth redirect back to the app?