Search Controls

Steer Answer API results with freshness, locale, domains, and safesearch.
View as MarkdownOpen in Claude

The Answer API accepts the same freshness, locale, domain, and explicit-content controls as the Web Search API. All controls are optional and can be combined, except include_domains with exclude_domains or boost_domains.

safesearch defaults to moderate. Set it to strict for stronger explicit-content filtering or off to return unfiltered web results.

Freshness

Restrict results to the last week for questions about recent events:

from youdotcom import You
with You() as you:
response = you.answer(
query="What changed in the latest Fed interest rate decision?",
freshness="week",
)

Use a custom date range for questions bounded to a specific period:

from youdotcom import You
with You() as you:
response = you.answer(
query="What were the major AI regulation developments in 2025?",
freshness="2025-01-01to2025-12-31",
)

Domain Filters

Restrict results to trusted sources with include_domains:

from youdotcom import You
with You() as you:
response = you.answer(
query="What are the FDA-approved GLP-1 receptor agonists?",
include_domains=["fda.gov", "nih.gov"],
)

Exclude unreliable sources while boosting authoritative ones. exclude_domains and boost_domains can be used together:

from youdotcom import You
with You() as you:
response = you.answer(
query="What is the current state of quantum computing?",
exclude_domains=["reddit.com", "quora.com"],
boost_domains=["nature.com", "science.org", "arxiv.org"],
)

Country and Language

Focus results on a specific region and language:

from youdotcom import You
with You() as you:
response = you.answer(
query="What are the top startup hubs in Germany?",
country="DE",
language="DE",
)

Select country and language from the supported values.

View full API reference

Next Steps