Hi, I’m using K6 for API testing automation. I want to create a pre-setup k6 script that should call an API and write it’s response body in a separate file like JSON or CSV . Then I should read that JSON or CSV file in another k6 script.
I am able to read a JSON or CSV file but I couldn’t able to write a file.
Can someone help me with this issue, Where I can write the API’s response to JSON or CSV file? I don’t want the --console output command.
Welcome to the community forum
Have you tried the extension GitHub - avitalique/xk6-file: k6 extension for writing files?
Cheers!