> ## Documentation Index
> Fetch the complete documentation index at: https://docs.keenable.ai/llms.txt
> Use this file to discover all available pages before exploring further.

> ## Agent Instructions
> Every page is listed in https://docs.keenable.ai/llms.txt. To pick a product for a job, read https://docs.keenable.ai/choose.md
> Setup steps for agents, covering the SDKs, the MCP server and the CLI: https://docs.keenable.ai/skill.md
> Keenable search and fetch work without an API key. To add them to code, use the official SDK for the project's language: https://docs.keenable.ai/sdks.md
> Without a key, call POST https://api.keenable.ai/v1/search/public or GET https://api.keenable.ai/v1/fetch/public with an X-Keenable-Title header that names your app.
> With a key, send it in the X-API-Key header and read it from the KEENABLE_API_KEY environment variable. Never ask a user to paste a key into chat. Every access method: https://docs.keenable.ai/auth.md
> To get an API key without the console, use device login: https://docs.keenable.ai/authentication.md#device-login
> MCP server: https://api.keenable.ai/mcp (no key, or X-API-Key; keyless Codex uses https://api.keenable.ai/mcp-public), or https://api.keenable.ai/mcp-oauth for OAuth sign-in. These docs are an MCP server at https://docs.keenable.ai/mcp and the OpenAPI spec is at https://docs.keenable.ai/api-reference/openapi.json
> Keenable searches and fetches public web pages. If a question needs no web information, skip the call.
> On 402 with an API key (code insufficient_credits), stop and ask a human to add credits; don't retry. On 429, wait the number of seconds in Retry-After, then retry. Before you ship, follow https://docs.keenable.ai/production.md
> Every error, with its cause and fix, is in https://docs.keenable.ai/errors.md and moving from another search API is covered in https://docs.keenable.ai/migrate.md
> Before you compare Keenable with another search API, read https://docs.keenable.ai/guides/evaluate-search-apis.md

# OctoTools web search tool

> Give OctoTools solvers web search with Keenable_Search_Tool, a tool card in the OctoTools toolbox, with site and date filters and no API key.

*Tool card in OctoTools*

`Keenable_Search_Tool` gives an OctoTools solver web search, with an optional site filter and publication date range. It is a tool card in [OctoTools](https://github.com/octotools/octotools), next to the Google, Exa, Parallel and Serply cards, and it runs without an API key.

→ [Keenable\_Search\_Tool in the OctoTools repository](https://github.com/octotools/octotools/blob/main/octotools/tools/keenable_search/tool.py)

## Install

The tool card ships in the `octotoolkit` package 0.3.7 and later:

```bash theme={"theme":{"light":"github-light-high-contrast","dark":"dark-plus"}}
pip install -U "octotoolkit>=0.3.7"
```

The solver example uses OctoTools' default `gpt-4o` engine, so put `OPENAI_API_KEY` in a `.env` file or the environment.

## Add it to a solver

Name `Keenable_Search_Tool` in `enabled_tools`. The default `enabled_tools=["all"]` leaves it out, so the solver only calls Keenable when you ask for it:

```python theme={"theme":{"light":"github-light-high-contrast","dark":"dark-plus"}}
from octotools.solver import construct_solver

solver = construct_solver(
    llm_engine_name="gpt-4o",
    enabled_tools=["Generalist_Solution_Generator_Tool", "Keenable_Search_Tool"],
)

output = solver.solve("What did the latest Python release change?")
print(output["direct_output"])
```

The solver plans with the tools you named, calls `Keenable_Search_Tool` when the question needs the web, and prints its answer with the intermediate steps above it.

## Call the tool directly

Run the tool card on its own to check results or to use it outside a solver:

```python theme={"theme":{"light":"github-light-high-contrast","dark":"dark-plus"}}
from octotools.tools.keenable_search.tool import Keenable_Search_Tool

tool = Keenable_Search_Tool()
results = tool.execute(
    query="protein structure prediction",
    num_results=5,
    site="arxiv.org",
    published_after="2025-01-01",
)
for r in results:
    print(r["title"], r["link"])
```

Each result has `title`, `link` and `snippet`, cut to 2,000 characters, plus `published_date` when Keenable knows it. If the call fails, the list holds one item with an `error` key instead.

## Inputs

| Input | Default | What it does |
| - | - | - |
| `query` | Required | The search query. |
| `num_results` | `10` | Number of results, from 1 to 50. |
| `site` | `None` | Domain to restrict results to, such as `"arxiv.org"`. |
| `published_after` | `None` | Only pages published on or after this date, as `YYYY-MM-DD`. |
| `published_before` | `None` | Only pages published on or before this date, as `YYYY-MM-DD`. |

> [!NOTE]
>
> If `KEENABLE_API_KEY` isn't set, the tool calls `/v1/search/public` on the shared public tier at [lower rate limits](https://docs.keenable.ai/rate-limits.md). Add `KEENABLE_API_KEY` to `.env` to use your organization's limits and remove the hourly cap. See [API keys](https://docs.keenable.ai/api-keys.md).

## Related pages

> [card] [PraisonAI](https://docs.keenable.ai/integrations/praisonai.md)
>
> Give PraisonAI agents web search with no API key through keenable\_search, a tool in praisonai-tools.

> [card] [NVIDIA NeMo Agent Toolkit](https://docs.keenable.ai/integrations/nemo-agent-toolkit.md)
>
> Give NVIDIA NeMo Agent Toolkit agents web search and page fetch with the Keenable function group (keenable\_\_search, keenable\_\_fetch).

> [card] [Scalekit](https://docs.keenable.ai/integrations/scalekit.md)
>
> Keenable MCP as a built-in connector in Scalekit AgentKit: each of your users signs in to Keenable once, and your agent calls search and fetch through Scalekit.

> [card] [Tool calling](https://docs.keenable.ai/tool-calling.md)
>
> Give an LLM web search and page fetch as tools. Pass the SDK's TOOLS to any OpenAI-compatible chat completions client and run each call with run\_tool\_call.


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.