Build with Valyu
The search API for AI knowledge work - agent-native access to the sources knowledge work depends on.
InstallationLearn more about the Search API →Learn more about the Contents API →Learn more about the Answer API →Learn more about DeepResearch →Learn more about the MCP Server →
Start BuildingPython SDK
pip install valyuJavaScript SDK
npm install valyu-js- Search the web
- Extract content
- Get answers
- Deep research
- Use with MCP
Search across the web and the sources knowledge work depends on.
from valyu import Valyu
client = Valyu(api_key="your-api-key")
response = client.search(
query="Latest AI inference datacenter projects",
search_type="all",
max_num_results=10
)
print(response)
import { Valyu } from "valyu-js";
const client = new Valyu("your-api-key");
const response = await client.search("Latest AI inference datacenter projects", {
searchType: "all",
maxNumResults: 10
});
console.log(response);
curl --request POST \
--url https://api.valyu.ai/v1/search \
--header 'Content-Type: application/json' \
--header "x-api-key: $VALYU_API_KEY" \
--data '{
"query": "Latest AI inference datacenter projects",
"search_type": "all",
"max_num_results": 10
}'
Extract and summarise content from any URL.
from valyu import Valyu
client = Valyu(api_key="your-api-key")
response = client.contents(
["https://www.morganstanley.com/insights/articles/economic-outlook-midyear-2025"],
summary=True,
extract_effort="high"
)
print(response)
import { Valyu } from "valyu-js";
const client = new Valyu("your-api-key");
const response = await client.contents([
"https://www.morganstanley.com/insights/articles/economic-outlook-midyear-2025"
], {
summary: true,
extractEffort: "high"
});
console.log(response);
curl --request POST \
--url https://api.valyu.ai/v1/contents \
--header 'Content-Type: application/json' \
--header "x-api-key: $VALYU_API_KEY" \
--data '{
"urls": ["https://www.morganstanley.com/insights/articles/economic-outlook-midyear-2025"],
"summary": true,
"extract_effort": "high"
}'
Get AI answers grounded by our search.
from valyu import Valyu
client = Valyu(api_key="your-api-key")
response = client.answer(
query="What did Apple cite as the main drivers of its revenue change in the MD&A section of its 2023 10-K?"
)
print(response.contents)
import { Valyu } from "valyu-js";
const client = new Valyu("your-api-key");
const response = await client.answer(
"What did Apple cite as the main drivers of its revenue change in the MD&A section of its 2023 10-K?"
);
console.log(response.contents);
curl --request POST \
--url https://api.valyu.ai/v1/answer \
--header 'Content-Type: application/json' \
--header "x-api-key: $VALYU_API_KEY" \
--data '{
"query": "What did Apple cite as the main drivers of its revenue change in the MD&A section of its 2023 10-K?"
}'
Let AI search and research for you, delivering comprehensive reports.
from valyu import Valyu
client = Valyu(api_key="your-api-key")
# Start a research task
task = client.deepresearch.create(
query="Analyze the impact of AI on healthcare"
)
# Check status
status = client.deepresearch.status(task.deepresearch_id)
print(status)
import { Valyu } from "valyu-js";
const client = new Valyu("your-api-key");
// Start a research task
const task = await client.deepresearch.create({
query: "Analyze the impact of AI on healthcare"
});
// Check status
const status = await client.deepresearch.status(task.deepresearch_id);
console.log(status);
curl --request POST \
--url https://api.valyu.ai/v1/deepresearch/tasks \
--header 'Content-Type: application/json' \
--header "x-api-key: $VALYU_API_KEY" \
--data '{
"query": "Analyze the impact of AI on healthcare"
}'
Connect any MCP-compatible AI client to Valyu’s hosted search tools via the remote MCP server.
{
"mcpServers": {
"valyu": {
"url": "https://mcp.valyu.ai/mcp?valyuApiKey=your-api-key"
}
}
}
from openai import OpenAI
client = OpenAI()
response = client.responses.create(
model="gpt-4o",
input="What are the latest AI research papers?",
tools=[
{
"type": "mcp",
"server_label": "Valyu",
"server_url": "https://mcp.valyu.ai/mcp?valyuApiKey=your-api-key",
"require_approval": "never"
}
]
)
print(response.output_text)
import OpenAI from "openai";
const client = new OpenAI();
const response = await client.responses.create({
model: "gpt-4o",
input: "What are the latest AI research papers?",
tools: [
{
type: "mcp",
server_label: "Valyu",
server_url: "https://mcp.valyu.ai/mcp?valyuApiKey=your-api-key",
require_approval: "never"
}
]
});
console.log(response.output_text);
Quickstart
Make your first API call in minutes
Overview
What Valyu is, the core APIs, and how they fit together
Agent Skills
Pre-built skills for Claude Code, Cursor, Windsurf and other coding agents
Pricing
Pay-per-use pricing, with plans that lower cost per credit

