http请求失败,状态代码:403,tile.opentreetmap.org flutter
在尝试从OpenStreetMap加载瓷砖时,我正在遇到403错误,我正在寻找一种解决问题的方法,我认为我可能违反了大量使用,但是该应用程序只是在开发阶段。 提前致谢
Am getting the 403 error while trying to load tiles from the OpenStreetMap, I am looking for a way to solve the issue, I think I might have violated the heavy use but the app is just in the development stage.
Thanks in advance
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
如果不设置适当的用户代理来访问开放式街道地图,这就是发生这种情况。
对于Android:
在加载地图之前,请将其放入活动中。
OpenStreetMaptilEpRoviderConstants.SetUserAgentValue(buildConfig.application_id);
但是对于扑朔迷离,您使用任何插件吗?例如: https://pub.dev/packages/ppackages/flutter_osm_plugin
请提供有关您如何提供您的更多详细信息正在您的Flutter应用程序访问OSM。
This is happening, if a proper User-Agent is not set to access open street map.
For Android:
Please put this in your activity before loading the map.
OpenStreetMapTileProviderConstants.setUserAgentValue(BuildConfig.APPLICATION_ID);
But for flutter, do you use any plugins? for example : https://pub.dev/packages/flutter_osm_plugin
Please provide some more details on how you are accessing osm from your flutter app.