AI Assistant
Generate production-ready load test scripts using natural language descriptions. The AI creates complete k6 scripts with realistic payloads, validation logic, and performance thresholds.
Using the AI Assistant
Step 1: Activate AI Generation
Click Create Test and select Build with AI, or click the AI icon from anywhere in the test creation interface.
![]() |
|---|
Step 2: Describe Your Test Scenario
Enter a clear description of your test requirements (up to 5,000 characters).
![]() |
|---|
Include key details:
- Target endpoint and HTTP method
- Load pattern (VUs, requests per second, duration)
- Authentication requirements
- Expected payloads and parameters
Example prompt:
Test a REST API at /api/products with GET requests, 100 concurrent users for 5 minutes.
The API requires Bearer token authentication and should respond within 200ms for 95% of requests.
Step 3: Review Generated Code
The AI generates a complete k6 script within 5-15 seconds.
![]() |
|---|
Review options:
- Accept Code - Load script into editor and proceed
- Reject - Discard and refine your prompt
- Copy - Copy script to clipboard
Step 4: Refine and Execute
After accepting, the script loads into Script Editor for customization. Adjust parameters, add validation checks, or configure execution options before running.
Writing Effective Prompts
Be specific:
- Vague: "Test my API"
- Better: "Test my REST API at /api/products with GET requests, 100 concurrent users, for 5 minutes"
Describe user flows for multi-step tests:
Simulate users who login, search for products, add items to cart, and complete checkout.
Include realistic think times between actions.
Specify performance expectations:
Response time should be under 200ms for 95% of requests with zero errors.


