1

I want to make my karate framework modular. I have some api's calls and want to make sure that these calls are independent for reusability. And call them via another js functions.

Is this possible in karate?

Example: function(payload){

GenerateSms(payload); }

Tried different approaches of calling js functions from one file to another but it's not possible.

1 Answers1

0

Karate can do this but I strongly do not recommend this for reasons given here: https://stackoverflow.com/a/54126724/143475

Karate is ALREADY a framework for you to make HTTP calls efficiently. That said, you CAN modularize things like auth headers and data "setup". All that is explained in the documentation.

Peter Thomas
  • 54,465
  • 21
  • 84
  • 248