Content
# yourcx-mcp
MCP server that connects Claude Desktop to the [YourCX](https://yourcx.io) customer experience platform.
Ask Claude to browse your surveys, analyze respondent answers, filter results by segments, and update segment values — all in natural language.
---
## What it does
- Browse clients, surveys, and survey questions
- Fetch paginated survey results with powerful segment-based filters
- Inspect individual respondent answers
- Update segment values on results (batch or single)
---
## Requirements
- Node.js v18 or newer
- [Claude Desktop](https://claude.ai/download)
- A YourCX API key (from your YourCX panel)
---
## Installation
```bash
git clone https://github.com/YOUR_USERNAME/yourcx-mcp.git
cd yourcx-mcp
npm install
```
---
## Configuration
Add the server to your Claude Desktop config file.
**Windows:** `%APPDATA%\Claude\claude_desktop_config.json`
**macOS:** `~/Library/Application Support/Claude/claude_desktop_config.json`
```json
{
"mcpServers": {
"yourcx": {
"command": "node",
"args": ["C:/path/to/yourcx-mcp/index.js"],
"env": {
"YOURCX_API_KEY": "your_api_key_here",
"YOURCX_CLIENT_ID": "1234",
"YOURCX_BASE_URL": "https://panel.yourcx.io/new/api/v1"
}
}
}
}
```
Restart Claude Desktop after saving.
---
## Environment variables
| Variable | Required | Description |
|---|---|---|
| `YOURCX_API_KEY` | Yes | Your YourCX API key |
| `YOURCX_CLIENT_ID` | No | Default client ID — omit it from every tool call if set |
| `YOURCX_BASE_URL` | No | API base URL (default: `https://panel.yourcx.io/new/api/v1`) |
---
## Available tools
| Tool | Description |
|---|---|
| `list_clients` | List all clients accessible with the API key |
| `get_client` | Get details for a specific client |
| `list_surveys` | List all surveys for a client |
| `get_survey` | Get full details of a specific survey |
| `list_questions` | List all questions and answer options for a survey |
| `get_question` | Get details of a single survey question |
| `list_segments` | List all segments available for a survey |
| `get_results` | Fetch paginated survey results with optional filters |
| `get_result` | Get full details of a single survey result |
| `update_results` | Batch update segment values on multiple results |
| `update_result` | Update segment values on a single result |
---
## Example prompts
- "List all my YourCX surveys"
- "Show me the 20 most recent results for survey 5432"
- "What questions are in survey 5432?"
- "Get results for survey 5432 where time_day is between 2024-01-01 and 2024-06-30"
- "What segments are available for survey 5432?"
- "Update result 1234567 in survey 5432 — set client segment 'priority' to 'high'"
---
## License
MIT