Access blocked per device #3791
Unanswered
wdburgdorf
asked this question in
Q&A
Replies: 1 comment 1 reply
-
The usage policy includes "Provide a valid HTTP Referer or User-Agent identifying the application (stock User-Agents as set by http libraries will not do)." I think email address parameter can be used as alternative if one doesn't have control of referer, user-agent. https://nominatim.org/release-docs/latest/api/Search/#other |
Beta Was this translation helpful? Give feedback.
1 reply
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
-
I am using leafletjs to display maps with a given address.
The call looks like this:
$.getJSON('https://nominatim.openstreetmap.org/search?format=json&q=' ...
It works fine on desktop and on my Android phone. I don't have other devices to test. But when switching to a mobile in Chrome dev tools (Toggle Device Toolbar), the request is blocked, 403:
"Access blocked - You have been blocked because you have violated the usage policy of OSM's Nominatim geocoding service. ..."
Console shows a CORS error: "Access to XMLHttpRequest at 'https://nominatim.openstreetmap.org/search?format=json&q=TheAddress' from origin 'https://mysite.dev' has been blocked by CORS policy: No 'Access-Control-Allow-Origin' header is present on the requested resource.
This happens when no specific device is selected. When one of the devices in the Dimensions dropdown is selected, then it works fine with all of the devices on the list, except "Samsung A51/71".
This is not a big issue, since it will apparently work on almost all devices. Still I'm wondering what causes the issue and if it can be fixed.
Beta Was this translation helpful? Give feedback.
All reactions