# Grafana k6 Cloud MCP for AI Agents AI Agent Connect

> Grafana k6 Cloud MCP lets you manage your load testing lifecycle through your AI agent. Run tests, check performance metrics, and audit SLO thresholds without leaving your chat interface.

## Overview
- **Category:** ship-it
- **Price:** Free
- **Endpoint:** https://edge.vinkius.com/vk_preview_puXmxTGW8nXFX6Ap8jEn9n2TkxtxCWKVzu5Is9v7/ai-agent-connect
- **Tags:** load-testing, performance-engineering, stress-testing, test-automation, cloud-infrastructure, metrics

## Description

This Connector connects your Grafana Cloud k6 account to your AI agent so you can handle performance engineering tasks with plain English. Instead of jumping between the k6 dashboard and your terminal, you can just tell your agent to start a new test run or check if your app is hitting its latency targets. It handles the heavy lifting of navigating complex organizations and projects while pulling in the specific data you need to see if a deployment broke something. It's a big part of how Vinkius helps teams move faster by making these technical actions accessible through a conversational interface. You can get a pulse on your system's behavior under load, find out why a test failed, or verify that your performance requirements are met, all by asking your agent to do the digging for you. You don't have to worry about the underlying technical calls or the complexity of the cloud infrastructure. You just get the answers you need to keep your production environment stable and your performance goals on track. It makes it easy to stay updated on test results without having to manually refresh pages or hunt through nested menus. This means you spend less time on data gathering and more time on actual performance optimization. It's about getting the right data at the right time without the friction of traditional UI navigation.

## Tools

### list_tests
Lists all load tests on Grafana Cloud k6 with their names, IDs, and last run statuses. This helps you see your entire test suite in one place without clicking through menus.

### get_test
Fetches the full configuration and script details for a specific k6 test. You can use this to verify the exact settings before a run starts.

### list_runs
Shows the status, VU counts, and durations for all runs of a specific test. It gives you a quick history of how your tests have performed over time.

### get_run
Retrieves the complete details for a single k6 test run. This is useful for deep-diving into the specifics of a single execution.

### start_test_run
Triggers a new k6 Cloud test run and returns the new active run ID. You can start your performance tests immediately through your agent.

### stop_test_run
Instantly stops a running k6 Cloud test to manage your cloud resources. This is critical for ending tests that are no longer needed.

### list_organizations
Lists all organizations on k6 Cloud including IDs and member counts. Use this to navigate between different company accounts easily.

### list_projects
Lists all projects within a specific k6 Cloud organization. This helps you find the right testing environment in a large enterprise setup.

### get_run_metrics
Pulls performance data like http_req_duration and error rates for a run. It lets you see the actual impact on your application's speed and stability.

### get_run_thresholds
Fetches the evaluation results for specific performance thresholds on a run. Use this to quickly see if your app passed or failed its performance goals.

## Prompt Examples

**Prompt:** 
```
List all my load tests in k6 Cloud
```

**Response:** 
```
I've found the following load tests in your k6 Cloud account:

| Test Name | ID | Last Run Status |
| :--- | :--- | :--- |
| API Stress Test | 123 | FINISHED |
| Checkout Flow | 456 | RUNNING |
| Inventory Spike | 789 | QUEUED |
| Frontend Smoke | 012 | ABORTED |

Would you like to see the details for any of these?
```

**Prompt:** 
```
Show me the performance metrics for the last run of the 'API Stress Test'
```

**Response:** 
```
Retrieving metrics for the last run of **API Stress Test** (ID: 123)...

**Performance Summary:**
*   **Average Response Time:** 142ms
*   **P95 Latency:** 285ms
*   **Failed Requests:** 0.2%
*   **Max Virtual Users (VUs):** 500

All metrics are within your defined acceptable ranges. Would you like me to check the specific threshold evaluations?
```

**Prompt:** 
```
Start a new test run for 'Checkout Flow' (ID: 456)
```

**Response:** 
```
Triggering a new run for **Checkout Flow** (ID: 456) now...

Done. The new run ID is `run-13579`. It is currently in the **QUEUED** state. I'll monitor the status and let you know as soon as the first VUs start injecting traffic.
```

## Capabilities

### Start load tests
Trigger new k6 Cloud test runs on demand.

### Stop active tests
Abort running executions to save cloud resources.

### Pull performance metrics
Get latency, error rates, and throughput data instantly.

### Check SLO thresholds
Verify if your application meets specific performance goals.

### Browse test history
List all cloud-hosted load tests and their recent statuses.

### Navigate environments
Switch between different organizations and projects securely.

## Use Cases

### Post-deployment check
An SRE asks the agent to run a test and check if P95 latency is under 200ms.

### Capacity planning
A performance engineer asks to list all tests to find the one with the highest VU count.

### Incident response
A developer asks to stop a runaway test run that is consuming too many resources.

### Reliability reporting
A QA lead asks the agent to pull threshold results for the last three runs to include in a report.

## Benefits

- Stop switching tabs by using list_tests to see your entire test suite in one place.
- Save cloud costs by using stop_test_run to kill long-running tests the moment they finish their job.
- Verify SLO compliance instantly with get_run_thresholds to see if your app is meeting targets.
- Get quick answers on system health by using get_run_metrics to see latency and throughput.
- Easily manage multi-tenant environments by navigating organizations with list_organizations and list_projects.

## How It Works

The bottom line is you get a conversational interface for your entire k6 Cloud performance testing workflow.

1. Subscribe to the Connector on Vinkius.
2. Provide your k6 Cloud API Token.
3. Ask your AI client to start a test or fetch metrics.

## Frequently Asked Questions

**Can I use Grafana k6 Cloud MCP to see if my app is meeting SLOs?**
Yes. The Connector can pull specific threshold evaluation results for any run. You can ask your agent to check if your app met its latency or error rate goals for a specific test.

**How do I stop a test run using the Grafana k6 Cloud MCP?**
You can simply tell your agent to stop a running test. It will immediately abort the execution in k6 Cloud, which helps you manage your resources and costs instantly.

**Can I manage multiple k6 organizations with this Connector?**
Yes. The Connector includes tools to list and navigate between different organizations and projects. This makes it easy to manage complex, multi-tenant testing environments.

**How does the Grafana k6 Cloud MCP handle performance metrics?**
It pulls raw data like response durations, failure rates, and throughput directly from your runs. Your agent can then summarize this data into a plain English report for you.

**Can I use the Grafana k6 Cloud MCP to see my test history?**
Yes. You can ask your agent to list all recent runs for a specific test. It will provide details on statuses, VU counts, and durations for your previous executions.

**Will the Grafana k6 Cloud MCP help me save on cloud costs?**
It can help by allowing you to quickly identify and stop runaway or unnecessary test runs. Being able to abort tests via chat helps ensure you aren't wasting cloud credits.

**How do I start a new load test using the Grafana k6 Cloud MCP?**
Just tell your agent which test you want to run. It will trigger the new run in the k6 Cloud infrastructure and give you the new run ID and current status immediately.

**Can I see if a load test passed its performance thresholds using my agent?**
Yes. Use the `get_run_thresholds` tool with a specific Run ID. Your agent will retrieve the final evaluation for all defined thresholds in the script, indicating which specific SLOs passed or failed.

**How do I start a new k6 Cloud test run through a conversation?**
Use the `start_test_run` tool by providing the Test ID. Your agent will trigger the execution on k6 Cloud infrastructure and return an active Run ID that you can use to track real-time progress.

**Can my agent retrieve the raw performance metrics for a completed run?**
Absolutely. The `get_run_metrics` tool allows your agent to aggregate data like `http_req_duration`, error counts, and total iterations, providing a rapid summary of your application's behavior under load.