Can a public IP address be used as Google OAuth redirect URI?

I'm trying to set a web service that needs the user's Google Latitude info, so I'm using Google OAuth to get the user authorization stuff.

However, when trying to set the redirection URI in the Google APIs Console for a web application client ID I get a message error if I try to set it to 'http://PUBLIC_IP/'.

I need to test it with non local users (thus localhost can't be used), so I would like to know if having a web domain is mandatory in order to use Google's OAuth. If not, how can I solve this issue?


Solution 1:

This is not currently supported. I filed a feature request and will update on progress.

Solution 2:

You can use xip.io to work around it.

For example: '192.168.0.50.xip.io:3000' will resolve to '192.168.0.50:3000'

Solution 3:

I ran into this issue too and so I entered a URL with a .com extension and also entered it into my /etc/hosts file. Works like a charm.

It totally sucks that my entire app now has to be developed on an apparently 'live' domain though.