The Legacy REST API is no longer under active development. It should not be used except when it provides capabilities not yet offered by the Grafana Cloud k6 REST API.
A load test run is an individual execution of a load test.
Every test run has an ID, held in an array of test_run_ids in the k6-test object.
Start load test run
Starts a test run in the cloud for the specified Load Test ID.
Note
Note that this endpoint uses the /v2/tests/ base URL rather than /v2/runs. It also needs to be provided with a Load Test {id}. This is because
this endpoint makes use of the data from the provided Load Test to create and return a new Load Test Run.
The test run is managed by the cloud from beginning to end.
You can monitor the test progress in the cloud application.
From there, you can also export and analyze the result.
{"k6-run":{"config":{},"created":"2020-08-18T13:33:41","duration":120,"ended":"2020-08-18T13:36:02","error_code":null,"error_detail":null,"export":null,"id":0,"is_baseline":false,"k6_archive":"string","load_time":75.0,"note":"","organization_id":0,"processing_status":2,"project_id":0,"public_id":null,"request_builder_config":null,"result_status":1,"run_process":"k6 to Cloud","run_status":3,"script":"","started":"2020-08-18T13:34:04","stopped_by_id":0,"test_id":0,"user_id":0,"version":2,"vus":200,"vus_per_instance":0}}
{"k6-runs":[{"config":{},"created":"2020-08-18T13:33:41","duration":120,"ended":"2020-08-18T13:36:02","error_code":null,"error_detail":null,"id":0,"is_baseline":false,"k6_archive":"string","load_time":75.0,"note":"","organization_id":0,"processing_status":2,"project_id":0,"public_id":null,"request_builder_config":null,"result_status":1,"run_process":"k6 to Cloud","run_status":3,"script":"","started":"2020-08-18T13:34:04","stopped_by_id":0,"test_id":0,"user_id":0,"version":2,"vus":200,"vus_per_instance":0}],"meta":{"count":1}}
Stop load test run
Manually stops a load test run. If you follow along in the app, the test-run will be marked as Aborted (by User). Note that can take a few moments
before the test actually stops as the processor shuts down.