This enables you to iterate through your requests using multiple sets of input values, without modifying your request parameters each time. Use this feature to test APIs with dynamic inputs, such as running the same workflow for multiple users, IDs, or configurations.
Using a Data File in Collection Runner
Follow these steps to run a collection with custom data:1
Open Collection Runner
In the Collections sidebar, find the collection you want to execute and click the Run icon next to it..png?fit=max&auto=format&n=Ann0jEECfxHAT9FZ&q=85&s=97f338c499c852e6a56a995da1655997)
.png?fit=max&auto=format&n=Ann0jEECfxHAT9FZ&q=85&s=97f338c499c852e6a56a995da1655997)
2
Select a Data File
In the Runner configuration panel, click Select Data File..png?fit=max&auto=format&n=Ann0jEECfxHAT9FZ&q=85&s=f51aee821fd18041ed97d202688af600)
Once added, Requestly will automatically detect the file type and preview its structure.
Supports JSON & CSV files (max 100MB)
.png?fit=max&auto=format&n=Ann0jEECfxHAT9FZ&q=85&s=f51aee821fd18041ed97d202688af600)
3
Preview Data and Map Variables
After selecting the file, a preview of your data will appear..png?fit=max&auto=format&n=Ann0jEECfxHAT9FZ&q=85&s=859991a0ec9d91ef9c67ad00d664dc5b)
- For CSV files: verify column names and types
- For JSON files: check object keys and structure
{{storyId}}..png?fit=max&auto=format&n=Ann0jEECfxHAT9FZ&q=85&s=859991a0ec9d91ef9c67ad00d664dc5b)
4
Start the Run
Click Save and then Start Run.
The Collection Runner will replace variables with data from your file for each iteration..png?fit=max&auto=format&n=Ann0jEECfxHAT9FZ&q=85&s=3ca18e5c047ee425c1fb561776c0aa35)
The Collection Runner will replace variables with data from your file for each iteration.
.png?fit=max&auto=format&n=Ann0jEECfxHAT9FZ&q=85&s=3ca18e5c047ee425c1fb561776c0aa35)
How Data Files Work
When you attach a CSV or JSON file to your manual run:- Each row (CSV) or object (JSON) represents one iteration
- Variables inside your requests (like
{{storyId}}) will be replaced with the corresponding values - Requestly automatically cycles through each data set until all iterations are complete
Supported File Formats
CSV Format
- The first row defines variable names
- Each subsequent row represents one iteration
- Each row must have the same number of columns
JSON Format
- Must be an array of key-value objects
- Each object defines one iteration
- A value can be text, a number, a boolean,
null, a nested object or an array
Nested values in JSON
A value in a JSON file can be a nested object or an array:- In a request,
{{name}}becomes an object’s or an array’s JSON text. With this file,{{user}}becomes{"name":"Ada"}and{{tags}}becomes["a","b"]. Anullvalue becomes empty text. - In a script,
rq.iterationDatareturns the value as it is written:rq.iterationData.get("user").nameis"Ada", andrq.iterationData.get("tags")is the array["a", "b"].
Example Use Case
For a request like{{city}} with each value during the run.
Accessing Data in Scripts
You can access data file values programmatically in your pre-request and post-response scripts using therq.iterationData object. This allows you to implement conditional logic, validate responses, or perform calculations based on the input data.
Example:

