BIG FAT WARNING!
This was put together as an experiment with Claude Code and Sonnet 4.5. Here be large, possibly drunken, and definitely unweildy dragons!
USE AT YOUR OWN RISK, AND PREFERABLY NOT ON YOU PRODUCTION ACCOUNT!
A Model Context Protocol (MCP) service for interacting with M2A Media's cloud-based video orchestration and automation platform. This service provides comprehensive access to M2A Connect, Live, Capture, and VOD APIs.
DID I MENTION THAT THIS IS EXPERIMENTAL? IT REALLY IS YOU KNOW. PLEASE DON'T USE THIS IN PRODUCTION, OR IN AN ACCOUNT YOU CARE ABOUT
- M2A Connect: Manage video sources, subscribers, subscriptions, and schedules
- M2A Live: Control MediaLive channels, encoder configurations, and workflows
- M2A Capture: Create live-to-VOD captures and frame-accurate clips
- M2A VOD: Manage video on demand assets and playback URLs
- Go 1.24 or later
- M2A Media account with API credentials
- Associated AWS account
git clone https://github.com/andy-wilson/m2a-mcp.git
cd m2a-mcp
go build -o m2a-mcpThe service requires the following environment variables:
M2A_API_KEY(required): Your M2A Media API keyM2A_BASE_URL(optional): M2A API base URL (default:https://cloud.m2amedia.tv)M2A_AWS_ACCOUNT_ID(required): Your AWS account ID associated with M2A
To obtain API credentials:
- Contact M2A Media
- Provide your company details and AWS Entitlement information
- Receive initial login credentials
- Associate your AWS account with M2A
Add to your claude_desktop_config.json:
{
"mcpServers": {
"m2a-media": {
"command": "/path/to/m2a-mcp",
"env": {
"M2A_API_KEY": "your-api-key-here",
"M2A_AWS_ACCOUNT_ID": "your-aws-account-id"
}
}
}
}list_sources- List all video sourcesget_source- Get source detailscreate_source- Create a new video sourceupdate_source- Update source configurationdelete_source- Delete a source
list_subscribers- List all subscribersget_subscriber- Get subscriber detailscreate_subscriber- Create a new subscriber
list_subscriptions- List subscription packagesget_subscription- Get subscription detailscreate_subscription- Create subscription package
list_schedules- List scheduled eventsget_schedule- Get schedule detailscreate_schedule- Create a new schedule
list_channels- List MediaLive channelsget_channel- Get channel detailscreate_channel- Create a new channelstart_channel- Start a channelstop_channel- Stop a channeldelete_channel- Delete a channel
list_encoder_configs- List encoder configurationsget_encoder_config- Get encoder config details
list_workflows- List live streaming workflowsget_workflow- Get workflow detailscreate_workflow- Create a new workflow
list_captures- List capture jobsget_capture- Get capture job detailscreate_capture- Create live-to-VOD capturecancel_capture- Cancel capture joblist_capture_exports- List completed exportsget_capture_export- Get export detailscreate_clip- Create frame-accurate clip
list_vod_assets- List VOD assetsget_vod_asset- Get VOD asset detailsupdate_vod_metadata- Update asset metadatadelete_vod_asset- Delete VOD assetget_playback_url- Get streaming URL
Can you list all my video sources in M2A Connect?
Create a new MediaLive channel named "Sports Stream" with RTMP_PUSH input type
Create a capture job from channel "ch-123" starting at 2025-10-01T14:00:00Z
and ending at 2025-10-01T16:00:00Z, name it "Game Highlights"
Get the HLS playback URL for VOD asset "asset-456"
The service interacts with the following M2A Media API endpoints:
- Connect API:
/api/v2/connect/*and/api/v1/connect/capture/* - Live API:
/api/v3/live/*,/api/v1/live/* - VOD API:
/api/v1/vod/*
The service provides detailed error messages for:
- Authentication failures
- Missing required parameters
- API errors with HTTP status codes
- Network connectivity issues
m2a-mcp/
├── main.go # MCP server entry point
├── internal/
│ ├── config/
│ │ └── config.go # Configuration management
│ ├── client/
│ │ └── client.go # M2A API HTTP client
│ └── tools/
│ ├── connect.go # Connect API tools
│ ├── live.go # Live API tools
│ ├── capture.go # Capture API tools
│ └── vod.go # VOD API tools
├── go.mod
└── README.md
go build -o m2a-mcpgo test ./...For M2A Media API support please speak to your assigned project/service contact.
For issues with this MCP service, please open an issue on GitHub.