First thing u need to check is the Rest service whether they respect the param u are passing and giving expected results.Do it using postman.
Once you get the param workig in postman u can mimick the same in mendix,and then put a debugger in the code to check what is the output/input etc.
also u can enable the trace debug option on RestConsume log which will print the rest logs like url body response etc to logs
this will make the debugging life easy.