Directions API

Find Link Id

Resource URL

Resource Information

Response Formats JSON, XML
Authentication Yes (Requires Key)
Rate Limited Yes

Request Parameters

Request Parameter Description Required?
The API Key, which is needed to make requests to MapQuest services. Yes
lat The latitude of the point to find a Link Id. Yes
lng The longitude of the point to find a Link Id. Yes
outFormat Specifies the format of the response. Must be one of the following, if supplied:
  • json
  • xml
Default: json
callback A JavaScript function name. The JSON-formatted response will be wrapped in a call to the supplied callback function name to provide JSONP functionality. This functionality might be needed to do cross-site scripting. See the entry for JSON for more details. No


Response Field Description
linkId The Link Id of a road, which can later be supplied with the mustAvoidLinkIds or the tryAvoidLinkIds route option attributes.
street The street name of the road Link Id found.
info This field contains information about the response.

The statuscode subfield is an integer return value. See the Status Codes page for more details on our status codes and error messages.

The messages subfield is an array of error messages which describe the status.

Example Request


Example Response

  "linkId": 37214459,
  "street": "Granite Run Dr",
  "info": {
    "copyright": {
      "text": "© 2018 MapQuest, Inc.",
      "imageUrl": "",
      "imageAltText": "© 2018 MapQuest, Inc."
    "statuscode": 0,
    "messages": []
<?xml version="1.0" encoding="UTF-8"?>
    <street>Granite Run Dr</street>
            <imageAltText>© 2018 MapQuest, Inc.</imageAltText>
            <text>© 2018 MapQuest, Inc.</text>