REST API

Loadmill's API is an interface for interacting with Loadmill’s servers. Use it to create and launch your tests.

Before getting started you’ll need to generate an API token, take a look how to generate it here

post
Run Test Suite

https://loadmill.com/api/v1/test-suites/:id/run
Run a predefined test suite
Request
Response
Request
Path Parameters
id
required
string
UUID of the Test Suite to run.
Headers
Authentication
required
string
Authentication token - you can generate it in the "User menu"> "Settings" > "Security".
Query Parameters
forceAllFlows
optional
boolean
Default = false - running only flows marked for execution with CI toggle. If true - executing all flows.
Body Parameters
additionalDescription
optional
string
Add an additional description at the end of the current suite's description
overrideParameters
optional
object
name: value pairs to override the default parameters values of this specific run. i.e. {{"paramName1":"paramVal1"}, ...}
Response
200: OK
Test suite has launched successfully.
{testSuiteRunId: "running-uuid"}

get
Get Test Suite Run (Test Suite results)

https://loadmill/com/api/v1/test-suites-runs/:id
Get a launched Test Suite results
Request
Response
Request
Path Parameters
id
required
string
The running uuid. You get this ID in the response when launching a Test Suite
Headers
Authentication
required
string
Authentication token - you can generate it in the "User menu"> "Settings" > "Security"
Response
200: OK
{
"id": "test suite run uuid,
"description": "test suite run description",
"startTime": timestamp,
"endTime": timestamp | null,
"conf": {
"useCookies": true
},
"status": "PASSED" | "FAILED" | "RUNNING",
"displayName": "Display name of the executing user",
"testSuiteId": "origin test suite uuid" | null (if deleted),
"testSuiteFlowRuns": [
{
"id": "test suite flow run uuid",
"startTime": timestamp,
"endTime": timestamp | null,
"conf": {}, // executed flow conf
"description": "Flow description",
"status": "PASSED" | "FAILED" | "RUNNING",
"numOfRequests": number of requests in this flow conf,
"avgResTime": 199, // in ms
"duration": "422 ms"
}
],
"progress": "1/1", // flows progress
"successRate": "100%", // flows success rate
"avgResTime": "422 ms"
}

get
Get Test Suite Flow Run

https://loadmill.com/api/v1/test-suites-runs/flows/:id
Get Test Suite Flow results
Request
Response
Request
Path Parameters
id
required
string
The flow running uuid. You get this ID when fetching the Test Suite Run entity
Headers
Authentication
required
string
Authentication token - you can generate it in the "User menu"> "Settings" > "Security"
Response
200: OK
{
"id": "test suite flow run uuid",
"description": "Flow description",
"conf": {...}, // the executed flow conf
"status": "PASSED" | "FAILED" | "RUNNING",
"startTime": timestamp,
"testSuiteFlowId": "origin test suite flow uuid" | null (if deleted),
"testSuiteId": "origin test suite uuid" | null (if deleted)
}

post
Create Load Test

https://loadmill.com/api/v1/tests
Create a load test from load test configuration
Request
Response
Request
Headers
Authentication
required
string
Authentication token - you can generate it in the "User menu"> "Settings" > "Security"
Body Parameters
config
required
object
A load test configuration. You can see a conf example here -> https://docs.loadmill.com/api-testing/test-suite-editor/parameters
Response
200: OK
{ testId: "load test id" }

put
Run Load Test

https://loadmill.com/api/v1/tests/:id/load
Run an existing load test. Be aware that a given load test can be run only once. In order to rerun it you will have to recreate it.
Request
Response
Request
Path Parameters
id
required
string
Load test ID
Headers
Authentication
required
string
Authentication token - you can generate it in the "User menu"> "Settings" > "Security"
Response
200: OK

get
Get Load Test

https://loadmill.com/api/v1/tests/:id
Returns the Load Test data. If the Load Test has ended it would contain its result.
Request
Response
Request
Path Parameters
id
required
string
Load test ID
Headers
Authentication
required
string
Authentication token - you can generate it in the "User menu"> "Settings" > "Security"
Response
200: OK
{
"id": "load test id",
"startTime": timestamp,
"endTime": timestamp,
"usedSeconds": "total seconds used by all sessions",
"description": "load description",
"conf": {}, // load test configuraion
"result": "aborted" | "done" | "failed",
"failedIterations": number,
"successfulIterations": number
}