iOS Google Places API: "This IP, site or mobile application is not authorized to use this API key"
Asked Answered
B

1

12

I am testing the Google Places API on an iOS 7 app.

When I send a request to the API I get a json result with the following error message:

This IP, site or mobile application is not authorized to use this API key.

To build the request, I went to the Google API console and generated my iOS API Key based on my application bundle.

I'm not using Google Maps or anything else on the app, just trying to make a request to the Places API.

Is there anything I'm missing?

PS: I copied the URL I'm using and changed the API key to the browser client key and tested it in Chrome and worked perfectly.

Booze answered 18/4, 2014 at 22:59 Comment(6)
Have you tried using the browser client key inside the iOS app? From what I remember, the places API Doesn't support the iOS keys.Acquire
I haven't, but I will. Right now they specifically ask you for your iOS app bundle identifier or app Id if deployed on the App Store. Will try and let you know.Booze
@JoelBell !!! You got it. It's working. It serves to the purposes of my testing but eventually I'll talk to them to see what happened, but the client side key worked!!! Thank you!Booze
I'm having the same "not authorized to use this API key" with my Android app and what I believe to be a properly generated Android client key. When I tried a no-referrer browser key I get 'The provided API key is expired.'Rriocard
@jsicary, no problem! Glad to help. I'll make this into answer so the we can have closure to the question.Acquire
#Following answer By @moe is working perfectly, [Answer by "Moe" is working full] [1] [1]: #14655258Labannah
A
26

Have you tried using the browser client key inside the iOS app? From what I remember, the places API doesn't support iOS keys.

More info here: https://groups.google.com/forum/#!topic/google-places-api/Jlm15dG7eMA

And from the google api console docs: https://developers.google.com/console/help/#generatingdevkeys

Acquire answered 21/4, 2014 at 2:11 Comment(0)

© 2022 - 2024 — McMap. All rights reserved.