Zyla API Hub MCP Server

by zyla-labs

Not rated
GitHub

About

Connect any AI agent to 7,500+ APIs on the Zyla API Hub using a single MCP tool (call_api)

Details

Author
zyla-labs
Categories
Developer Tools

Setup

Install Zyla API Hub MCP Server in your MCP client (Claude Desktop, Cursor, Windsurf, and others).

Repository: https://github.com/zyla-labs/mcp-server

Follow the installation instructions in the repository README, then restart your MCP client.

Connect any AI agent to 7,500+ APIs on the Zyla API Hub using a single MCP tool (call_api)

AnMCP (Model Context Protocol)server that gives any AI agent the ability to callany APIon theZyla API Hub— with a single tool.

Zyla API Hub•Browse APIs•Get an API Key

You connect this server to your AI agent (Claude, Cursor,OpenClaw, OpenAI Agents, etc.), and the agent automatically learns how to make HTTP requests to any Zyla API endpoint. No custom code needed.

Built with theofficialMCP Python SDK(v1.x).

- How It Works (Simple Explanation)
-
Quick Start (3 Steps)
-
Connecting to AI Agents

- Claude Desktop
-
Claude Code (CLI)
-
Cursor IDE
-
OpenClaw
-
OpenAI Agents SDK
-
LangChain
-
Custom Python Agent
-
SSE Network Agent
-
MCP Inspector (Testing)

You (human) AI Agent This MCP Server Zyla API Hub │ │ │ │ │ "Get crime data │ │ │ │ for zip 90210" │ │ │ │ ──────────────────► │ │ │ │ │ call_api(GET, url, │ │ │ │ headers, params) │ │ │ │ ─────────────────────► │ HTTP GET │ │ │ │ ─────────────────────► │ │ │ │ JSON response │ │ │ │ ◄───────────────────── │ │ │ {status: 200, │ │ │ │ response: {...}} │ │ │ │ ◄───────────────────── │ │ │ "Crime grade is │ │ │ │ B+ for 90210..." │ │ │ │ ◄────────────────── │ │ │

- You ask your AI agent a question (in natural language).
- The agent decides it needs to call an API and uses thecall_apitool from this server.
- This server makes the HTTP request to the Zyla API Hub and returns the data.
- The agent reads the data and answers you in natural language.

The agent figures outwhich API to call, what parameters to use, and how to interpret the results— all on its own. You just ask the question.

git clone https://github.com/zyla-labs/zyla-api-hub-mcp.git cd zyla-api-hub-mcp pip install -r requirements.txt

Pick your agent from the list below and follow the one-time setup. After that, just chat normally — the agent will use the Zyla APIs when needed.

Add to your config file (claude_desktop_config.json):

{ "mcpServers": { "zyla-api-hub": { "command": "python", "args": ["/absolute/path/to/mcp_server.py"], "env": {} } } }

Restart Claude Desktop. You'll see a hammer icon in the chat — that means the tool is available. Just ask:

"Use the Zyla API to get the crime rates for zip code 90210. My API key is Bearer sk-zyla..."

claude mcp add zyla-api-hub -- python /absolute/path/to/mcp_server.py

Then chat normally. Claude Code will invokecall_apiwhen it needs to call an API.

Add to.cursor/mcp.jsonin your project (or global Cursor settings):

{ "mcpServers": { "zyla-api-hub": { "command": "python", "args": ["/absolute/path/to/mcp_server.py"] } } }

In Cursor'sAgent mode, the AI will usecall_apiwhen you ask it to fetch data from an API.

OpenClawis a self-hosted AI agent gateway that supports multiple chat channels (WhatsApp, Telegram, Slack, Discord, iMessage, etc.) and can use external tools via MCP.

openclaw mcp add --transport stdio zyla-api-hub python /absolute/path/to/mcp_server.py

This registers the MCP server so the OpenClaw agent can discover and use thecall_apitool.

Option B — Add via config (~/.openclaw/openclaw.json):

If you prefer manual configuration, add the MCP server in your OpenClaw config:

{ // ... your existing openclaw.json config ... "mcpServers": { "zyla-api-hub": { "command": "python", "args": ["/absolute/path/to/mcp_server.py"], "transport": "stdio" } } }

Option C — Docker + SSE (network deployment):

If your OpenClaw gateway runs on a remote server or in Docker, use SSE transport:

# Start the MCP server with SSE transport docker run -p 8000:8000 -e MCP_TRANSPORT=sse ghcr.io/zyla-labs/mcp-server:latest # Then register it in OpenClaw pointing to the network URL openclaw mcp add --transport sse zyla-api-hub http://localhost:8000/sse

Once connected, chat with your OpenClaw agent through any channel (WhatsApp, Slack, Telegram, etc.) and it will automatically use the Zyla API when needed:

You (via WhatsApp): "What's the weather like in Buenos Aires?" OpenClaw agent → calls call_api( method="GET", url="https://www.zylalabs.com/api/.../weather", headers={"Authorization": "Bearer sk-zyla..."}, params={"city": "Buenos Aires"} ) OpenClaw agent: "It's currently 18C and partly cloudy in Buenos Aires."

For more on OpenClaw setup, see theGetting Started guide.

TheOpenAI Agents SDKsupports MCP servers as tool providers natively:

from agents import Agent from agents.mcp import MCPServerStdio async with MCPServerStdio( command="python", args=["/absolute/path/to/mcp_server.py"], ) as mcp_server: agent = Agent( name="Zyla Assistant", instructions="You can call any API on the Zyla API Hub using the call_api tool.", mcp_servers=[mcp_server], ) # The agent now has access to call_api

Use theLangChain MCP Adapterto wrap MCP tools as LangChain tools:

from langchain_mcp_adapters.client import MultiServerMCPClient async with MultiServerMCPClient({ "zyla-api-hub": { "command": "python", "args": ["/absolute/path/to/mcp_server.py"], "transport": "stdio", } }) as client: tools = client.get_tools() # Use tools with any LangChain agent

Build your own agent using the official MCP Python SDK:

import asyncio from mcp import ClientSession, StdioServerParameters from mcp.client.stdio import stdio_client async def main(): # 1. Point to the MCP server server_params = StdioServerParameters( command="python", args=["mcp_server.py"], ) # 2. Connect async with stdio_client(server_params) as (read, write): async with ClientSession(read, write) as session: await session.initialize() # 3. See available tools tools = await session.list_tools() print("Tools:", [t.name for t in tools.tools]) # Output: Tools: ['call_api'] # 4. Call an API result = await session.call_tool("call_api", arguments={ "method": "GET", "url": "https://www.zylalabs.com/api/824/crime+data+by+zipcode+api/583/get+crime+rates+by+zip", "headers": {"Authorization": "Bearer YOUR_ZYLA_API_KEY"}, "params": {"zip": "90210"}, }) # 5. Read the response print("Status:", result.structured_content["status_code"]) print("Data:", result.structured_content["response"]) asyncio.run(main())

For agents connecting over HTTP (web apps, microservices, remote deployments):

# Start the server with SSE transport first python mcp_server.py sse
import asyncio from mcp import ClientSession from mcp.client.sse import sse_client async def main(): async with sse_client("http://localhost:8000/sse") as (read, write): async with ClientSession(read, write) as session: await session.initialize() result = await session.call_tool("call_api", arguments={ "method": "GET", "url": "https://www.zylalabs.com/api/XXXX/your+api/YYY/endpoint", "headers": {"Authorization": "Bearer YOUR_KEY"}, }) print(result.structured_content) asyncio.run(main())

TheMCP Inspectorlets you test the server interactively in a browser:

# Terminal 1: start the server python mcp_server.py sse # Terminal 2: start the inspector npx -y @modelcontextprotocol/inspector

Open the Inspector UI and connect tohttp://localhost:8000/sse. You can browse the tool schema and invokecall_apimanually.

When an AI agent connects, it receives this tool schema automatically via the MCP protocol:

Call any API endpoint from the Zyla API Hub. Supports GET, POST, PUT, DELETE, PATCH, HEAD, OPTIONS. Always include an Authorization header with your Zyla API key.

{ "method": "GET", "url": "https://www.zylalabs.com/api/824/crime+data+by+zipcode+api/583/get+crime+rates+by+zip", "headers": { "Authorization": "Bearer YOUR_ZYLA_API_KEY" }, "params": { "zip": "90210" } }
{ "method": "POST", "url": "https://www.zylalabs.com/api/XXXX/some+api/YYY/endpoint", "headers": { "Authorization": "Bearer YOUR_ZYLA_API_KEY", "Content-Type": "application/json" }, "data": { "input_text": "Hello, world!", "language": "en" } }
{ "method": "POST", "url": "https://www.zylalabs.com/api/XXXX/some+api/YYY/search", "headers": { "Authorization": "Bearer YOUR_ZYLA_API_KEY" }, "params": { "page": "1", "limit": "10" }, "data": { "query": "machine learning" } }
{ "status_code": 200, "response": { "data": "...", "count": 42 }, "error": null }
{ "status_code": 0, "response": "", "error": "Request timed out after 30 seconds" }
docker run -p 8000:8000 -e MCP_TRANSPORT=sse zyla-mcp-server
docker pull ghcr.io/zyla-labs/mcp-server:latest docker run -p 8000:8000 -e MCP_TRANSPORT=sse ghcr.io/zyla-labs/mcp-server:latest

The CI pipeline auto-publishes to GitHub Container Registry on every push tomaster.

zyla-api-hub-mcp/ ├── mcp_server.py # MCP server (single file, all logic) ├── pyproject.toml # Python packaging (PEP 621) ├── requirements.txt # Pinned dependencies ├── Dockerfile # Docker image ├── .dockerignore ├── .github/ │ └── workflows/ │ └── publish.yml # CI/CD → GHCR └── README.md

Dependencies:mcp[cli]>=1.26.0,httpx>=0.27.0— that's it.

- OfficialmcpSDK (mcp.server.fastmcp.FastMCP), not the third-partyfastmcppackage
- httpxinstead ofrequests(async-ready, aligned with the MCP ecosystem)
- PydanticApiResponsemodel for structured output (LLMs get a typed JSON schema)
- No mutable default arguments (Noneinstead of{})
- Granular error handling (timeout, request error, unexpected error — each with a clear message)
- Query params sent on all HTTP methods (not just GET)
- Transport selectable via CLI argument (stdioorsse)

This is a web browser that enables your coding agent, such as Claude Code, to visit websites on your behalf and assist you in identifying bugs or creating UI test cases.

Create crafted UI components inspired by the best 21st.dev design engineers.

Bring agent evaluations, observability, and synthetic test set generation directly into your IDE for free with Galileo's new MCP server

An MCP server to help AI assistants to answer questions and generate AccelByte Extend SDK code more effectively .

MCP server for AI Diagram Maker — generate beautiful software engineering diagrams directly inside Cursor, Claude Desktop, Claude Code, or any MCP-compatible AI agent

ALAPI MCP Tools,Call hundreds of API interfaces via MCP

AI-powered SVG animation generator that transforms static files into animated SVG components using the Allyson platform

MCP server that gives AI assistants on-demand access to 1,500+ amCharts docs, ~300 code examples, and 1000+ class API references.

APIMatic MCP Server is used to validate OpenAPI specifications using APIMatic. The server processes OpenAPI files and returns validation summaries by leveraging APIMatic’s API.

One shared context layer for AI agents and humans — live API specs, DB schemas, and versioned contracts across repos so every agent and teammate works from the same source of truth.

Build and deploy full-stack Next.js apps with 98 tools for React, AWS, and MongoDB

No reviews yet — be the first

Sign in to leave a review

Use Google, GitHub, or an email account so ratings stay tied to real people.

Email sign in

No reviews posted yet.