GoogleNavigation Framework Reference
Stay organized with collections
Save and categorize content based on your preferences.
GMSRouteStatus
enum GMSRouteStatus : NSInteger {}
A GMSRouteStatus
is a status code that represents the result of a route request.
-
A route could not be calculated because of an internal error. In some case, this can be
resolved by updating to a newer SDK version.
Declaration
Swift
case internalError = 0
Objective-C
GMSRouteStatusInternalError = 0
-
A route to the destination was successfully calculated.
Declaration
Objective-C
GMSRouteStatusOK
-
A route to the destination could not be calculated.
Declaration
Swift
case noRouteFound = 2
Objective-C
GMSRouteStatusNoRouteFound
-
A route to the destination could not be calculated because of a network error.
Declaration
Swift
case networkError = 3
Objective-C
GMSRouteStatusNetworkError
-
A route to the destination could not be calculated because of insufficient quota.
Declaration
Swift
case quotaExceeded = 4
Objective-C
GMSRouteStatusQuotaExceeded
-
A route could not be calculated because the provided key does not have permission to use the
Navigation SDK.
Declaration
Swift
case apiKeyNotAuthorized = 5
Objective-C
GMSRouteStatusAPIKeyNotAuthorized
-
The route calculation was canceled in favor of a newer one.
Declaration
Objective-C
GMSRouteStatusCanceled
-
A route could not be calculated because there were duplicate waypoints present in the request.
Declaration
Swift
case duplicateWaypointsError = 7
Objective-C
GMSRouteStatusDuplicateWaypointsError
-
A route could not be calculated because no waypoints were provided.
Declaration
Swift
case noWaypointsError = 8
Objective-C
GMSRouteStatusNoWaypointsError
-
A route could not be calculated because the user’s location is not available. This could be
because the user hasn’t granted location permissions for the app.
Declaration
Swift
case locationUnavailable = 9
Objective-C
GMSRouteStatusLocationUnavailable
-
A route could not be generated because there was a problem with the waypoints provided in the
request. For example, a stale or invalid Place ID may have been provided.
Declaration
Swift
case waypointError = 10
Objective-C
GMSRouteStatusWaypointError
-
A route could not be generated if given an unsupported travel mode. For example, if you are
setting destinations with a route token, only Driving and TwoWheeler travel mode are supported.
Declaration
Swift
case travelModeUnsupported = 11
Objective-C
GMSRouteStatusTravelModeUnsupported
Except as otherwise noted, the content of this page is licensed under the Creative Commons Attribution 4.0 License, and code samples are licensed under the Apache 2.0 License. For details, see the Google Developers Site Policies. Java is a registered trademark of Oracle and/or its affiliates.
Last updated 2025-08-27 UTC.
[null,null,["Last updated 2025-08-27 UTC."],[[["\u003cp\u003e\u003ccode\u003eGMSRouteStatus\u003c/code\u003e is an enum representing the result of a Google Maps route request, indicating success, various errors, or other states.\u003c/p\u003e\n"],["\u003cp\u003eA successful route calculation is represented by \u003ccode\u003eGMSRouteStatusOK\u003c/code\u003e.\u003c/p\u003e\n"],["\u003cp\u003eMultiple error statuses, like \u003ccode\u003eGMSRouteStatusNoRouteFound\u003c/code\u003e or \u003ccode\u003eGMSRouteStatusNetworkError\u003c/code\u003e, signal specific reasons for route calculation failures.\u003c/p\u003e\n"],["\u003cp\u003eSome errors, such as \u003ccode\u003eGMSRouteStatusQuotaExceeded\u003c/code\u003e or \u003ccode\u003eGMSRouteStatusAPIKeyNotAuthorized\u003c/code\u003e, relate to usage limits or permissions.\u003c/p\u003e\n"],["\u003cp\u003eOther status codes indicate issues with the request itself, such as \u003ccode\u003eGMSRouteStatusDuplicateWaypointsError\u003c/code\u003e or invalid waypoints.\u003c/p\u003e\n"]]],["`GMSRouteStatus` represents the outcome of a route request, with codes for various results. A successful route calculation is indicated by `OK`. Failures include: `internalError`, `noRouteFound`, `networkError`, `quotaExceeded`, `apiKeyNotAuthorized`, and `canceled`. Waypoint issues are represented by `duplicateWaypointsError`, `noWaypointsError`, `locationUnavailable` and `waypointError`. In addition `travelModeUnsupported` denotes that a route could not be generated if an unsupported travel mode is given. Each status code is declared for both Swift and Objective-C.\n"],null,["# GoogleNavigation Framework Reference\n\nGMSRouteStatus\n==============\n\n enum GMSRouteStatus : NSInteger {}\n\nA `GMSRouteStatus` is a status code that represents the result of a route request.\n- `\n ``\n ``\n `\n\n ### [GMSRouteStatusInternalError](#/c:@E@GMSRouteStatus@GMSRouteStatusInternalError)\n\n `\n ` \n A route could not be calculated because of an internal error. In some case, this can be\n resolved by updating to a newer SDK version. \n\n #### Declaration\n\n Swift \n\n case internalError = 0\n\n Objective-C \n\n GMSRouteStatusInternalError = 0\n\n- `\n ``\n ``\n `\n\n ### [GMSRouteStatusOK](#/c:@E@GMSRouteStatus@GMSRouteStatusOK)\n\n `\n ` \n A route to the destination was successfully calculated. \n\n #### Declaration\n\n Swift \n\n case OK = 1\n\n Objective-C \n\n GMSRouteStatusOK\n\n- `\n ``\n ``\n `\n\n ### [GMSRouteStatusNoRouteFound](#/c:@E@GMSRouteStatus@GMSRouteStatusNoRouteFound)\n\n `\n ` \n A route to the destination could not be calculated. \n\n #### Declaration\n\n Swift \n\n case noRouteFound = 2\n\n Objective-C \n\n GMSRouteStatusNoRouteFound\n\n- `\n ``\n ``\n `\n\n ### [GMSRouteStatusNetworkError](#/c:@E@GMSRouteStatus@GMSRouteStatusNetworkError)\n\n `\n ` \n A route to the destination could not be calculated because of a network error. \n\n #### Declaration\n\n Swift \n\n case networkError = 3\n\n Objective-C \n\n GMSRouteStatusNetworkError\n\n- `\n ``\n ``\n `\n\n ### [GMSRouteStatusQuotaExceeded](#/c:@E@GMSRouteStatus@GMSRouteStatusQuotaExceeded)\n\n `\n ` \n A route to the destination could not be calculated because of insufficient quota. \n\n #### Declaration\n\n Swift \n\n case quotaExceeded = 4\n\n Objective-C \n\n GMSRouteStatusQuotaExceeded\n\n- `\n ``\n ``\n `\n\n ### [GMSRouteStatusAPIKeyNotAuthorized](#/c:@E@GMSRouteStatus@GMSRouteStatusAPIKeyNotAuthorized)\n\n `\n ` \n A route could not be calculated because the provided key does not have permission to use the\n Navigation SDK. \n\n #### Declaration\n\n Swift \n\n case apiKeyNotAuthorized = 5\n\n Objective-C \n\n GMSRouteStatusAPIKeyNotAuthorized\n\n- `\n ``\n ``\n `\n\n ### [GMSRouteStatusCanceled](#/c:@E@GMSRouteStatus@GMSRouteStatusCanceled)\n\n `\n ` \n The route calculation was canceled in favor of a newer one. \n\n #### Declaration\n\n Swift \n\n case canceled = 6\n\n Objective-C \n\n GMSRouteStatusCanceled\n\n- `\n ``\n ``\n `\n\n ### [GMSRouteStatusDuplicateWaypointsError](#/c:@E@GMSRouteStatus@GMSRouteStatusDuplicateWaypointsError)\n\n `\n ` \n A route could not be calculated because there were duplicate waypoints present in the request. \n\n #### Declaration\n\n Swift \n\n case duplicateWaypointsError = 7\n\n Objective-C \n\n GMSRouteStatusDuplicateWaypointsError\n\n- `\n ``\n ``\n `\n\n ### [GMSRouteStatusNoWaypointsError](#/c:@E@GMSRouteStatus@GMSRouteStatusNoWaypointsError)\n\n `\n ` \n A route could not be calculated because no waypoints were provided. \n\n #### Declaration\n\n Swift \n\n case noWaypointsError = 8\n\n Objective-C \n\n GMSRouteStatusNoWaypointsError\n\n- `\n ``\n ``\n `\n\n ### [GMSRouteStatusLocationUnavailable](#/c:@E@GMSRouteStatus@GMSRouteStatusLocationUnavailable)\n\n `\n ` \n A route could not be calculated because the user's location is not available. This could be\n because the user hasn't granted location permissions for the app. \n\n #### Declaration\n\n Swift \n\n case locationUnavailable = 9\n\n Objective-C \n\n GMSRouteStatusLocationUnavailable\n\n- `\n ``\n ``\n `\n\n ### [GMSRouteStatusWaypointError](#/c:@E@GMSRouteStatus@GMSRouteStatusWaypointError)\n\n `\n ` \n A route could not be generated because there was a problem with the waypoints provided in the\n request. For example, a stale or invalid Place ID may have been provided. \n\n #### Declaration\n\n Swift \n\n case waypointError = 10\n\n Objective-C \n\n GMSRouteStatusWaypointError\n\n- `\n ``\n ``\n `\n\n ### [GMSRouteStatusTravelModeUnsupported](#/c:@E@GMSRouteStatus@GMSRouteStatusTravelModeUnsupported)\n\n `\n ` \n A route could not be generated if given an unsupported travel mode. For example, if you are\n setting destinations with a route token, only Driving and TwoWheeler travel mode are supported. \n\n #### Declaration\n\n Swift \n\n case travelModeUnsupported = 11\n\n Objective-C \n\n GMSRouteStatusTravelModeUnsupported"]]