music-mcp-server
v0.0.2
Published
Trunks Music MCP Server - Professional music analytics tools for AI agents
Maintainers
Readme
Trunks MCP Server
MCP (Model Context Protocol) server for Trunks Music - professional music analytics. Exposes Trunks data to AI agents (Claude, ChatGPT, Cursor, etc.).
Trunks prédit l'avenir de la musique.
Tools
| Tool | Description |
|------|-------------|
| search_artists | Search artists by name. Returns matching artists from Trunks database. |
| get_artist_score | Get Trunks Score and Scouting Score for an artist (by ID, name, or slug). |
| get_growth_metrics | Get growth metrics: growthRate7d, growthRate30d, trendingScore, totalFollowers. |
| compare_artists | Compare 2-10 artists side-by-side (scores, followers, growth). |
| get_trending | Get trending artists with optional genre/region filters. |
| get_charts | Get top music charts by country (fr, us, gb, etc.). |
Setup
Option A — npx (recommended for production)
No clone or build required. Use once music-mcp-server is published to npm:
# Add to ~/.cursor/mcp.json or Cursor Settings > MCP{
"mcpServers": {
"trunks": {
"command": "npx",
"args": ["-y", "music-mcp-server"],
"env": {
"TRUNKS_API_URL": "https://trunks.app"
}
}
}
}For local development, use http://localhost:3000 for TRUNKS_API_URL.
Option B — Local build (monorepo)
- Install dependencies:
cd mcp-server
npm install
npm run build- Configure environment (optional, defaults to
http://localhost:3000):
Copy .env.example to .env and set:
TRUNKS_API_URL=http://localhost:3000For production, use https://trunks.app.
- Configure Cursor:
Add to your Cursor MCP settings (~/.cursor/mcp.json or Cursor Settings > MCP):
{
"mcpServers": {
"trunks": {
"command": "node",
"args": ["/absolute/path/to/trunks-dev/mcp-server/dist/index.js"],
"env": {
"TRUNKS_API_URL": "https://trunks.app"
}
}
}
}Replace the path with your actual mcp-server/dist/index.js location.
Trunks API
The MCP server calls the Trunks SaaS API. For production, the API is at https://trunks.app. For local dev, run the saas app:
cd saas
npm run devUsage in Cursor
Once configured, you can ask Cursor (with Trunks MCP enabled):
- "Search for artist Billie Eilish in Trunks"
- "What's the Trunks Score for Drake?"
- "Compare growth metrics of Artist A and Artist B"
- "Show me trending artists in rap genre"
Development
npm run build # Compile TypeScript
npm run start # Run compiled server (for testing)Note: The server uses stdio transport. It expects to be spawned by an MCP client (Cursor, Claude Desktop, etc.) and will block waiting for JSON-RPC messages on stdin. Do not run it directly for interactive use.
Publishing to npm
cd mcp-server
npm run build
npm version patch
npm publishBump version in package.json per semver when tools or config change.
API Requirements
The MCP server requires these Trunks API routes:
GET /api/search?q=...&stream=false- Artist searchGET /api/mcp/artist-score?artistId=...|artistName=...|artistSlug=...GET /api/mcp/growth-metrics?artistId=...|artistName=...|artistSlug=...POST /api/mcp/compare-artists- Body:{ artistIds }or{ artistNames }GET /api/scouting?limit=...&genres=...®ions=...
