Keenable for AI Agents: Web Search, Fresh Evidence and Citations You Can Verify
How to integrate Keenable search and fetch into a research agent, distinguish snippets from evidence, handle freshness and truncation, and evaluate grounded answers. Includes Python HTTP examples and an evidence pipeline diagram.
BY MEI LIN · FDEINTERVIEWS EDITORIAL · UPDATED NOVEMBER 15, 2026 · 4 MIN READ
PRACTICE THIS:Learn web-grounded decisions ·Build production AI agents ·Practice RAG and agent design
Keenable is a web search and page-fetching API for AI agents. It can supply compact search results, but a reliable research agent must still fetch relevant evidence, preserve its provenance and verify the claims it writes. The engineering work lies in that path from search result to answer.
This article uses Keenable's official documentation and its Python SDK source, reviewed on November 15, 2026. Provider benchmark rankings and token-saving claims are not treated as independent measurements here.
Separate discovery from evidence
Suppose a customer asks whether a database feature is available in their region. A snippet may mention the feature and region without showing the condition that separates preview access from general availability. Passing that snippet straight to an answer writer creates a plausible answer with a missing qualification.
Use search to discover candidates. Fetch the strongest primary sources, preserve their text, and ask the writer to use only supported claims. If the source is incomplete, return that limitation or retrieve the missing section. Our deep research agent review shows why a reviewer that merely sees the same snippets can miss the same error.
The diagram describes a recommended application design, not an automatic guarantee supplied by Keenable. The evidence record is what lets you inspect the answer later.
A small HTTP integration
The official SDK offers search() and fetch(). Raw HTTP makes the boundary especially clear: public search is a POST, public fetch is a GET, and both require an application header. Authenticated routes omit /public and use an API key. Check the API reference when moving between these modes.
This Python example searches only public documentation. It makes one request, with no retry loop or customer information in the query.
import json
from urllib.request import Request, urlopen
headers = {
"Content-Type": "application/json",
"X-Keenable-Title": "FDE Interviews learning example",
}
payload = {
"query": "Python sqlite3 transaction control documentation",
"site": "docs.python.org",
"max_results": 3,
"snippet_max_length": 600,
"disable_cards": True,
}
request = Request(
"https://api.keenable.ai/v1/search/public",
data=json.dumps(payload).encode(),
headers=headers,
method="POST",
)
with urlopen(request, timeout=15) as response:
result = json.load(response)
for item in result["results"]:
print(item["title"], item["url"])
This is a discovery result. For a known source, fetching is a separate operation:
from urllib.parse import urlencode
query = urlencode({
"url": "https://docs.python.org/3/library/sqlite3.html",
"live": "true",
"max_chars": 12000,
})
request = Request(
"https://api.keenable.ai/v1/fetch/public?" + query,
headers=headers,
)
with urlopen(request, timeout=15) as response:
page = json.load(response)
print("Truncated:", page["truncated"])
print(page["content"][:300])
We ran both requests: search returned three results, and the 12,000-character fetch reported truncated: true. That is a useful result to test, since the returned introduction did not establish that every transaction-control detail was present. Search results and source text will change over time.
The timeout limits socket waits; it is not an end-to-end task deadline. A production wrapper also needs response-size limits, cancellation and explicit handling of API errors. These snippets demonstrate the request contract, not a complete production client.
Preserve the distinction between page text and extraction
According to the fetch reference, fetch can use an indexed copy unless you request live=true. With a prompt, the returned content is a model-generated extraction rather than the complete page. That can be useful, but it changes what you are auditing.
| Record | What to retain | Why it matters |
|---|---|---|
| Search hit | Query, rank, URL and snippet | Reconstruct why the page was selected |
| Fetched page | URL, fetch time, content hash and text | Inspect the version actually used |
| Extraction | Prompt, extracted text and source reference | Distinguish model interpretation from source text |
| Claim | Answer span, evidence span and review result | Check support at the level the user reads |
Store truncated and total_chars too. A character cap is not a completeness check. If a limit removes the relevant exceptions table, a short result can make the answer worse.
The search reference also describes provider-generated cards whose URLs expire. The example disables them because a durable citation should lead back to a stable source. Search filters can reduce the number of results; do not fill the requested count with unrelated evidence.
Use freshness that matches the question
Publication time, index time and fetch time answer different questions. A fresh fetch of an old policy is still an old policy. A recently indexed page may describe an event from years ago.
For a current availability question, check the relevant release date and applicable version in the source. For historical research, retrieving today's documentation may erase precisely the behavior being investigated. Keep the user's time requirement explicit in the context packet.
When sources disagree, show the disagreement and prefer the applicable authoritative version. More searches are useful only if they address a named evidence gap. The web-grounded decisions concept explains how that evidence affects a downstream decision.
Bound the search loop and its authority
Give the agent a request budget and a deadline. On a transient failure, retry only while both allow it. A rate-limit response and an exhausted-credit response require different actions; repeatedly retrying exhausted credits cannot restore service. The SDK guide documents retry behavior, so count library retries when budgeting the task.
Keenable's data policy describes retention of queries, URLs, prompts and results. Remove customer identifiers and internal details before an external search. Keyless access does not remove that data boundary.
Retrieved text can also contain hostile instructions. Keep it separate from tool policy, and never let a fetched page authorize another network call or a write to customer systems. Start with approved domains and read-only tools. The agent gateway concept covers centralized enforcement.
Evaluate the answer the customer receives
Compare providers on the same representative questions, not a collection of convenient demos. Include a changed policy, an unanswerable question, a misleading snippet, a contradictory source and an unavailable page.
Measure relevant-source coverage before generation. Then measure claim support, correct abstention, completed-task cost and latency. A cheaper snippet format earns its place when the answer retains the necessary conditions. It does not earn its place merely by reducing tokens.
Use agent trajectory evals to inspect unnecessary fetches and repeated searches. Keep failures as regression cases, and practice the design tradeoffs in the RAG and agent question bank. A good search integration leaves you able to explain both why an answer was given and why the agent sometimes declined to give one.
Turn it into offers. Work the real questions and concepts this maps to:
FAQ
Keenable provides hosted web search and page fetching for agents. Search helps discover candidate pages; fetch retrieves page content for closer examination. An application still needs to verify whether that evidence supports its answer.
The documented public endpoints support keyless requests. Raw HTTP uses the /public routes and an X-Keenable-Title application header. Production integrations can use authenticated endpoints, and should handle shared limits, timeouts and data retention explicitly.
No. Fetch can return an indexed copy. The live option requests the origin, and a character limit can still truncate the result. Record fetch time and inspect the truncation fields before calling the evidence complete.
No. A numbered citation identifies a source candidate. Grounding requires checking that the cited content supports the particular claim, including qualifications, dates and units.
Discussion (3)
A valid source URL and a supported claim are separate checks. The first can pass even when the page contradicts the answer.
A useful empty-result experience asks for a narrower question or names the missing evidence. Filling the gap from model memory defeats the reason for searching.
Put a deadline on the whole research task. A timeout applied independently to each retry does not bound the time the user waits.
