CallHub

CallHub

CallHub MCP is a Python-based tool that allows you to interact with the CallHub API through Claude. This tool provides a comprehensive set of functions for managing contacts, phonebooks, agents, teams, campaigns, and other CallHub resources.

Category
访问服务器

README

CallHub

A Claude-powered tool for managing CallHub resources via API

Overview

CallHub MCP is a Python-based tool that allows you to interact with the CallHub API through Claude. This tool provides a comprehensive set of functions for managing contacts, phonebooks, agents, teams, campaigns, and other CallHub resources.

Features

  • Account Management: Configure and manage multiple CallHub accounts
  • Contact Management: Create, retrieve, update, and delete contacts
  • Phonebook Management: Create and manage phonebooks and their contacts
  • Agent Management: Create, activate, and manage agents
  • Team Management: Create and manage teams and team memberships
  • Campaign Management: Manage call center, voice broadcast,P2P and SMS campaigns
  • DNC Management: Create and manage Do Not Call lists
  • Bulk Operations: Upload and process CSV files for bulk operations
  • Error Handling: Robust error handling with retries and rate limit awareness

Installation

Download Callhub & open in claude ( Requires Python 3.10 )

Prerequisites

  • Python 3.10+
  • An active CallHub account with API access
  • API credentials (username, API key, base URL)
  • Claude access with MCP capability

Setup

  1. Clone the repository:

    git clone https://github.com/callhub/callhub-mcp.git
    cd callhub-mcp
    
  2. Create a virtual environment:

    python -m venv .venv
    source .venv/bin/activate  # On Windows: .venv\Scripts\activate
    
  3. Install dependencies:

    pip install -r requirements.txt
    
  4. Configure credentials using the setup wizard:

    python setup.py
    

Claude Configuration

To use the CallHub MCP with Claude, you need to add it to Claude's configuration:

  1. Add the MCP to Claude's Configuration File:

    • Locate your Claude configuration file
    • Add the following configuration:
    "callhub-mcp": {
      "command": "/path/to/callhub-mcp/.venv/bin/python",
      "args": [
        "/path/to/callhub-mcp/src/server.py"
      ]
    }
    

    Make sure to replace:

    • /path/to/callhub-mcp-py with the actual path where you cloned the repository

    Note: Claude will automatically start and manage the MCP server process. You don't need to manually start or stop it.

  2. Using the MCP in Claude:

    • After adding the configuration, Claude will automatically load the CallHub MCP
    • When you start a conversation with Claude, the CallHub tools will be available
    • You can use the configureAccount tool to set up your CallHub credentials the first time
  3. First-time Setup:

    • Once connected, ask Claude to configure your CallHub account:
      I need to set up my CallHub account credentials. Can you help me?
      
    • Claude will guide you through using the configureAccount tool
  4. Starting to Use the MCP:

    • Ask Claude about available functions:
      What CallHub tools are available?
      
    • Claude will show you the available tools and how to use them

Configuration

CallHub MCP supports multiple accounts with descriptive names. Configuration is stored in the .env file:

# Default account
CALLHUB_DEFAULT_USERNAME=your_username
CALLHUB_DEFAULT_API_KEY=your_api_key
CALLHUB_DEFAULT_BASE_URL=https://api-na1.callhub.io

# Personal account
CALLHUB_PERSONAL_USERNAME=personal_username
CALLHUB_PERSONAL_API_KEY=personal_api_key
CALLHUB_PERSONAL_BASE_URL=https://api-na1.callhub.io

# Client account
CALLHUB_CLIENT_USERNAME=client_username
CALLHUB_CLIENT_API_KEY=client_api_key
CALLHUB_CLIENT_BASE_URL=https://api-na1.callhub.io

You can use any descriptive name for your accounts (letters, numbers, and underscores only). The account name is extracted from the environment variable name - for example, CALLHUB_PERSONAL_API_KEY creates an account named "personal" that you can reference in API calls.

To use a specific account for an API call, just mention the account name to Claude in natural language:

Claude, can you list the teams in my personal account?

If no account is specified, the "default" account is used.

Example Conversations with Claude

Here are some example prompts to get started with Claude and the CallHub MCP:

Configuring an Account

I need to set up my CallHub account. My username is user@example.com, my API key is abc123def456, and the base URL is https://api-na1.callhub.io. Can you configure this for me?

Creating and Managing Contacts

I'd like to create a new contact with phone number 1234567890, first name John, and last name Doe. After that, can you add this contact to a new phonebook called "VIP Customers"?

Agent Management

Can you show me all the teams in my CallHub account? I'd like to create a new agent in the "Sales" team.

Using Multiple Accounts

First, I need to check the teams in my client account. Then, create a similar team structure in my personal account.

Server Restart Guidelines

The CallHub MCP server must be restarted manually by the user after any code changes. If you're using Claude or another AI assistant to modify this code:

  1. The AI should NEVER assume a restart has occurred
  2. The AI should ALWAYS pause after suggesting code changes
  3. The AI should explicitly ask the user to restart the server
  4. The AI should wait for confirmation before proceeding with testing

This is critical for ensuring code changes take effect before testing.

Error Handling

The MCP implements robust error handling with automatic retries for transient errors and rate limiting. Error responses include detailed information about what went wrong and potential solutions.

Agent Activation Workflow

When new agents are created via the API, they exist in a 'pending' state and must verify their email before becoming active. These pending agents are:

  • NOT visible through the standard listAgents API (even with include_pending=true)
  • NOT manageable through direct API calls
  • Only accessible through the activation exports workflow

To activate pending agents:

  1. Use exportAgentActivationUrls or getAgentActivationExportUrl to obtain the export URL
  2. User downloads the activation CSV file from the CallHub UI
  3. Process the CSV using processAgentActivationCsv or related functions
  4. Activate agents using activateAgentsWithPassword or activateAgentsWithBatchPassword

IMPORTANT: NEVER create new test agents to check activation status - this workflow is specifically designed because pending agents are not accessible through direct API calls.

Security Considerations

  • Store your credentials securely
  • Do not share your .env file
  • Be cautious with browser automation features
  • Follow the principle of least privilege when creating API keys

Troubleshooting

  • If you encounter rate limits, the tool will automatically retry with backoff
  • For persistent errors, check your credentials and network connectivity
  • Log files are written to logs directory with automatic rotation

Contributing

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

License

MIT License

推荐服务器

Baidu Map

Baidu Map

百度地图核心API现已全面兼容MCP协议,是国内首家兼容MCP协议的地图服务商。

官方
精选
JavaScript
Playwright MCP Server

Playwright MCP Server

一个模型上下文协议服务器,它使大型语言模型能够通过结构化的可访问性快照与网页进行交互,而无需视觉模型或屏幕截图。

官方
精选
TypeScript
Magic Component Platform (MCP)

Magic Component Platform (MCP)

一个由人工智能驱动的工具,可以从自然语言描述生成现代化的用户界面组件,并与流行的集成开发环境(IDE)集成,从而简化用户界面开发流程。

官方
精选
本地
TypeScript
Audiense Insights MCP Server

Audiense Insights MCP Server

通过模型上下文协议启用与 Audiense Insights 账户的交互,从而促进营销洞察和受众数据的提取和分析,包括人口统计信息、行为和影响者互动。

官方
精选
本地
TypeScript
VeyraX

VeyraX

一个单一的 MCP 工具,连接你所有喜爱的工具:Gmail、日历以及其他 40 多个工具。

官方
精选
本地
graphlit-mcp-server

graphlit-mcp-server

模型上下文协议 (MCP) 服务器实现了 MCP 客户端与 Graphlit 服务之间的集成。 除了网络爬取之外,还可以将任何内容(从 Slack 到 Gmail 再到播客订阅源)导入到 Graphlit 项目中,然后从 MCP 客户端检索相关内容。

官方
精选
TypeScript
Kagi MCP Server

Kagi MCP Server

一个 MCP 服务器,集成了 Kagi 搜索功能和 Claude AI,使 Claude 能够在回答需要最新信息的问题时执行实时网络搜索。

官方
精选
Python
e2b-mcp-server

e2b-mcp-server

使用 MCP 通过 e2b 运行代码。

官方
精选
Neon MCP Server

Neon MCP Server

用于与 Neon 管理 API 和数据库交互的 MCP 服务器

官方
精选
Exa MCP Server

Exa MCP Server

模型上下文协议(MCP)服务器允许像 Claude 这样的 AI 助手使用 Exa AI 搜索 API 进行网络搜索。这种设置允许 AI 模型以安全和受控的方式获取实时的网络信息。

官方
精选