MCP server that connects to Max AI agents
Project description
AnswerRocket Multi-Copilot MCP Server
An MCP (Model Context Protocol) server that provides access to AnswerRocket's analytics and insights platform. This server automatically creates separate MCP servers for each copilot in your AnswerRocket instance, allowing dedicated, focused interactions with individual copilots through LLM clients.
Features
- 🚀 Multi-Copilot Architecture: Automatically creates separate MCP servers for each copilot in your AnswerRocket instance
- 🎯 Dedicated Copilot Servers: Each copilot gets its own MCP server with copilot-specific tools and capabilities
- 🛠️ Skill Operations: List, inspect, and run specific skills within each copilot
- 💬 Interactive Q&A: Ask questions directly to specific AnswerRocket copilots and receive insights
Quick Install
Install the AnswerRocket MCP Server with a single command:
/bin/bash -c "$(curl -fsSL https://raw.githubusercontent.com/answerrocket/mcp-server/refs/heads/main/bootstrap.sh)"
The installer will:
- Check system requirements (git, curl)
- Install uv package manager (if not already installed)
- Install and configure Python 3.10.7 using uv
- Prompt you for your AnswerRocket URL
- Guide you to generate an API key from your AnswerRocket instance
- Set up a Python virtual environment with uv
- Install all dependencies (including AnswerRocket SDK from git repository)
- Discover all copilots in your AnswerRocket instance
- Create and install separate MCP servers for each copilot
Bootstrap vs Install Scripts
This project uses a two-stage installation process:
bootstrap.sh - The entry point script that:
- Can be downloaded and run with a single
curlcommand - Clones the full repository to a permanent, cross-platform application directory
- Ensures all required files (
lib/,scripts/, etc.) are available - Runs the main installer and passes through any command-line arguments
- Handles updates by fetching the latest changes from the repository
install.sh - The main installer script that:
- Performs the actual installation steps listed above
- Always works with the local repository (no remote cloning)
- Depends on modular library files in
lib/and utility scripts inscripts/ - Handles system setup, dependency installation, and MCP server configuration
- Used for development work when you have a local clone
Installation Locations:
- macOS:
~/Library/Application Support/AnswerRocket/mcp-server - Linux:
~/.local/share/answerrocket/mcp-server - Windows:
%APPDATA%/AnswerRocket/mcp-server
The bootstrap approach allows us to maintain clean, modular code while providing a convenient single-command installation experience and proper application directory structure.
Manual Installation
If you prefer to install manually:
Prerequisites
- Git
- curl (for downloading uv)
- An AnswerRocket instance with API access
Note: Python 3.10.7 will be automatically installed by the installer using uv.
Steps
-
Clone the repository:
git clone https://github.com/answerrocket/mcp-server-demo.git cd mcp-server-demo
-
Install uv package manager:
# macOS/Linux curl -LsSf https://astral.sh/uv/install.sh | sh # Windows powershell -ExecutionPolicy ByPass -c "irm https://astral.sh/uv/install.ps1 | iex"
-
Create and activate a virtual environment with uv:
uv venv --python 3.10.7 source .venv/bin/activate # On Windows: .venv\Scripts\activate
-
Install dependencies:
uv add "mcp[cli]" uv add "git+ssh://git@github.com/answerrocket/answerrocket-python-client.git@get-copilots-for-mcp"
-
Get your API credentials:
- Go to
{YOUR_AR_URL}/apps/chat/topics?panel=user-info - Click "Generate" under "Client API Key"
- Copy the generated API key
- Go to
-
Create copilot metadata script:
uv run python get_copilots.py "{YOUR_AR_URL}" "{YOUR_API_TOKEN}"
-
Install MCP servers for each copilot:
# This will create a separate server for each copilot uv run mcp install server.py -n "answerrocket-copilot-{COPILOT_ID}" -v AR_URL="{YOUR_AR_URL}" -v AR_TOKEN="{YOUR_API_TOKEN}" -v COPILOT_ID="{COPILOT_ID}" --with "git+ssh://git@github.com/answerrocket/answerrocket-python-client.git@get-copilots-for-mcp"
Available Tools (Per Copilot Server)
Each copilot gets its own dedicated MCP server with the following tools:
ask_question
Ask a question to this specific AnswerRocket copilot and receive insights with visualizations.
Parameters:
fully_contextualized_question(string): Your question with full context
get_copilot_info
Get detailed information about this copilot, including its available skills.
Parameters:
use_published_version(boolean, optional): Use published version (default: true)
get_skill_info
Get detailed information about a specific skill within this copilot.
Parameters:
skill_id(string): The ID of the skilluse_published_version(boolean, optional): Use published version (default: true)
run_skill
Execute a specific skill within this copilot with optional parameters.
Parameters:
skill_name(string): The name of the skill to runparameters(object, optional): Parameters to pass to the skill
How It Works
The installer automatically:
- Discovers all copilots in your AnswerRocket instance
- Creates a separate MCP server for each copilot
- Each server is named
answerrocket-copilot-{copilot-id} - Each server's tools are specific to that copilot (no need to specify copilot ID)
Benefits:
- ✅ Clean namespace separation per copilot
- ✅ No need to specify copilot IDs in tool calls
- ✅ Easy to manage individual copilot servers
- ✅ Better organization for teams with multiple copilots
Usage Examples
Basic Question Asking
// Using the copilot-specific MCP server (no copilot_id needed!)
await callTool('ask_question', {
fully_contextualized_question: 'What were our top performing products last quarter?'
});
Exploring Copilots
// Get information about this copilot
const copilotInfo = await callTool('get_copilot_info');
// List available skills
console.log('Available skills:', copilotInfo.skill_ids);
Running Skills
// Run a specific skill on this copilot
await callTool('run_skill', {
skill_name: 'Revenue Analysis',
parameters: {
time_period: 'last_quarter',
breakdown: 'by_product'
}
});
Configuration
Each copilot server requires three environment variables:
AR_URL: Your AnswerRocket instance URL (e.g.,https://your-instance.answerrocket.com)AR_TOKEN: Your AnswerRocket API tokenCOPILOT_ID: The specific copilot ID for this server
These are automatically configured during installation. The installer:
- Discovers all copilots using the
get_copilots.pyscript - Creates a separate server for each copilot with its unique
COPILOT_ID - Names each server
answerrocket-copilot-{copilot-id}
Troubleshooting
Common Issues
-
"ERROR: No matching distribution found for mcp[cli]"
- This is usually due to an old pip version
- The installer now automatically upgrades pip first
- If you still see this error, manually run:
python -m pip install --upgrade pip
-
"Cannot connect to AnswerRocket"
- Verify your
AR_URLis correct and accessible - Check that your
AR_TOKENis valid and not expired
- Verify your
-
"Python version not supported"
- The installer should automatically install Python 3.10.7 using uv
- If you see this error, try running:
uv python install 3.10.7 - Check your Python version with:
uv run python --version
-
"mcp command not found"
- Try running:
uv add "mcp[cli]" - Ensure your virtual environment is created with uv:
uv venv --python 3.10.7 - Check if the installation was successful:
uv run mcp --help
- Try running:
-
"No copilots found"
- Check that your API token has the correct permissions
- Verify you can access copilots through the AnswerRocket web interface
Getting Help
- Check the AnswerRocket documentation
- Visit the MCP specification for protocol details
- Open an issue on this repository for bug reports
Development
To contribute or modify the server:
-
Clone and install in development mode:
git clone https://github.com/answerrocket/mcp-server-demo.git cd mcp-server-demo
-
Run the installer for development (uses local repository):
./install.sh
-
Run the server locally:
uv run python src/answerrocket_mcp/server.py
-
Test with the MCP inspector:
uv run mcp inspect src/answerrocket_mcp/server.py
Note: When developing, always use ./install.sh directly. The bootstrap.sh script is only for end-users who want to install from the remote repository.
License
This project is licensed under the MIT License - see the LICENSE file for details.
Support
For support with AnswerRocket integration, please contact AnswerRocket support.
For MCP protocol questions, refer to the Model Context Protocol documentation.
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 maxai_mcp-0.1.4.tar.gz.
File metadata
- Download URL: maxai_mcp-0.1.4.tar.gz
- Upload date:
- Size: 10.3 kB
- Tags: Source
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.12.9
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
6ce397f4e67edf01e7931206368b076f3b0412f1409112012d6ba85d0eee6324
|
|
| MD5 |
6a3469c17e36d171950b6db17546f167
|
|
| BLAKE2b-256 |
fab501bb7a997adac082c6c89038488ebec2edb770a4a4453ada2a11c6bf5dfb
|
Provenance
The following attestation bundles were made for maxai_mcp-0.1.4.tar.gz:
Publisher:
build-and-publish.yml on answerrocket/mcp-server
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
maxai_mcp-0.1.4.tar.gz -
Subject digest:
6ce397f4e67edf01e7931206368b076f3b0412f1409112012d6ba85d0eee6324 - Sigstore transparency entry: 267925986
- Sigstore integration time:
-
Permalink:
answerrocket/mcp-server@049731a72a77d9608547cb5ccdced29911142241 -
Branch / Tag:
refs/tags/v0.1.4 - Owner: https://github.com/answerrocket
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
build-and-publish.yml@049731a72a77d9608547cb5ccdced29911142241 -
Trigger Event:
push
-
Statement type:
File details
Details for the file maxai_mcp-0.1.4-py3-none-any.whl.
File metadata
- Download URL: maxai_mcp-0.1.4-py3-none-any.whl
- Upload date:
- Size: 11.6 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.12.9
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
72aa52d50fe52f3a03fc22eefb8b7b22535db290bc103ed6a413e2ffbe3aff91
|
|
| MD5 |
11d550736589d9d512e7adc7432d6acc
|
|
| BLAKE2b-256 |
e60e652a548daef79c77d9c13a96576923081fe95adacad6d5b78feae304b293
|
Provenance
The following attestation bundles were made for maxai_mcp-0.1.4-py3-none-any.whl:
Publisher:
build-and-publish.yml on answerrocket/mcp-server
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
maxai_mcp-0.1.4-py3-none-any.whl -
Subject digest:
72aa52d50fe52f3a03fc22eefb8b7b22535db290bc103ed6a413e2ffbe3aff91 - Sigstore transparency entry: 267925993
- Sigstore integration time:
-
Permalink:
answerrocket/mcp-server@049731a72a77d9608547cb5ccdced29911142241 -
Branch / Tag:
refs/tags/v0.1.4 - Owner: https://github.com/answerrocket
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
build-and-publish.yml@049731a72a77d9608547cb5ccdced29911142241 -
Trigger Event:
push
-
Statement type: