# DuckDuckGo Search API

### Basic Information

**Interface Description:** Retrieve real-time search data from DuckDuckGo via API.

**Interface URL:** <https://scraperapi.thordata.com/request>

**Request Method:** <mark style="color:green;">POST</mark>

### Request parameters

**Headers：**

<table><thead><tr><th width="130.3333740234375">Parameter name</th><th width="130.55560302734375">Type</th><th width="129.6666259765625">Required</th><th>Describe</th></tr></thead><tbody><tr><td><code>token</code></td><td>string</td><td>Yes</td><td>Please log in to the <a href="https://dashboard.thordata.com/account-settings">Dashboard-account-settings</a> to view your <code>token</code></td></tr></tbody></table>

**Body：**

<table><thead><tr><th width="130.22222900390625">Parameter</th><th width="130.22222900390625">Type</th><th width="129.888916015625">Required</th><th width="358.4444580078125">Description</th></tr></thead><tbody><tr><td><code>q</code></td><td>string</td><td>Yes</td><td>Defines the search query for scraping (default: q=pizza). Supports any keyword in any language.<br>For a list of possible values, see <a href="https://duckduckgo.com/duckduckgo-help-pages/settings/params/">Query Parameter</a></td></tr><tr><td><code>format</code></td><td>string</td><td>No</td><td>This parameter defines the output format of the crawl results. <br><code>json=1</code> for JSON, <br><code>json=2</code> for both,<br><code>json=3</code> for HTML.</td></tr><tr><td><code>kl</code></td><td>string</td><td>No</td><td>Specify the interface language and region for search results .For a list of possible values, see <a href="https://duckduckgo.com/duckduckgo-help-pages/settings/params/#kl">Region/Lang</a></td></tr><tr><td><code>start</code></td><td>string</td><td>No</td><td>Set the pagination starting point for search results (e.g., 'start=1 skips the first 1 results and displays from the 2st).For a list of possible values, see <a href="https://duckduckgo.com/duckduckgo-help-pages/settings/params/#s">Pagination</a></td></tr><tr><td><code>df</code></td><td>string</td><td>No</td><td>Filter search results by time range ('<code>d</code>=last 24 hours', '<code>w</code> = last week', '<code>m</code> = last month').For a list of possible values, see <a href="https://duckduckgo.com/duckduckgo-help-pages/settings/params/#df">Time Filter</a></td></tr><tr><td><code>kp</code></td><td>string</td><td>No</td><td>Set the security filter level for search content (Strict/Medium/Off).For a list of possible values, see <a href="https://duckduckgo.com/duckduckgo-help-pages/settings/params/#kp">SafeSearch</a></td></tr></tbody></table>

### Response example

```json
    {
    "spider_parameter": {
        "engine": "duckduckgo",
        "q": "pizza"
    }
    "search_metadata": {
        "created_at": "2025-06-21 14:08:06",
        "id": "xxx",
        "url": "https://duckduckgo.com/search?q=pizza"
    },
    "result":{}
```

<table><thead><tr><th width="170.33331298828125">Parameter Name</th><th width="129.77783203125">Type</th><th width="129.6666259765625">Required</th><th>Description</th></tr></thead><tbody><tr><td><code>spider_parameter</code></td><td>object</td><td>yes</td><td>Search engine parameters configuration</td></tr><tr><td> <code>engine</code></td><td>string</td><td>yes</td><td>Search engine type </td></tr><tr><td><code>q</code></td><td>string</td><td>yes</td><td>Search keyword</td></tr><tr><td><code>search_metadata</code></td><td>object</td><td>yes</td><td>Metadata of the search</td></tr><tr><td> <code>created_at</code></td><td>string</td><td>yes</td><td>Timestamp of the search</td></tr><tr><td> <code>id</code></td><td>string</td><td>yes</td><td>Unique task ID</td></tr><tr><td><code>url</code></td><td>string</td><td>yes</td><td>Full URL of the search request</td></tr><tr><td><code>result</code></td><td>string</td><td>yes</td><td>Return Result</td></tr></tbody></table>


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://doc.thordata.com/interface-documentation/serp-api/duckduckgo-search-api.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
