POST
/v1/searchWeb search
Runs a search via the Brave Search API (2000 free queries/month) and optionally scrapes each result URL in parallel using the Playwright browser pool. Requires BRAVE_API_KEY in your environment.
Request body
| Name | Type | Required | Description |
|---|---|---|---|
| query | string | required | Search query |
| maxResults | number | optionaldefault: 5 | Number of results to return (max 10) |
| scrape | boolean | optionaldefault: true | Scrape each result URL and include markdown content |
| formats | string[] | optionaldefault: ["markdown"] | Content formats when scrape is true |
Example
bash
curl -X POST http://localhost:3000/v1/search \
-H "Content-Type: application/json" \
-d '{"query":"open source web scrapers","maxResults":5,"scrape":false}'Response
bash
{
"success": true,
"data": {
"results": [
{
"url": "https://github.com/apify/crawlee",
"title": "Crawlee — web scraping library",
"description": "A fast, reliable crawler for Node.js..."
}
],
"total": 5
}
}Try it
Live preview only works when the API is running on your machine.
Run docker compose up and the Try-It panel will become interactive. Until then, copy the curl example below.