Best way of calling another API before the performance test


Is there any way of making a call to another API to get some data from it, which is needed in the calls for performance testing of my API?

To clarify, I need to make a GET request to https://api1/id to generate a valid id for my user, which he will use during the entire scenario. I need to do this thing for every user before starting to make calls to my API endpoints. My API is on a different domain, for example, https://api2/.

Thanks and have a nice day ahead!

You can use before() Hook
to run custom Code before Simulation start.

I was thinking about your case and create Example (without before() Hook) how you can do it:

I’m not sure if it’s optimal but it works :slight_smile:

You may also want to create your custom feeder.