> ## Documentation Index
> Fetch the complete documentation index at: https://deepline.com/docs/llms.txt
> Use this file to discover all available pages before exploring further.

# Brave: Web Search

> Searching the public web with Brave results, snippets, links, and favicons. Includes SDK V2 examples, input constraints, response fields, and Deepline cost.

Searching the public web with Brave results, snippets, links, and favicons.

<Info>
  Tool ID: `brave_web_search`
</Info>

## Run this action

Use the TypeScript SDK for a single call. Put `ctx.tools.execute(...)` inside a Play when the call should be durable, scheduled, or run across a CSV.

```ts theme={null}
import { Deepline } from 'deepline';

const deepline = await Deepline.connect();
const result = await deepline.tools.execute(
  'brave_web_search',
  {
    "query": "software companies hiring engineers"
  },
);

console.log(result.toolResponse.raw);
```

### CLI

```bash theme={null}
deepline tools execute brave_web_search --input '{
  "query": "software companies hiring engineers"
}' --json
```

## Example response

The SDK exposes this shape at `result.toolResponse.raw`. Values below are representative.

```json theme={null}
{
  "data": {
    "results": [
      {
        "rank": 123,
        "link": "example",
        "title": "VP of Engineering",
        "snippet": "example"
      }
    ]
  }
}
```

Use `deepline tools get brave_web_search --json` for the latest machine-readable contract.

## Input reference

Search the web with Brave Web Search.

| Name                  | Type                       | Required | Default | Details                                                         |
| --------------------- | -------------------------- | -------- | ------- | --------------------------------------------------------------- |
| `payload.query`       | `string`                   | Yes      | —       | Search query, for example: best laptop 2026. Minimum length: 1. |
| `payload.country`     | `string`                   | No       | `"us"`  | Country code, such as us or gb. Minimum length: 1.              |
| `payload.language`    | `string`                   | No       | `"en"`  | Language code, such as en or fr. Minimum length: 1.             |
| `payload.lastUpdated` | `"d" \| "w" \| "m" \| "y"` | No       | —       | Allowed: `d`, `w`, `m`, `y`.                                    |
| `payload.page`        | `integer`                  | No       | —       | Minimum: 1.                                                     |

<details>
  <summary>Show raw input schema</summary>

  ### Input JSON Schema

  ```json theme={null}
  {
    "type": "object",
    "description": "Search the web with Brave Web Search.",
    "properties": {
      "query": {
        "type": "string",
        "description": "Search query, for example: best laptop 2026.",
        "minLength": 1
      },
      "country": {
        "type": "string",
        "description": "Country code, such as us or gb.",
        "default": "us",
        "minLength": 1
      },
      "language": {
        "type": "string",
        "description": "Language code, such as en or fr.",
        "default": "en",
        "minLength": 1
      },
      "lastUpdated": {
        "type": "string",
        "enum": [
          "d",
          "w",
          "m",
          "y"
        ]
      },
      "page": {
        "type": "integer",
        "minimum": 1
      }
    },
    "required": [
      "query"
    ],
    "additionalProperties": false
  }
  ```
</details>

## Output reference

| Name                            | Type      | Required | Default | Details |
| ------------------------------- | --------- | -------- | ------- | ------- |
| `result.data`                   | `object`  | Yes      | —       | —       |
| `result.data.results`           | `array`   | Yes      | —       | —       |
| `result.data.results[].rank`    | `integer` | Yes      | —       | —       |
| `result.data.results[].link`    | `string`  | Yes      | —       | —       |
| `result.data.results[].title`   | `string`  | Yes      | —       | —       |
| `result.data.results[].snippet` | `string`  | Yes      | —       | —       |
| `result.data.results[].favicon` | `string`  | No       | —       | —       |
| `result.meta`                   | `object`  | No       | —       | —       |
| `result.meta.status`            | `integer` | Yes      | —       | —       |

<details>
  <summary>Show raw output schema</summary>

  ### Output JSON Schema

  ```json theme={null}
  {
    "type": "object",
    "properties": {
      "data": {
        "type": "object",
        "properties": {
          "results": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "rank": {
                  "type": "integer"
                },
                "link": {
                  "type": "string"
                },
                "title": {
                  "type": "string"
                },
                "snippet": {
                  "type": "string"
                },
                "favicon": {
                  "type": "string"
                }
              },
              "required": [
                "rank",
                "link",
                "title",
                "snippet"
              ],
              "additionalProperties": true
            }
          }
        },
        "required": [
          "results"
        ],
        "additionalProperties": true
      },
      "meta": {
        "type": "object",
        "properties": {
          "status": {
            "type": "integer"
          }
        },
        "required": [
          "status"
        ],
        "additionalProperties": true
      }
    },
    "required": [
      "data"
    ],
    "additionalProperties": false
  }
  ```
</details>

## Deepline cost

* Pricing model: `provider_usage` (provider usage).
* Estimated Deepline credits: `0.01` per pricing unit.

## Related documentation

* [Brave provider guide](/docs/providers/brave/guide)
* [SDK V2 quickstart](/docs/sdk-v2/quickstart)
* [SDK reference](/docs/sdk-v2/sdk-reference)
* [Run tools across a CSV](/docs/sdk-v2/batch-csv)
