← Back to Plugins
Tools

Tinyfish Search

rolandkakonyi By rolandkakonyi 👁 30 views ▲ 0 votes

Unofficial community TinyFish Search provider plugin for OpenClaw

GitHub

Install

npm install
pnpm

Configuration Example

{
  "providers": {
    "tinyfish": {
      "apiKey": "tf_..."
    }
  }
}

README

# OpenClaw TinyFish Search

Unofficial community OpenClaw plugin for TinyFish Search.

This plugin registers a `tinyfish` provider for OpenClaw's `web_search` tool.
It is not affiliated with or endorsed by TinyFish.

## Install

Local package validation:

```bash
pnpm install
pnpm test
pnpm pack
openclaw plugins install ./rolandkakonyi-openclaw-tinyfish-search-0.1.3.tgz
openclaw gateway restart
```

After ClawHub publishing:

```bash
openclaw plugins install clawhub:@rolandkakonyi/openclaw-tinyfish-search
openclaw gateway restart
```

## Configure

Create a TinyFish account and API key:

1. Sign in at [agent.tinyfish.ai](https://agent.tinyfish.ai).
2. Open [API Keys](https://agent.tinyfish.ai/api-keys).
3. Create a key and keep it private.

TinyFish currently describes Search and Fetch as free for agent use; check the
[TinyFish pricing page](https://www.tinyfish.ai/pricing) for current limits.

Set the API key on the machine running the OpenClaw Gateway. The plugin can use
`TINYFISH_API_KEY` directly:

```bash
export TINYFISH_API_KEY=...
```

For managed service installs, put the variable in the service environment or
`~/.openclaw/.env` so the Gateway can still resolve it after restart.

Then select TinyFish as the OpenClaw web search provider:

```bash
openclaw config set tools.web.search.enabled true --strict-json
openclaw config set tools.web.search.provider tinyfish
openclaw gateway restart
```

### SecretRef options

The plugin reads `plugins.entries.tinyfish.config.webSearch.apiKey` as an
OpenClaw secret input. Plain strings work, but SecretRefs are preferred so API
keys stay outside `openclaw.json`. OpenClaw SecretRefs support `env`, `file`,
and `exec` providers; see [Secrets Management](https://docs.openclaw.ai/gateway/secrets)
for the full contract.

Recommended env SecretRef:

```bash
openclaw config set plugins.entries.tinyfish.config.webSearch.apiKey \
  --ref-provider default \
  --ref-source env \
  --ref-id TINYFISH_API_KEY
```

File SecretRef, using a JSON secrets file:

```json
{
  "providers": {
    "tinyfish": {
      "apiKey": "tf_..."
    }
  }
}
```

```bash
openclaw config set secrets.providers.tinyfishfile \
  --provider-source file \
  --provider-path ~/.openclaw/secrets.json \
  --provider-mode json

openclaw config set plugins.entries.tinyfish.config.webSearch.apiKey \
  --ref-provider tinyfishfile \
  --ref-source file \
  --ref-id /providers/tinyfish/apiKey
```

Exec SecretRef, using a protocol-speaking secret command:

```bash
openclaw config set secrets.providers.tinyfishvault \
  --provider-source exec \
  --provider-command /usr/local/bin/openclaw-secret-provider \
  --provider-json-only \
  --provider-trusted-dir /usr/local/bin

openclaw config set plugins.entries.tinyfish.config.webSearch.apiKey \
  --ref-provider tinyfishvault \
  --ref-source exec \
  --ref-id providers/tinyfish/apiKey
```

Equivalent JSON5 config for the env SecretRef setup:

```json5
{
  plugins: {
    entries: {
      tinyfish: {
        enabled: true,
        config: {
          webSearch: {
            apiKey: { source: "env", provider: "default", id: "TINYFISH_API_KEY" },
          },
        },
      },
    },
  },
  tools: {
    web: {
      search: {
        enabled: true,
        provider: "tinyfish",
      },
    },
  },
}
```

You can also run:

```bash
openclaw configure --section web
```

and choose TinyFish when prompted.

## Parameters

TinyFish supports:

- `query` - search query
- `count` - results to return, 1-10
- `country` / `location` - country code for geo-targeted results, such as `AT`, `DE`, or `US`
- `language` - language code, such as `en`, `de`, or `fr`
- `page` - TinyFish result page, starting from `0`, max `10`

Example:

```javascript
await web_search({
  query: "OpenClaw plugin SDK",
  country: "AT",
  language: "en",
  count: 5,
});
```

## Validation

```bash
pnpm typecheck
pnpm test
pnpm build
pnpm pack
openclaw plugins inspect tinyfish --runtime --json
```

For live validation, configure `TINYFISH_API_KEY`, select `provider: "tinyfish"`,
and invoke `web_search`. A successful gateway result includes
`provider: "tinyfish"` and structured results with titles, URLs, snippets, and
site names.

Example validated queries:

- `latest AI news`
- `weather Vienna Austria today`
tools

Comments

Sign in to leave a comment

Loading comments...