Connect AI assistants to your Uptime and Telemetry data through the Model Context Protocol.
If this is your first time working with MCP servers, check out our MCP explained guide to understand the basics.
You'll need a Better Stack API token to authenticate the MCP server. Follow our API authentication guide to create one.
The Better Stack MCP server runs as a remote HTTP server. Add this configuration to your MCP client:
For clients supporting HTTP servers:
{
"mcpServers": {
"betterstack": {
"type": "http",
"url": "https://mcp.betterstack.com",
"headers": {
"Authorization": "Bearer $TOKEN"
}
}
}
}
Using Cursor? Click here to add the Better Stack MCP server
For clients without HTTP server support:
If your MCP client doesn't support remote HTTP servers, you can use the mcp-remote proxy instead:
{
"mcpServers": {
"betterstack": {
"command": "npx",
"args": [
"-y",
"mcp-remote",
"https://mcp.betterstack.com",
"--header",
"Authorization: Bearer ${BETTERSTACK_API_TOKEN}"
],
"env": {
"BETTERSTACK_API_TOKEN": "$TOKEN"
}
}
}
}
Using Claude? Check out Connect to Local MCP Servers for setup instructions.
Your AI assistant can now access Better Stack data. Try these:
You can execute ClickHouse queries directly against your Better Stack data. For optimal performance, include your cloud connection details via headers:
{
"mcpServers": {
"better-stack": {
"type": "http",
"url": "http://mcp.betterstack.com/",
"headers": {
"Authorization": "Bearer $TOKEN",
"X-Connection-User": "user",
"X-Connection-Password": "password",
"X-Connection-Host": "host"
}
}
}
}
Or if your client doesn't support remote MCP servers
{
"mcpServers": {
"better-stack": {
"command": "npx",
"args": [
"-y",
"mcp-remote",
"https://mcp.betterstack.com/",
"--header",
"Authorization: Bearer ${BETTER_STACK_PRODUCTION_AUTH_TOKEN}",
"--header",
"X-Connection-User: ${BETTER_STACK_CONNECTION_USER}",
"--header",
"X-Connection-Password: ${BETTER_STACK_CONNECTION_PASSWORD}",
"--header",
"X-Connection-Host: ${BETTER_STACK_CONNECTION_HOST}"
],
"env": {
"BETTER_STACK_PRODUCTION_AUTH_TOKEN": "$TOKEN",
"BETTER_STACK_CONNECTION_USER": "user",
"BETTER_STACK_CONNECTION_PASSWORD": "password",
"BETTER_STACK_CONNECTION_HOST": "host"
}
}
}
}
Your AI assistant can manage monitoring infrastructure and incidents through natural language. Ask questions like:
Find who's on-call and understand escalation policies.
Get on-call details: Shows who's currently on-call across all schedulesList on-call calendars: Provides information about on-call calendars and rotationsList on-call events: Lists upcoming shifts and schedule changesGet on-call event details: Fetches details for specific on-call eventsGet on-call rotation details: Explains how rotations are configuredExample queries:
Get incident escalation options: Shows available escalation targets for incidentsList escalation policies: Lists configured escalation rules and stepsGet escalation policy details: Provides detailed policy informationList severities: Shows incident severity levels and configurationsGet severity details: Explains specific severity settingsExample queries:
Create, manage, and collaborate on incidents from start to resolution.
Create incident: Reports new issues with context and metadataList incidents: Finds incidents by date, status, monitor, or other criteriaGet incident details: Shows full incident information including error messages and screenshotsGet incident timeline: Displays complete incident historyGet incident comments: Retrieves incident commentsCreate incident comment: Adds team collaboration commentsAcknowledge incident: Takes ownership of incidents to stop escalationsEscalate incident: Routes incidents to users, teams, or policiesResolve incident: Marks incidents as fixedExample queries:
Check service health through monitors and heartbeats.
List monitors: Shows all monitors with filtering optionsGet monitor details: Provides monitor configuration, status, and settingsGet monitor availability: Calculates SLA summaries and uptime percentagesGet monitor response times: Analyzes performance metrics and trendsExample queries:
List heartbeats: Shows all heartbeat monitors and their statusGet heartbeat details: Provides heartbeat configuration and recent activityGet heartbeat availability: Tracks uptime for scheduled tasksExample queries:
Communicate service status and maintenance to users.
List status pages: Shows all public status pagesGet status page details: Provides status page configuration and current statusGet status page resources: Lists monitors and heartbeats displayed on each pageCreate status page report: Creates incident reports or maintenance announcementsCreate status page report update: Adds updates to ongoing reportsList status page reports: Shows status reports for a specific pageList status page report updates: Lists updates for a specific reportGet status page report update details: Provides details for specific updatesExample queries:
Your AI assistant can analyze logs, query metrics, and manage observability infrastructure through natural language. Ask questions like:
Manage log sources and explore data structure.
List sources: Shows all log sources with status and configurationGet source details: Provides detailed source configuration and settingsCreate source: Creates new log sources with integration guidesGet source fields: Discovers available fields for querying logs and spansExample queries:
Query and explore logs and distributed traces.
Build explore query: Generates ClickHouse queries from natural language for exploring dataGet query instructions: Provides context to help create better ClickHouse queriesquery: Executes ClickHouse queries directly against telemetry dataExample queries:
Build dashboards and analyze performance trends.
Get metrics and cardinality: Shows available metrics with data points and series countGet metric details: Explains how to query and use specific metrics with examplesBuild metric query: Generates ClickHouse queries for dashboard visualizationsGet metric query instructions: Provides context for building metrics queriesExample queries:
Manage data regions, clusters, and secure connections.
List data regions: Shows available regions for storing dataList clusters: Lists storage clusters for direct data accessList teams: Shows teams with telemetry platform accessCreate cloud connection: Creates temporary credentials for direct ClickHouse accessExample queries:
Your AI assistant can manage error tracking applications, analyze exceptions, and query error data through natural language. Ask questions like:
Manage error tracking applications and their configuration.
List applications: Shows all error tracking applications with status and configurationGet application details: Provides detailed configuration, ingestion settings, and available data tablesCreate application: Creates new error tracking applications with platform-specific integration guidesExample queries:
Track application releases and their error patterns.
List releases: Shows all releases for an application with first and last seen timestampsExample queries:
View detailed error information and manage error states for triage and resolution tracking.
Get error details: Shows comprehensive error information including type, message, call site, first occurrence, and current state (unhandled, unresolved, ignored, resolved, or reoccurred)Update error state: Changes error state to mark errors as resolved, ignored, or unresolved with optional notification settingsExample queries:
Build and execute ClickHouse queries to analyze error patterns and individual exceptions.
Get errors query instructions: Provides comprehensive documentation for querying error data including the two-layer architecture (errors and exceptions), available columns, query patterns, and best practicesExample queries:
Please feel free to message us at hello@betterstack.com.
We'll get back to you as soon as we can, typically within a few hours. ๐
Thank you!
We use cookies to authenticate users, improve the product user experience, and for personalized ads. Learn more.