-2

As part API Automation using karate framework, I am trying to send 'form-data' as body in karate feature file.

Please provide your solution with following example attached.enter image description here

I tried to call the get method with body as form-data using karate framework feature file.

Feature: Get API Background:

  • def data = """

    { "name":"tom", "email":"tom110@gmail.com", "gender":"male", "status":"active" }

    """

Scenario: get Auth details Given url 'https://demo.domain.com/ea80952e/oauth2/token' And request data When method GET Then status 200

  • please read this: https://stackoverflow.com/help/how-to-ask -and if you read the documentation, you can save a lot of time: https://github.com/karatelabs/karate#form-field – Peter Thomas Oct 31 '22 at 08:02

1 Answers1

0

You can use form-data like this:

And multipart field client_id = 76t775e676