# Bing Search API

### Basic Information

**Interface Description:** Retrieve real-time search data from Bing 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">Parameter name</th><th width="130">Type</th><th width="130">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">Parameter name</th><th width="130">Type</th><th width="130">Required</th><th>Describe</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). <a href="https://learn.microsoft.com/en-us/bing/search-apis/bing-web-search/reference/query-parameters#query-parameters">Full list</a>.</td></tr><tr><td><code>json</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>cc</code></td><td>string</td><td>No</td><td>This sets the country code (two-letter) for tailoring search results.For a list of possible values, see <a href="https://learn.microsoft.com/en-us/bing/search-apis/bing-web-search/reference/market-codes#country-codes">Country  codes</a>.</td></tr><tr><td><code>mkt</code></td><td>string</td><td>No</td><td>This defines the UI language for search results.For a list of possible market values, see <a href="https://learn.microsoft.com/en-us/bing/search-apis/bing-web-search/reference/market-codes">Market codes</a>.</td></tr><tr><td><code>location</code></td><td>string</td><td>No</td><td>This parameter defines the starting geographic <code>location</code> for scraping. It should be used together with <code>lat</code> (latitude) and <code>lon</code> (longitude). </td></tr><tr><td><code>lat</code></td><td>string</td><td>No</td><td>latitude of the starting geographic location during scraping. Use it together with location and <code>lat</code> (longitude). </td></tr><tr><td><code>lon</code></td><td>string</td><td>No</td><td>This parameter defines the {a1} longitude of the starting geographic location during scraping. Use it together with {a2} and {} (latitude). </td></tr><tr><td><code>first</code></td><td>string</td><td>No</td><td>This parameter controls the offset of the natural search results.It defaults to 1 (for example, if first=10, the 10th natural search result will be promoted to the first place).</td></tr><tr><td><code>count</code></td><td>string</td><td>No</td><td>The per page parameter controls the number of search results displayed per page (minimum: 1, maximum: 50)<br> For more information, see <a href="https://learn.microsoft.com/en-us/bing/search-apis/bing-web-search/page-results">Paging results</a>.</td></tr><tr><td><code>adlt</code></td><td>string</td><td>No</td><td>This parameter specifies whether to filter adult content. Options are <code>strict</code> (strict filtering) or <code>off</code> (no filtering).<a href="https://learn.microsoft.com/en-us/bing/search-apis/bing-web-search/reference/query-parameters#safesearch">Full list</a>.</td></tr></tbody></table>

### Response example

```json
{
    "spider_parameter": {
        "engine": "bing",
        "q": "pizza"
    },
    "total": {
        "value": "About 2,240,000,000 results (0.30 seconds) "
    },
    "search_metadata": {
        "created_at": "2025-06-21 14:08:06",
        "id": "xxx",
        "url": "https://www.bing.com/search?q=pizza"
    },
    "result":{}
```

<table><thead><tr><th width="160">Parameter Name</th><th width="130">Type</th><th width="130">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>total</code></td><td>object</td><td>yes</td><td>Total search results information</td></tr><tr><td>    <code>value</code></td><td>string</td><td>yes</td><td>Result count and time </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/bing-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.
