Metadata-Version: 2.5
Name: mcp-amazon-connect
Version: 0.1.0
Summary: Read-only MCP server for Amazon Connect contact centers: live queue metrics, contacts, agent stats, queue reports, recordings.
License-Expression: MIT
License-File: LICENSE
Keywords: amazon-connect,aws,contact-center,mcp,model-context-protocol
Classifier: Environment :: Console
Classifier: Programming Language :: Python :: 3
Requires-Python: >=3.10
Requires-Dist: boto3>=1.34
Requires-Dist: mcp<2,>=1.2
Provides-Extra: test
Requires-Dist: pytest; extra == 'test'
Description-Content-Type: text/markdown

# mcp-amazon-connect

Read-only MCP server that lets Claude look at an Amazon Connect contact center: live queues, past contacts, agent and queue statistics, call recordings.

## Install

```bash
pip install mcp-amazon-connect      # or: uvx mcp-amazon-connect
```

Configuration (environment variables):

| Variable | Meaning |
|---|---|
| `CONNECT_INSTANCE_ID` | Amazon Connect instance id (required) |
| `AWS_REGION` | Region of the instance (required) |
| `AWS_PROFILE` or standard AWS credentials | Any identity with the read permissions below |
| `CONNECT_ALLOW_RECORDINGS=1` | Enables `get_contact_recording` (off by default: recordings are sensitive) |
| `CONNECT_DEMO=1` | Demo mode: fictional contact center, no AWS account needed |

No secret is stored by this package; it uses the standard AWS credential chain.

### Claude Code

```bash
claude mcp add amazon-connect -e CONNECT_INSTANCE_ID=<id> -e AWS_REGION=eu-west-3 -- uvx mcp-amazon-connect
# try it without AWS:
claude mcp add amazon-connect-demo -e CONNECT_DEMO=1 -- uvx mcp-amazon-connect
```

### Claude Desktop

```json
{
  "mcpServers": {
    "amazon-connect": {
      "command": "uvx",
      "args": ["mcp-amazon-connect"],
      "env": { "CONNECT_INSTANCE_ID": "<id>", "AWS_REGION": "eu-west-3", "AWS_PROFILE": "default" }
    }
  }
}
```

Then ask: "How many contacts are waiting in Billing right now?" or "Which queue has the worst abandonment rate this week?"

## Tools (all read-only)

| Tool | What it does |
|---|---|
| `get_realtime_metrics` | Agents online/available/on call, contacts waiting, longest wait, per voice queue |
| `list_contacts` | Past contacts filtered by queue, channel, date range, minimum duration |
| `get_contact_recording` | S3 location + 15-min presigned URL of a recording; optional download to a folder (e.g. to analyze it with [callscope](https://pypi.org/project/callscope-ai/)) |
| `get_agent_stats` | Contacts handled, handle/hold/after-call time, occupancy per agent |
| `get_queue_report` | Queued, handled, abandoned, abandonment %, average wait per queue |

## IAM permissions

`connect:ListQueues`, `connect:GetCurrentMetricData`, `connect:SearchContacts`, `connect:DescribeContact`, `connect:DescribeInstance`, `connect:ListUsers`, `connect:GetMetricDataV2`; for recordings also `connect:ListInstanceStorageConfigs` and `s3:ListBucket` / `s3:GetObject` on the recordings bucket (plus `kms:Decrypt` if encrypted).

## Development

```bash
pip install -e ".[test]" && pytest     # no network, no AWS account
```

MIT licence.
