locust-mcp-server logo

locust-mcp-server

by QAInsights

A Model Context Protocol (MCP) server implementation for running Locust load tests. This server enables seamless integration of Locust load testing capabilities with AI-powered development environments.

View on GitHub

Last updated: N/A

What is locust-mcp-server?

The locust-mcp-server is an implementation of a Model Context Protocol (MCP) server designed to facilitate Locust load testing. It allows you to integrate Locust with AI-powered development environments, enabling you to run and manage load tests through an MCP client.

How to use locust-mcp-server?

To use the locust-mcp-server, first clone the repository and install the dependencies using uv pip install -r requirements.txt. Then, configure the MCP server in your client with the provided JSON specs, pointing to the locust_server.py file. Finally, use your LLM to trigger the tests using commands like run locust test for hello.py.

Key features of locust-mcp-server

  • Simple integration with Model Context Protocol framework

  • Support for headless and UI modes

  • Configurable test parameters (users, spawn rate, runtime)

  • Easy-to-use API for running Locust load tests

  • Real-time test execution output

  • HTTP/HTTPS protocol support out of the box

  • Custom task scenarios support

Use cases of locust-mcp-server

  • LLM powered results analysis

  • Effective debugging with the help of LLM

  • Automated load testing within AI development environments

  • Integrating load testing into CI/CD pipelines using AI agents

FAQ from locust-mcp-server

What is Locust?

Locust is an open-source load testing tool written in Python.

What is MCP?

MCP stands for Model Context Protocol, a framework for integrating tools with AI-powered development environments.

What Python version is required?

Python 3.13 or higher is required.

How do I run a Locust test?

Use the run_locust function with the path to your test file and desired parameters.

Can I run the tests in headless mode?

Yes, you can run the tests in headless mode by setting the headless parameter to True.