curl -X POST https://win.oneshotagent.com/v1/tools/search \
-H "Content-Type: application/json" \
-H "payment-signature: <base64 x402 payment>" \
-d '{
"query": "best AI agent frameworks 2026",
"max_results": 5
}'
import { OneShot } from "@oneshot-agent/sdk";
const agent = new OneShot({ privateKey: process.env.AGENT_PRIVATE_KEY });
const results = await agent.webSearch({
query: "best AI agent frameworks 2026",
max_results: 5,
});
for (const result of results.data.results) {
console.log(`${result.title}: ${result.url}`);
}
{
"success": true,
"data": {
"query": "best AI agent frameworks 2026",
"results": [
{
"url": "https://example.com/ai-frameworks",
"title": "Top AI Agent Frameworks in 2026",
"description": "A comprehensive comparison of the leading AI agent frameworks..."
},
{
"url": "https://example.com/langchain-vs-crewai",
"title": "LangChain vs CrewAI: Which Framework to Choose",
"description": "An in-depth comparison of two popular agent frameworks..."
}
],
"result_count": 2
}
}
Web & Browser
Web Search
Search the web and get structured results synchronously
POST
/
v1
/
tools
/
search
curl -X POST https://win.oneshotagent.com/v1/tools/search \
-H "Content-Type: application/json" \
-H "payment-signature: <base64 x402 payment>" \
-d '{
"query": "best AI agent frameworks 2026",
"max_results": 5
}'
import { OneShot } from "@oneshot-agent/sdk";
const agent = new OneShot({ privateKey: process.env.AGENT_PRIVATE_KEY });
const results = await agent.webSearch({
query: "best AI agent frameworks 2026",
max_results: 5,
});
for (const result of results.data.results) {
console.log(`${result.title}: ${result.url}`);
}
{
"success": true,
"data": {
"query": "best AI agent frameworks 2026",
"results": [
{
"url": "https://example.com/ai-frameworks",
"title": "Top AI Agent Frameworks in 2026",
"description": "A comprehensive comparison of the leading AI agent frameworks..."
},
{
"url": "https://example.com/langchain-vs-crewai",
"title": "LangChain vs CrewAI: Which Framework to Choose",
"description": "An in-depth comparison of two popular agent frameworks..."
}
],
"result_count": 2
}
}
Overview
Synchronous web search. Results return in the response, with no polling.Authentication
Requires x402 payment in thepayment-signature header.
Request Body
string
required
Search query (1-500 characters)
integer
default:5
Maximum results to return (1-20)
Response (200)
string
The search query
array
Results, each with
url, title, and descriptioninteger
Number of results returned
curl -X POST https://win.oneshotagent.com/v1/tools/search \
-H "Content-Type: application/json" \
-H "payment-signature: <base64 x402 payment>" \
-d '{
"query": "best AI agent frameworks 2026",
"max_results": 5
}'
import { OneShot } from "@oneshot-agent/sdk";
const agent = new OneShot({ privateKey: process.env.AGENT_PRIVATE_KEY });
const results = await agent.webSearch({
query: "best AI agent frameworks 2026",
max_results: 5,
});
for (const result of results.data.results) {
console.log(`${result.title}: ${result.url}`);
}
{
"success": true,
"data": {
"query": "best AI agent frameworks 2026",
"results": [
{
"url": "https://example.com/ai-frameworks",
"title": "Top AI Agent Frameworks in 2026",
"description": "A comprehensive comparison of the leading AI agent frameworks..."
},
{
"url": "https://example.com/langchain-vs-crewai",
"title": "LangChain vs CrewAI: Which Framework to Choose",
"description": "An in-depth comparison of two popular agent frameworks..."
}
],
"result_count": 2
}
}
See Pricing for web search costs.
Notes
- Results return synchronously (no job polling)
- Each paid call is recorded: it has a job record and a receipt, like Web Read
- 15-second timeout per request