3

I am trying to use the Google Roads API but it is returning an error when I use the example!

If I type the following URL into my browser I get the following response:

https://roads.googleapis.com/v1/speedLimits?path=51.4907313,-0.2160447|51.4905303,-0.2139847&key=*******

I have replaced my API key with asterisks for obvious reasons.

Response:

{
"error": {
"code": 404,
"message": "Requested entity was not found.",
"status": "NOT_FOUND"
}
}

How can I fix this?

Please note that I am a newbie regarding Google APIs.

2
  • Notice: The Speed Limit service is available to all customers with an Asset Tracking license. - First line of the docs. You have that? If yes, ask Google support.
    – MrUpsidown
    Commented Dec 25, 2019 at 21:19
  • Did you find a solution becasue im having the same issue on android ? Commented Jan 17, 2020 at 11:12

1 Answer 1

4

You most likely do not have a billing Account associated to your Google API project. The same thing happened to me. Since I have set up a billing account and added this to the API project the requests are working as expected.

See: How to add a Google billing account and How to modify a projects billig account

3
  • 1
    I don't undestand why this answer was downvoted. This actually solved my issue when I got 404 message when using snapToRoads API. Although it doesn't match with google troubleshooting as they claim that you should get 403 instead, which makes things a bit more confusing. But nevertheless, this solved my 404 error Commented Apr 10, 2020 at 16:30
  • Isn't there anyway to test the Roads API without setting up a billing account? I just want to try it, not to use it. Commented Oct 16, 2021 at 11:39
  • No, I doubt it. I had to set one up in order to test it. However, it is free.
    – hbertsch
    Commented Oct 25, 2021 at 8:32

Not the answer you're looking for? Browse other questions tagged or ask your own question.