Library

Use rampa as a Python library to build, configure, and run load tests programmatically.

Save this as example.py. The PEP 723 inline-metadata header declares rampa as a dependency, so uv resolves and runs the script in an ephemeral environment:

# /// script
# requires-python = ">=3.14"
# dependencies = [
#   "rampa",
# ]
# ///

import asyncio
import rampa


@rampa.scenario(executor="constant-vus", vus=5, duration="10s")
async def default(worker: rampa.Worker) -> None:
    resp = await worker.http.get("https://httpbin.org/get")
    worker.check(resp, {"status is 200": lambda r: r.status == 200})

Then run it:

$ uv run load_test.py
Tutorial

Write your first scenario, add checks and thresholds.

Tutorial
Executors

Choose the right scheduling model for your test.

Executors
Metrics

Built-in metrics, custom metrics, and the metric pipeline.

Metrics
Thresholds

Expression syntax and pass/fail evaluation.

Thresholds
Outputs

Send results to CSV, InfluxDB, Prometheus, OTEL, and more.

Output backends
TUI Dashboard

Live terminal dashboard with metrics, timing, and thresholds.

TUI dashboard
Protocols

HTTP, WebSocket, gRPC, and custom protocol clients.

Protocol clients
Distributed

Split tests across machines with execution segments.

Distributed execution
CI Integration

GitHub Actions, result comparison, and benchmarking.

CI integration
API Reference

Public API: Engine, RunController, Worker, Config.

API Reference