Rest Assured — URL encoding

When “RequestSpecification” for the HTTP request, you may forget to check URL encoding. That may affect the path you need to invoke.


You need to invoke:

By default, URL encoding enabled with RequestSpecification requests and will be the request as follows:

Hence disable URL encoding:

RestAssured.baseURI = "";RestAssured.urlEncodingEnabled = false;RequestSpecification httpRequest = RestAssured.given().
Response response = httpRequest.request(Method.GET);

Written by

Techie | Traveler | Writer

Get the Medium app

A button that says 'Download on the App Store', and if clicked it will lead you to the iOS App store
A button that says 'Get it on, Google Play', and if clicked it will lead you to the Google Play store