# DuckDuckGo Search ## Overview | Property | Value | |----------|-------| | **Status** | active | | **Method** | `GET` | | **Endpoint** | `/v2/duckduckgo/search` | | **Base URL** | `https://api.autom.dev` | | **Credit Cost** | 1 credit per call | | **Documentation** | https://www.piloterr.com/library/duckduckgo-search | ## Description Query DuckDuckGo via API and retrieve structured organic results with region and language. ## Authentication - **Key Name:** `x-api-key` - **Location:** HTTP Header - **Get an API key:** https://app.autom.dev/register ## Example Request ```bash curl --location --request GET 'https://api.autom.dev/v2/duckduckgo/search' \ --header 'Content-Type: application/json' \ --header 'x-api-key: YOUR_API_KEY' ``` ## Example Response ### Search anthropic ```json { "organic_results": [ { "link": "https://www.anthropic.com/", "title": "Anthropic", "domain": "www.anthropic.com", "snippet": "Anthropic is an AI safety company. Claude is its assistant.", "position": 1, "displayed_link": "https://www.anthropic.com" } ], "search_parameters": { "q": "anthropic", "gl": "us", "hl": "en", "page": 1, "engine": "duckduckgo" } } ``` ## Documentation ## Overview Query DuckDuckGo and retrieve organic results: title, link, domain, snippet, and position. ## Quickstart ``` POST https://api.piloterr.com/v2/duckduckgo/search Content-Type: application/json {"query": "anthropic", "page": 1, "gl": "us", "hl": "en"} ``` ## Parameters | Parameter | Type | Required | Description | |---|---|---|---| | `query` | string | yes | Search query | | `page` | integer | no | Page number, starting at 1, capped at 10 | | `gl` | string | no | Country code. gb is sent as uk | | `hl` | string | no | Language code | ## Response `organic_results` contains `position`, `title`, `link`, `domain`, `displayed_link`, and `snippet`. `search_parameters.engine` is `duckduckgo`. ## Notes - An empty query returns 400. - A page with no results returns 404.