5

I'am trying to write unit tests for each one of my requests in insomnia. Is there a way to access the request in javascript and modify the body/query params? I want to test the different edge cases.

Are the insomnia js functions documented anywhere?

enter image description here

luffy
  • 2,246
  • 3
  • 22
  • 28
  • I was sneaking into the code from the Insomnia class and it has a activeEnvironmentId parameter but it's not used anywhere, if this parameter were used to make the api request would be possible to create a body based on the environment like in Postman do. https://www.postman.com/postman/workspace/postman-answers/documentation/9215231-b9133e48-73c3-4aa4-b189-e038ee4c5e00 – Andre Sampaio Feb 21 '22 at 16:46

0 Answers0