You.com
Search web and news results with YouTools, including domain filters and optional page content.
YouTools wraps the You.com Search API and combines its web and news results into JSON or Markdown. It extracts snippets and available page content, with a configurable text limit per result.
The adapter uses GET /v1/search, which You.com continues to support. Its optional livecrawl settings are deprecated by the provider but remain supported. The newer POST-only extraction features are not exposed by this adapter.
Prerequisites
YouTools uses the httpx client already bundled with Agno. The example below runs on the default OpenAI model, so it needs the openai library and a You.com API key, available at you.com/platform/api-keys.
uv pip install -U agno openaiexport YDC_API_KEY=***
# optional: override the default API endpoint (https://ydc-index.io)
# export YDC_BASE_URL=https://your-you-compatible-endpointExample
The following agent searches within the selected news domains:
from agno.agent import Agent
from agno.tools.youcom import YouTools
agent = Agent(
tools=[YouTools(
include_domains=["cnbc.com", "reuters.com", "bloomberg.com"],
num_results=8,
show_results=True,
)],
)
agent.print_response("Search for AAPL news", markdown=True)Toolkit Functions
| Function | Description |
|---|---|
you_search | Search the web for a given query. Accepts query (str) and an optional num_results (int) to override the count per provider section. Web and news results are combined, so the total can exceed that count. Returns results as JSON or markdown. |
Toolkit Params
| Parameter | Type | Default | Description |
|---|---|---|---|
api_key | Optional[str] | None | You.com API key. Falls back to the YDC_API_KEY environment variable. |
base_url | Optional[str] | None | Override the API base URL. Falls back to YDC_BASE_URL, then https://ydc-index.io. |
num_results | int | 5 | Requested count per provider section (web/news), not a combined-result cap. |
livecrawl | Optional[Literal["web", "news", "all"]] | None | Optional page crawling by result section; off by default. |
livecrawl_formats | Union[str, List[str]] | "markdown" | Content formats. A comma-separated string is converted to a list; used only with live crawling. |
text_length_limit | int | 1000 | Maximum length of text content per result. |
include_domains | Optional[List[str]] | None | Restrict results to these domains. Cannot combine with exclude_domains or boost_domains. |
exclude_domains | Optional[List[str]] | None | Exclude results from these domains. |
country | Optional[str] | None | Geographical focus of results. |
freshness | Optional[str] | None | Date filter, such as day, week, month, or year. |
language | Optional[str] | None | Result language. |
safesearch | Optional[str] | None | Provider filter: off, moderate, or strict. |
offset | Optional[int] | None | Pagination offset in multiples of result count; 0–9. |
boost_domains | Optional[List[str]] | None | Prefer domains without restricting results to them. Cannot combine with include_domains. |
crawl_timeout | int | 10 | Page-content timeout in seconds, 1–60; sent only with live crawling. |
search_params | Optional[Dict[str, Any]] | None | Additional GET query parameters; override named request settings on collision. |
timeout | int | 30 | Maximum time in seconds to wait for API responses. |
format | Literal['json', 'markdown'] | 'json' | Output format for search results. |
show_results | bool | False | Log responses for debugging. |