@mcp-packages/newrelic-server
v0.1.0
Published
MCP server for New Relic — NRQL queries, entity search, and APM observability tools via the Model Context Protocol
Maintainers
Readme
@mcp-packages/newrelic-server
MCP server for New Relic — execute NRQL queries, search entities, and retrieve APM observability data via the Model Context Protocol.
Tools
| Tool | Description |
|---|---|
| run_nrql | Execute arbitrary NRQL queries with formatted results |
| search_entities | Search entities by name, type, or domain |
| get_entity | Get entity details by GUID (tags, alert severity, reporting status) |
| get_deployments | Recent deployment markers for an APM application |
| get_error_traces | Recent error traces for an APM application |
| get_golden_signals | Key metrics: throughput, error rate, avg/P95 response time |
| get_alert_violations | Recent alert incidents for an APM application (filterable by priority) |
Setup
1. Create a New Relic User API Key
- Go to https://one.newrelic.com/api-keys
- Click Create a key, select User as the key type
- Select your account, name the key (e.g., "MCP Server"), and create it
- Copy the key (starts with
NRAK-)
2. Find Your Account ID
Your account ID is visible in the URL when logged into New Relic (e.g., https://one.newrelic.com/nr1-core?account=1234567), or in Administration > Access Management > Accounts.
3. Configure Your IDE
Cursor (.cursor/mcp.json)
{
"mcpServers": {
"newrelic": {
"command": "npx",
"args": ["-y", "@mcp-packages/newrelic-server"],
"env": {
"NEW_RELIC_API_KEY": "${NEW_RELIC_API_KEY}",
"NEW_RELIC_ACCOUNT_ID": "${NEW_RELIC_ACCOUNT_ID}"
}
}
}
}Claude Code
claude mcp add newrelic -- npx -y @mcp-packages/newrelic-serverSet environment variables in your shell profile:
export NEW_RELIC_API_KEY="NRAK-..."
export NEW_RELIC_ACCOUNT_ID="1234567"Environment Variables
| Variable | Required | Description |
|---|---|---|
| NEW_RELIC_API_KEY | Yes | New Relic User API key for NerdGraph authentication |
| NEW_RELIC_ACCOUNT_ID | Yes | New Relic account ID (scopes NRQL queries) |
Development
# From the monorepo root
npm install
npm run build -w @mcp-packages/newrelic-server
npm run dev -w @mcp-packages/newrelic-server # watch mode