ringba-api-mcp
Ringba API MCP Server
Streamable HTTP MCP server that exposes Ringba analytics APIs as tools for AI-assisted workflows — starting with EHG insights reports, with more Ringba endpoints to follow.
Quick Start
npm install
cp .env.example .env # then edit .env with your credentials
npm run build
npm startThe server listens on http://0.0.0.0:3031/mcp-ringba by default. Point your
MCP client at that URL.
Client Setup Guides
All clients below assume the server is running. Start it first:
npm startFor production use, run it under a process manager (PM2, systemd, launchd,
or a simple nohup / background task).
Claude Code (CLI)
Add this to your Claude Code settings. The location depends on your scope:
Scope | Path |
User (all projects) |
|
Project (this repo only) |
|
{
"mcpServers": {
"ringba-api": {
"type": "http",
"url": "http://localhost:3031/mcp-ringba"
}
}
}Restart Claude Code or run /mcp to verify the server is connected.
The ringba_insights and ringba_list_available_columns tools will appear
in Claude's tool list automatically.
Claude Desktop
Claude Desktop supports HTTP MCP servers directly. Open the config file:
OS | Path |
macOS |
|
Windows |
|
Linux |
|
{
"mcpServers": {
"ringba-api": {
"type": "http",
"url": "http://localhost:3031/mcp-ringba"
}
}
}Restart Claude Desktop after saving. The Ringba tools will be listed under the tools panel (hammer icon) in the chat input.
Cursor
Create or edit .cursor/mcp.json in your project root:
{
"mcpServers": {
"ringba-api": {
"url": "http://localhost:3031/mcp-ringba"
}
}
}You can also place this at ~/.cursor/mcp.json for global access across all
projects. Restart Cursor after adding the configuration.
Cursor discovers MCP tools automatically; use Cmd/Ctrl+I to open Composer and the tools will be available.
GitHub Copilot (VS Code / VS Code Insiders)
GitHub Copilot supports MCP servers through the .vscode/mcp.json file
(VS Code 1.99+ with Copilot Chat). Create it in your project root:
{
"servers": {
"ringba-api": {
"type": "http",
"url": "http://localhost:3031/mcp-ringba"
}
}
}After saving, open the Copilot Chat panel. Copilot will auto-discover the MCP tools on the next prompt.
Codex (OpenAI)
Codex supports MCP via its agent configuration. Add a server entry in your
Codex config file (~/.codex/config.toml or project .codex.toml):
[mcp_servers.ringba-api]
url = "http://localhost:3031/mcp-ringba"If running Codex in a container or remote environment, replace localhost
with the host machine's reachable IP.
Windsurf
Create or edit .windsurf/mcp.json in your project:
{
"mcpServers": {
"ringba-api": {
"url": "http://localhost:3031/mcp-ringba"
}
}
}Use Cascade (Cmd+L) after restart — the tools will be available to the agent.
Continue (VS Code / JetBrains extension)
Add to ~/.continue/config.json under the mcpServers key:
{
"mcpServers": [
{
"name": "ringba-api",
"transport": "http",
"url": "http://localhost:3031/mcp-ringba"
}
]
}Continue will connect on the next chat session.
Generic / Other Clients
This server speaks standard JSON-RPC 2.0 over Streamable HTTP at the
configured MCP_PATH. Any MCP-compatible client that supports the
streamable-http transport can connect.
Transport detail | Value |
Protocol | JSON-RPC 2.0 |
Transport | Streamable HTTP (SSE) |
Endpoint |
|
Methods |
|
Auth | None on the MCP layer (Ringba API auth is server-side) |
Architecture
Client (Claude Code / IDE)
│
│ JSON-RPC 2.0 over Streamable HTTP
▼
ringba-api-mcp (TypeScript, @modelcontextprotocol/sdk)
│
│ POST Authorization: Token <api_key>
▼
Ringba API (api.ringba.com/v2/{accountId}/insights)Transport: Streamable HTTP (
/mcp-ringba), stateless, no session IDsAuth: Ringba API token in
Authorizationheader on upstream callsPort/Host: Configurable via
MCP_PORT/MCP_HOST(defaults:3031/0.0.0.0)CORS: Open (
*) for local tooling
Environment Variables
Variable | Required | Default | Description |
| yes | — | Ringba account ID (e.g. |
| yes | — | Ringba API token |
| no |
| HTTP listen port |
| no |
| HTTP bind address |
| no |
| MCP endpoint path |
The server also loads ../RingbaApi/.env and ../RingbaApi/.env.local if they
exist, so you can share credentials with the main RingbaApi project.
Tools
ringba_insights
Run an EHG insights report — group call data by a dimension and get aggregated metrics for a date range.
Required parameters:
Parameter | Type | Description |
| string | ISO 8601 start timestamp ( |
| string | ISO 8601 end timestamp ( |
| string | Dimension to group by (see available columns below) |
Optional parameters:
Parameter | Type | Default | Description |
| string | same as | Label in output |
| string[] | all 20 default metrics | Metrics to include |
| object[] |
| Filter conditions |
| string |
| Sort column |
|
|
| Sort direction |
| number |
| Row cap per group |
| string |
| IANA timezone for dates |
| boolean |
| Human-readable durations |
| boolean |
| Human-readable percentages |
| boolean |
| Include aggregate rows |
Filter syntax:
Each filter object wraps an anyConditionToMatch array of conditions:
{
"column": "targetName",
"value": "Elevated",
"isNegativeMatch": false,
"comparisonType": "CONTAINS"
}Supported comparison types: CONTAINS, EQUALS, STARTS_WITH, ENDS_WITH,
GREATER_THAN, LESS_THAN, and others provided by the Ringba API.
Example call via MCP:
{
"name": "ringba_insights",
"arguments": {
"reportStart": "2026-06-11T06:00:00Z",
"reportEnd": "2026-06-18T05:59:59Z",
"groupByColumn": "targetName",
"filters": [
{
"anyConditionToMatch": [
{
"column": "targetName",
"value": "Elevated",
"isNegativeMatch": false,
"comparisonType": "CONTAINS"
}
]
}
]
}
}ringba_list_available_columns
Reference tool — returns all known columns you can use in groupByColumn,
valueColumns, orderByColumn, and filters.
Optional parameter:
Parameter | Type | Description |
| string | Filter by |
Available group-by dimensions:
targetName, publisherName, campaignName, buyerName, inboundNumber,
callerId, callStatus, tag:InboundNumber:State, tag:InboundNumber:City,
tag:InboundNumber:Zip
Default value metrics (20 columns):
callCount, liveCallCount, completedCalls, endedCalls,
connectedCallCount, nonConnectedCallCount, duplicateCalls, blockedCalls,
incompleteCalls, payoutCount, convertedCalls, conversionAmount,
payoutAmount, profitGross, profitMarginGross, earningsPerCallGross,
totalCost, callLengthInSeconds, avgHandleTime, convertedPercent
Extending
This server is scoped to ringba-api-mcp so additional Ringba endpoints
(number management, campaign config, etc.) can be added as new tools under the
same server without breaking existing clients.
To add a new endpoint:
Add a tool definition in
ListToolsRequestSchemahandlerAdd a case in the
CallToolRequestSchemaswitchWrite a handler that calls the Ringba API via
fetch()Add any new column definitions to
AVAILABLE_COLUMNSif needed
Differences from db-mcp-server
Aspect |
|
|
Backend | Prisma / PostgreSQL | Ringba REST API |
Operations | CRUD (no delete) on DB models | API endpoints as tools |
Auth | Database credentials | Ringba API token |
Default port |
|
|
Default path |
|
|
Latest Blog Posts
- Who's Calling? MCP Hosts Are an Identity Blind Spot (And the Spec Knows It)By Om-Shree-0709 on .mcpAgent IdentityOAuth 2.1
- Your AI Chatbot Just Exposed Your CEO's Salary to an InternBy Om-Shree-0709 on .Agent IdentityMCP SecurityOAuth Delegation
- Why MCP Servers Need Execution Sandboxing (And Why Your Current Stack Isn't Enough)By Om-Shree-0709 on .Agentic AiPrompt InjectionWebAssembly
MCP directory API
We provide all the information about MCP servers via our MCP API.
curl -X GET 'https://glama.ai/api/mcp/v1/servers/wahajnintyeight/ringba-api-mcp'
If you have feedback or need assistance with the MCP directory API, please join our Discord server