I am using the path keyword from Karate API framework to concatenate strings to form a url. However, I am not able to pass '?'. Here is what I am doing:
Background:
* url 'https://api.cloud.abcde.com/animal/'
Scenario: Verify the get status
Given path 'herbivore?id=25'
When method get
Then status 200
When I run the test, i see the '?' being passed as %3F. I tried to escape it using \ and tried some other answers too but couldn't succeed. Do I need to use url encoding ? Any pointers or help would be appreciated. Thanks
You should use
param
for this case: