Skip to main content

Public APIs MCP

Catalog of free public APIs with semantic search.

🎯 Features

  • search_public_apis: embedding-based search over API names and descriptions
  • get_public_api_details: retrieve full details by id
  • Resources: public-apis://apis, public-apis://api/{id}

🔧 Setup (uv)

Add to MCP clients (e.g., Claude Desktop) using uv.

Claude Desktop

macOS: ~/Library/Application Support/Claude/claude_desktop_config.json

{
  "mcpServers": {
    "public-apis": {
      "command": "uvx",
      "args": ["public-apis-mcp"]
    }
  }
}

🚀 Usage

  • Build embeddings index (optional; auto-build on first search):
uvx public-apis-mcp build-index
  • Run the MCP server over STDIO:
uvx public-apis-mcp run

📋 Tool Reference

search_public_apis

  • Purpose: Semantic search over the catalog
  • Parameters: query (str), limit (int, default 5)
  • Returns: list of { id, name, score, snippet }

Example call payload:

{ "name": "search_public_apis", "arguments": { "query": "weather", "limit": 5 } }

get_public_api_details

  • Purpose: Fetch full details by id
  • Parameters: id (str)
  • Returns: ApiItem

Example call payload:

{ "name": "get_public_api_details", "arguments": { "id": "a6b3a6b3-a6b3-a6b3-a6b3-a6b3a6b3a6b3" } }

🛠️ Development

Prerequisites:

  • Python 3.10+
  • uv (https://docs.astral.sh/uv/)

Setup:

uv sync --dev

Run tests:

FREE_APIS_MCP_TEST_MODE=1 uv run pytest -q

Lint and format:

uv run ruff check --fix
uv run ruff format

Type checking:

uv run mypy src/

MCP Client Dev Config

{
  "mcpServers": {
    "public-apis-dev": {
      "command": "uv",
      "args": [
        "--directory",
        "<abs_path>/public-apis-mcp",
        "run",
        "public-apis-mcp"
      ]
    }
  }
}

Build and Try

uv build
uv run --with dist/*.whl public-apis-mcp --help

📦 Data & Index

  • Data: src/public_apis_mcp/datastore/free_apis.json
  • Embedding index: src/public_apis_mcp/datastore/index.npz (auto-built)

Testing with MCP Inspector

For exploring and/or developing this server, use the MCP Inspector npm utility:

# Install MCP Inspector
npm install -g @modelcontextprotocol/inspector

# Run local development server with the inspector
npx @modelcontextprotocol/inspector uv run public-apis-mcp

# Run PyPI production server with the inspector
npx @modelcontextprotocol/inspector uvx public-apis-mcp

📝 License

MIT License - see LICENSE file for details.

🤝 Contributing

Contributions are welcome! Please feel free to submit a Pull Request.

Metadata

Release files for public-apis-mcp 0.1.0

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for public-apis-mcp 0.1.0
File Size Uploaded
public_apis_mcp-0.1.0.tar.gz 2.1 MB Details

Built distribution (wheel)

Table of built distributions (wheels) for public-apis-mcp 0.1.0
File Interpreter ABI Platform
public_apis_mcp-0.1.0-py3-none-any.whl Python 3 none any Details

Total release size: 4.3 MB

Release files / public_apis_mcp-0.1.0.tar.gz

Download URL public_apis_mcp-0.1.0.tar.gz
Size 2.1 MB
Tags Source
SHA-256 checksum
How to use checksums
7ac1c58d7fea86370d80c9cb5ca314e2d24036d01b1e69ecbe57e889f75a77bd
BLAKE2b-256 checksum
How to use checksums
e0ccaee2ce782201aaafdbb0029e2c3e15e41d65e6f7a3843e8a4be148c7de83
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/6.1.0 CPython/3.12.9

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Aug 17, 2025.

Transparency log

Release files / public_apis_mcp-0.1.0-py3-none-any.whl

Download URL public_apis_mcp-0.1.0-py3-none-any.whl
Size 2.1 MB
Tags Python 3
SHA-256 checksum
How to use checksums
73d8bdcc3084b6c272f6340957faeb8c2edb8c9ed1a3e689407d5ee3e9d024d1
BLAKE2b-256 checksum
How to use checksums
a46263003ae1db6f86ed444e247e0e723e97a10a1f72df9a7f34b588bde66783
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/6.1.0 CPython/3.12.9

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Aug 17, 2025.

Transparency log

Release history Release notifications | RSS feed

This release

0.1.0 This release

2 release files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page