A restricted TinyFish MCP gateway for free search and fetch capabilities.
Project description
🐟 microfish
Free-only MCP gateway for TinyFish — exposes just Search & Fetch, nothing else.
Why microfish?
| Official MCP | microfish | |
|---|---|---|
| Search & Fetch (free) | ✅ | ✅ |
| Agent / Browser / Batch (paid) | ✅ exposed | ❌ stripped |
| Agent accidentally calls paid tools | ⚠️ possible | 🚫 impossible |
| API key pool | ❌ | ✅ built-in |
| Rate limit | single key | pooled, higher throughput |
- 🔒 Free-only by design — Only
search,fetch_content,get_search_usage, andlist_fetch_usageare registered. Paid APIs are never exposed, so agents can't see or invoke them — no accidental charges, no wasted tokens. - ⚡ Built-in key pool — Supply multiple TinyFish API keys and microfish round-robins across them. If one key fails, it automatically falls back to the next (up to 3 retries), effectively bypassing single-key rate limits.
Quick Start
Get a free API key → https://agent.tinyfish.ai/api-keys
stdio (recommended)
Claude Code:
TINYFISH_KEYS=<KEY> \
claude mcp add microfish --env TINYFISH_KEYS -- uvx microfish
Cursor / other MCP clients:
{
"mcpServers": {
"microfish": {
"command": "uvx",
"args": ["microfish"],
"env": { "TINYFISH_KEYS": "<KEY>" }
}
}
}
HTTP
MICROFISH_TRANSPORT=http TINYFISH_KEYS=<KEY> uvx microfish
# endpoint: http://localhost:8000/mcp
Tools
✅ Available
| Tool | Description |
|---|---|
search |
Web search (free) |
fetch_content |
Fetch & extract page content (free) |
get_search_usage |
Search usage stats |
list_fetch_usage |
Fetch usage stats |
🚫 Blocked
Agent automation · Batch automation · Browser sessions · Run lifecycle
Authentication
1. Client-owned key — Leave TINYFISH_KEYS unset. Each client passes its own key via Authorization: Bearer.
2. Server-managed single key — Set TINYFISH_KEYS=<key>. Optionally set MCP_AUTH_TOKEN to protect the endpoint.
3. Server-managed key pool ⚡ — Set TINYFISH_KEYS=k1,k2,k3. Requests are distributed in order; failures automatically fall back to the next key (up to 3 retries).
Configuration
| Variable | Default | Description |
|---|---|---|
TINYFISH_KEYS |
— | Comma-separated API keys; enables server-managed mode |
MCP_AUTH_TOKEN |
— | Bearer token required from clients (server-managed mode) |
MICROFISH_TRANSPORT |
stdio |
stdio or http |
MICROFISH_HOST |
0.0.0.0 |
Bind host (HTTP mode) |
MICROFISH_PORT |
8000 |
Bind port (HTTP mode) |
MICROFISH_MCP_PATH |
/mcp |
MCP endpoint path (HTTP mode) |
Client Examples
-
Claude Code
HTTP:
# Without auth claude mcp add --transport http microfish http://localhost:8000/mcp # With auth claude mcp add --transport http microfish http://localhost:8000/mcp \ --header "Authorization: Bearer <YOUR_MCP_OR_TINYFISH_TOKEN>"
stdio:
TINYFISH_KEYS=<KEY> \ claude mcp add microfish --env TINYFISH_KEYS -- uvx microfish
-
Codex
HTTP:
[mcp_servers.microfish] url = "http://localhost:8000/mcp" bearer_token_env_var = "MICROFISH_MCP_BEARER"
Set
MICROFISH_MCP_BEARERto your TinyFish API key (client-owned) or MCP auth token (server-managed).stdio:
[mcp_servers.microfish] command = "uvx" args = ["microfish"] env = { TINYFISH_KEYS = "<KEY>" }
-
Cursor
HTTP:
{ "mcpServers": { "microfish": { "url": "http://localhost:8000/mcp", "headers": { "Authorization": "Bearer ${env:MICROFISH_MCP_BEARER}" } } } }
Drop the
headersblock if no auth is required.stdio:
{ "mcpServers": { "microfish": { "command": "uvx", "args": ["microfish"], "env": { "TINYFISH_KEYS": "<KEY>" } } } }
Deployment
Local
uvx microfish # run directly, no clone needed
Docker
docker compose up -d # pulls ghcr.io/vvtommy/microfish:latest
docker-compose.yml— pulls the published imagedocker-compose_build.yml— builds from local Dockerfile
Contributing
PRs and issues are welcome. Please open an issue first for major changes.
Releasing
Push a vX.Y.Z tag to trigger: PyPI publish + GHCR image publish.
License
MIT
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file microfish-1.1.1b2.tar.gz.
File metadata
- Download URL: microfish-1.1.1b2.tar.gz
- Upload date:
- Size: 340.0 kB
- Tags: Source
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.12
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
377c47c4061b54a6a5faed64b6acadd05e024295c732d864490e03b7910e2937
|
|
| MD5 |
db6c259a981a0cc2809296bcdd7381ac
|
|
| BLAKE2b-256 |
f549050bb95da0b5bcbac85dd874ac3116fdd2a4dd4cf5c2151192a0a57aad6a
|
Provenance
The following attestation bundles were made for microfish-1.1.1b2.tar.gz:
Publisher:
pypi.yml on vvtommy/microfish
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
microfish-1.1.1b2.tar.gz -
Subject digest:
377c47c4061b54a6a5faed64b6acadd05e024295c732d864490e03b7910e2937 - Sigstore transparency entry: 1484272783
- Sigstore integration time:
-
Permalink:
vvtommy/microfish@fafe30a7b467f2452afe63751c743b72ba19fb8a -
Branch / Tag:
refs/tags/v1.1.1-beta.2 - Owner: https://github.com/vvtommy
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
pypi.yml@fafe30a7b467f2452afe63751c743b72ba19fb8a -
Trigger Event:
push
-
Statement type:
File details
Details for the file microfish-1.1.1b2-py3-none-any.whl.
File metadata
- Download URL: microfish-1.1.1b2-py3-none-any.whl
- Upload date:
- Size: 13.2 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.12
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
4a68aeab46adff0f905e349178a486d00a06b32027154cc578fd4e638b301e3f
|
|
| MD5 |
689994fb02561311c819d92cd616d566
|
|
| BLAKE2b-256 |
8dd892c0b10b3819fb1d546be4ba946130ce47cc3725f0048e786f43e9a7f44c
|
Provenance
The following attestation bundles were made for microfish-1.1.1b2-py3-none-any.whl:
Publisher:
pypi.yml on vvtommy/microfish
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
microfish-1.1.1b2-py3-none-any.whl -
Subject digest:
4a68aeab46adff0f905e349178a486d00a06b32027154cc578fd4e638b301e3f - Sigstore transparency entry: 1484272889
- Sigstore integration time:
-
Permalink:
vvtommy/microfish@fafe30a7b467f2452afe63751c743b72ba19fb8a -
Branch / Tag:
refs/tags/v1.1.1-beta.2 - Owner: https://github.com/vvtommy
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
pypi.yml@fafe30a7b467f2452afe63751c743b72ba19fb8a -
Trigger Event:
push
-
Statement type: