A random full name: {{$person.fullName}}
, results like Rachel Wheeler
An email address: {{$internet.email}}
, results like Arno.Huels33@yahoo.com
A product name: {{$commerce.productName}}
, results like Elegant Plastic Bike
Add multiple expectations with different conditions.
The mock engine matches incoming requests to these conditions (from top to bottom), returning the first matching expectation.
If no conditions match, Apidog falls back to the Mock method priority set in Project Settings > Feature Settings > Mock Settings.
An array of 20 user objects (id = 0 to 19)
Each with randomly generated "firstname" and "lastname"
A constant "success": true
{{$...}}
syntax invokes Faker.js to generate random values.
Nunjucks is used for loops ({% for ... %}
) and logic.
{{i}}
refers to a Nunjucks loop variable—not an Apidog variable.
Mix specific mock values with auto-generated data for flexibility.
Define full fixed, conditional, or dynamic responses for comprehensive test scenarios.
Leverage Faker.js and Nunjucks to create powerful, realistic, and variable mock data.
Simulate headers, delays, status codes, and more!