Documentation

Here you'll find everything you need to use Loadsy

Create account

The first thing you will undoubtedly need is to create an account .

Loadsy Interface
CLI

Administration

Invite members to your team

To invite members to your team, go to:

Team > Users
In the Users section, click on the Create Invite button, an invitation link will be copied to your clipboard. Using that invitation link, the new member can create his account and automatically join your team.

Remove a member from your team

If you need to remove a user from the team, please contact loadsy support here.

Staff augmentation

If you need Load Test Engineers to write your scripts on your behalf, we can provide them for you. To request Load Test Engineers, go to:

Team > Users
In the Users section, click on the Create Invite button, an invitation link will be copied to your clipboard. Using that invitation link, the new member can create his account and automatically join your team.

Manage roles

If you want to update roles for the member within your team, go to:

Team > Users
In the Users section, find the user you want to update and select a new role from the dropdown.

Create tokens

If you want to allow users to run tests without having an account (for short periods) or you want to implement loadsy for your CI/CD integration, you can create a token that will grant permissions to the loadsy cli run command. To create a new token, go to:

Team > Tokens
In the Tokens section, click on the Create Tokenbutton, a modal will pop up where you can enter a description for the token. Click on create and a new token will be created. You can manually copy it or click on the Copy to clipboardbutton.

Delete tokens

If you no longer need a token, you can delete it. To delete a token, go to:

Team > Tokens
Find the token you want to delete and click on the Delete button. It will be removed and won’t grant access to the run command.

Billing

Add hours

You need to have hours to run tests over the free tier (max 512 threads and 30 seconds). If you need to add hours, go to:

Billing
In the Billing section, add your credit card as payment method and save it.
Once you added a payment method, click on the Add Hours button, a modal will pop up, specify the amount of hours that you want to add, then click on Pay. The hours will be automatically added to your team and will be ready to use!

See transactions

We have a record of every time you add hours to your team in case you need it. If you need to see your transactions, go to:

Billing
In the Billing section, at the bottom, there’s a table with your most recent transactions.

Projects

Create a project

A project will contain multiple scripts for the same purpose. You can create a project for a specific purpose like "accounts-service" or "prep-for-aug-21st".

Projects
In the Projects section, at the top right, there’s a button to Create Project. Specify a name and accept, project names must be unique.

Delete a project

If a project is not useful for you anymore, you can delete it.

Projects
In the Projects section, select the project that you want to delete. Then, in the Project Details section, there’s a button on the top right to Delete Project. Click on the button and confirm that you want to delete it. You can’t undo this action.

Create/Modify a script

You can write a script using any javascript code with native libraries.

Projects
In the Projects section, select the project that you want to work on. Then, in the Project Details section, there is a tab selector with three options: Overview, Files and Run Test. Select the Files tab and there you will find a code editor where you will be able to create, modify, and delete scripts.

Use the loadsy methods to make your http requests:

Copy
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
/*
* Headers must be an object where values are all strings.
* Body must be an object or a string.
* CallId is a unique identifier for you to find this specific call in the report.
It must be a static value.
*/
loadsy.get(url: string, headers: Record<string, string>, callId: string): ILoadsyResponse;
loadsy.post(url: string, headers: Record<string, string>, body: Record<string, any>, callId: string): ILoadsyResponse;
loadsy.put(url: string, headers: Record<string, string>, body: Record<string, any>, callId: string): ILoadsyResponse;
loadsy.options(url: string, headers: Record<string, string>, body: Record<string, any>, callId: string): ILoadsyResponse;
loadsy.patch(url: string, headers: Record<string, string>, body: Record<string, any>, callId: string): ILoadsyResponse;
loadsy.delete(url: string, headers: Record<string, string>, body: Record<string, any>, callId: string): ILoadsyResponse;
/*
Every request returns an ILoadsyResponse object which is defined by:
*/
interface ILoadsyResponse {
status: number;
headers: Record<string, string>;
body: string | Record<string, any>;
}

/* Loadsy has also 2 support methods */
loadsy.csv(fileName: string): Array<{ [key: string]: string }>;
/*
* Loads a csv file into an array of objects.
It reads the file from /resources inside your project folder.
*/
loadsy.sleep(milliseconds: number): void;
/*
*  Waits for the specified milliseconds.
*/

Global variables are:

  • env: Record<string, string>: Similar to process.env, contains all the environment variables parsed when used the -e flag
  • uuidv4(): string: Creates a unique id using the v4 of uuid
  • atob(data: string): string: Does base-64 decoding
  • btoa(data: string): string: Does base-64 encoding

Download files

If you don’t want to use our code editor anymore and want to handle your scripts using your local editor and the loadsy cli, you can download your files to continue your work anywhere else.

Projects
In the Projects section, select the project that you want to work on. Then, in the Project Details section, on the right top you will find a button to Download Project Files. Click on that button, confirm and you will get the project files compressed in a zip file.

Run a test

Running a test means executing your script file in our servers using as many threads as you want, each thread will be running your script asynchronously.

Projects
In the Projects section, select the project that you want to work on. Then, in the Project Details section, there is a tab selector with three options: Overview, Files and Run Test. Select the Run Test tab and there you will find a form with options to run your test. Real time resuls will be displayed in the terminal on the right so you can see it. At the end of the test, you can switch back to the Overview tab and select the test.

Options are:

  • Script Your script name (including path if it’s inside a folder)
  • Threads Define the number of threads, this means, how many concurrent threads will be executing your script during the test
  • Req. per second Define the number or requests per second
  • Rampup (s) Define the rampup time in seconds, this means, we will increase the load from 0 to desired within this time.
  • Duration (s) Define the duration of the test
  • Environment Define the environment file name, for example: production.env, development.env, etc. Any .env file where you store environment variables
  • Profile Define the profile name, used for the CI/CD integration
  • Req. per second threshold % Define the requests per second percentage threshold
  • Latency threshold % Define the latency percentage threshold
  • Include all If validating a threshold, it will include non 200 status on the validation. This value is false by default.

See results

To see the results of a test, go to:

Projects
Find the project you’re looking for and click on it. Find the load test you’re looking for and click on it. You can see the detailed information of a specific call by clicking the button in front of each call.