JustSERPDocs
DuckDuckGo

DuckDuckGo Maps

The places DuckDuckGo lists for a query in an area, answered as the document: `search_metadata`, `search_parameters`, `search_information` (`query_displayed`), `local_results` and `place_result`.

GET
/v1/duckduckgo/maps

The places DuckDuckGo lists for a query in an area, answered as the document: search_metadata, search_parameters, search_information (query_displayed), local_results and place_result. Exactly one of location, lat with lon, or bounding_box is required, so that the area is the caller's. A place is a Yelp or Apple Maps record DuckDuckGo merged; keys it lacks are left out. distance, bounds, region, country, neighborhoods and types are not answered. zero_retention is not handled.

Authorization

headerX-API-Key<token>

Your API key.

Query Parameters

cancel_token?string

A name you make up for this request (a UUID is fine), so you can later GET /v1/cancel with it. Only you know it, so only you can cancel. Use a new one for every request, retries included: a cancelled token stays cancelled for a few minutes.

Length1 <= length <= 128
q*string

What to look for, optionally naming the place ("coffee shops in brooklyn").

Length1 <= length <= 500
device?"desktop"

Anything but desktop is a 400.

Default"desktop"
Value in"desktop"
location?string

A city, region or country name, asked as "q in location" with no box. A postcode is not understood.

Lengthlength <= 200
lat?number

With lon: a box of +/-0.04 degrees (about 9 km across) around the point.

Range-90 <= value <= 90
lon?number

With lat.

Range-180 <= value <= 180
bounding_box?string

west,south,east,north, brackets optional, latitudes in either order. A side spans at most 60 degrees, no antimeridian crossing.

Response Body

The places, as the document. When the page could not be parsed, the usual envelope.

application/json
  1. response

The DuckDuckGo Maps document.

search_metadata*
search_parameters*

The request's own fields as sent, engine first, without cancel_token.

search_information*

The parser's own, e.g. yelp_search's; otherwise {}.

local_results?array<>
place_result?

The area named in the query and the middle of the places.

[key: string]?any
Example Request
curl -X GET 'https://api.justserp.com/v1/duckduckgo/maps?q=coffee+shops&location=brooklyn'
Example Response
{  "search_metadata": {    "id": "string",    "status": "Success",    "created_at": "string",    "request_url": "string",    "html_url": "string"  },  "search_parameters": {},  "search_information": {    "query_displayed": "string"  },  "local_results": [    {      "position": 0,      "title": "string",      "source": "string",      "link": "string",      "apple_maps_place_id": "string",      "yelp_place_id": "string",      "address": "string",      "city": "string",      "country_code": "string",      "gps_coordinates": {        "latitude": 0,        "longitude": 0      },      "phone": "string",      "phone_formatted": "string",      "website": "string",      "rating": 0,      "reviews": 0,      "price_score": 0,      "type": "string",      "open_state": "string",      "open_hours": {},      "timezone": "string",      "amenities": [        "string"      ],      "thumbnail": "string",      "images": [        "string"      ],      "images_link": "string",      "menu_link": "string",      "user_reviews": [        {          "review_id": "string",          "snippet": "string",          "rating": 0,          "iso_date": "string",          "user": {            "name": "string"          }        }      ]    }  ],  "place_result": {    "title": "string",    "gps_coordinates": {      "latitude": 0,      "longitude": 0    }  }}