使用 Google 地图 API - 路线 API 如何知道我们何时离开环岛

How to know when we exited a roundabout when using Google Map API - Directions API

我正在使用 Google 地图 API with Directions API 来获取在驾驶时向用户显示说明的路线。

在他们转一圈之前,我可以告诉他们走 "n th" 出口。但是当他们绕圈时,google api 认为我们在下一步,并说类似在 500 米处右转。所以,我想知道我们什么时候离开环岛,然后再显示下一步指令。

我知道使用 Mapbox API 方向我们可以有交叉点,但是有没有办法通过 Google API 获得此信息?

您应该了解服务条款中公开的限制。请查看第 10.4 (c) 段

No navigation. You will not use the Service or Content for or in connection with (a) real-time navigation or route guidance; or (b) automatic or autonomous vehicle control.

https://developers.google.com/maps/terms#10-license-restrictions

您的用例可能违反了 ToS。