Katalon REST Service with query parameter date with blank value is not giving response.
1 . Katalon is giving response with valid date value in ‘yyyy-mm-dd’ in string format. But with blank value its giving error.
2. Katalon is giving response for other query parameters which are of string type in the backend, for both cases, like with and without values
3. Other Tools like Insnomia and Postman will work for the all query parameter combinations
3a- valid value and blank value in string format ‘yyyy-mm-dd’ for a field which is of date type in BE code
3b- valid value and blank value in string field which is of String type in BE code
Note: These values are used in a query to fetch matched row.
@huynguyen - The error code i am getting in case of blank value for dateOfBirth field is 400 bad request.
I have noticed that , this issue appearing when i test request at “Object Repository” level with sample values. But at test case level, where i am pulling data from another data source, this issue didn’t occurred. So its not a blocking issue, as i am anyway running from Testcase , Testsuite level.
@huynguyen - I have compared the har files for failed request for passed request. It seems query parameter is formatted (if query string has space inside, its formatted to + sign in my local har file), but the failed request in another machine has space and it failed, here is example endpoints values in har files. Is there any way i can externally format the query parameter to avoid this issue??
Local run which is passed:
“url” : “${endpoint}?firstName=Julia&lastName=Miller&dateOfBirth=2000-01-25&zip=30519&streetNumber=273&checkboxIdentityCheck=true&checkboxDataProtection=true&street=Hildesheimer+Weg”,
But at runtime url value is something like this and request failed:
“url” : “${endpoint}?firstName=Julia&lastName=Miller&dateOfBirth=2000-01-25&zip=30519&streetNumber=273&checkboxIdentityCheck=true&checkboxDataProtection=true&street=Hildesheimer Weg”,
Note: I replaced actual endpoint as ‘${endpoint}’ here , as i don’t wanted to share my endpoint url here and data values used here are dummy values.
My apologies for not updating. Project was on hold and I just re-started my automation for this project now. Now the request was format was changed hence this problem can’t be re-produced as the request itself was changed.